OSDN Git Service

Angband 3.0.0から、my_strcpy()を移植('\0'をちゃんと付けるstrncpy()のようなもの)
[hengband/hengband.git] / src / z-util.h
1 /* File z-util.h */
2
3 #ifndef INCLUDED_Z_UTIL_H
4 #define INCLUDED_Z_UTIL_H
5
6 #include "h-basic.h"
7
8
9 /*
10  * Extremely basic stuff, like global temp and constant variables.
11  * Also, some very useful low level functions, such as "streq()".
12  * All variables and functions in this file are "addressable".
13  */
14
15
16 /**** Available variables ****/
17
18 /* A cptr to the name of the program */
19 extern cptr argv0;
20
21
22 /* Aux functions */
23 extern void (*plog_aux)(cptr);
24 extern void (*quit_aux)(cptr);
25 extern void (*core_aux)(cptr);
26
27
28 /**** Available Functions ****/
29
30 /* Test equality, prefix, suffix */
31 extern bool streq(cptr s, cptr t);
32 extern bool prefix(cptr s, cptr t);
33 extern bool suffix(cptr s, cptr t);
34
35
36 /* Print an error message */
37 extern void plog(cptr str);
38
39 /* Exit, with optional message */
40 extern void quit(cptr str);
41
42 /* Dump core, with optional message */
43 extern void core(cptr str);
44
45
46
47 #endif
48