4 * Derived from the mingw header written by Colin Peters.
5 * Modified for Wine use by Jon Griffiths and Francois Gouget.
6 * This file is in the public domain.
8 #ifndef __WINE_STRING_H
9 #define __WINE_STRING_H
11 #include <corecrt_wstring.h>
13 #ifndef _NLSCMP_DEFINED
14 #define _NLSCMPERROR ((unsigned int)0x7fffffff)
15 #define _NLSCMP_DEFINED
22 _ACRTIMP
size_t __cdecl
__strncnt(const char*,size_t);
23 _ACRTIMP
int __cdecl
_strcmpi(const char*,const char*);
24 _ACRTIMP
int __cdecl
_strcoll_l(const char*, const char*, _locale_t
);
25 _ACRTIMP
char* __cdecl
_strdup(const char*);
26 _ACRTIMP
char* __cdecl
_strerror(const char*);
27 _ACRTIMP errno_t __cdecl
strerror_s(char*,size_t,int);
28 _ACRTIMP
int __cdecl
_stricmp(const char*,const char*);
29 _ACRTIMP
int __cdecl
_stricoll(const char*,const char*);
30 _ACRTIMP
int __cdecl
_stricoll_l(const char*, const char*, _locale_t
);
31 _ACRTIMP
char* __cdecl
_strlwr(char*);
32 _ACRTIMP errno_t __cdecl
_strlwr_s(char*,size_t);
33 _ACRTIMP
int __cdecl
_strncoll(const char*, const char*, size_t);
34 _ACRTIMP
int __cdecl
_strncoll_l(const char*, const char*, size_t, _locale_t
);
35 _ACRTIMP
int __cdecl
_strnicmp(const char*,const char*,size_t);
36 _ACRTIMP
int __cdecl
_strnicoll(const char*, const char*, size_t);
37 _ACRTIMP
int __cdecl
_strnicoll_l(const char*, const char*, size_t, _locale_t
);
38 _ACRTIMP
char* __cdecl
_strnset(char*,int,size_t);
39 _ACRTIMP
char* __cdecl
_strrev(char*);
40 _ACRTIMP
char* __cdecl
_strset(char*,int);
41 _ACRTIMP
char* __cdecl
_strupr(char*);
42 _ACRTIMP errno_t __cdecl
_strupr_s(char *, size_t);
43 _ACRTIMP
size_t __cdecl
_strxfrm_l(char*,const char*,size_t,_locale_t
);
45 _ACRTIMP errno_t __cdecl
memmove_s(void*,size_t,const void*,size_t);
46 _ACRTIMP
char* __cdecl
strcat(char*,const char*);
47 _ACRTIMP errno_t __cdecl
strcat_s(char*,size_t,const char*);
48 _ACRTIMP
char* __cdecl
strchr(const char*,int);
49 _ACRTIMP
int __cdecl
strcmp(const char*,const char*);
50 _ACRTIMP
int __cdecl
strcoll(const char*,const char*);
51 _ACRTIMP
char* __cdecl
strcpy(char*,const char*);
52 _ACRTIMP errno_t __cdecl
strcpy_s(char*,size_t,const char*);
53 _ACRTIMP
size_t __cdecl
strcspn(const char*,const char*);
54 _ACRTIMP
char* __cdecl
strerror(int);
55 _ACRTIMP
size_t __cdecl
strlen(const char*);
56 _ACRTIMP
char* __cdecl
strncat(char*,const char*,size_t);
57 _ACRTIMP errno_t __cdecl
strncat_s(char*,size_t,const char*,size_t);
58 _ACRTIMP
int __cdecl
strncmp(const char*,const char*,size_t);
59 _ACRTIMP
char* __cdecl
strncpy(char*,const char*,size_t);
60 _ACRTIMP errno_t __cdecl
strncpy_s(char*,size_t,const char*,size_t);
61 _ACRTIMP
size_t __cdecl
strnlen(const char*,size_t);
62 _ACRTIMP
char* __cdecl
strpbrk(const char*,const char*);
63 _ACRTIMP
char* __cdecl
strrchr(const char*,int);
64 _ACRTIMP
size_t __cdecl
strspn(const char*,const char*);
65 _ACRTIMP
char* __cdecl
strstr(const char*,const char*);
66 _ACRTIMP
char* __cdecl
strtok(char*,const char*);
67 _ACRTIMP
char* __cdecl
strtok_s(char*,const char*,char**);
68 _ACRTIMP
size_t __cdecl
strxfrm(char*,const char*,size_t);
75 static inline int strcasecmp(const char* s1
, const char* s2
) { return _stricmp(s1
, s2
); }
76 static inline int strcmpi(const char* s1
, const char* s2
) { return _strcmpi(s1
, s2
); }
77 static inline char* strdup(const char* buf
) { return _strdup(buf
); }
78 static inline int stricmp(const char* s1
, const char* s2
) { return _stricmp(s1
, s2
); }
79 static inline int stricoll(const char* s1
, const char* s2
) { return _stricoll(s1
, s2
); }
80 static inline char* strlwr(char* str
) { return _strlwr(str
); }
81 static inline int strncasecmp(const char *str1
, const char *str2
, size_t n
) { return _strnicmp(str1
, str2
, n
); }
82 static inline int strnicmp(const char* s1
, const char* s2
, size_t n
) { return _strnicmp(s1
, s2
, n
); }
83 static inline char* strnset(char* str
, int value
, unsigned int len
) { return _strnset(str
, value
, len
); }
84 static inline char* strrev(char* str
) { return _strrev(str
); }
85 static inline char* strset(char* str
, int value
) { return _strset(str
, value
); }
86 static inline char* strupr(char* str
) { return _strupr(str
); }
88 static inline wchar_t* wcsdup(const wchar_t* str
) { return _wcsdup(str
); }
89 static inline int wcsicoll(const wchar_t* str1
, const wchar_t* str2
) { return _wcsicoll(str1
, str2
); }
90 static inline wchar_t* wcslwr(wchar_t* str
) { return _wcslwr(str
); }
91 static inline int wcsicmp(const wchar_t* s1
, const wchar_t* s2
) { return _wcsicmp(s1
, s2
); }
92 static inline int wcsnicmp(const wchar_t* str1
, const wchar_t* str2
, size_t n
) { return _wcsnicmp(str1
, str2
, n
); }
93 static inline wchar_t* wcsnset(wchar_t* str
, wchar_t c
, size_t n
) { return _wcsnset(str
, c
, n
); }
94 static inline wchar_t* wcsrev(wchar_t* str
) { return _wcsrev(str
); }
95 static inline wchar_t* wcsset(wchar_t* str
, wchar_t c
) { return _wcsset(str
, c
); }
96 static inline wchar_t* wcsupr(wchar_t* str
) { return _wcsupr(str
); }
98 #endif /* __WINE_STRING_H */