include: Add wmemchr to wchar.h.

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Alex Henrie 2018-05-27 21:05:52 -06:00 committed by Alexandre Julliard
parent 7715a1aaef
commit e1bfd4b4cb
1 changed files with 8 additions and 0 deletions

View File

@ -476,6 +476,14 @@ size_t __cdecl wcrtomb(char*,wchar_t,mbstate_t*);
size_t __cdecl wcsrtombs(char*,const wchar_t**,size_t,mbstate_t*); size_t __cdecl wcsrtombs(char*,const wchar_t**,size_t,mbstate_t*);
int __cdecl wctob(wint_t); int __cdecl wctob(wint_t);
static inline wchar_t *wmemchr(const wchar_t *s, wchar_t c, size_t n)
{
const wchar_t *end;
for (end = s + n; s < end; s++)
if (*s == c) return (wchar_t*)s;
return NULL;
}
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif