ReactOS 0.4.16-dev-716-g2b2bdab
tchar.h
Go to the documentation of this file.
1/***
2*tchar.h - definitions for generic international text functions
3*
4* Copyright (c) Microsoft Corporation. All rights reserved.
5*
6*Purpose:
7* Definitions for generic international functions, mostly defines
8* which map string/formatted-io/ctype functions to char, wchar_t, or
9* MBCS versions. To be used for compatibility between single-byte,
10* multi-byte and Unicode text models.
11*
12* [Public]
13*
14****/
15
16#pragma once
17#ifndef _INC_TCHAR // include guard for 3rd party interop
18#define _INC_TCHAR
19
20#include <corecrt.h>
21
22#pragma warning(push)
23#pragma warning(disable: _UCRT_DISABLED_WARNINGS)
25
26/* Notes */
27
28/* There is no:
29 * _tcscat_l
30 * _tcscpy_l
31 * because mbscat and mbscpy just behave like strcat and strcpy,
32 * so no special locale-specific behavior is needed.
33 */
34
35/* Functions like:
36 * _strncat_l
37 * _strncat_s_l
38 * are only available if ANSI is defined (i.e. no _UNICODE nor _MBCS),
39 * because these functions are only accessible through the _tcs macros.
40 */
41
42#ifdef __cplusplus
43extern "C" {
44#endif /* __cplusplus */
45
46#ifndef _CRT_FAR_MAPPINGS_NO_DEPRECATE
47/*
48Long ago, these f prefix text functions referred to handling of text in segmented architectures. Ever since the move
49to Win32 they have been obsolete names, but we kept them around as aliases. Now that we have a deprecation
50mechanism we can warn about them. You should switch to the identical function without the f prefix.
51*/
52#pragma deprecated("_ftcscat")
53#pragma deprecated("_ftcschr")
54#pragma deprecated("_ftcscpy")
55#pragma deprecated("_ftcscspn")
56#pragma deprecated("_ftcslen")
57#pragma deprecated("_ftcsncat")
58#pragma deprecated("_ftcsncpy")
59#pragma deprecated("_ftcspbrk")
60#pragma deprecated("_ftcsrchr")
61#pragma deprecated("_ftcsspn")
62#pragma deprecated("_ftcsstr")
63#pragma deprecated("_ftcstok")
64#pragma deprecated("_ftcsdup")
65#pragma deprecated("_ftcsnset")
66#pragma deprecated("_ftcsrev")
67#pragma deprecated("_ftcsset")
68#pragma deprecated("_ftcscmp")
69#pragma deprecated("_ftcsicmp")
70#pragma deprecated("_ftcsnccmp")
71#pragma deprecated("_ftcsncmp")
72#pragma deprecated("_ftcsncicmp")
73#pragma deprecated("_ftcsnicmp")
74#pragma deprecated("_ftcscoll")
75#pragma deprecated("_ftcsicoll")
76#pragma deprecated("_ftcsnccoll")
77#pragma deprecated("_ftcsncoll")
78#pragma deprecated("_ftcsncicoll")
79#pragma deprecated("_ftcsnicoll")
80#pragma deprecated("_ftcsclen")
81#pragma deprecated("_ftcsnccat")
82#pragma deprecated("_ftcsnccpy")
83#pragma deprecated("_ftcsncset")
84#pragma deprecated("_ftcsdec")
85#pragma deprecated("_ftcsinc")
86#pragma deprecated("_ftcsnbcnt")
87#pragma deprecated("_ftcsnccnt")
88#pragma deprecated("_ftcsnextc")
89#pragma deprecated("_ftcsninc")
90#pragma deprecated("_ftcsspnp")
91#pragma deprecated("_ftcslwr")
92#pragma deprecated("_ftcsupr")
93#pragma deprecated("_ftclen")
94#pragma deprecated("_ftccpy")
95#pragma deprecated("_ftccmp")
96#endif /* _CRT_FAR_MAPPINGS_NO_DEPRECATE */
97
98#define _ftcscat _tcscat
99#define _ftcschr _tcschr
100#define _ftcscpy _tcscpy
101#define _ftcscspn _tcscspn
102#define _ftcslen _tcslen
103#define _ftcsncat _tcsncat
104#define _ftcsncpy _tcsncpy
105#define _ftcspbrk _tcspbrk
106#define _ftcsrchr _tcsrchr
107#define _ftcsspn _tcsspn
108#define _ftcsstr _tcsstr
109#define _ftcstok _tcstok
110
111#define _ftcsdup _tcsdup
112#define _ftcsnset _tcsnset
113#define _ftcsrev _tcsrev
114#define _ftcsset _tcsset
115
116#define _ftcscmp _tcscmp
117#define _ftcsicmp _tcsicmp
118#define _ftcsnccmp _tcsnccmp
119#define _ftcsncmp _tcsncmp
120#define _ftcsncicmp _tcsncicmp
121#define _ftcsnicmp _tcsnicmp
122
123#define _ftcscoll _tcscoll
124#define _ftcsicoll _tcsicoll
125#define _ftcsnccoll _tcsnccoll
126#define _ftcsncoll _tcsncoll
127#define _ftcsncicoll _tcsncicoll
128#define _ftcsnicoll _tcsnicoll
129
130/* Redundant "logical-character" mappings */
131
132#define _ftcsclen _tcsclen
133#define _ftcsnccat _tcsnccat
134#define _ftcsnccpy _tcsnccpy
135#define _ftcsncset _tcsncset
136
137#define _ftcsdec _tcsdec
138#define _ftcsinc _tcsinc
139#define _ftcsnbcnt _tcsnbcnt
140#define _ftcsnccnt _tcsnccnt
141#define _ftcsnextc _tcsnextc
142#define _ftcsninc _tcsninc
143#define _ftcsspnp _tcsspnp
144
145#define _ftcslwr _tcslwr
146#define _ftcsupr _tcsupr
147
148#define _ftclen _tclen
149#define _ftccpy _tccpy
150#define _ftccmp _tccmp
151
152#ifdef _UNICODE
153
154#ifdef __cplusplus
155} /* ... extern "C" */
156#endif /* __cplusplus */
157
158/* ++++++++++++++++++++ UNICODE ++++++++++++++++++++ */
159
160#include <wchar.h>
161
162#ifdef __cplusplus
163extern "C" {
164#endif /* __cplusplus */
165
166#ifndef __TCHAR_DEFINED
167typedef wchar_t _TCHAR;
168typedef wchar_t _TSCHAR;
169typedef wchar_t _TUCHAR;
170typedef wchar_t _TXCHAR;
171typedef wint_t _TINT;
172#define __TCHAR_DEFINED
173#endif /* __TCHAR_DEFINED */
174
175#if defined(_CRT_INTERNAL_NONSTDC_NAMES) && _CRT_INTERNAL_NONSTDC_NAMES
176#ifndef _TCHAR_DEFINED
177typedef wchar_t TCHAR;
178typedef wchar_t * PTCHAR;
179typedef wchar_t TBYTE;
180typedef wchar_t * PTBYTE;
181#define _TCHAR_DEFINED
182#endif /* _TCHAR_DEFINED */
183#endif /* _CRT_INTERNAL_NONSTDC_NAMES */
184
185#define _TEOF WEOF
186
187#define __T(x) L ## x
188
189
190/* Program */
191
192#define _tmain wmain
193#define _tWinMain wWinMain
194#define _tenviron _wenviron
195#define __targv __wargv
196
197/* Formatted i/o */
198
199#define _tprintf wprintf
200#define _tprintf_l _wprintf_l
201#define _tprintf_s wprintf_s
202#define _tprintf_s_l _wprintf_s_l
203#define _tprintf_p _wprintf_p
204#define _tprintf_p_l _wprintf_p_l
205#define _tcprintf _cwprintf
206#define _tcprintf_l _cwprintf_l
207#define _tcprintf_s _cwprintf_s
208#define _tcprintf_s_l _cwprintf_s_l
209#define _tcprintf_p _cwprintf_p
210#define _tcprintf_p_l _cwprintf_p_l
211#define _vtcprintf _vcwprintf
212#define _vtcprintf_l _vcwprintf_l
213#define _vtcprintf_s _vcwprintf_s
214#define _vtcprintf_s_l _vcwprintf_s_l
215#define _vtcprintf_p _vcwprintf_p
216#define _vtcprintf_p_l _vcwprintf_p_l
217#define _ftprintf fwprintf
218#define _ftprintf_l _fwprintf_l
219#define _ftprintf_s fwprintf_s
220#define _ftprintf_s_l _fwprintf_s_l
221#define _ftprintf_p _fwprintf_p
222#define _ftprintf_p_l _fwprintf_p_l
223#define _stprintf _swprintf
224#define _stprintf_l __swprintf_l
225#define _stprintf_s swprintf_s
226#define _stprintf_s_l _swprintf_s_l
227#define _stprintf_p _swprintf_p
228#define _stprintf_p_l _swprintf_p_l
229#define _sctprintf _scwprintf
230#define _sctprintf_l _scwprintf_l
231#define _sctprintf_p _scwprintf_p
232#define _sctprintf_p_l _scwprintf_p_l
233#define _sntprintf _snwprintf
234#define _sntprintf_l _snwprintf_l
235#define _sntprintf_s _snwprintf_s
236#define _sntprintf_s_l _snwprintf_s_l
237#define _vtprintf vwprintf
238#define _vtprintf_l _vwprintf_l
239#define _vtprintf_s vwprintf_s
240#define _vtprintf_s_l _vwprintf_s_l
241#define _vtprintf_p _vwprintf_p
242#define _vtprintf_p_l _vwprintf_p_l
243#define _vftprintf vfwprintf
244#define _vftprintf_l _vfwprintf_l
245#define _vftprintf_s vfwprintf_s
246#define _vftprintf_s_l _vfwprintf_s_l
247#define _vftprintf_p _vfwprintf_p
248#define _vftprintf_p_l _vfwprintf_p_l
249#define _vstprintf vswprintf
250#define _vstprintf_l _vswprintf_l
251#define _vstprintf_s vswprintf_s
252#define _vstprintf_s_l _vswprintf_s_l
253#define _vstprintf_p _vswprintf_p
254#define _vstprintf_p_l _vswprintf_p_l
255#define _vsctprintf _vscwprintf
256#define _vsctprintf_l _vscwprintf_l
257#define _vsctprintf_p _vscwprintf_p
258#define _vsctprintf_p_l _vscwprintf_p_l
259#define _vsntprintf _vsnwprintf
260#define _vsntprintf_l _vsnwprintf_l
261#define _vsntprintf_s _vsnwprintf_s
262#define _vsntprintf_s_l _vsnwprintf_s_l
263
264#define _tscanf wscanf
265#define _tscanf_l _wscanf_l
266#define _tscanf_s wscanf_s
267#define _tscanf_s_l _wscanf_s_l
268#define _tcscanf _cwscanf
269#define _tcscanf_l _cwscanf_l
270#define _tcscanf_s _cwscanf_s
271#define _tcscanf_s_l _cwscanf_s_l
272#define _ftscanf fwscanf
273#define _ftscanf_l _fwscanf_l
274#define _ftscanf_s fwscanf_s
275#define _ftscanf_s_l _fwscanf_s_l
276#define _stscanf swscanf
277#define _stscanf_l _swscanf_l
278#define _stscanf_s swscanf_s
279#define _stscanf_s_l _swscanf_s_l
280#define _sntscanf _snwscanf
281#define _sntscanf_l _snwscanf_l
282#define _sntscanf_s _snwscanf_s
283#define _sntscanf_s_l _snwscanf_s_l
284#define _vtscanf vwscanf
285#define _vtscanf_s vwscanf_s
286#define _vftscanf vfwscanf
287#define _vftscanf_s vfwscanf_s
288#define _vstscanf vswscanf
289#define _vstscanf_s vswscanf_s
290
291
292/* Unformatted i/o */
293
294#define _fgettc fgetwc
295#define _fgettc_nolock _fgetwc_nolock
296#define _fgettchar _fgetwchar
297#define _fgetts fgetws
298#define _fputtc fputwc
299#define _fputtc_nolock _fputwc_nolock
300#define _fputtchar _fputwchar
301#define _fputts fputws
302#define _cputts _cputws
303#define _cgetts_s _cgetws_s
304#define _gettc getwc
305#define _gettc_nolock _getwc_nolock
306#define _gettch _getwch
307#define _gettch_nolock _getwch_nolock
308#define _gettche _getwche
309#define _gettche_nolock _getwche_nolock
310#define _gettchar getwchar
311#define _gettchar_nolock _getwchar_nolock
312#define _getts_s _getws_s
313#define _puttc putwc
314#define _puttc_nolock _fputwc_nolock
315#define _puttchar putwchar
316#define _puttchar_nolock _putwchar_nolock
317#define _puttch _putwch
318#define _puttch_nolock _putwch_nolock
319#define _putts _putws
320#define _ungettc ungetwc
321#define _ungettc_nolock _ungetwc_nolock
322#define _ungettch _ungetwch
323#define _ungettch_nolock _ungetwch_nolock
324
325
326/* String conversion functions */
327
328#define _tcstod wcstod
329#define _tcstof wcstof
330#define _tcstol wcstol
331#define _tcstold wcstold
332#define _tcstoll wcstoll
333#define _tcstoul wcstoul
334#define _tcstoull wcstoull
335#define _tcstoimax wcstoimax
336#define _tcstoumax wcstoumax
337#define _tcstoi64 _wcstoi64
338#define _tcstoui64 _wcstoui64
339#define _ttof _wtof
340#define _tstof _wtof
341#define _tstol _wtol
342#define _tstoll _wtoll
343#define _tstoi _wtoi
344#define _tstoi64 _wtoi64
345#define _tcstod_l _wcstod_l
346#define _tcstof_l _wcstof_l
347#define _tcstol_l _wcstol_l
348#define _tcstold_l _wcstold_l
349#define _tcstoll_l _wcstoll_l
350#define _tcstoul_l _wcstoul_l
351#define _tcstoull_l _wcstoull_l
352#define _tcstoi64_l _wcstoi64_l
353#define _tcstoui64_l _wcstoui64_l
354#define _tcstoimax_l _wcstoimax_l
355#define _tcstoumax_l _wcstoumax_l
356#define _tstof_l _wtof_l
357#define _tstol_l _wtol_l
358#define _tstoll_l _wtoll_l
359#define _tstoi_l _wtoi_l
360#define _tstoi64_l _wtoi64_l
361
362#define _itot_s _itow_s
363#define _ltot_s _ltow_s
364#define _ultot_s _ultow_s
365#define _itot _itow
366#define _ltot _ltow
367#define _ultot _ultow
368#define _ttoi _wtoi
369#define _ttol _wtol
370#define _ttoll _wtoll
371
372#define _ttoi64 _wtoi64
373#define _i64tot_s _i64tow_s
374#define _ui64tot_s _ui64tow_s
375#define _i64tot _i64tow
376#define _ui64tot _ui64tow
377
378/* String functions */
379
380#define _tcscat wcscat
381#define _tcscat_s wcscat_s
382#define _tcschr wcschr
383#define _tcscpy wcscpy
384#define _tcscpy_s wcscpy_s
385#define _tcscspn wcscspn
386#define _tcslen wcslen
387#define _tcsnlen wcsnlen
388#define _tcsncat wcsncat
389#define _tcsncat_s wcsncat_s
390#define _tcsncat_l _wcsncat_l
391#define _tcsncat_s_l _wcsncat_s_l
392#define _tcsncpy wcsncpy
393#define _tcsncpy_s wcsncpy_s
394#define _tcsncpy_l _wcsncpy_l
395#define _tcsncpy_s_l _wcsncpy_s_l
396#define _tcspbrk wcspbrk
397#define _tcsrchr wcsrchr
398#define _tcsspn wcsspn
399#define _tcsstr wcsstr
400#define _tcstok _wcstok
401#define _tcstok_s wcstok_s
402#define _tcstok_l _wcstok_l
403#define _tcstok_s_l _wcstok_s_l
404#define _tcserror _wcserror
405#define _tcserror_s _wcserror_s
406#define __tcserror __wcserror
407#define __tcserror_s __wcserror_s
408
409#define _tcsdup _wcsdup
410#define _tcsnset _wcsnset
411#define _tcsnset_s _wcsnset_s
412#define _tcsnset_l _wcsnset_l
413#define _tcsnset_s_l _wcsnset_s_l
414#define _tcsrev _wcsrev
415#define _tcsset _wcsset
416#define _tcsset_s _wcsset_s
417#define _tcsset_l _wcsset_l
418#define _tcsset_s_l _wcsset_s_l
419
420#define _tcscmp wcscmp
421#define _tcsicmp _wcsicmp
422#define _tcsicmp_l _wcsicmp_l
423#define _tcsnccmp wcsncmp
424#define _tcsncmp wcsncmp
425#define _tcsncicmp _wcsnicmp
426#define _tcsncicmp_l _wcsnicmp_l
427#define _tcsnicmp _wcsnicmp
428#define _tcsnicmp_l _wcsnicmp_l
429
430#define _tcscoll wcscoll
431#define _tcscoll_l _wcscoll_l
432#define _tcsicoll _wcsicoll
433#define _tcsicoll_l _wcsicoll_l
434#define _tcsnccoll _wcsncoll
435#define _tcsnccoll_l _wcsncoll_l
436#define _tcsncoll _wcsncoll
437#define _tcsncoll_l _wcsncoll_l
438#define _tcsncicoll _wcsnicoll
439#define _tcsncicoll_l _wcsnicoll_l
440#define _tcsnicoll _wcsnicoll
441#define _tcsnicoll_l _wcsnicoll_l
442
443#ifdef _DEBUG
444#define _tcsdup_dbg _wcsdup_dbg
445#endif /* _DEBUG */
446
447/* Execute functions */
448
449#define _texecl _wexecl
450#define _texecle _wexecle
451#define _texeclp _wexeclp
452#define _texeclpe _wexeclpe
453#define _texecv _wexecv
454#define _texecve _wexecve
455#define _texecvp _wexecvp
456#define _texecvpe _wexecvpe
457
458#define _tspawnl _wspawnl
459#define _tspawnle _wspawnle
460#define _tspawnlp _wspawnlp
461#define _tspawnlpe _wspawnlpe
462#define _tspawnv _wspawnv
463#define _tspawnve _wspawnve
464#define _tspawnvp _wspawnvp
465#define _tspawnvp _wspawnvp
466#define _tspawnvpe _wspawnvpe
467
468#define _tsystem _wsystem
469
470
471/* Time functions */
472
473#define _tasctime _wasctime
474#define _tctime _wctime
475#define _tctime32 _wctime32
476#define _tctime64 _wctime64
477#define _tstrdate _wstrdate
478#define _tstrtime _wstrtime
479#define _tutime _wutime
480#define _tutime32 _wutime32
481#define _tutime64 _wutime64
482#define _tcsftime wcsftime
483#define _tcsftime_l _wcsftime_l
484
485#define _tasctime_s _wasctime_s
486#define _tctime_s _wctime_s
487#define _tctime32_s _wctime32_s
488#define _tctime64_s _wctime64_s
489#define _tstrdate_s _wstrdate_s
490#define _tstrtime_s _wstrtime_s
491
492/* Directory functions */
493
494#define _tchdir _wchdir
495#define _tgetcwd _wgetcwd
496#define _tgetdcwd _wgetdcwd
497#define _tgetdcwd_nolock _wgetdcwd_nolock
498#define _tmkdir _wmkdir
499#define _trmdir _wrmdir
500
501#ifdef _DEBUG
502#define _tgetcwd_dbg _wgetcwd_dbg
503#define _tgetdcwd_dbg _wgetdcwd_dbg
504#define _tgetdcwd_lk_dbg _wgetdcwd_lk_dbg
505#endif /* _DEBUG */
506
507/* Environment/Path functions */
508
509#define _tfullpath _wfullpath
510#define _tgetenv _wgetenv
511#define _tgetenv_s _wgetenv_s
512#define _tdupenv_s _wdupenv_s
513#define _tmakepath _wmakepath
514#define _tmakepath_s _wmakepath_s
515#define _tpgmptr _wpgmptr
516#define _get_tpgmptr _get_wpgmptr
517#define _tputenv _wputenv
518#define _tputenv_s _wputenv_s
519#define _tsearchenv _wsearchenv
520#define _tsearchenv_s _wsearchenv_s
521#define _tsplitpath _wsplitpath
522#define _tsplitpath_s _wsplitpath_s
523
524#ifdef _DEBUG
525#define _tfullpath_dbg _wfullpath_dbg
526#define _tdupenv_s_dbg _wdupenv_s_dbg
527#endif /* _DEBUG */
528
529/* Stdio functions */
530
531#define _tfdopen _wfdopen
532#define _tfsopen _wfsopen
533#define _tfopen _wfopen
534#define _tfopen_s _wfopen_s
535#define _tfreopen _wfreopen
536#define _tfreopen_s _wfreopen_s
537#define _tperror _wperror
538#define _tpopen _wpopen
539#define _ttempnam _wtempnam
540#define _ttmpnam _wtmpnam
541#define _ttmpnam_s _wtmpnam_s
542
543#ifdef _DEBUG
544#define _ttempnam_dbg _wtempnam_dbg
545#endif /* _DEBUG */
546
547
548/* Io functions */
549
550#define _taccess _waccess
551#define _taccess_s _waccess_s
552#define _tchmod _wchmod
553#define _tcreat _wcreat
554#define _tfindfirst _wfindfirst
555#define _tfindfirst32 _wfindfirst32
556#define _tfindfirst64 _wfindfirst64
557#define _tfindfirsti64 _wfindfirsti64
558#define _tfindfirst32i64 _wfindfirst32i64
559#define _tfindfirst64i32 _wfindfirst64i32
560#define _tfindnext _wfindnext
561#define _tfindnext32 _wfindnext32
562#define _tfindnext64 _wfindnext64
563#define _tfindnexti64 _wfindnexti64
564#define _tfindnext32i64 _wfindnext32i64
565#define _tfindnext64i32 _wfindnext64i32
566#define _tmktemp _wmktemp
567#define _tmktemp_s _wmktemp_s
568#define _topen _wopen
569#define _tremove _wremove
570#define _trename _wrename
571#define _tsopen _wsopen
572#define _tsopen_s _wsopen_s
573#define _tunlink _wunlink
574
575#define _tfinddata_t _wfinddata_t
576#define _tfinddata32_t _wfinddata32_t
577#define _tfinddata64_t _wfinddata64_t
578#define _tfinddatai64_t _wfinddatai64_t
579#define _tfinddata32i64_t _wfinddata32i64_t
580#define _tfinddata64i32_t _wfinddata64i32_t
581
582
583/* Stat functions */
584
585#define _tstat _wstat
586#define _tstat32 _wstat32
587#define _tstat32i64 _wstat32i64
588#define _tstat64 _wstat64
589#define _tstat64i32 _wstat64i32
590#define _tstati64 _wstati64
591
592
593/* Setlocale functions */
594
595#define _tsetlocale _wsetlocale
596
597
598/* Redundant "logical-character" mappings */
599
600#define _tcsclen wcslen
601#define _tcscnlen wcsnlen
602#define _tcsclen_l(_String, _Locale) wcslen(_String)
603#define _tcscnlen_l(_String, _Max_count, _Locale) wcsnlen((_String), (_Max_count))
604#define _tcsnccat wcsncat
605#define _tcsnccat_s wcsncat_s
606#define _tcsnccat_l _wcsncat_l
607#define _tcsnccat_s_l _wcsncat_s_l
608#define _tcsnccpy wcsncpy
609#define _tcsnccpy_s wcsncpy_s
610#define _tcsnccpy_l _wcsncpy_l
611#define _tcsnccpy_s_l _wcsncpy_s_l
612#define _tcsncset _wcsnset
613#define _tcsncset_s _wcsnset_s
614#define _tcsncset_l _wcsnset_l
615#define _tcsncset_s_l _wcsnset_s_l
616
617#define _tcsdec _wcsdec
618#define _tcsinc _wcsinc
619#define _tcsnbcnt _wcsncnt
620#define _tcsnccnt _wcsncnt
621#define _tcsnextc _wcsnextc
622#define _tcsninc _wcsninc
623#define _tcsspnp _wcsspnp
624
625#define _tcslwr _wcslwr
626#define _tcslwr_l _wcslwr_l
627#define _tcslwr_s _wcslwr_s
628#define _tcslwr_s_l _wcslwr_s_l
629#define _tcsupr _wcsupr
630#define _tcsupr_l _wcsupr_l
631#define _tcsupr_s _wcsupr_s
632#define _tcsupr_s_l _wcsupr_s_l
633#define _tcsxfrm wcsxfrm
634#define _tcsxfrm_l _wcsxfrm_l
635
636
637#if __STDC__ || defined (_NO_INLINING)
638#define _tclen(_pc) (1)
639#define _tccpy(_pc1,_cpc2) ((*(_pc1) = *(_cpc2)))
640#define _tccpy_l(_pc1,_cpc2,_locale) _tccpy((_pc1),(_cpc2))
641#define _tccmp(_cpc1,_cpc2) ((*(_cpc1))-(*(_cpc2)))
642#else /* __STDC__ || defined (_NO_INLINING) */
643_Check_return_ __inline size_t __CRTDECL _tclen(_In_z_ const wchar_t *_Cpc)
644{
645 /* avoid compiler warning */
646 (void)_Cpc;
647 return 1;
648}
649__inline void __CRTDECL _tccpy(_Out_ wchar_t *_Pc1, _In_z_ const wchar_t *_Cpc2) { *_Pc1 = (wchar_t)*_Cpc2; }
650__inline void __CRTDECL _tccpy_l(_Out_ wchar_t *_Pc1, _In_z_ const wchar_t *_Cpc2, _In_opt_ _locale_t _Locale)
651{
653 _tccpy(_Pc1, _Cpc2);
654}
655_Check_return_ __inline int __CRTDECL _tccmp(_In_z_ const wchar_t *_Cpc1, _In_z_ const wchar_t *_Cpc2) { return (int) ((*_Cpc1)-(*_Cpc2)); }
656#endif /* __STDC__ || defined (_NO_INLINING) */
657
658/* ctype functions */
659
660#define _istalnum iswalnum
661#define _istalnum_l _iswalnum_l
662#define _istalpha iswalpha
663#define _istalpha_l _iswalpha_l
664#define _istascii iswascii
665#define _istcntrl iswcntrl
666#define _istcntrl_l _iswcntrl_l
667#define _istdigit iswdigit
668#define _istdigit_l _iswdigit_l
669#define _istgraph iswgraph
670#define _istgraph_l _iswgraph_l
671#define _istlower iswlower
672#define _istlower_l _iswlower_l
673#define _istprint iswprint
674#define _istprint_l _iswprint_l
675#define _istpunct iswpunct
676#define _istpunct_l _iswpunct_l
677#define _istblank iswblank
678#define _istblank_l _iswblank_l
679#define _istspace iswspace
680#define _istspace_l _iswspace_l
681#define _istupper iswupper
682#define _istupper_l _iswupper_l
683#define _istxdigit iswxdigit
684#define _istxdigit_l _iswxdigit_l
685
686#define _totupper towupper
687#define _totupper_l _towupper_l
688#define _totlower towlower
689#define _totlower_l _towlower_l
690
691#define _istlegal(_Char) (1)
692#define _istlead(_Char) (0)
693#define _istleadbyte(_Char) (0)
694#define _istleadbyte_l(_Char, _Locale) (0)
695
696
697#if __STDC__ || defined _NO_INLINING
698#define _wcsdec(_cpc1, _cpc2) ((_cpc1)>=(_cpc2) ? NULL : (_cpc2)-1)
699#define _wcsinc(_pc) ((_pc)+1)
700#define _wcsnextc(_cpc) ((unsigned int) *(_cpc))
701#define _wcsninc(_pc, _sz) (((_pc)+(_sz)))
702_Check_return_ _ACRTIMP size_t __cdecl __wcsncnt(_In_reads_or_z_(_MaxCount) const wchar_t * _Str, _In_ size_t _MaxCount);
703#define _wcsncnt(_cpc, _sz) (__wcsncnt(_cpc,_sz))
704#define _wcsspnp(_cpc1, _cpc2) (_cpc1==NULL ? NULL : ((*((_cpc1)+wcsspn(_cpc1,_cpc2))) ? ((_cpc1)+wcsspn(_cpc1,_cpc2)) : NULL))
705#define _wcsncpy_l(_Destination, _Source, _Count, _Locale) (wcsncpy(_Destination, _Source, _Count))
706#if __STDC_WANT_SECURE_LIB__
707#define _wcsncpy_s_l(_Destination, _Destination_size_chars, _Source, _Count, _Locale) (wcsncpy_s(_Destination, _Destination_size_chars, _Source, _Count))
708#endif /* __STDC_WANT_SECURE_LIB__ */
709#define _wcsncat_l(_Destination, _Source, _Count, _Locale) (wcsncat(_Destination, _Source, _Count))
710#if __STDC_WANT_SECURE_LIB__
711#define _wcsncat_s_l(_Destination, _Destination_size_chars, _Source, _Count, _Locale) (wcsncat_s(_Destination, _Destination_size_chars, _Source, _Count))
712#endif /* __STDC_WANT_SECURE_LIB__ */
713#define _wcstok_l(_String, _Delimiters, _Locale) (_wcstok(_String, _Delimiters))
714#define _wcstok_s_l(_String, _Delimiters, _Current_position, _Locale) (wcstok_s(_String, _Delimiters, _Current_position))
715#define _wcsnset_l(_Destination, _Value, _Count, _Locale) (_wcsnset(_Destination, _Value, _Count))
716#define _wcsnset_s_l(_Destination, _Destination_size_chars, _Value, _Count, _Locale) (_wcsnset_s(_Destination, _Destination_size_chars, _Value, _Count))
717#define _wcsset_l(_Destination, _Value, _Locale) (_wcsset(_Destination, _Value))
718#define _wcsset_s_l(_Destination, _Destination_size_chars, _Value, _Locale) (_wcsset_s(_Destination, _Destination_size_chars, _Value))
719#else /* __STDC__ || defined (_NO_INLINING) */
720_Check_return_ __inline wchar_t * __CRTDECL _wcsdec(_In_z_ const wchar_t * _Cpc1, _In_z_ const wchar_t * _Cpc2) { return (wchar_t *)((_Cpc1)>=(_Cpc2) ? NULL : ((_Cpc2)-1)); }
721_Check_return_ __inline wchar_t * __CRTDECL _wcsinc(_In_z_ const wchar_t * _Pc) { return (wchar_t *)(_Pc+1); }
722_Check_return_ __inline unsigned int __CRTDECL _wcsnextc(_In_z_ const wchar_t * _Cpc) { return (unsigned int)*_Cpc; }
723_Check_return_ __inline wchar_t * __CRTDECL _wcsninc(_In_z_ const wchar_t * _Pc, _In_ size_t _Sz) { return (wchar_t *)(_Pc+_Sz); }
724_Check_return_ __inline size_t __CRTDECL _wcsncnt( _In_reads_or_z_(_Cnt) const wchar_t * _String, _In_ size_t _Cnt)
725{
726 size_t n = _Cnt;
727 wchar_t *cp = (wchar_t *)_String;
728 while (n-- && *cp)
729 cp++;
730 return _Cnt - n - 1;
731}
732_Check_return_ __inline wchar_t * __CRTDECL _wcsspnp
733(
734 _In_z_ const wchar_t * _Cpc1,
735 _In_z_ const wchar_t * _Cpc2
736)
737{
738 return _Cpc1==NULL ? NULL : ((*(_Cpc1 += wcsspn(_Cpc1,_Cpc2))!='\0') ? (wchar_t*)_Cpc1 : NULL);
739}
740
741#if __STDC_WANT_SECURE_LIB__
743{
746}
747#endif /* __STDC_WANT_SECURE_LIB__ */
748
749__DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_3(errno_t, _wcsncpy_s_l, wchar_t, _Dest, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
750
751__DECLARE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(wchar_t *, __RETURN_POLICY_DST, _wcsncpy_l, _wcsncpy_s_l, _Out_writes_z_(_Size) wchar_t, _Out_writes_(_Count) wchar_t, _Dst, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
752{
754#pragma warning(suppress: 6054) // String may not be zero-terminated
755 return wcsncpy(_Dst, _Source, _Count);
756}
757
758__DEFINE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(wchar_t *, __RETURN_POLICY_DST, _wcsncpy_l, _wcsncpy_s_l, _Out_writes_z_(_Size) wchar_t, _Out_writes_(_Count), wchar_t, _Dst, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
759
760#if __STDC_WANT_SECURE_LIB__
762{
765}
766#endif /* __STDC_WANT_SECURE_LIB__ */
767
768__DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_3(errno_t, _wcsncat_s_l, wchar_t, _Dest, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
769
770__DECLARE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(wchar_t *, __RETURN_POLICY_DST, _wcsncat_l, _wcsncat_s_l, _Inout_updates_z_(_Size) wchar_t, _Inout_z_ wchar_t, _Dst, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
771{
773// C6054: String may not be zero-terminated
774// C6059: Incorrect length parameter in call
775#pragma warning(suppress: 6054 6059)
776 return wcsncat(_Dst, _Source, _Count);
777}
778
779__DEFINE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(wchar_t *, __RETURN_POLICY_DST, _wcsncat_l, _wcsncat_s_l, _Inout_updates_z_(_Size) wchar_t, _Inout_z_, wchar_t, _Dst, _In_z_ const wchar_t *, _Source, _In_ size_t, _Count, _In_opt_ _locale_t, _Locale)
780
781_CRT_INSECURE_DEPRECATE(_wcstok_s_l) __inline wchar_t * _wcstok_l(_Inout_opt_z_ wchar_t * _String, _In_z_ const wchar_t * _Delimiters, _In_opt_ _locale_t _Locale)
782{
784#ifdef _CRT_NON_CONFORMING_WCSTOK
785 return wcstok(_String,_Delimiters);
786#else
787 return wcstok(_String,_Delimiters,0);
788#endif
789}
790
791#if __STDC_WANT_SECURE_LIB__
792__inline wchar_t * _wcstok_s_l(_Inout_opt_z_ wchar_t * _String, _In_z_ const wchar_t * _Delimiters, _Inout_ _Deref_prepost_opt_z_ wchar_t **_Current_position, _In_opt_ _locale_t _Locale)
793{
795 return wcstok_s(_String, _Delimiters, _Current_position);
796}
797#endif /* __STDC_WANT_SECURE_LIB__ */
798
800{
803}
804
806
808{
810 return _wcsnset(_Dst, _Value, _MaxCount);
811}
812
814
816{
819}
820
822
823__DECLARE_CPP_OVERLOAD_INLINE_FUNC_0_2_EX(wchar_t *, __RETURN_POLICY_DST, _wcsset_l, _wcsset_s_l, _Inout_updates_z_(_Size) wchar_t, _Inout_z_ wchar_t, _Dst, _In_ wchar_t, _Value, _In_opt_ _locale_t, _Locale)
824{
826 return _wcsset(_Dst, _Value);
827}
828
829__DEFINE_CPP_OVERLOAD_INLINE_FUNC_0_2_EX(wchar_t *, __RETURN_POLICY_DST, _wcsset_l, _wcsset_s_l, _Inout_updates_z_(_Size) wchar_t, _Inout_z_, wchar_t, _Dst, _In_ wchar_t, _Value, _In_opt_ _locale_t, _Locale)
830
831#endif /* __STDC__ || defined (_NO_INLINING) */
832
833#else /* _UNICODE */
834
835/* ++++++++++++++++++++ SBCS and MBCS ++++++++++++++++++++ */
836
837#ifdef __cplusplus
838} /* ... extern "C" */
839#endif /* __cplusplus */
840
841#include <string.h>
842
843#ifdef __cplusplus
844extern "C" {
845#endif /* __cplusplus */
846
847
848#define _TEOF EOF
849
850#define __T(x) x
851
852
853/* Program */
854
855#define _tmain main
856#define _tWinMain WinMain
857#define _tenviron _environ
858#define __targv __argv
859
860
861/* Formatted i/o */
862
863#define _tprintf printf
864#define _tprintf_l _printf_l
865#define _tprintf_s printf_s
866#define _tprintf_s_l _printf_s_l
867#define _tprintf_p _printf_p
868#define _tprintf_p_l _printf_p_l
869#define _tcprintf _cprintf
870#define _tcprintf_l _cprintf_l
871#define _tcprintf_s _cprintf_s
872#define _tcprintf_s_l _cprintf_s_l
873#define _tcprintf_p _cprintf_p
874#define _tcprintf_p_l _cprintf_p_l
875#define _vtcprintf _vcprintf
876#define _vtcprintf_l _vcprintf_l
877#define _vtcprintf_s _vcprintf_s
878#define _vtcprintf_s_l _vcprintf_s_l
879#define _vtcprintf_p _vcprintf_p
880#define _vtcprintf_p_l _vcprintf_p_l
881#define _ftprintf fprintf
882#define _ftprintf_l _fprintf_l
883#define _ftprintf_s fprintf_s
884#define _ftprintf_s_l _fprintf_s_l
885#define _ftprintf_p _fprintf_p
886#define _ftprintf_p_l _fprintf_p_l
887#define _stprintf sprintf
888#define _stprintf_l _sprintf_l
889#define _stprintf_s sprintf_s
890#define _stprintf_s_l _sprintf_s_l
891#define _stprintf_p _sprintf_p
892#define _stprintf_p_l _sprintf_p_l
893#define _sctprintf _scprintf
894#define _sctprintf_l _scprintf_l
895#define _sctprintf_p _scprintf_p
896#define _sctprintf_p_l _scprintf_p_l
897#define _sntprintf _snprintf
898#define _sntprintf_l _snprintf_l
899#define _sntprintf_s _snprintf_s
900#define _sntprintf_s_l _snprintf_s_l
901#define _vtprintf vprintf
902#define _vtprintf_l _vprintf_l
903#define _vtprintf_s vprintf_s
904#define _vtprintf_s_l _vprintf_s_l
905#define _vtprintf_p _vprintf_p
906#define _vtprintf_p_l _vprintf_p_l
907#define _vftprintf vfprintf
908#define _vftprintf_l _vfprintf_l
909#define _vftprintf_s vfprintf_s
910#define _vftprintf_s_l _vfprintf_s_l
911#define _vftprintf_p _vfprintf_p
912#define _vftprintf_p_l _vfprintf_p_l
913#define _vstprintf vsprintf
914#define _vstprintf_l _vsprintf_l
915#define _vstprintf_s vsprintf_s
916#define _vstprintf_s_l _vsprintf_s_l
917#define _vstprintf_p _vsprintf_p
918#define _vstprintf_p_l _vsprintf_p_l
919#define _vsctprintf _vscprintf
920#define _vsctprintf_l _vscprintf_l
921#define _vsctprintf_p _vscprintf_p
922#define _vsctprintf_p_l _vscprintf_p_l
923#define _vsntprintf _vsnprintf
924#define _vsntprintf_l _vsnprintf_l
925#define _vsntprintf_s _vsnprintf_s
926#define _vsntprintf_s_l _vsnprintf_s_l
927
928#define _tscanf scanf
929#define _tscanf_l _scanf_l
930#define _tscanf_s scanf_s
931#define _tscanf_s_l _scanf_s_l
932#define _tcscanf _cscanf
933#define _tcscanf_l _cscanf_l
934#define _tcscanf_s _cscanf_s
935#define _tcscanf_s_l _cscanf_s_l
936#define _ftscanf fscanf
937#define _ftscanf_l _fscanf_l
938#define _ftscanf_s fscanf_s
939#define _ftscanf_s_l _fscanf_s_l
940#define _stscanf sscanf
941#define _stscanf_l _sscanf_l
942#define _stscanf_s sscanf_s
943#define _stscanf_s_l _sscanf_s_l
944#define _sntscanf _snscanf
945#define _sntscanf_l _snscanf_l
946#define _sntscanf_s _snscanf_s
947#define _sntscanf_s_l _snscanf_s_l
948#define _vtscanf vscanf
949#define _vtscanf_s vscanf_s
950#define _vftscanf vfscanf
951#define _vftscanf_s vfscanf_s
952#define _vstscanf vsscanf
953#define _vstscanf_s vsscanf_s
954
955
956/* Unformatted i/o */
957
958#define _fgettc fgetc
959#define _fgettc_nolock _fgetc_nolock
960#define _fgettchar _fgetchar
961#define _fgetts fgets
962#define _fputtc fputc
963#define _fputtc_nolock _fputc_nolock
964#define _fputtchar _fputchar
965#define _fputts fputs
966#define _cputts _cputs
967#define _gettc getc
968#define _gettc_nolock _getc_nolock
969#define _gettch _getch
970#define _gettch_nolock _getch_nolock
971#define _gettche _getche
972#define _gettche_nolock _getche_nolock
973#define _gettchar getchar
974#define _gettchar_nolock _getchar_nolock
975#define _getts_s gets_s
976#define _cgetts_s _cgets_s
977#define _puttc putc
978#define _puttc_nolock _fputc_nolock
979#define _puttchar putchar
980#define _puttchar_nolock _putchar_nolock
981#define _puttch _putch
982#define _puttch_nolock _putch_nolock
983#define _putts puts
984#define _ungettc ungetc
985#define _ungettc_nolock _ungetc_nolock
986#define _ungettch _ungetch
987#define _ungettch_nolock _ungetch_nolock
988
989/* String conversion functions */
990
991#define _tcstod strtod
992#define _tcstof strtof
993#define _tcstol strtol
994#define _tcstold strtold
995#define _tcstoll strtoll
996#define _tcstoul strtoul
997#define _tcstoull strtoull
998#define _tcstoimax strtoimax
999#define _tcstoumax strtoumax
1000#define _ttof atof
1001#define _tstof atof
1002#define _tstol atol
1003#define _tstoll atoll
1004#define _tstoi atoi
1005#define _tstoi64 _atoi64
1006#define _tcstod_l _strtod_l
1007#define _tcstof_l _strtof_l
1008#define _tcstol_l _strtol_l
1009#define _tcstold_l _strtold_l
1010#define _tcstoll_l _strtoll_l
1011#define _tcstoul_l _strtoul_l
1012#define _tcstoull_l _strtoull_l
1013#define _tcstoimax_l _strtoimax_l
1014#define _tcstoumax_l _strtoumax_l
1015#define _tstof_l _atof_l
1016#define _tstol_l _atol_l
1017#define _tstoll_l _atoll_l
1018#define _tstoi_l _atoi_l
1019#define _tstoi64_l _atoi64_l
1020
1021#define _itot_s _itoa_s
1022#define _ltot_s _ltoa_s
1023#define _ultot_s _ultoa_s
1024#define _itot _itoa
1025#define _ltot _ltoa
1026#define _ultot _ultoa
1027#define _ttoi atoi
1028#define _ttol atol
1029#define _ttoll atoll
1030
1031#define _ttoi64 _atoi64
1032#define _tcstoi64 _strtoi64
1033#define _tcstoi64_l _strtoi64_l
1034#define _tcstoui64 _strtoui64
1035#define _tcstoui64_l _strtoui64_l
1036#define _i64tot_s _i64toa_s
1037#define _ui64tot_s _ui64toa_s
1038#define _i64tot _i64toa
1039#define _ui64tot _ui64toa
1040
1041/* String functions */
1042
1043/* Note that _mbscat, _mbscpy and _mbsdup are functionally equivalent to
1044 strcat, strcpy and strdup, respectively. */
1045
1046#define _tcscat strcat
1047#define _tcscat_s strcat_s
1048#define _tcscpy strcpy
1049#define _tcscpy_s strcpy_s
1050#define _tcsdup _strdup
1051#define _tcslen strlen
1052#define _tcsnlen strnlen
1053#define _tcsxfrm strxfrm
1054#define _tcsxfrm_l _strxfrm_l
1055#define _tcserror strerror
1056#define _tcserror_s strerror_s
1057#define __tcserror _strerror
1058#define __tcserror_s _strerror_s
1059
1060#ifdef _DEBUG
1061#define _tcsdup_dbg _strdup_dbg
1062#endif /* _DEBUG */
1063
1064/* Execute functions */
1065
1066#define _texecl _execl
1067#define _texecle _execle
1068#define _texeclp _execlp
1069#define _texeclpe _execlpe
1070#define _texecv _execv
1071#define _texecve _execve
1072#define _texecvp _execvp
1073#define _texecvpe _execvpe
1074
1075#define _tspawnl _spawnl
1076#define _tspawnle _spawnle
1077#define _tspawnlp _spawnlp
1078#define _tspawnlpe _spawnlpe
1079#define _tspawnv _spawnv
1080#define _tspawnve _spawnve
1081#define _tspawnvp _spawnvp
1082#define _tspawnvpe _spawnvpe
1083
1084#define _tsystem system
1085
1086
1087/* Time functions */
1088
1089#define _tasctime asctime
1090#define _tctime ctime
1091#define _tctime32 _ctime32
1092#define _tctime64 _ctime64
1093#define _tstrdate _strdate
1094#define _tstrtime _strtime
1095#define _tutime _utime
1096#define _tutime32 _utime32
1097#define _tutime64 _utime64
1098#define _tcsftime strftime
1099#define _tcsftime_l _strftime_l
1100
1101#define _tasctime_s asctime_s
1102#define _tctime_s ctime_s
1103#define _tctime32_s _ctime32_s
1104#define _tctime64_s _ctime64_s
1105#define _tstrdate_s _strdate_s
1106#define _tstrtime_s _strtime_s
1107
1108/* Directory functions */
1109
1110#define _tchdir _chdir
1111#define _tgetcwd _getcwd
1112#define _tgetdcwd _getdcwd
1113#define _tgetdcwd_nolock _getdcwd_nolock
1114#define _tmkdir _mkdir
1115#define _trmdir _rmdir
1116
1117#ifdef _DEBUG
1118#define _tgetcwd_dbg _getcwd_dbg
1119#define _tgetdcwd_dbg _getdcwd_dbg
1120#define _tgetdcwd_lk_dbg _getdcwd_lk_dbg
1121#endif /* _DEBUG */
1122
1123/* Environment/Path functions */
1124
1125#define _tfullpath _fullpath
1126#define _tgetenv getenv
1127#define _tgetenv_s getenv_s
1128#define _tdupenv_s _dupenv_s
1129#define _tmakepath _makepath
1130#define _tmakepath_s _makepath_s
1131#define _tpgmptr _pgmptr
1132#define _get_tpgmptr _get_pgmptr
1133#define _tputenv _putenv
1134#define _tputenv_s _putenv_s
1135#define _tsearchenv _searchenv
1136#define _tsearchenv_s _searchenv_s
1137#define _tsplitpath _splitpath
1138#define _tsplitpath_s _splitpath_s
1139
1140#ifdef _DEBUG
1141#define _tfullpath_dbg _fullpath_dbg
1142#define _tdupenv_s_dbg _dupenv_s_dbg
1143#endif /* _DEBUG */
1144
1145/* Stdio functions */
1146
1147#define _tfdopen _fdopen
1148#define _tfsopen _fsopen
1149#define _tfopen fopen
1150#define _tfopen_s fopen_s
1151#define _tfreopen freopen
1152#define _tfreopen_s freopen_s
1153#define _tperror perror
1154#define _tpopen _popen
1155#define _ttempnam _tempnam
1156#define _ttmpnam tmpnam
1157#define _ttmpnam_s tmpnam_s
1158
1159#ifdef _DEBUG
1160#define _ttempnam_dbg _tempnam_dbg
1161#endif /* _DEBUG */
1162
1163
1164/* Io functions */
1165
1166#define _tchmod _chmod
1167#define _tcreat _creat
1168#define _tfindfirst _findfirst
1169#define _tfindfirst32 _findfirst32
1170#define _tfindfirst64 _findfirst64
1171#define _tfindfirsti64 _findfirsti64
1172#define _tfindfirst32i64 _findfirst32i64
1173#define _tfindfirst64i32 _findfirst64i32
1174#define _tfindnext _findnext
1175#define _tfindnext32 _findnext32
1176#define _tfindnext64 _findnext64
1177#define _tfindnexti64 _findnexti64
1178#define _tfindnext32i64 _findnext32i64
1179#define _tfindnext64i32 _findnext64i32
1180#define _tmktemp _mktemp
1181#define _tmktemp_s _mktemp_s
1182
1183#define _topen _open
1184#define _taccess _access
1185#define _taccess_s _access_s
1186
1187#define _tremove remove
1188#define _trename rename
1189#define _tsopen _sopen
1190#define _tsopen_s _sopen_s
1191#define _tunlink _unlink
1192
1193#define _tfinddata_t _finddata_t
1194#define _tfinddata32_t _finddata32_t
1195#define _tfinddata64_t __finddata64_t
1196#define _tfinddatai64_t _finddatai64_t
1197#define _tfinddata32i64_t _finddata32i64_t
1198#define _tfinddata64i32_t _finddata64i32_t
1199
1200/* ctype functions */
1201#define _istascii __isascii
1202#define _istcntrl iscntrl
1203#define _istcntrl_l _iscntrl_l
1204#define _istxdigit isxdigit
1205#define _istxdigit_l _isxdigit_l
1206
1207/* Stat functions */
1208#define _tstat _stat
1209#define _tstat32 _stat32
1210#define _tstat32i64 _stat32i64
1211#define _tstat64 _stat64
1212#define _tstat64i32 _stat64i32
1213#define _tstati64 _stati64
1214
1215
1216/* Setlocale functions */
1217
1218#define _tsetlocale setlocale
1219
1220
1221#ifdef _MBCS
1222
1223#ifndef _CRT_USE_WINAPI_FAMILY_DESKTOP_APP
1224#error Multibyte Character Set (MBCS) not supported for the current WINAPI_FAMILY.
1225#endif /* _CRT_USE_WINAPI_FAMILY_DESKTOP_APP */
1226
1227/* ++++++++++++++++++++ MBCS ++++++++++++++++++++ */
1228
1229#ifdef __cplusplus
1230} /* ... extern "C" */
1231#endif /* __cplusplus */
1232
1233#include <mbstring.h>
1234
1235#ifdef __cplusplus
1236extern "C" {
1237#endif /* __cplusplus */
1238
1239
1240#ifndef __TCHAR_DEFINED
1241typedef char _TCHAR;
1242typedef signed char _TSCHAR;
1243typedef unsigned char _TUCHAR;
1244typedef unsigned char _TXCHAR;
1245typedef unsigned int _TINT;
1246#define __TCHAR_DEFINED
1247#endif /* __TCHAR_DEFINED */
1248
1249#if defined(_CRT_INTERNAL_NONSTDC_NAMES) && _CRT_INTERNAL_NONSTDC_NAMES
1250#ifndef _TCHAR_DEFINED
1251typedef char TCHAR;
1252typedef char * PTCHAR;
1253typedef unsigned char TBYTE;
1254typedef unsigned char * PTBYTE;
1255#define _TCHAR_DEFINED
1256#endif /* _TCHAR_DEFINED */
1257#endif /* _CRT_INTERNAL_NONSTDC_NAMES */
1258
1259
1260#ifdef _MB_MAP_DIRECT
1261
1262/* use mb functions directly - types must match */
1263
1264/* String functions */
1265
1266#define _tcschr _mbschr
1267#define _tcscspn _mbscspn
1268#define _tcsncat _mbsnbcat
1269#define _tcsncat_s _mbsnbcat_s
1270#define _tcsncat_l _mbsnbcat_l
1271#define _tcsncat_s_l _mbsnbcat_s_l
1272#define _tcsncpy _mbsnbcpy
1273#define _tcsncpy_s _mbsnbcpy_s
1274#define _tcsncpy_l _mbsnbcpy_l
1275#define _tcsncpy_s_l _mbsnbcpy_s_l
1276#define _tcspbrk _mbspbrk
1277#define _tcsrchr _mbsrchr
1278#define _tcsspn _mbsspn
1279#define _tcsstr _mbsstr
1280#define _tcstok _mbstok
1281#define _tcstok_s _mbstok_s
1282#define _tcstok_l _mbstok_l
1283#define _tcstok_s_l _mbstok_s_l
1284
1285#define _tcsnset _mbsnbset
1286#define _tcsnset_l _mbsnbset_l
1287#define _tcsnset_s _mbsnbset_s
1288#define _tcsnset_s_l _mbsnbset_s_l
1289#define _tcsrev _mbsrev
1290#define _tcsset _mbsset
1291#define _tcsset_s _mbsset_s
1292#define _tcsset_l _mbsset_l
1293#define _tcsset_s_l _mbsset_s_l
1294
1295#define _tcscmp _mbscmp
1296#define _tcsicmp _mbsicmp
1297#define _tcsicmp_l _mbsicmp_l
1298#define _tcsnccmp _mbsncmp
1299#define _tcsncmp _mbsnbcmp
1300#define _tcsncicmp _mbsnicmp
1301#define _tcsncicmp_l _mbsnicmp_l
1302#define _tcsnicmp _mbsnbicmp
1303#define _tcsnicmp_l _mbsnbicmp_l
1304
1305#define _tcscoll _mbscoll
1306#define _tcscoll_l _mbscoll_l
1307#define _tcsicoll _mbsicoll
1308#define _tcsicoll_l _mbsicoll_l
1309#define _tcsnccoll _mbsncoll
1310#define _tcsnccoll_l _mbsncoll_l
1311#define _tcsncoll _mbsnbcoll
1312#define _tcsncoll_l _mbsnbcoll_l
1313#define _tcsncicoll _mbsnicoll
1314#define _tcsncicoll_l _mbsnicoll_l
1315#define _tcsnicoll _mbsnbicoll
1316#define _tcsnicoll_l _mbsnbicoll_l
1317
1318/* "logical-character" mappings */
1319
1320#define _tcsclen _mbslen
1321#define _tcscnlen _mbsnlen
1322#define _tcsclen_l _mbslen_l
1323#define _tcscnlen_l _mbsnlen_l
1324#define _tcsnccat _mbsncat
1325#define _tcsnccat_s _mbsncat_s
1326#define _tcsnccat_l _mbsncat_l
1327#define _tcsnccat_s_l _mbsncat_s_l
1328#define _tcsnccpy _mbsncpy
1329#define _tcsnccpy_s _mbsncpy_s
1330#define _tcsnccpy_l _mbsncpy_l
1331#define _tcsnccpy_s_l _mbsncpy_s_l
1332#define _tcsncset _mbsnset
1333#define _tcsncset_s _mbsnset_s
1334#define _tcsncset_l _mbsnset_l
1335#define _tcsncset_s_l _mbsnset_s_l
1336
1337/* MBCS-specific mappings */
1338
1339#define _tcsdec _mbsdec
1340#define _tcsinc _mbsinc
1341#define _tcsnbcnt _mbsnbcnt
1342#define _tcsnccnt _mbsnccnt
1343#define _tcsnextc _mbsnextc
1344#define _tcsninc _mbsninc
1345#define _tcsspnp _mbsspnp
1346
1347#define _tcslwr _mbslwr
1348#define _tcslwr_l _mbslwr_l
1349#define _tcslwr_s _mbslwr_s
1350#define _tcslwr_s_l _mbslwr_s_l
1351#define _tcsupr _mbsupr
1352#define _tcsupr_l _mbsupr_l
1353#define _tcsupr_s _mbsupr_s
1354#define _tcsupr_s_l _mbsupr_s_l
1355
1356#define _tclen _mbclen
1357#define _tccpy _mbccpy
1358#define _tccpy_l _mbccpy_l
1359#define _tccpy_s _mbccpy_s
1360#define _tccpy_s_l _mbccpy_s_l
1361
1362#else /* _MB_MAP_DIRECT */
1363
1364#if __STDC__ || defined _NO_INLINING
1365
1366/* use type-safe linked-in function thunks */
1367
1368/* String functions */
1369
1370_Check_return_ _ACRTIMP _CONST_RETURN char * __cdecl _tcschr(_In_z_ const char * _Str, _In_ unsigned int _Val);
1371_Check_return_ _ACRTIMP size_t __cdecl _tcscspn(_In_z_ const char * _Str, _In_z_ const char * _Control);
1373_ACRTIMP char * __cdecl _tcsncat_s(_Inout_updates_z_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, size_t _MaxCount);
1375_ACRTIMP char * __cdecl _tcsncat_s_l(_Inout_updates_z_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1377_ACRTIMP char * __cdecl _tcsncpy_s(_Out_writes_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, size_t _MaxCount);
1379_ACRTIMP char * __cdecl _tcsncpy_s_l(_Out_writes_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1380_Check_return_ _ACRTIMP _CONST_RETURN char * __cdecl _tcspbrk(_In_z_ const char * _Str, _In_z_ const char * _Control);
1381_Check_return_ _ACRTIMP _CONST_RETURN char * __cdecl _tcsrchr(_In_z_ const char * _Str, _In_ unsigned int _Ch);
1382_Check_return_ _ACRTIMP size_t __cdecl _tcsspn(_In_z_ const char * _Str, _In_z_ const char * _Control);
1383_Check_return_ _ACRTIMP _CONST_RETURN char * __cdecl _tcsstr(_In_z_ const char * _Str, _In_z_ const char * _Substr);
1385_Check_return_ _ACRTIMP char * __cdecl _tcstok_s(_Inout_opt_ char *_Str, _In_z_ const char *_Delim, _Inout_ _Deref_prepost_opt_z_ char **_Context);
1388
1389_CRT_INSECURE_DEPRECATE(_tcsnset_s) _ACRTIMP char * __cdecl _tcsnset(_Inout_z_ char * _Str, _In_ unsigned int _Val, _In_ size_t _MaxCount);
1390_Check_return_wat_ _ACRTIMP errno_t __cdecl _tcsnset_s(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int _Val , _In_ size_t _MaxCount);
1392_Check_return_wat_ _ACRTIMP errno_t __cdecl _tcsnset_s_l(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int _Val , _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1393_ACRTIMP char * __cdecl _tcsrev(_Inout_z_ char * _Str);
1394_CRT_INSECURE_DEPRECATE(_tcsset_s) _ACRTIMP char * __cdecl _tcsset(_Inout_z_ char * _Str, _In_ unsigned int _Val);
1396_Check_return_wat_ _ACRTIMP errno_t __cdecl _tcsset_s(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int _Val);
1397_Check_return_wat_ _ACRTIMP errno_t __cdecl _tcsset_s_l(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int, _In_opt_ _locale_t _Locale);
1398
1399_Check_return_ _ACRTIMP int __cdecl _tcscmp(_In_z_ const char *_Str1, _In_z_ const char * _Str);
1400_Check_return_ _ACRTIMP int __cdecl _tcsicmp(_In_z_ const char *_Str1, _In_z_ const char *_Str2);
1401_Check_return_ _ACRTIMP int __cdecl _tcsicmp_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_opt_ _locale_t _Locale);
1402_Check_return_ _ACRTIMP int __cdecl _tcsnccmp(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1403_Check_return_ _ACRTIMP int __cdecl _tcsncmp(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1404_Check_return_ _ACRTIMP int __cdecl _tcsncicmp(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1405_Check_return_ _ACRTIMP int __cdecl _tcsncicmp_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1406_Check_return_ _ACRTIMP int __cdecl _tcsnicmp(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1407_Check_return_ _ACRTIMP int __cdecl _tcsnicmp_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, size_t _MaxCount, _In_opt_ _locale_t _Locale);
1408
1409_Check_return_ _ACRTIMP int __cdecl _tcscoll(_In_z_ const char * _Str1, _In_z_ const char * _Str2);
1410_Check_return_ _ACRTIMP int __cdecl _tcscoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_opt_ _locale_t _Locale);
1411_Check_return_ _ACRTIMP int __cdecl _tcsicoll(_In_z_ const char * _Str1, _In_z_ const char * _Str2);
1412_Check_return_ _ACRTIMP int __cdecl _tcsicoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_opt_ _locale_t _Locale);
1413_Check_return_ _ACRTIMP int __cdecl _tcsnccoll(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1414_Check_return_ _ACRTIMP int __cdecl _tcsnccoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1415_Check_return_ _ACRTIMP int __cdecl _tcsncoll(_In_z_ const char *_Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1416_Check_return_ _ACRTIMP int __cdecl _tcsncoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, size_t _MaxCount, _In_opt_ _locale_t _Locale);
1417_Check_return_ _ACRTIMP int __cdecl _tcsncicoll(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1418_Check_return_ _ACRTIMP int __cdecl _tcsncicoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1419_Check_return_ _ACRTIMP int __cdecl _tcsnicoll(_In_z_ const char * _Str1, _In_z_ const char * _Str2, _In_ size_t _MaxCount);
1420_Check_return_ _ACRTIMP int __cdecl _tcsnicoll_l(_In_z_ const char *_Str1, _In_z_ const char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1421
1422/* "logical-character" mappings */
1423
1424_Post_satisfies_(return <= _String_length_(_Str))
1425_Check_return_ _ACRTIMP size_t __cdecl _tcsclen(_In_z_ const char *_Str);
1426
1427_Post_satisfies_(return <= _String_length_(_Str) && return <= _MaxCount)
1428_Check_return_ _ACRTIMP size_t __cdecl _tcscnlen(_In_z_ const char *_Str, _In_ size_t _MaxCount);
1429
1430_Post_satisfies_(return <= _String_length_(_Str))
1432
1433_Post_satisfies_(return <= _String_length_(_Str) && return <= _MaxCount)
1435
1436_CRT_INSECURE_DEPRECATE(_tcsnccat_s) _ACRTIMP char * __cdecl _tcsnccat(_Inout_ char *_Dst, _In_z_ const char *_Src, _In_ size_t _MaxCount);
1437_ACRTIMP char * __cdecl _tcsnccat_s(_Inout_updates_z_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount);
1439_ACRTIMP char * __cdecl _tcsnccat_s_l(_Inout_updates_z_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1441_ACRTIMP char * __cdecl _tcsnccpy_s(_Out_writes_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount);
1443_ACRTIMP char * __cdecl _tcsnccpy_s_l(_Out_writes_(_DstSizeInChars) char *_Dst, _In_ size_t _DstSizeInChars, _In_z_ const char *_Src, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1445_ACRTIMP char * __cdecl _tcsncset_s(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int _Val, _In_ size_t _MaxCount);
1447_ACRTIMP char * __cdecl _tcsncset_s_l(_Inout_updates_z_(_SizeInChars) char * _Str, _In_ size_t _SizeInChars, _In_ unsigned int _Val, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale);
1448
1449/* MBCS-specific mappings */
1450
1451_ACRTIMP char * __cdecl _tcsdec(_In_reads_z_(_Pos-_Start+1) const char * _Start, _In_z_ const char * _Pos);
1452_ACRTIMP char * __cdecl _tcsinc(_In_z_ const char * _Ptr);
1453_ACRTIMP size_t __cdecl _tcsnbcnt(_In_reads_or_z_(_MaxCount) const char * _Str, _In_ size_t _MaxCount);
1454_ACRTIMP size_t __cdecl _tcsnccnt(_In_reads_or_z_(_MaxCount) const char * _Str, _In_ size_t _MaxCount);
1455_ACRTIMP unsigned int __cdecl _tcsnextc (_In_z_ const char * _Str);
1456_ACRTIMP char * __cdecl _tcsninc(_In_reads_or_z_(_Count) const char * _Ptr, _In_ size_t _Count);
1457_ACRTIMP char * __cdecl _tcsspnp(_In_z_ const char * _Str1, _In_z_ const char * _Str2);
1458
1461_ACRTIMP char * __cdecl _tcslwr_s(_Inout_updates_z_(_SizeInChars) char *_Str, _In_ size_t _SizeInChars);
1462_ACRTIMP char * __cdecl _tcslwr_s_l(_Inout_updates_z_(_SizeInChars) char *_Str, _In_ size_t _SizeInChars, _In_opt_ _locale_t _Locale);
1465_ACRTIMP char * __cdecl _tcsupr_s(_Inout_updates_z_(_SizeInChars) char *_Str, _In_ size_t _SizeInChars);
1466_ACRTIMP char * __cdecl _tcsupr_s_l(_Inout_updates_z_(_SizeInChars) char *_Str, _In_ size_t _SizeInChars, _In_opt_ _locale_t _Locale);
1467
1468_Check_return_ _ACRTIMP size_t __cdecl _tclen(_In_z_ const char * _Str);
1469_CRT_INSECURE_DEPRECATE(_tccpy_s) _ACRTIMP void __cdecl _tccpy(_Pre_notnull_ _Post_z_ char * _DstCh, _In_z_ const char * _SrcCh);
1470_CRT_INSECURE_DEPRECATE(_tccpy_s_l) _ACRTIMP void __cdecl _tccpy_l(_Pre_notnull_ _Post_z_ char * _DstCh, _In_z_ const char * _SrcCh, _In_opt_ _locale_t _Locale);
1471_Check_return_wat_ _ACRTIMP errno_t __cdecl _tccpy_s(_Out_writes_z_(_SizeInBytes) char * _DstCh, size_t _SizeInBytes, _Out_opt_ int *_PCopied, _In_z_ const char * _SrcCh);
1472_Check_return_wat_ _ACRTIMP errno_t __cdecl _tccpy_s_l(_Out_writes_z_(_SizeInBytes) char * _DstCh, size_t _SizeInBytes, _Out_opt_ int *_PCopied, _In_z_ const char * _SrcCh, _In_opt_ _locale_t _Locale);
1473
1474#else /* __STDC__ || defined (_NO_INLINING) */
1475
1476/* the default: use type-safe inline function thunks */
1477
1478#define _PUC unsigned char *
1479#define _CPUC const unsigned char *
1480#define _PC char *
1481#define _CRPC _CONST_RETURN char *
1482#define _CPC const char *
1483#define _UI unsigned int
1484
1485
1486/* String functions */
1487
1488__inline _CRPC _tcschr(_In_z_ _CPC _s1,_In_ _UI _c) {return (_CRPC)_mbschr((_CPUC)_s1,_c);}
1489__inline size_t _tcscspn(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return _mbscspn((_CPUC)_s1,(_CPUC)_s2);}
1490
1492{
1493 return _mbsnbcat_s((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source,_Count);
1494}
1495
1497
1499{
1500 return (char *)_mbsnbcat((unsigned char *)_Dst,(const unsigned char *)_Source,_Count);
1501}
1502
1504
1506{
1507 return _mbsnbcat_s_l((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source,_Count, _Locale);
1508}
1509
1511
1513{
1514 return (char *)_mbsnbcat_l((unsigned char *)_Dst,(const unsigned char *)_Source,_Count, _Locale);
1515}
1516
1518
1520{
1521 return _mbsnbcpy_s((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source,_Count);
1522}
1523
1525
1527{
1528 return (char *)_mbsnbcpy((unsigned char *)_Dst,(const unsigned char *)_Source,_Count);
1529}
1530
1532
1534{
1535 return _mbsnbcpy_s_l((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source,_Count, _Locale);
1536}
1537
1539
1541{
1542 return (char *)_mbsnbcpy_l((unsigned char *)_Dst,(const unsigned char *)_Source,_Count, _Locale);
1543}
1544
1546
1547_Check_return_ __inline _CRPC _tcspbrk(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return (_CRPC)_mbspbrk((_CPUC)_s1,(_CPUC)_s2);}
1548_Check_return_ __inline _CRPC _tcsrchr(_In_z_ _CPC _s1,_In_ _UI _c) {return (_CRPC)_mbsrchr((_CPUC)_s1,_c);}
1549_Check_return_ __inline size_t _tcsspn(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return _mbsspn((_CPUC)_s1,(_CPUC)_s2);}
1550_Check_return_ __inline _CRPC _tcsstr(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return (_CRPC)_mbsstr((_CPUC)_s1,(_CPUC)_s2);}
1551
1553{
1554 return (char * )_mbstok((unsigned char *)_String,(const unsigned char *)_Delimiters);
1555}
1556
1557_Check_return_ __inline char * _tcstok_s(_Inout_opt_z_ char * _String,_In_z_ const char * _Delimiters, _Inout_ _Deref_prepost_opt_z_ char **_Current_position)
1558{
1559 return (char * )_mbstok_s((unsigned char *)_String,(const unsigned char *)_Delimiters, (unsigned char **)_Current_position);
1560}
1561
1563{
1564 return (char * )_mbstok_l((unsigned char *)_String,(const unsigned char *)_Delimiters, _Locale);
1565}
1566
1568{
1569 return (char * )_mbstok_s_l((unsigned char *)_String,(const unsigned char *)_Delimiters, (unsigned char **)_Current_position, _Locale);
1570}
1571
1573{
1574 return _mbsnbset_s((unsigned char *)_Dst, _SizeInBytes, _Value, _Count);
1575}
1576
1578
1580{
1581 return (char *)_mbsnbset((unsigned char *)_Dst, _Value, _Count);
1582}
1583
1585
1587{
1588 return _mbsnbset_s_l((unsigned char *)_Dst, _SizeInBytes, _Value, _Count, _Locale);
1589}
1590
1592
1594{
1595 return (char *)_mbsnbset_l((unsigned char *)_Dst, _Value, _Count, _Locale);
1596}
1597
1599
1600__inline _PC _tcsrev(_Inout_z_ _PC _s1) {return (_PC)_mbsrev((_PUC)_s1);}
1601
1603{
1604 return _mbsset_s((unsigned char *)_Dst, _SizeInBytes, _Value);
1605}
1606
1608
1610{
1611 return (char *)_mbsset((unsigned char *)_Dst, _Value);
1612}
1613
1615
1617{
1618 return _mbsset_s_l((unsigned char *)_Dst, _SizeInBytes, _Value, _Locale);
1619}
1620
1622
1624{
1625 return (char *)_mbsset_l((unsigned char *)_Dst, _Value, _Locale);
1626}
1627
1629
1630_Check_return_ __inline int _tcscmp(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return _mbscmp((_CPUC)_s1,(_CPUC)_s2);}
1631
1632_Check_return_ __inline int _tcsicmp(_In_z_ const char * _String1, _In_z_ const char * _String2)
1633{
1634 return _mbsicmp((const unsigned char *)_String1,(const unsigned char *)_String2);
1635}
1636
1637_Check_return_ __inline int _tcsicmp_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_opt_ _locale_t _Locale)
1638{
1639 return _mbsicmp_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Locale);
1640}
1641
1642_Check_return_ __inline int _tcsnccmp(_In_reads_or_z_(_n) _CPC _s1,_In_z_ _CPC _s2,_In_ size_t _n) {return _mbsncmp((_CPUC)_s1,(_CPUC)_s2,_n);}
1643__inline int _tcsncmp(_In_z_ _CPC _s1,_In_z_ _CPC _s2,_In_ size_t _n) {return _mbsnbcmp((_CPUC)_s1,(_CPUC)_s2,_n);}
1644
1645_Check_return_ __inline int _tcsncicmp(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Char_count)
1646{
1647 return _mbsnicmp((const unsigned char *)_String1,(const unsigned char *)_String2,_Char_count);
1648}
1649
1650_Check_return_ __inline int _tcsncicmp_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Char_count, _In_opt_ _locale_t _Locale)
1651{
1652 return _mbsnicmp_l((const unsigned char *)_String1,(const unsigned char *)_String2,_Char_count, _Locale);
1653}
1654
1655_Check_return_ __inline int _tcsnicmp(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Char_count)
1656{
1657 return _mbsnbicmp((const unsigned char *)_String1,(const unsigned char *)_String2,_Char_count);
1658}
1659
1660_Check_return_ __inline int _tcsnicmp_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Char_count, _In_opt_ _locale_t _Locale)
1661{
1662 return _mbsnbicmp_l((const unsigned char *)_String1,(const unsigned char *)_String2,_Char_count, _Locale);
1663}
1664
1665_Check_return_ __inline int _tcscoll(_In_z_ const char * _String1, _In_z_ const char * _String2)
1666{
1667 return _mbscoll((const unsigned char *)_String1,(const unsigned char *)_String2);
1668}
1669
1670_Check_return_ __inline int _tcscoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_opt_ _locale_t _Locale)
1671{
1672 return _mbscoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Locale);
1673}
1674
1675_Check_return_ __inline int _tcsicoll(_In_z_ const char * _String1, _In_z_ const char * _String2)
1676{
1677 return _mbsicoll((const unsigned char *)_String1,(const unsigned char *)_String2);
1678}
1679
1680_Check_return_ __inline int _tcsicoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_opt_ _locale_t _Locale)
1681{
1682 return _mbsicoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Locale);
1683}
1684
1685_Check_return_ __inline int _tcsnccoll(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count)
1686{
1687 return _mbsncoll((const unsigned char *)_String1,(const unsigned char *)_String2, _Count);
1688}
1689
1690_Check_return_ __inline int _tcsnccoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
1691{
1692 return _mbsncoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Count, _Locale);
1693}
1694
1695_Check_return_ __inline int _tcsncoll(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count)
1696{
1697 return _mbsnbcoll((const unsigned char *)_String1,(const unsigned char *)_String2, _Count);
1698}
1699
1700_Check_return_ __inline int _tcsncoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
1701{
1702 return _mbsnbcoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Count, _Locale);
1703}
1704
1705_Check_return_ __inline int _tcsncicoll(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count)
1706{
1707 return _mbsnicoll((const unsigned char *)_String1,(const unsigned char *)_String2, _Count);
1708}
1709
1710_Check_return_ __inline int _tcsncicoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
1711{
1712 return _mbsnicoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Count, _Locale);
1713}
1714
1715_Check_return_ __inline int _tcsnicoll(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count)
1716{
1717 return _mbsnbicoll((const unsigned char *)_String1,(const unsigned char *)_String2, _Count);
1718}
1719
1720_Check_return_ __inline int _tcsnicoll_l(_In_z_ const char * _String1, _In_z_ const char * _String2, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
1721{
1722 return _mbsnbicoll_l((const unsigned char *)_String1,(const unsigned char *)_String2, _Count, _Locale);
1723}
1724
1725/* "logical-character" mappings */
1726_Check_return_ __inline size_t _tcsclen(_In_z_ const char * _String)
1727{
1728 return _mbslen((const unsigned char *)_String);
1729}
1730
1731_Check_return_ __inline size_t _tcscnlen(_In_z_ const char * _String, _In_ size_t _Maximum)
1732{
1733 return _mbsnlen((const unsigned char *)_String, _Maximum);
1734}
1735
1737{
1738 return _mbslen_l((const unsigned char *)_String, _Locale);
1739}
1740
1741_Check_return_ __inline size_t _tcscnlen_l(_In_z_ const char * _String, _In_ size_t _Maximum, _In_opt_ _locale_t _Locale)
1742{
1743 return _mbsnlen_l((const unsigned char *)_String, _Maximum, _Locale);
1744}
1745
1747{
1748 return _mbsncat_s((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source, _Count);
1749}
1750
1752
1754{
1755 return (char *)_mbsncat((unsigned char *)_Dst,(const unsigned char *)_Source, _Count);
1756}
1757
1759
1761{
1762 return _mbsncat_s_l((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source, _Count, _Locale);
1763}
1764
1766
1768{
1769 return (char *)_mbsncat_l((unsigned char *)_Dst,(const unsigned char *)_Source, _Count, _Locale);
1770}
1771
1773
1775{
1776 return _mbsncpy_s((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source, _Count);
1777}
1778
1780
1782{
1783 return (char *)_mbsncpy((unsigned char *)_Dst,(const unsigned char *)_Source, _Count);
1784}
1785
1787
1789{
1790 return _mbsncpy_s_l((unsigned char *)_Destination, _Destination_size_chars, (const unsigned char *)_Source, _Count, _Locale);
1791}
1792
1794
1796{
1797 return (char *)_mbsncpy_l((unsigned char *)_Dst,(const unsigned char *)_Source, _Count, _Locale);
1798}
1799
1801
1803{
1804 return _mbsnset_s((unsigned char *)_Destination, _SizeInBytes, _Value, _Count);
1805}
1806
1808
1810{
1811 return (char *)_mbsnset((unsigned char *)_Dst, _Value, _Count);
1812}
1813
1815
1817{
1818 return _mbsnset_s_l((unsigned char *)_Destination, _SizeInBytes, _Value, _Count, _Locale);
1819}
1820
1822
1824{
1825 return (char *)_mbsnset_l((unsigned char *)_Dst, _Value, _Count, _Locale);
1826}
1827
1829
1830/* MBCS-specific mappings */
1831
1832_Check_return_ __inline _PC _tcsdec(_In_reads_z_(_s2 - _s1 + 1) _CPC _s1,_In_z_ _CPC _s2) {return (_PC)_mbsdec((_CPUC)_s1,(_CPUC)_s2);}
1833_Check_return_ __inline _PC _tcsinc(_In_z_ _CPC _s1) {return (_PC)_mbsinc((_CPUC)_s1);}
1834_Check_return_ __inline size_t _tcsnbcnt(_In_reads_or_z_(_n) _CPC _s1,_In_ size_t _n) {return _mbsnbcnt((_CPUC)_s1,_n);}
1835_Check_return_ __inline size_t _tcsnccnt(_In_reads_or_z_(_n) _CPC _s1,_In_ size_t _n) {return _mbsnccnt((_CPUC)_s1,_n);}
1836_Check_return_ __inline _PC _tcsninc(_In_reads_or_z_(_n) _CPC _s1,_In_ size_t _n) {return (_PC)_mbsninc((_CPUC)_s1,_n);}
1837_Check_return_ __inline _PC _tcsspnp(_In_z_ _CPC _s1,_In_z_ _CPC _s2) {return (_PC)_mbsspnp((_CPUC)_s1,(_CPUC)_s2);}
1838
1840{
1841 return _mbslwr_s((unsigned char *)_String, _SizeInBytes);
1842}
1843
1845
1847{
1848 return (char *)_mbslwr((unsigned char *)_String);
1849}
1850
1852
1854{
1855 return _mbslwr_s_l((unsigned char *)_String, _SizeInBytes, _Locale);
1856}
1857
1859
1861{
1862 return (char *)_mbslwr_l((unsigned char *)_String, _Locale);
1863}
1864
1866
1868{
1869 return _mbsupr_s((unsigned char *)_String, _Count);
1870}
1871
1873
1875{
1876 return (char *)_mbsupr((unsigned char *)_String);
1877}
1878
1880
1882{
1883 return _mbsupr_s_l((unsigned char *)_String, _Count, _Locale);
1884}
1885
1887
1889{
1890 return (char *)_mbsupr_l((unsigned char *)_String, _Locale);
1891}
1892
1894
1895_Check_return_ __inline size_t _tclen(_In_z_ _CPC _s1) {return _mbclen((_CPUC)_s1);}
1896
1898{
1899 return _mbccpy_s((unsigned char *)_Destination, _SizeInBytes, _PCopied, (const unsigned char *)_Source);
1900}
1901
1902__DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_2(errno_t, _tccpy_s, _Post_z_ char, _Dest, _Out_opt_ int *, _PCopied, _In_z_ const char *, _Source)
1903
1904_CRT_INSECURE_DEPRECATE(_tccpy_s) __inline void _tccpy(_Out_writes_z_(2) char * _Destination, _In_z_ const char * _Source)
1905{
1906 _mbccpy((unsigned char *)_Destination, (const unsigned char *)_Source);
1907}
1908
1910{
1911 return _mbccpy_s_l((unsigned char *)_Destination, _SizeInBytes, _PCopied, (const unsigned char *)_Source, _Locale);
1912}
1913
1915
1917{
1918 _mbccpy_l((unsigned char *)_Destination,( const unsigned char *)_Source, _Locale);
1919}
1920
1921/* inline helper */
1923{
1924 _UI _n=0;
1925 if (_ismbblead((_UI)*(_PUC)_s1))
1926 {
1927 /* for a dud MBCS string (leadbyte, EOS), we don't move forward 2
1928 We do not assert here because this routine is too low-level
1929 */
1930 if(_s1[1]!='\0')
1931 {
1932 _n=((_UI)*(_PUC)_s1)<<8;
1933 _s1++;
1934 }
1935 }
1936 _n+=(_UI)*(_PUC)_s1;
1937
1938 return(_n);
1939}
1940
1941#endif /* __STDC__ || defined (_NO_INLINING) */
1942
1943#ifdef __cplusplus
1944#ifndef _CPP_TCHAR_INLINES_DEFINED
1945#define _CPP_TCHAR_INLINES_DEFINED
1946extern "C++" {
1947_Check_return_ inline char * __CRTDECL _tcschr(_In_z_ char *_S, _In_ unsigned int _C)
1948 {return ((char *)_tcschr((const char *)_S, _C)); }
1949_Check_return_ inline char * __CRTDECL _tcspbrk(_In_z_ char *_S, _In_z_ const char *_P)
1950 {return ((char *)_tcspbrk((const char *)_S, _P)); }
1951_Check_return_ inline char * __CRTDECL _tcsrchr(_In_z_ char *_S, _In_ unsigned int _C)
1952 {return ((char *)_tcsrchr((const char *)_S, _C)); }
1953_Check_return_ inline char * __CRTDECL _tcsstr(_In_z_ char *_S, _In_z_ const char *_P)
1954 {return ((char *)_tcsstr((const char *)_S, _P)); }
1955}
1956#endif /* _CPP_TCHAR_INLINES_DEFINED */
1957#endif /* __cplusplus */
1958
1959#endif /* _MB_MAP_DIRECT */
1960
1961
1962/* MBCS-specific mappings */
1963
1964#define _tccmp(_cp1,_cp2) _tcsnccmp(_cp1,_cp2,1)
1965
1966
1967/* ctype functions */
1968
1969#define _istalnum _ismbcalnum
1970#define _istalnum_l _ismbcalnum_l
1971#define _istalpha _ismbcalpha
1972#define _istalpha_l _ismbcalpha_l
1973#define _istdigit _ismbcdigit
1974#define _istdigit_l _ismbcdigit_l
1975#define _istgraph _ismbcgraph
1976#define _istgraph_l _ismbcgraph_l
1977#define _istlegal _ismbclegal
1978#define _istlegal_l _ismbclegal_l
1979#define _istlower _ismbclower
1980#define _istlower_l _ismbclower_l
1981#define _istprint _ismbcprint
1982#define _istprint_l _ismbcprint_l
1983#define _istpunct _ismbcpunct
1984#define _istpunct_l _ismbcpunct_l
1985#define _istblank _ismbcblank
1986#define _istblank_l _ismbcblank_l
1987#define _istspace _ismbcspace
1988#define _istspace_l _ismbcspace_l
1989#define _istupper _ismbcupper
1990#define _istupper_l _ismbcupper_l
1991
1992#define _totupper _mbctoupper
1993#define _totupper_l _mbctoupper_l
1994#define _totlower _mbctolower
1995#define _totlower_l _mbctolower_l
1996
1997#define _istlead _ismbblead
1998#define _istleadbyte isleadbyte
1999#define _istleadbyte_l _isleadbyte_l
2000
2001#else /* _MBCS */
2002
2003/* ++++++++++++++++++++ SBCS ++++++++++++++++++++ */
2004
2005
2006#ifndef __TCHAR_DEFINED
2007typedef char _TCHAR;
2008typedef signed char _TSCHAR;
2009typedef unsigned char _TUCHAR;
2010typedef char _TXCHAR;
2011typedef int _TINT;
2012#define __TCHAR_DEFINED
2013#endif /* __TCHAR_DEFINED */
2014
2015#if defined(_CRT_INTERNAL_NONSTDC_NAMES) && _CRT_INTERNAL_NONSTDC_NAMES
2016#ifndef _TCHAR_DEFINED
2017typedef char TCHAR;
2018typedef char * PTCHAR;
2019typedef unsigned char TBYTE;
2020typedef unsigned char * PTBYTE;
2021#define _TCHAR_DEFINED
2022#endif /* _TCHAR_DEFINED */
2023#endif /* _CRT_INTERNAL_NONSTDC_NAMES */
2024
2025
2026/* String functions */
2027
2028#define _tcschr strchr
2029#define _tcscspn strcspn
2030#define _tcsncat strncat
2031#define _tcsncat_s strncat_s
2032#define _tcsncat_l _strncat_l
2033#define _tcsncat_s_l _strncat_s_l
2034#define _tcsncpy strncpy
2035#define _tcsncpy_s strncpy_s
2036#define _tcsncpy_l _strncpy_l
2037#define _tcsncpy_s_l _strncpy_s_l
2038#define _tcspbrk strpbrk
2039#define _tcsrchr strrchr
2040#define _tcsspn strspn
2041#define _tcsstr strstr
2042#define _tcstok strtok
2043#define _tcstok_s strtok_s
2044#define _tcstok_l _strtok_l
2045#define _tcstok_s_l _strtok_s_l
2046
2047#define _tcsnset _strnset
2048#define _tcsnset_s _strnset_s
2049#define _tcsnset_l _strnset_l
2050#define _tcsnset_s_l _strnset_s_l
2051#define _tcsrev _strrev
2052#define _tcsset _strset
2053#define _tcsset_s _strset_s
2054#define _tcsset_l _strset_l
2055#define _tcsset_s_l _strset_s_l
2056
2057#define _tcscmp strcmp
2058#define _tcsicmp _stricmp
2059#define _tcsicmp_l _stricmp_l
2060#define _tcsnccmp strncmp
2061#define _tcsncmp strncmp
2062#define _tcsncicmp _strnicmp
2063#define _tcsncicmp_l _strnicmp_l
2064#define _tcsnicmp _strnicmp
2065#define _tcsnicmp_l _strnicmp_l
2066
2067#define _tcscoll strcoll
2068#define _tcscoll_l _strcoll_l
2069#define _tcsicoll _stricoll
2070#define _tcsicoll_l _stricoll_l
2071#define _tcsnccoll _strncoll
2072#define _tcsnccoll_l _strncoll_l
2073#define _tcsncoll _strncoll
2074#define _tcsncoll_l _strncoll_l
2075#define _tcsncicoll _strnicoll
2076#define _tcsncicoll_l _strnicoll_l
2077#define _tcsnicoll _strnicoll
2078#define _tcsnicoll_l _strnicoll_l
2079
2080/* "logical-character" mappings */
2081
2082#define _tcsclen strlen
2083#define _tcscnlen strnlen
2084#define _tcsclen_l(_String, _Locale) strlen(_String)
2085#define _tcscnlen_l(_String, _Max_count, _Locale) strnlen((_String), (_Max_count))
2086#define _tcsnccat strncat
2087#define _tcsnccat_s strncat_s
2088#define _tcsnccat_l _strncat_l
2089#define _tcsnccat_s_l _strncat_s_l
2090#define _tcsnccpy strncpy
2091#define _tcsnccpy_s strncpy_s
2092#define _tcsnccpy_l _strncpy_l
2093#define _tcsnccpy_s_l _strncpy_s_l
2094#define _tcsncset _strnset
2095#define _tcsncset_s _strnset_s
2096#define _tcsncset_l _strnset_l
2097#define _tcsncset_s_l _strnset_s_l
2098
2099/* MBCS-specific functions */
2100
2101#define _tcsdec _strdec
2102#define _tcsinc _strinc
2103#define _tcsnbcnt _strncnt
2104#define _tcsnccnt _strncnt
2105#define _tcsnextc _strnextc
2106#define _tcsninc _strninc
2107#define _tcsspnp _strspnp
2108
2109#define _tcslwr _strlwr
2110#define _tcslwr_l _strlwr_l
2111#define _tcslwr_s _strlwr_s
2112#define _tcslwr_s_l _strlwr_s_l
2113#define _tcsupr _strupr
2114#define _tcsupr_l _strupr_l
2115#define _tcsupr_s _strupr_s
2116#define _tcsupr_s_l _strupr_s_l
2117#define _tcsxfrm strxfrm
2118#define _tcsxfrm_l _strxfrm_l
2119
2120#define _istlead(_Char) (0)
2121#define _istleadbyte(_Char) (0)
2122#define _istleadbyte_l(_Char, _Locale) (0)
2123
2124#if __STDC__ || defined (_NO_INLINING)
2125#define _tclen(_pc) (1)
2126#define _tccpy(_pc1,_cpc2) (*(_pc1) = *(_cpc2))
2127#define _tccpy_l(_pc1,_cpc2,_locale) _tccpy((_pc1),(_cpc2))
2128#define _tccmp(_cpc1,_cpc2) (((unsigned char)*(_cpc1))-((unsigned char)*(_cpc2)))
2129#else /* __STDC__ || defined (_NO_INLINING) */
2131{
2132 _CRT_UNUSED(_cpc);
2133 return 1;
2134}
2135__inline void __CRTDECL _tccpy(_Out_ char *_pc1, _In_z_ const char *_cpc2) { *_pc1 = *_cpc2; }
2136__inline void __CRTDECL _tccpy_l(_Out_ char *_Pc1, _In_z_ const char *_Cpc2, _In_opt_ _locale_t _Locale)
2137{
2139 _tccpy(_Pc1, _Cpc2);
2140}
2141_Check_return_ __inline int __CRTDECL _tccmp(_In_z_ const char *_cpc1, _In_z_ const char *_cpc2) { return (int) (((unsigned char)*_cpc1)-((unsigned char)*_cpc2)); }
2142#endif /* __STDC__ || defined (_NO_INLINING) */
2143
2144
2145/* ctype-functions */
2146
2147#define _istalnum isalnum
2148#define _istalnum_l _isalnum_l
2149#define _istalpha isalpha
2150#define _istalpha_l _isalpha_l
2151#define _istdigit isdigit
2152#define _istdigit_l _isdigit_l
2153#define _istgraph isgraph
2154#define _istgraph_l _isgraph_l
2155#define _istlower islower
2156#define _istlower_l _islower_l
2157#define _istprint isprint
2158#define _istprint_l _isprint_l
2159#define _istpunct ispunct
2160#define _istpunct_l _ispunct_l
2161#define _istblank isblank
2162#define _istblank_l _isblank_l
2163#define _istspace isspace
2164#define _istspace_l _isspace_l
2165#define _istupper isupper
2166#define _istupper_l _isupper_l
2167
2168#define _totupper toupper
2169#define _totupper_l _toupper_l
2170#define _totlower tolower
2171#define _totlower_l _tolower_l
2172
2173#define _istlegal(_c) (1)
2174
2175
2176/* the following is optional if functional versions are available */
2177
2178#if __STDC__ || defined (_NO_INLINING)
2179#define _strdec(_cpc1, _cpc2) ((_cpc1)>=(_cpc2) ? NULL : (_cpc2)-1)
2180#define _strinc(_pc) ((_pc)+1)
2181#define _strnextc(_cpc) ((unsigned int) *(const unsigned char *)(_cpc))
2182#define _strninc(_pc, _sz) (((_pc)+(_sz)))
2183_ACRTIMP size_t __cdecl __strncnt(_In_reads_or_z_(_Cnt) const char * _Str, _In_ size_t _Cnt);
2184#define _strncnt(_cpc, _sz) (__strncnt(_cpc,_sz))
2185#define _strspnp(_cpc1, _cpc2) (_cpc1==NULL ? NULL : ((*((_cpc1)+strspn(_cpc1,_cpc2))) ? ((_cpc1)+strspn(_cpc1,_cpc2)) : NULL))
2186
2187#define _strncpy_l(_Destination, _Source, _Count, _Locale) (strncpy(_Destination, _Source, _Count))
2188#if __STDC_WANT_SECURE_LIB__
2189#define _strncpy_s_l(_Destination, _Destination_size_chars, _Source, _Count, _Locale) (strncpy_s(_Destination, _Destination_size_chars, _Source, _Count))
2190#endif /* __STDC_WANT_SECURE_LIB__ */
2191#define _strncat_l(_Destination, _Source, _Count, _Locale) (strncat(_Destination, _Source, _Count))
2192#if __STDC_WANT_SECURE_LIB__
2193#define _strncat_s_l(_Destination, _Destination_size_chars, _Source, _Count, _Locale) (strncat_s(_Destination, _Destination_size_chars, _Source, _Count))
2194#endif /* __STDC_WANT_SECURE_LIB__ */
2195#define _strtok_l(_String, _Delimiters, _Locale) (strtok(_String, _Delimiters))
2196#if __STDC_WANT_SECURE_LIB__
2197#define _strtok_s_l(_String, _Delimiters, _Current_position, _Locale) (strtok_s(_String, _Delimiters, _Current_position))
2198#endif /* __STDC_WANT_SECURE_LIB__ */
2199#define _strnset_l(_Destination, _Value, _Count, _Locale) (_strnset(_Destination, _Value, _Count))
2200#define _strnset_s_l(_Destination, _Destination_size_chars, _Value, _Count, _Locale) (_strnset_s(_Destination, _Destination_size_chars, _Value, _Count))
2201#define _strset_l(_Destination, _Value, _Locale) (_strset(_Destination, _Value))
2202#define _strset_s_l(_Destination, _Destination_size_chars, _Value, _Locale) (_strset_s(_Destination, _Destination_size_chars, _Value))
2203#else /* __STDC__ || defined (_NO_INLINING) */
2204_Check_return_ __inline char * __CRTDECL _strdec(_In_reads_z_(_Cpc2 - _Cpc1) const char * _Cpc1, _In_z_ const char * _Cpc2) { return (char *)((_Cpc1)>=(_Cpc2) ? NULL : (_Cpc2-1)); }
2205_Check_return_ __inline char * __CRTDECL _strinc(_In_z_ const char * _Pc) { return (char *)(_Pc+1); }
2206_Check_return_ __inline unsigned int __CRTDECL _strnextc(_In_z_ const char * _Cpc) { return (unsigned int)*(const unsigned char *)_Cpc; }
2207_Check_return_ __inline char * __CRTDECL _strninc(_In_reads_or_z_(_Sz) const char * _Pc, _In_ size_t _Sz) { return (char *)(_Pc+_Sz); }
2209{
2210 size_t n = _Cnt;
2211 char *cp = (char *)_String;
2212 while (n-- && *cp)
2213 cp++;
2214 return _Cnt - n - 1;
2215}
2217(
2218 _In_z_ const char * _Cpc1,
2219 _In_z_ const char * _Cpc2
2220)
2221{
2222 return _Cpc1==NULL ? NULL : ((*(_Cpc1 += strspn(_Cpc1,_Cpc2))!='\0') ? (char*)_Cpc1 : NULL);
2223}
2224
2225#if __STDC_WANT_SECURE_LIB__
2227{
2230}
2231#endif /* __STDC_WANT_SECURE_LIB__ */
2232
2234
2236{
2238 return strncpy(_Dst, _Source, _Count);
2239}
2240
2242
2243#if __STDC_WANT_SECURE_LIB__
2245{
2248}
2249#endif /* __STDC_WANT_SECURE_LIB__ */
2250
2252
2254{
2256#pragma warning(suppress: 6054) // String may not be zero-terminated
2257 return strncat(_Dst, _Source, _Count);
2258}
2259
2261
2263{
2266}
2267
2268#if __STDC_WANT_SECURE_LIB__
2269_Check_return_ __inline char * _strtok_s_l(_Inout_opt_z_ char * _String, _In_z_ const char * _Delimiters, _Inout_ _Deref_prepost_opt_z_ char **_Current_position, _In_opt_ _locale_t _Locale)
2270{
2272 return strtok_s(_String, _Delimiters, _Current_position);
2273}
2274#endif /* __STDC_WANT_SECURE_LIB__ */
2275
2277{
2280}
2281
2283
2285{
2287#pragma warning(suppress: 6054) // String may not be zero-terminated
2288 return _strnset(_Dst, _Value, _MaxCount);
2289}
2290
2292
2294{
2297}
2298
2300
2302{
2304 return _strset(_Dst, _Value);
2305}
2306
2308
2309#endif /* __STDC__ || defined (_NO_INLINING) */
2310
2311
2312#endif /* _MBCS */
2313
2314#endif /* _UNICODE */
2315
2316
2317/* Generic text macros to be used with string literals and character constants.
2318 Will also allow symbolic constants that resolve to same. */
2319
2320#define _T(x) __T(x)
2321#define _TEXT(x) __T(x)
2322
2323
2324#ifdef __cplusplus
2325} /* ... extern "C" */
2326#endif /* __cplusplus */
2328#pragma warning(pop) // _UCRT_DISABLED_WARNINGS
2329#endif /* _INC_TCHAR */
2330
int wint_t
Definition: _apple.h:38
#define __inline
Definition: _wctype.cpp:15
#define __cdecl
Definition: accygwin.h:79
_wcsnset_s
wcsncat
_In_z_ wchar_t const * _String2
_wcsset
wcsncpy
_Source
_Check_return_ _In_z_ wchar_t const _Inout_opt_ _Deref_prepost_opt_z_ wchar_t ** _Context
_Destination
_wcsnset
_String
wcsncat_s
_wcsset_s
#define __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_3(_ReturnType, _FuncName, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2, _TType3, _TArg3)
Definition: corecrt.h:179
#define __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_1(_ReturnType, _FuncName, _DstType, _Dst, _TType1, _TArg1)
Definition: corecrt.h:177
#define __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_2(_ReturnType, _FuncName, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2)
Definition: corecrt.h:178
#define __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_0(_ReturnType, _FuncName, _DstType, _Dst)
Definition: corecrt.h:176
_Check_return_ _Ret_maybenull_ _In_ size_t _In_ size_t _Size
Definition: malloc.h:109
_Check_return_ _Ret_maybenull_ _In_ size_t _Count
Definition: malloc.h:108
#define NULL
Definition: types.h:112
unsigned char
Definition: typeof.h:29
GLdouble n
Definition: glext.h:7729
_Check_return_ _CRTIMP int __cdecl _mbsnicmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_CRTIMP unsigned char *__cdecl _mbsncpy_l(_Out_writes_(_Count) _Post_maybez_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsnbicoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP int __cdecl _mbsicoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_opt_ _locale_t _Locale)
_CRTIMP unsigned char *__cdecl _mbsupr(_Inout_z_ unsigned char *_String)
_CRTIMP unsigned char *__cdecl _mbsnbset(_Inout_updates_z_(_MaxCount) unsigned char *_Str, _In_ unsigned int _Ch, _In_ size_t _MaxCount)
_CRTIMP unsigned char * _mbsupr_l(_Inout_z_ unsigned char *_String, _In_opt_ _locale_t _Locale)
_CRTIMP errno_t __cdecl _mbsnbcpy_s(_Out_writes_z_(_DstSizeInBytes) unsigned char *_Dst, _In_ size_t _DstSizeInBytes, _In_z_ const unsigned char *_Src, _In_ size_t _MaxCount)
_CRTIMP unsigned char *__cdecl _mbsset(_Inout_z_ unsigned char *_Str, _In_ unsigned int _Val)
_Check_return_ _CRTIMP size_t __cdecl _mbsnlen(_In_z_ const unsigned char *_Str, _In_ size_t _MaxCount)
Definition: _mbsnlen.c:15
_CRTIMP unsigned char *__cdecl _mbsncpy(_Pre_notnull_ _Out_writes_(2 *_Count) _Post_maybez_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count)
_CRTIMP unsigned char *__cdecl _mbsnbset_l(_Inout_updates_z_(_MaxCount) unsigned char *_Str, _In_ unsigned int _Ch, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsnbicmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP int __cdecl _mbsnbicoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_CRTIMP unsigned char *__cdecl _mbsncat_l(_Inout_z_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP size_t __cdecl _mbscspn(_In_z_ const unsigned char *_Str, _In_z_ const unsigned char *_Control)
_CRTIMP unsigned char *__cdecl _mbsnbcpy_l(_Out_writes_(_Count) _Post_maybez_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsicmp_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsnicmp_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP _CONST_RETURN unsigned char *__cdecl _mbsstr(_In_z_ const unsigned char *_Str, _In_z_ const unsigned char *_Substr)
_CRTIMP unsigned char *__cdecl _mbsncat(_Inout_z_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count)
_CRTIMP unsigned char *__cdecl _mbsnset(_Inout_updates_z_(_MaxCount) unsigned char *_Dst, _In_ unsigned int _Val, _In_ size_t _MaxCount)
_CRTIMP unsigned char *__cdecl _mbsnbcat(_Inout_z_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count)
_Check_return_ _CRTIMP _CONST_RETURN unsigned char *__cdecl _mbsrchr(_In_z_ const unsigned char *_Str, _In_ unsigned int _Ch)
_CRTIMP unsigned char *__cdecl _mbsnset_l(_Inout_updates_z_(_MaxCount) unsigned char *_Dst, _In_ unsigned int _Val, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsncoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP size_t __cdecl _mbsspn(_In_z_ const unsigned char *_Str, _In_z_ const unsigned char *_Control)
_Check_return_ _CRTIMP _CONST_RETURN unsigned char *__cdecl _mbschr(_In_z_ const unsigned char *_Str, _In_ unsigned int _Ch)
_Check_return_ _CRTIMP size_t __cdecl _mbsnbcnt(_In_reads_bytes_(_MaxCount) _Pre_z_ const unsigned char *_Str, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP size_t __cdecl _mbsnlen_l(_In_z_ const unsigned char *_Str, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_CRTIMP unsigned char *__cdecl _mbsnbcat_l(_Inout_z_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsninc(_In_reads_bytes_(_Count) _Pre_z_ const unsigned char *_Str, _In_ size_t _Count)
_CRTIMP unsigned char * _mbslwr_l(_Inout_z_ unsigned char *_String, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbscmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2)
_Check_return_ _CRTIMP int __cdecl _mbsncoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_CRTIMP unsigned char *__cdecl _mbslwr(_Inout_z_ unsigned char *_String)
_Check_return_ _CRTIMP size_t __cdecl _mbsnccnt(_In_reads_bytes_(_MaxCount) _Pre_z_ const unsigned char *_Str, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP int __cdecl _mbsnbicmp_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_CRTIMP unsigned char *__cdecl _mbsnbcpy(_Out_writes_(_Count) _Post_maybez_ unsigned char *_Dest, _In_z_ const unsigned char *_Source, _In_ size_t _Count)
_Check_return_ _CRTIMP size_t __cdecl _mbslen(_In_z_ const unsigned char *_Str)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsinc(_In_z_ const unsigned char *_Ptr)
_Check_return_ _CRTIMP size_t __cdecl _mbslen_l(_In_z_ const unsigned char *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbstok(_Inout_opt_z_ unsigned char *_Str, _In_z_ const unsigned char *_Delim)
_CRTIMP unsigned char *__cdecl _mbsset_l(_Inout_z_ unsigned char *_Str, _In_ unsigned int _Val, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP _CONST_RETURN unsigned char *__cdecl _mbspbrk(_In_z_ const unsigned char *_Str, _In_z_ const unsigned char *_Control)
_Check_return_ _CRTIMP int __cdecl _mbsicoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2)
_CRTIMP void __cdecl _mbccpy(_Out_writes_bytes_(2) unsigned char *_Dst, _In_z_ const unsigned char *_Src)
_Check_return_ _CRTIMP int __cdecl _mbsnbcmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsspnp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2)
_Check_return_ _CRTIMP int __cdecl _mbscoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbstok_l(_Inout_opt_z_ unsigned char *_Str, _In_z_ const unsigned char *_Delim, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsncmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_CRTIMP unsigned char *__cdecl _mbsrev(_Inout_z_ unsigned char *_Str)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsdec(_In_reads_z_(_Pos-_Start+1) const unsigned char *_Start, _In_z_ const unsigned char *_Pos)
_Check_return_ _CRTIMP int __cdecl _mbsnbcoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_CRTIMP void __cdecl _mbccpy_l(_Out_writes_bytes_(2) unsigned char *_Dst, _In_z_ const unsigned char *_Src, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsnicoll(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP int __cdecl _mbsnbcoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _mbsicmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2)
_Check_return_ _CRTIMP int __cdecl _mbsnicoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP size_t __cdecl _mbclen(_In_z_ const unsigned char *_Str)
_Check_return_ _CRTIMP int __cdecl _mbscoll_l(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_opt_ _locale_t _Locale)
char TCHAR
Definition: tchar.h:1402
#define _tcsinc
Definition: tchar.h:1458
#define _tcsnicoll_l
Definition: tchar.h:1445
#define _tcsnset
Definition: tchar.h:1419
#define _tccpy(_pc1, _cpc2)
Definition: tchar.h:1477
#define _tcsnccmp
Definition: tchar.h:1427
#define _tcscmp
Definition: tchar.h:1424
#define _tcsncpy_l
Definition: tchar.h:1411
#define _tcsncpy
Definition: tchar.h:1410
#define _strnextc(_cpc)
Definition: tchar.h:1518
#define _tclen(_pc)
Definition: tchar.h:1476
#define _tcsnicoll
Definition: tchar.h:1444
#define _tcsnicmp_l
Definition: tchar.h:1432
#define _tcscnlen_l(_String, _Max_count, _Locale)
Definition: tchar.h:1450
#define _tcsncat_l
Definition: tchar.h:1409
#define _strninc(_pc, _sz)
Definition: tchar.h:1519
#define _tcsnccoll_l
Definition: tchar.h:1439
#define _tcsicoll
Definition: tchar.h:1436
#define _tcsninc
Definition: tchar.h:1462
#define _strdec(_cpc1, _cpc2)
Definition: tchar.h:1516
#define _tcsncicoll_l
Definition: tchar.h:1443
#define _tcsicmp_l
Definition: tchar.h:1426
#define _tcslwr
Definition: tchar.h:1465
#define _tcsnccpy_l
Definition: tchar.h:1454
#define _tcstok
Definition: tchar.h:1416
#define _tcsclen_l(_String, _Locale)
Definition: tchar.h:1449
#define _tcsset
Definition: tchar.h:1422
#define _tcsnbcnt
Definition: tchar.h:1459
#define _tcsncoll
Definition: tchar.h:1440
#define _tcsclen
Definition: tchar.h:1447
#define _tcsupr_l
Definition: tchar.h:1468
#define _tccmp(_cpc1, _cpc2)
Definition: tchar.h:1478
#define _tcsnccnt
Definition: tchar.h:1460
#define _tcspbrk
Definition: tchar.h:1412
#define _tcsnccat_l
Definition: tchar.h:1452
#define _strncpy_l(_Destination, _Source, _Count, _Locale)
Definition: tchar.h:1524
#define _strtok_l(_String, _Delimiters, _Locale)
Definition: tchar.h:1526
signed char _TSCHAR
Definition: tchar.h:1393
#define _CONST_RETURN
Definition: tchar.h:76
#define _tcsupr
Definition: tchar.h:1467
#define _tcscnlen
Definition: tchar.h:1448
#define _tcsncmp
Definition: tchar.h:1428
#define _tcsnicmp
Definition: tchar.h:1431
_CRTIMP size_t __cdecl __strncnt(const char *_Str, size_t _Cnt)
Definition: strncnt.cpp:13
#define _tcsnextc
Definition: tchar.h:1461
#define _tcsnccat
Definition: tchar.h:1451
#define _tcscspn
Definition: tchar.h:1407
#define _tcsncset
Definition: tchar.h:1455
#define _strnset_l(_Destination, _Value, _Count, _Locale)
Definition: tchar.h:1527
#define _tcsicoll_l
Definition: tchar.h:1437
#define _strinc(_pc)
Definition: tchar.h:1517
#define _tcsspnp
Definition: tchar.h:1463
#define _tcsrev
Definition: tchar.h:1421
char _TCHAR
Definition: tchar.h:1392
#define _tcsncicmp
Definition: tchar.h:1429
int _TINT
Definition: tchar.h:1396
#define _tcsdec
Definition: tchar.h:1457
#define _tcscoll
Definition: tchar.h:1434
char _TXCHAR
Definition: tchar.h:1395
#define _tcsncicmp_l
Definition: tchar.h:1430
#define _tcscoll_l
Definition: tchar.h:1435
#define _tcsncat
Definition: tchar.h:1408
#define _tcsstr
Definition: tchar.h:1415
#define _strncnt(_cpc, _sz)
Definition: tchar.h:1521
#define _tcslwr_l
Definition: tchar.h:1466
#define _strspnp(_cpc1, _cpc2)
Definition: tchar.h:1522
unsigned char _TUCHAR
Definition: tchar.h:1394
#define _tcsnccoll
Definition: tchar.h:1438
#define _tcsicmp
Definition: tchar.h:1425
#define _tcsncoll_l
Definition: tchar.h:1441
#define _tcsspn
Definition: tchar.h:1414
#define _tcsncicoll
Definition: tchar.h:1442
#define _strset_l(_Destination, _Value, _Locale)
Definition: tchar.h:1528
#define _tcschr
Definition: tchar.h:1406
#define _strncat_l(_Destination, _Source, _Count, _Locale)
Definition: tchar.h:1525
#define _tcstok_l
Definition: tchar.h:1417
#define _tcsrchr
Definition: tchar.h:1413
#define _tcsnccpy
Definition: tchar.h:1453
_Dest
Definition: stdlib.h:926
#define _tcsncat_s_l
Definition: tchar.h:2033
#define _tcsnccpy_s_l
Definition: tchar.h:2093
#define _tcsnset_l
Definition: tchar.h:2049
#define _tcsnccat_s
Definition: tchar.h:2087
#define _tcsncat_s
Definition: tchar.h:2031
_Check_return_ _In_z_ const char * _Delimiters
Definition: tchar.h:2262
#define _tcsnccat_s_l
Definition: tchar.h:2089
#define _tcsset_s_l
Definition: tchar.h:2055
#define _tcsnset_s
Definition: tchar.h:2048
#define _tcsncset_s
Definition: tchar.h:2095
#define _tcstok_s_l
Definition: tchar.h:2045
#define _tcstok_s
Definition: tchar.h:2043
#define _tcsupr_s_l
Definition: tchar.h:2116
#define _tcsncset_s_l
Definition: tchar.h:2097
_In_ size_t _Destination_size_chars
Definition: tchar.h:2293
__inline void __CRTDECL _tccpy_l(_Out_ char *_Pc1, _In_z_ const char *_Cpc2, _In_opt_ _locale_t _Locale)
Definition: tchar.h:2136
#define _tcsset_s
Definition: tchar.h:2053
#define _tcsupr_s
Definition: tchar.h:2115
#define _tcsncpy_s_l
Definition: tchar.h:2037
return strtok(_String, _Delimiters)
#define _tcslwr_s_l
Definition: tchar.h:2112
#define _tcsncpy_s
Definition: tchar.h:2035
__inline errno_t __CRTDECL _strnset_s_l(_Inout_updates_z_(_Destination_size_chars) char *_Destination, _In_ size_t _Destination_size_chars, _In_ int _Value, _In_ size_t _Count, _In_opt_ _locale_t _Locale)
Definition: tchar.h:2276
_In_ size_t _In_ int _Value
Definition: tchar.h:2293
#define _tcslwr_s
Definition: tchar.h:2111
#define _tcsncset_l
Definition: tchar.h:2096
#define _tcsset_l
Definition: tchar.h:2054
#define _tcsnset_s_l
Definition: tchar.h:2050
return _strset_s(_Destination, _Destination_size_chars, _Value)
#define _tcsnccpy_s
Definition: tchar.h:2091
POINT cp
Definition: magnifier.c:59
errno_t __cdecl _mbccpy_s_l(unsigned char *_Dst, size_t _SizeInBytes, int *_PCopied, const unsigned char *_Src, _LOCALE_ARG_DECL)
Definition: mbccpy_s_l.cpp:17
errno_t __cdecl _mbslwr_s_l(unsigned char *string, size_t sizeInBytes, _locale_t plocinfo)
Definition: mbslwr.cpp:42
errno_t __cdecl _mbsset_s_l(unsigned char *_Dst, size_t _SizeInBytes, unsigned int _Value, _LOCALE_ARG_DECL)
Definition: mbsset_s_l.cpp:17
unsigned char *__cdecl _mbstok_s_l(unsigned char *_String, const unsigned char *_Control, unsigned char **_Context, _LOCALE_ARG_DECL)
Definition: mbstok_s.cpp:17
errno_t __cdecl _mbsupr_s_l(unsigned char *string, size_t sizeInBytes, _locale_t plocinfo)
Definition: mbsupr.cpp:40
#define wcsncpy_s(d, l, s, n)
Definition: utility.h:202
int __cdecl _ismbblead(unsigned int)
Definition: ismblead.c:20
#define _Deref_prepost_opt_z_
Definition: ms_sal.h:1424
#define _Post_maybez_
Definition: ms_sal.h:1372
#define _Prepost_z_
Definition: no_sal2.h:510
#define _Out_writes_z_(s)
Definition: no_sal2.h:180
#define _Out_opt_
Definition: no_sal2.h:214
#define _Inout_
Definition: no_sal2.h:162
#define _Success_(c)
Definition: no_sal2.h:84
#define _In_z_
Definition: no_sal2.h:164
#define _Check_return_
Definition: no_sal2.h:60
#define _Post_z_
Definition: no_sal2.h:508
#define _Inout_updates_z_(s)
Definition: no_sal2.h:186
#define _Pre_notnull_
Definition: no_sal2.h:516
#define _In_reads_or_z_(s)
Definition: no_sal2.h:174
#define _Inout_opt_
Definition: no_sal2.h:216
#define _Out_writes_(s)
Definition: no_sal2.h:176
#define _Post_satisfies_(e)
Definition: no_sal2.h:66
#define _Out_
Definition: no_sal2.h:160
#define _In_
Definition: no_sal2.h:158
#define _In_opt_
Definition: no_sal2.h:212
#define _In_reads_z_(s)
Definition: no_sal2.h:172
#define _Inout_opt_z_
Definition: no_sal2.h:220
#define _Inout_updates_bytes_(s)
Definition: no_sal2.h:184
#define _Out_writes_bytes_(s)
Definition: no_sal2.h:178
#define _Inout_z_
Definition: no_sal2.h:166
char * PTCHAR
Definition: ntbasedef.h:484
* PTBYTE
Definition: ntbasedef.h:489
_MaxCount
Definition: memory.h:72
_In_ int _Val
Definition: memory.h:91
_Check_return_ _CRTIMP size_t __cdecl wcsspn(_In_z_ const wchar_t *_Str, _In_z_ const wchar_t *_Control)
_CRT_RESTORE_GCC_WARNINGS _Check_return_ _CRTIMP wchar_t *__cdecl wcstok(_Inout_opt_z_ wchar_t *_Str, _In_z_ const wchar_t *_Delim)
_Check_return_ wchar_t _Ch
Definition: string.h:697
_Check_return_ _CRTIMP size_t __cdecl strspn(_In_z_ const char *_Str, _In_z_ const char *_Control)
_In_ size_t _SizeInBytes
Definition: time.h:146
_In_ size_t _In_z_ _Printf_format_string_ const char _In_ const struct tm _In_opt_ _locale_t _Locale
Definition: time.h:159
strncpy
Definition: string.h:335
_strset
Definition: string.h:424
_In_opt_ _Locale strncat
Definition: string.h:263
strncpy_s
Definition: string.h:335
_strnset_s
Definition: string.h:393
_In_opt_ _Locale strncat_s
Definition: string.h:263
_strnset
Definition: string.h:393
char *CDECL strtok_s(char *str, const char *delim, char **ctx)
Definition: strtok_s.c:9
#define wchar_t
Definition: wchar.h:102
#define __DEFINE_CPP_OVERLOAD_INLINE_FUNC_0_2_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _SalAttributeDst, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2)
Definition: corecrt.h:1998
#define __DECLARE_CPP_OVERLOAD_INLINE_FUNC_0_2_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2)
Definition: corecrt.h:1993
#define _CRT_UNUSED(x)
Definition: corecrt.h:340
#define __DECLARE_CPP_OVERLOAD_INLINE_NFUNC_0_2_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2)
Definition: corecrt.h:2021
#define __RETURN_POLICY_DST(_FunctionCall)
Definition: corecrt.h:1892
#define _ACRTIMP
Definition: corecrt.h:138
#define __DECLARE_CPP_OVERLOAD_INLINE_FUNC_0_1_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst, _TType1, _TArg1)
Definition: corecrt.h:1986
#define _UCRT_DISABLE_CLANG_WARNINGS
Definition: corecrt.h:109
#define _UCRT_RESTORE_CLANG_WARNINGS
Definition: corecrt.h:117
#define _Check_return_wat_
Definition: corecrt.h:230
#define __DECLARE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2, _TType3, _TArg3)
Definition: corecrt.h:2028
#define __DEFINE_CPP_OVERLOAD_INLINE_FUNC_0_0_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst)
Definition: corecrt.h:1984
#define __DEFINE_CPP_OVERLOAD_INLINE_FUNC_0_1_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst, _TType1, _TArg1)
Definition: corecrt.h:1991
#define __DEFINE_CPP_OVERLOAD_INLINE_NFUNC_0_2_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _SalAttributeDst, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2)
Definition: corecrt.h:2026
#define __DEFINE_CPP_OVERLOAD_INLINE_NFUNC_0_3_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _SalAttributeDst, _DstType, _Dst, _TType1, _TArg1, _TType2, _TArg2, _TType3, _TArg3)
Definition: corecrt.h:2033
#define __DECLARE_CPP_OVERLOAD_INLINE_FUNC_0_0_EX(_ReturnType, _ReturnPolicy, _FuncName, _SecureFuncName, _SecureDstType, _DstType, _Dst)
Definition: corecrt.h:1979
int errno_t
Definition: corecrt.h:615
#define _CRT_INSECURE_DEPRECATE(_Replacement)
Definition: vcruntime.h:99
size_t __cdecl __wcsncnt(wchar_t const *const string, size_t const count)
Definition: wcsncnt.cpp:13
wchar_t *CDECL wcstok_s(wchar_t *str, const wchar_t *delim, wchar_t **next_token)
Definition: wcstok.c:8
#define __CRTDECL
Definition: yvals.h:17
#define const
Definition: zconf.h:233