prototype for mempcpy
[musl] / include / string.h
1 #ifndef _STRING_H
2 #define _STRING_H
3
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7
8 #undef NULL
9 #ifdef __cplusplus
10 #define NULL 0
11 #else
12 #define NULL ((void*)0)
13 #endif
14
15 #define __NEED_size_t
16 #include <bits/alltypes.h>
17
18 void *memcpy (void *, const void *, size_t);
19 void *memmove (void *, const void *, size_t);
20 void *memset (void *, int, size_t);
21 int memcmp (const void *, const void *, size_t);
22 void *memchr (const void *, int, size_t);
23
24 char *strcpy (char *, const char *);
25 char *strncpy (char *, const char *, size_t);
26
27 char *strcat (char *, const char *);
28 char *strncat (char *, const char *, size_t);
29
30 int strcmp (const char *, const char *);
31 int strncmp (const char *, const char *, size_t);
32
33 int strcoll (const char *, const char *);
34 size_t strxfrm (char *, const char *, size_t);
35
36 char *strchr (const char *, int);
37 char *strrchr (const char *, int);
38
39 size_t strcspn (const char *, const char *);
40 size_t strspn (const char *, const char *);
41 char *strpbrk (const char *, const char *);
42 char *strstr (const char *, const char *);
43 char *strtok (char *, const char *);
44
45 size_t strlen (const char *);
46
47 char *strerror (int);
48
49
50 #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
51  || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE)
52 char *strtok_r (char *, const char *, char **);
53 int strerror_r (int, char *, size_t);
54 char *stpcpy(char *, const char *);
55 char *stpncpy(char *, const char *, size_t);
56 size_t strnlen (const char *, size_t);
57 char *strdup (const char *);
58 char *strndup (const char *, size_t);
59 char *strsignal(int);
60 #endif
61
62 #if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE)
63 void *memccpy (void *, const void *, int, size_t);
64 #endif
65
66 #ifdef _BSD_SOURCE
67 size_t strlcat (char *, const char *, size_t);
68 size_t strlcpy (char *, const char *, size_t);
69 #endif
70
71 #ifdef _GNU_SOURCE
72 int strcasecmp (const char *, const char *);
73 int strncasecmp (const char *, const char *, size_t);
74 char *strchrnul(const char *, int);
75 char *strcasestr(const char *, const char *);
76 char *strsep(char **, const char *);
77 void *memrchr(const void *, int, size_t);
78 void *mempcpy(void *, void *, size_t)
79 #endif
80
81 #ifdef __cplusplus
82 }
83 #endif
84
85 #endif