11 #define __NEED___isoc_va_list
13 #define __NEED_wchar_t
16 #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
17 || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
18 #define __NEED_locale_t
19 #define __NEED_va_list
22 #if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
23 #define __NEED_wctype_t
26 #include <bits/alltypes.h>
29 #define WCHAR_MAX (0xffffffffu+L'\0')
30 #define WCHAR_MIN (0+L'\0')
32 #define WCHAR_MAX (0x7fffffff+L'\0')
33 #define WCHAR_MIN (-1-0x7fffffff+L'\0')
39 #define NULL ((void*)0)
43 #define WEOF 0xffffffffU
45 typedef struct __mbstate_t
47 unsigned __opaque1, __opaque2;
50 wchar_t *wcscpy (wchar_t *__restrict, const wchar_t *__restrict);
51 wchar_t *wcsncpy (wchar_t *__restrict, const wchar_t *__restrict, size_t);
53 wchar_t *wcscat (wchar_t *__restrict, const wchar_t *__restrict);
54 wchar_t *wcsncat (wchar_t *__restrict, const wchar_t *__restrict, size_t);
56 int wcscmp (const wchar_t *, const wchar_t *);
57 int wcsncmp (const wchar_t *, const wchar_t *, size_t);
59 int wcscoll(const wchar_t *, const wchar_t *);
60 size_t wcsxfrm (wchar_t *__restrict, const wchar_t *__restrict, size_t n);
62 wchar_t *wcschr (const wchar_t *, wchar_t);
63 wchar_t *wcsrchr (const wchar_t *, wchar_t);
65 size_t wcscspn (const wchar_t *, const wchar_t *);
66 size_t wcsspn (const wchar_t *, const wchar_t *);
67 wchar_t *wcspbrk (const wchar_t *, const wchar_t *);
69 wchar_t *wcstok (wchar_t *__restrict, const wchar_t *__restrict, wchar_t **__restrict);
71 size_t wcslen (const wchar_t *);
73 wchar_t *wcsstr (const wchar_t *__restrict, const wchar_t *__restrict);
74 wchar_t *wcswcs (const wchar_t *, const wchar_t *);
76 wchar_t *wmemchr (const wchar_t *, wchar_t, size_t);
77 int wmemcmp (const wchar_t *, const wchar_t *, size_t);
78 wchar_t *wmemcpy (wchar_t *__restrict, const wchar_t *__restrict, size_t);
79 wchar_t *wmemmove (wchar_t *, const wchar_t *, size_t);
80 wchar_t *wmemset (wchar_t *, wchar_t, size_t);
85 int mbsinit (const mbstate_t *);
86 size_t mbrtowc (wchar_t *__restrict, const char *__restrict, size_t, mbstate_t *__restrict);
87 size_t wcrtomb (char *__restrict, wchar_t, mbstate_t *__restrict);
89 size_t mbrlen (const char *__restrict, size_t, mbstate_t *__restrict);
91 size_t mbsrtowcs (wchar_t *__restrict, const char **__restrict, size_t, mbstate_t *__restrict);
92 size_t wcsrtombs (char *__restrict, const wchar_t **__restrict, size_t, mbstate_t *__restrict);
94 float wcstof (const wchar_t *__restrict, wchar_t **__restrict);
95 double wcstod (const wchar_t *__restrict, wchar_t **__restrict);
96 long double wcstold (const wchar_t *__restrict, wchar_t **__restrict);
98 long wcstol (const wchar_t *__restrict, wchar_t **__restrict, int);
99 unsigned long wcstoul (const wchar_t *__restrict, wchar_t **__restrict, int);
101 long long wcstoll (const wchar_t *__restrict, wchar_t **__restrict, int);
102 unsigned long long wcstoull (const wchar_t *__restrict, wchar_t **__restrict, int);
106 int fwide (FILE *, int);
109 int wprintf (const wchar_t *__restrict, ...);
110 int fwprintf (FILE *__restrict, const wchar_t *__restrict, ...);
111 int swprintf (wchar_t *__restrict, size_t, const wchar_t *__restrict, ...);
113 int vwprintf (const wchar_t *__restrict, __isoc_va_list);
114 int vfwprintf (FILE *__restrict, const wchar_t *__restrict, __isoc_va_list);
115 int vswprintf (wchar_t *__restrict, size_t, const wchar_t *__restrict, __isoc_va_list);
117 int wscanf (const wchar_t *__restrict, ...);
118 int fwscanf (FILE *__restrict, const wchar_t *__restrict, ...);
119 int swscanf (const wchar_t *__restrict, const wchar_t *__restrict, ...);
121 int vwscanf (const wchar_t *__restrict, __isoc_va_list);
122 int vfwscanf (FILE *__restrict, const wchar_t *__restrict, __isoc_va_list);
123 int vswscanf (const wchar_t *__restrict, const wchar_t *__restrict, __isoc_va_list);
125 wint_t fgetwc (FILE *);
126 wint_t getwc (FILE *);
127 wint_t getwchar (void);
129 wint_t fputwc (wchar_t, FILE *);
130 wint_t putwc (wchar_t, FILE *);
131 wint_t putwchar (wchar_t);
133 wchar_t *fgetws (wchar_t *__restrict, int, FILE *__restrict);
134 int fputws (const wchar_t *__restrict, FILE *__restrict);
136 wint_t ungetwc (wint_t, FILE *);
139 size_t wcsftime (wchar_t *__restrict, size_t, const wchar_t *__restrict, const struct tm *__restrict);
143 #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
144 || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
145 FILE *open_wmemstream(wchar_t **, size_t *);
146 size_t mbsnrtowcs(wchar_t *__restrict, const char **__restrict, size_t, size_t, mbstate_t *__restrict);
147 size_t wcsnrtombs(char *__restrict, const wchar_t **__restrict, size_t, size_t, mbstate_t *__restrict);
148 wchar_t *wcsdup(const wchar_t *);
149 size_t wcsnlen (const wchar_t *, size_t);
150 wchar_t *wcpcpy (wchar_t *__restrict, const wchar_t *__restrict);
151 wchar_t *wcpncpy (wchar_t *__restrict, const wchar_t *__restrict, size_t);
152 int wcscasecmp(const wchar_t *, const wchar_t *);
153 int wcscasecmp_l(const wchar_t *, const wchar_t *, locale_t);
154 int wcsncasecmp(const wchar_t *, const wchar_t *, size_t);
155 int wcsncasecmp_l(const wchar_t *, const wchar_t *, size_t, locale_t);
156 int wcscoll_l(const wchar_t *, const wchar_t *, locale_t);
157 size_t wcsxfrm_l(wchar_t *__restrict, const wchar_t *__restrict, size_t n, locale_t);
160 #if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
161 int wcwidth (wchar_t);
162 int wcswidth (const wchar_t *, size_t);
163 int iswalnum(wint_t);
164 int iswalpha(wint_t);
165 int iswblank(wint_t);
166 int iswcntrl(wint_t);
167 int iswdigit(wint_t);
168 int iswgraph(wint_t);
169 int iswlower(wint_t);
170 int iswprint(wint_t);
171 int iswpunct(wint_t);
172 int iswspace(wint_t);
173 int iswupper(wint_t);
174 int iswxdigit(wint_t);
175 int iswctype(wint_t, wctype_t);
176 wint_t towlower(wint_t);
177 wint_t towupper(wint_t);
178 wctype_t wctype(const char *);
180 #define iswdigit(a) ((unsigned)(a)-'0' < 10)