1 /* CC0 (Public domain) - see LICENSE file for details */
3 #include <ccan/str/str_debug.h>
9 /* Because we mug the real ones with macros, we need our own wrappers. */
10 int str_isalnum(int i)
12 assert(i >= -1 && i < 256);
16 int str_isalpha(int i)
18 assert(i >= -1 && i < 256);
22 int str_isascii(int i)
24 assert(i >= -1 && i < 256);
29 int str_isblank(int i)
31 assert(i >= -1 && i < 256);
36 int str_iscntrl(int i)
38 assert(i >= -1 && i < 256);
42 int str_isdigit(int i)
44 assert(i >= -1 && i < 256);
48 int str_isgraph(int i)
50 assert(i >= -1 && i < 256);
54 int str_islower(int i)
56 assert(i >= -1 && i < 256);
60 int str_isprint(int i)
62 assert(i >= -1 && i < 256);
66 int str_ispunct(int i)
68 assert(i >= -1 && i < 256);
72 int str_isspace(int i)
74 assert(i >= -1 && i < 256);
78 int str_isupper(int i)
80 assert(i >= -1 && i < 256);
84 int str_isxdigit(int i)
86 assert(i >= -1 && i < 256);
94 char *str_strstr(const char *haystack, const char *needle)
96 return strstr(haystack, needle);
99 char *str_strchr(const char *haystack, int c)
101 return strchr(haystack, c);
104 char *str_strrchr(const char *haystack, int c)
106 return strrchr(haystack, c);