summaryrefslogtreecommitdiff
path: root/src/z-util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/z-util.h')
-rw-r--r--src/z-util.h70
1 files changed, 10 insertions, 60 deletions
diff --git a/src/z-util.h b/src/z-util.h
index 11dbdb4e..d2fa79dc 100644
--- a/src/z-util.h
+++ b/src/z-util.h
@@ -1,7 +1,4 @@
-/* File z-util.h */
-
-#ifndef INCLUDED_Z_UTIL_H
-#define INCLUDED_Z_UTIL_H
+#pragma once
#ifdef __cplusplus
extern "C" {
@@ -11,81 +8,34 @@ extern "C" {
/*
- * Extremely basic stuff, like global temp and constant variables.
- * Also, some very useful low level functions, such as "streq()".
- * All variables and functions in this file are "addressable".
+ * Extremely basic stuff, like "streq()".
*/
-/**** Available variables ****/
-
-/* Temporary Vars */
-extern char char_tmp;
-extern byte byte_tmp;
-extern sint sint_tmp;
-extern uint uint_tmp;
-extern long long_tmp;
-extern huge huge_tmp;
-extern errr errr_tmp;
-
-/* Temporary Pointers */
-extern cptr cptr_tmp;
-extern vptr vptr_tmp;
-
-
-/* Constant pointers (NULL) */
-extern cptr cptr_null;
-extern vptr vptr_null;
-
-
-/* A bizarre vptr that always points at itself */
-extern vptr vptr_self;
-
-
-/* A cptr to the name of the program */
-extern cptr argv0;
-
-
/* Aux functions */
extern void (*plog_aux)(cptr);
extern void (*quit_aux)(cptr);
-extern void (*core_aux)(cptr);
/**** Available Functions ****/
-/* Function that does nothing */
-extern void func_nothing(void);
-
-/* Functions that return basic "errr" codes */
-extern errr func_success(void);
-extern errr func_problem(void);
-extern errr func_failure(void);
-
-/* Functions that return bools */
-extern bool_ func_true(void);
-extern bool_ func_false(void);
-
/* Test equality, prefix, suffix */
-extern bool_ streq(cptr s, cptr t);
-extern bool_ prefix(cptr s, cptr t);
-extern bool_ suffix(cptr s, cptr t);
+bool_ streq(cptr s, cptr t);
+bool_ prefix(cptr s, cptr t);
+bool_ suffix(cptr s, cptr t);
+
+/* Capitalize the first letter of string. Ignores whitespace at the start of string. */
+void capitalize(char *s);
/* Print an error message */
-extern void plog(cptr str);
+void plog(cptr str);
/* Exit, with optional message */
-extern void quit(cptr str);
-
-/* Dump core, with optional message */
-extern void core(cptr str);
-
+void quit(cptr str);
#ifdef __cplusplus
} /* extern "C" */
#endif
-
-#endif