ok() does not support '%S'. Store the Ansi version, convert to Unicode
[wine] / include / msvcrt / string.h
1 /*
2  * String definitions
3  *
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.
7  */
8 #ifndef __WINE_STRING_H
9 #define __WINE_STRING_H
10 #define __WINE_USE_MSVCRT
11
12 #ifndef MSVCRT
13 # ifdef USE_MSVCRT_PREFIX
14 #  define MSVCRT(x)    MSVCRT_##x
15 # else
16 #  define MSVCRT(x)    x
17 # endif
18 #endif
19
20 #ifndef MSVCRT_WCHAR_T_DEFINED
21 #define MSVCRT_WCHAR_T_DEFINED
22 #ifndef __cplusplus
23 typedef unsigned short MSVCRT(wchar_t);
24 #endif
25 #endif
26
27 #ifndef MSVCRT_SIZE_T_DEFINED
28 typedef unsigned int MSVCRT(size_t);
29 #define MSVCRT_SIZE_T_DEFINED
30 #endif
31
32 #ifndef MSVCRT_NLSCMP_DEFINED
33 #define _NLSCMPERROR               ((unsigned int)0x7fffffff)
34 #define MSVCRT_NLSCMP_DEFINED
35 #endif
36
37 #ifndef NULL
38 #ifdef __cplusplus
39 #define NULL  0
40 #else
41 #define NULL  ((void *)0)
42 #endif
43 #endif
44
45 #ifdef __cplusplus
46 extern "C" {
47 #endif
48
49 void*       _memccpy(void*,const void*,int,MSVCRT(size_t));
50 int         _memicmp(const void*,const void*,MSVCRT(size_t));
51 int         _strcmpi(const char*,const char*);
52 char*       _strdup(const char*);
53 char*       _strerror(const char*);
54 int         _stricmp(const char*,const char*);
55 int         _stricoll(const char*,const char*);
56 char*       _strlwr(char*);
57 int         _strnicmp(const char*,const char*,MSVCRT(size_t));
58 char*       _strnset(char*,int,MSVCRT(size_t));
59 char*       _strrev(char*);
60 char*       _strset(char*,int);
61 char*       _strupr(char*);
62
63 void*       MSVCRT(memchr)(const void*,int,MSVCRT(size_t));
64 int         MSVCRT(memcmp)(const void*,const void*,MSVCRT(size_t));
65 void*       MSVCRT(memcpy)(void*,const void*,MSVCRT(size_t));
66 void*       MSVCRT(memmove)(void*,const void*,MSVCRT(size_t));
67 void*       MSVCRT(memset)(void*,int,MSVCRT(size_t));
68 char*       MSVCRT(strcat)(char*,const char*);
69 char*       MSVCRT(strchr)(const char*,int);
70 int         MSVCRT(strcmp)(const char*,const char*);
71 int         MSVCRT(strcoll)(const char*,const char*);
72 char*       MSVCRT(strcpy)(char*,const char*);
73 MSVCRT(size_t) MSVCRT(strcspn)(const char*,const char*);
74 char*       MSVCRT(strerror)(int);
75 MSVCRT(size_t) MSVCRT(strlen)(const char*);
76 char*       MSVCRT(strncat)(char*,const char*,MSVCRT(size_t));
77 int         MSVCRT(strncmp)(const char*,const char*,MSVCRT(size_t));
78 char*       MSVCRT(strncpy)(char*,const char*,MSVCRT(size_t));
79 char*       MSVCRT(strpbrk)(const char*,const char*);
80 char*       MSVCRT(strrchr)(const char*,int);
81 MSVCRT(size_t) MSVCRT(strspn)(const char*,const char*);
82 char*       MSVCRT(strstr)(const char*,const char*);
83 char*       MSVCRT(strtok)(char*,const char*);
84 MSVCRT(size_t) MSVCRT(strxfrm)(char*,const char*,MSVCRT(size_t));
85
86 #ifndef MSVCRT_WSTRING_DEFINED
87 #define MSVCRT_WSTRING_DEFINED
88 MSVCRT(wchar_t)*_wcsdup(const MSVCRT(wchar_t)*);
89 int             _wcsicmp(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
90 int             _wcsicoll(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
91 MSVCRT(wchar_t)*_wcslwr(MSVCRT(wchar_t)*);
92 int             _wcsnicmp(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*,MSVCRT(size_t));
93 MSVCRT(wchar_t)*_wcsnset(MSVCRT(wchar_t)*,MSVCRT(wchar_t),MSVCRT(size_t));
94 MSVCRT(wchar_t)*_wcsrev(MSVCRT(wchar_t)*);
95 MSVCRT(wchar_t)*_wcsset(MSVCRT(wchar_t)*,MSVCRT(wchar_t));
96 MSVCRT(wchar_t)*_wcsupr(MSVCRT(wchar_t)*);
97
98 MSVCRT(wchar_t)*MSVCRT(wcscat)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
99 MSVCRT(wchar_t)*MSVCRT(wcschr)(const MSVCRT(wchar_t)*,MSVCRT(wchar_t));
100 int             MSVCRT(wcscmp)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
101 int             MSVCRT(wcscoll)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
102 MSVCRT(wchar_t)*MSVCRT(wcscpy)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
103 MSVCRT(size_t)  MSVCRT(wcscspn)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
104 MSVCRT(size_t)  MSVCRT(wcslen)(const MSVCRT(wchar_t)*);
105 MSVCRT(wchar_t)*MSVCRT(wcsncat)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*,MSVCRT(size_t));
106 int             MSVCRT(wcsncmp)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*,MSVCRT(size_t));
107 MSVCRT(wchar_t)*MSVCRT(wcsncpy)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*,MSVCRT(size_t));
108 MSVCRT(wchar_t)*MSVCRT(wcspbrk)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
109 MSVCRT(wchar_t)*MSVCRT(wcsrchr)(const MSVCRT(wchar_t)*,MSVCRT(wchar_t) wcFor);
110 MSVCRT(size_t)  MSVCRT(wcsspn)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
111 MSVCRT(wchar_t)*MSVCRT(wcsstr)(const MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
112 MSVCRT(wchar_t)*MSVCRT(wcstok)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*);
113 MSVCRT(size_t)  MSVCRT(wcsxfrm)(MSVCRT(wchar_t)*,const MSVCRT(wchar_t)*,MSVCRT(size_t));
114 #endif /* MSVCRT_WSTRING_DEFINED */
115
116 #ifdef __cplusplus
117 }
118 #endif
119
120
121 #ifndef USE_MSVCRT_PREFIX
122 #define memccpy _memccpy
123 #define memicmp _memicmp
124 #define strcasecmp _stricmp
125 #define strcmpi _strcmpi
126 #define strdup _strdup
127 #define stricmp _stricmp
128 #define stricoll _stricoll
129 #define strlwr _strlwr
130 #define strncasecmp _strncasecmp
131 #define strnicmp _strnicmp
132 #define strnset _strnset
133 #define strrev _strrev
134 #define strset _strset
135 #define strupr _strupr
136
137 #define wcsdup _wcsdup
138 #define wcsicoll _wcsicoll
139 #define wcslwr _wcslwr
140 #define wcsnicmp _wcsnicmp
141 #define wcsnset _wcsnset
142 #define wcsrev _wcsrev
143 #define wcsset _wcsset
144 #define wcsupr _wcsupr
145 #endif /* USE_MSVCRT_PREFIX */
146
147 #endif /* __WINE_STRING_H */