00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040 #ifndef _STRING_H_
00041 #define _STRING_H_ 1
00042
00043 #define __need_NULL
00044 #define __need_size_t
00045 #include <stddef.h>
00046
00047 #ifndef __ATTR_PURE__
00048 #define __ATTR_PURE__ __attribute__((__pure__))
00049 #endif
00050
00051 #ifndef __ATTR_CONST__
00052 # define __ATTR_CONST__ __attribute__((__const__))
00053 #endif
00054
00055 #ifdef __cplusplus
00056 extern "C" {
00057 #endif
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088 #if defined(__DOXYGEN__)
00089 #define _FFS(x)
00090 #else
00091 #define _FFS(x) \
00092 (1 \
00093 + (((x) & 1) == 0) \
00094 + (((x) & 3) == 0) \
00095 + (((x) & 7) == 0) \
00096 + (((x) & 017) == 0) \
00097 + (((x) & 037) == 0) \
00098 + (((x) & 077) == 0) \
00099 + (((x) & 0177) == 0) \
00100 + (((x) & 0377) == 0) \
00101 + (((x) & 0777) == 0) \
00102 + (((x) & 01777) == 0) \
00103 + (((x) & 03777) == 0) \
00104 + (((x) & 07777) == 0) \
00105 + (((x) & 017777) == 0) \
00106 + (((x) & 037777) == 0) \
00107 + (((x) & 077777) == 0) \
00108 - (((x) & 0177777) == 0) * 16)
00109 #endif
00110
00111 extern int ffs (int __val) __ATTR_CONST__;
00112 extern int ffsl (long __val) __ATTR_CONST__;
00113 extern int ffsll (long long __val) __ATTR_CONST__;
00114 extern void *memccpy(void *, const void *, int, size_t);
00115 extern void *memchr(const void *, int, size_t) __ATTR_PURE__;
00116 extern int memcmp(const void *, const void *, size_t) __ATTR_PURE__;
00117 extern void *memcpy(void *, const void *, size_t);
00118 extern void *memmem(const void *, size_t, const void *, size_t) __ATTR_PURE__;
00119 extern void *memmove(void *, const void *, size_t);
00120 extern void *memrchr(const void *, int, size_t) __ATTR_PURE__;
00121 extern void *memset(void *, int, size_t);
00122 extern char *strcat(char *, const char *);
00123 extern char *strchr(const char *, int) __ATTR_PURE__;
00124 extern char *strchrnul(const char *, int) __ATTR_PURE__;
00125 extern int strcmp(const char *, const char *) __ATTR_PURE__;
00126 extern char *strcpy(char *, const char *);
00127 extern int strcasecmp(const char *, const char *) __ATTR_PURE__;
00128 extern char *strcasestr(const char *, const char *) __ATTR_PURE__;
00129 extern size_t strcspn(const char *__s, const char *__reject) __ATTR_PURE__;
00130 extern char *strdup(const char *s1);
00131 extern size_t strlcat(char *, const char *, size_t);
00132 extern size_t strlcpy(char *, const char *, size_t);
00133 extern size_t strlen(const char *) __ATTR_PURE__;
00134 extern char *strlwr(char *);
00135 extern char *strncat(char *, const char *, size_t);
00136 extern int strncmp(const char *, const char *, size_t) __ATTR_PURE__;
00137 extern char *strncpy(char *, const char *, size_t);
00138 extern int strncasecmp(const char *, const char *, size_t) __ATTR_PURE__;
00139 extern size_t strnlen(const char *, size_t) __ATTR_PURE__;
00140 extern char *strpbrk(const char *__s, const char *__accept) __ATTR_PURE__;
00141 extern char *strrchr(const char *, int) __ATTR_PURE__;
00142 extern char *strrev(char *);
00143 extern char *strsep(char **, const char *);
00144 extern size_t strspn(const char *__s, const char *__accept) __ATTR_PURE__;
00145 extern char *strstr(const char *, const char *) __ATTR_PURE__;
00146 extern char *strtok(char *, const char *);
00147 extern char *strtok_r(char *, const char *, char **);
00148 extern char *strupr(char *);
00149
00150 #ifdef __cplusplus
00151 }
00152 #endif
00153
00154 #endif
00155