summaryrefslogtreecommitdiff
path: root/src/z-util.h
blob: 914a64e76271a4bad6d8ecb9d8f7f13c2014685a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#pragma once

#ifdef __cplusplus
extern "C" {
#endif

#include "h-basic.h"


/*
 * Extremely basic stuff, like "streq()".
 */


/* Aux functions */
extern void (*plog_aux)(cptr);
extern void (*quit_aux)(cptr);


/**** Available Functions ****/


/* 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);


/* Capitalize the first letter of string. Ignores whitespace at the start of string. */
extern void capitalize(char *s);

/* Print an error message */
extern void plog(cptr str);

/* Exit, with optional message */
extern void quit(cptr str);


#ifdef __cplusplus
} /* extern "C" */
#endif