1 /** 2 * This file has no copyright assigned and is placed in the Public Domain. 3 * This file is part of the w64 mingw-runtime package. 4 * No warranty is given; refer to the file DISCLAIMER within this package. 5 */ 6 #ifndef _INC_WCHAR 7 #define _INC_WCHAR 8 9 #include <crtdefs.h> 10 11 #define __need___va_list 12 #include <stdarg.h> 13 14 #pragma pack(push,_CRT_PACKING) 15 16 #ifdef __cplusplus 17 extern "C" { 18 #endif 19 20 #ifdef _MSC_VER 21 #pragma warning(push) 22 #pragma warning(disable:4820) 23 #endif 24 25 #ifndef WCHAR_MIN 26 #define WCHAR_MIN 0 27 #endif 28 #ifndef WCHAR_MAX 29 #define WCHAR_MAX ((wchar_t)-1) /* UINT16_MAX */ 30 #endif 31 32 #ifndef WEOF 33 #define WEOF (wint_t)(0xFFFF) 34 #endif 35 36 #ifndef _FILE_DEFINED 37 struct _iobuf { 38 char *_ptr; 39 int _cnt; 40 char *_base; 41 int _flag; 42 int _file; 43 int _charbuf; 44 int _bufsiz; 45 char *_tmpfname; 46 }; 47 typedef struct _iobuf FILE; 48 #define _FILE_DEFINED 49 #endif 50 51 #ifndef _STDIO_DEFINED 52 _CRTIMP FILE *__cdecl __iob_func(void); 53 _CRTDATA(extern FILE _iob[];) 54 #ifdef _M_CEE_PURE 55 #define _iob __iob_func() 56 #endif 57 #endif 58 59 #ifndef _STDSTREAM_DEFINED 60 #define _STDSTREAM_DEFINED 61 #define stdin (&_iob[0]) 62 #define stdout (&_iob[1]) 63 #define stderr (&_iob[2]) 64 #endif /* !_STDSTREAM_DEFINED */ 65 66 #ifndef _FSIZE_T_DEFINED 67 typedef unsigned long _fsize_t; 68 #define _FSIZE_T_DEFINED 69 #endif 70 71 #ifndef _WFINDDATA_T_DEFINED 72 struct _wfinddata_t { 73 unsigned attrib; 74 time_t time_create; 75 time_t time_access; 76 time_t time_write; 77 _fsize_t size; 78 wchar_t name[260]; 79 }; 80 81 struct _wfinddata32_t { 82 unsigned attrib; 83 __time32_t time_create; 84 __time32_t time_access; 85 __time32_t time_write; 86 _fsize_t size; 87 wchar_t name[260]; 88 }; 89 90 #if _INTEGRAL_MAX_BITS >= 64 91 struct _wfinddatai64_t { 92 unsigned attrib; 93 time_t time_create; 94 time_t time_access; 95 time_t time_write; 96 __MINGW_EXTENSION __int64 size; 97 wchar_t name[260]; 98 }; 99 100 struct _wfinddata32i64_t { 101 unsigned attrib; 102 __time32_t time_create; 103 __time32_t time_access; 104 __time32_t time_write; 105 __MINGW_EXTENSION __int64 size; 106 wchar_t name[260]; 107 }; 108 109 struct _wfinddata64i32_t { 110 unsigned attrib; 111 __time64_t time_create; 112 __time64_t time_access; 113 __time64_t time_write; 114 _fsize_t size; 115 wchar_t name[260]; 116 }; 117 118 struct _wfinddata64_t { 119 unsigned attrib; 120 __time64_t time_create; 121 __time64_t time_access; 122 __time64_t time_write; 123 __MINGW_EXTENSION __int64 size; 124 wchar_t name[260]; 125 }; 126 #endif 127 128 #define _WFINDDATA_T_DEFINED 129 #endif /* !_WFINDDATA_T_DEFINED */ 130 131 #ifndef _CRT_CTYPEDATA_DEFINED 132 # define _CRT_CTYPEDATA_DEFINED 133 # ifndef _CTYPE_DISABLE_MACROS 134 # ifndef __PCTYPE_FUNC 135 # ifdef _DLL 136 # define __PCTYPE_FUNC __pctype_func() 137 # else 138 # define __PCTYPE_FUNC _pctype 139 # endif 140 # endif /* !__PCTYPE_FUNC */ 141 _CRTIMP const unsigned short * __cdecl __pctype_func(void); 142 # ifndef _M_CEE_PURE 143 _CRTDATA(extern unsigned short *_pctype); 144 # else 145 # define _pctype (__pctype_func()) 146 # endif /* !_M_CEE_PURE */ 147 # endif /* !_CTYPE_DISABLE_MACROS */ 148 #endif /* !_CRT_CTYPEDATA_DEFINED */ 149 150 #ifndef _CRT_WCTYPEDATA_DEFINED 151 #define _CRT_WCTYPEDATA_DEFINED 152 # ifndef _CTYPE_DISABLE_MACROS 153 _CRTDATA(extern unsigned short *_wctype); 154 _CRTIMP const wctype_t * __cdecl __pwctype_func(void); 155 # ifndef _M_CEE_PURE 156 _CRTDATA(extern const wctype_t *_pwctype); 157 # else 158 # define _pwctype (__pwctype_func()) 159 # endif /* !_M_CEE_PURE */ 160 # endif /* !_CTYPE_DISABLE_MACROS */ 161 #endif /* !_CRT_WCTYPEDATA_DEFINED */ 162 163 #define _UPPER 0x1 164 #define _LOWER 0x2 165 #define _DIGIT 0x4 166 #define _SPACE 0x8 167 168 #define _PUNCT 0x10 169 #define _CONTROL 0x20 170 #define _BLANK 0x40 171 #define _HEX 0x80 172 173 #define _LEADBYTE 0x8000 174 #define _ALPHA (0x0100|_UPPER|_LOWER) 175 176 #ifndef _WCTYPE_DEFINED 177 #define _WCTYPE_DEFINED 178 _Check_return_ _CRTIMP int __cdecl iswalpha(_In_ wint_t _C); 179 _Check_return_ _CRTIMP int __cdecl _iswalpha_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 180 _Check_return_ _CRTIMP int __cdecl iswupper(_In_ wint_t _C); 181 _Check_return_ _CRTIMP int __cdecl _iswupper_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 182 _Check_return_ _CRTIMP int __cdecl iswlower(_In_ wint_t _C); 183 _Check_return_ _CRTIMP int __cdecl _iswlower_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 184 _Check_return_ _CRTIMP int __cdecl iswdigit(_In_ wint_t _C); 185 _Check_return_ _CRTIMP int __cdecl _iswdigit_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 186 _Check_return_ _CRTIMP int __cdecl iswxdigit(_In_ wint_t _C); 187 _Check_return_ _CRTIMP int __cdecl _iswxdigit_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 188 _Check_return_ _CRTIMP int __cdecl iswspace(_In_ wint_t _C); 189 _Check_return_ _CRTIMP int __cdecl _iswspace_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 190 _Check_return_ _CRTIMP int __cdecl iswpunct(_In_ wint_t _C); 191 _Check_return_ _CRTIMP int __cdecl _iswpunct_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 192 _Check_return_ _CRTIMP int __cdecl iswalnum(_In_ wint_t _C); 193 _Check_return_ _CRTIMP int __cdecl _iswalnum_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 194 _Check_return_ _CRTIMP int __cdecl iswprint(_In_ wint_t _C); 195 _Check_return_ _CRTIMP int __cdecl _iswprint_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 196 _Check_return_ _CRTIMP int __cdecl iswgraph(_In_ wint_t _C); 197 _Check_return_ _CRTIMP int __cdecl _iswgraph_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 198 _Check_return_ _CRTIMP int __cdecl iswcntrl(_In_ wint_t _C); 199 _Check_return_ _CRTIMP int __cdecl _iswcntrl_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 200 _Check_return_ _CRTIMP int __cdecl iswascii(_In_ wint_t _C); 201 _Check_return_ _CRTIMP int __cdecl isleadbyte(_In_ int _C); 202 _Check_return_ _CRTIMP int __cdecl _isleadbyte_l(_In_ int _C, _In_opt_ _locale_t _Locale); 203 _Check_return_ _CRTIMP wint_t __cdecl towupper(_In_ wint_t _C); 204 _Check_return_ _CRTIMP wint_t __cdecl _towupper_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 205 _Check_return_ _CRTIMP wint_t __cdecl towlower(_In_ wint_t _C); 206 _Check_return_ _CRTIMP wint_t __cdecl _towlower_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 207 _Check_return_ _CRTIMP int __cdecl iswctype(_In_ wint_t _C, _In_ wctype_t _Type); 208 _Check_return_ _CRTIMP int __cdecl _iswctype_l(_In_ wint_t _C, _In_ wctype_t _Type, _In_opt_ _locale_t _Locale); 209 _Check_return_ _CRTIMP int __cdecl __iswcsymf(_In_ wint_t _C); 210 _Check_return_ _CRTIMP int __cdecl _iswcsymf_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 211 _Check_return_ _CRTIMP int __cdecl __iswcsym(_In_ wint_t _C); 212 _Check_return_ _CRTIMP int __cdecl _iswcsym_l(_In_ wint_t _C, _In_opt_ _locale_t _Locale); 213 _CRTIMP int __cdecl is_wctype(_In_ wint_t _C, _In_ wctype_t _Type); 214 215 #if (defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || !defined (NO_OLDNAMES) 216 _CRTIMP int __cdecl iswblank(wint_t _C); 217 #endif 218 #endif 219 220 #ifndef _WDIRECT_DEFINED 221 #define _WDIRECT_DEFINED 222 223 _Check_return_ 224 _Ret_opt_z_ 225 _CRTIMP 226 wchar_t* 227 __cdecl 228 _wgetcwd( 229 _Out_writes_opt_(_SizeInWords) wchar_t *_DstBuf, 230 _In_ int _SizeInWords); 231 232 _Check_return_ 233 _Ret_opt_z_ 234 _CRTIMP 235 wchar_t* 236 __cdecl 237 _wgetdcwd( 238 _In_ int _Drive, 239 _Out_writes_opt_(_SizeInWords) wchar_t *_DstBuf, 240 _In_ int _SizeInWords); 241 242 _Check_return_ 243 _Ret_opt_z_ 244 wchar_t* 245 __cdecl 246 _wgetdcwd_nolock( 247 _In_ int _Drive, 248 _Out_writes_opt_(_SizeInWords) wchar_t *_DstBuf, 249 _In_ int _SizeInWords); 250 251 _Check_return_ 252 _CRTIMP 253 int 254 __cdecl 255 _wchdir( 256 _In_z_ const wchar_t *_Path); 257 258 _Check_return_ 259 _CRTIMP 260 int 261 __cdecl 262 _wmkdir( 263 _In_z_ const wchar_t *_Path); 264 265 _Check_return_ 266 _CRTIMP 267 int 268 __cdecl 269 _wrmdir( 270 _In_z_ const wchar_t *_Path); 271 272 #endif /* _WDIRECT_DEFINED */ 273 274 #ifndef _WIO_DEFINED 275 #define _WIO_DEFINED 276 277 _Check_return_ 278 _CRTIMP 279 int 280 __cdecl 281 _waccess( 282 _In_z_ const wchar_t *_Filename, 283 _In_ int _AccessMode); 284 285 _Check_return_ 286 _CRTIMP 287 int 288 __cdecl 289 _wchmod( 290 _In_z_ const wchar_t *_Filename, 291 _In_ int _Mode); 292 293 _Check_return_ 294 _CRTIMP 295 int 296 __cdecl 297 _wcreat( 298 _In_z_ const wchar_t *_Filename, 299 _In_ int _PermissionMode); 300 301 _Check_return_ 302 _CRTIMP 303 intptr_t 304 __cdecl 305 _wfindfirst32( 306 _In_z_ const wchar_t *_Filename, 307 _Out_ struct _wfinddata32_t *_FindData); 308 309 _Check_return_ 310 _CRTIMP 311 int 312 __cdecl 313 _wfindnext32( 314 _In_ intptr_t _FindHandle, 315 _Out_ struct _wfinddata32_t *_FindData); 316 317 _Check_return_ 318 _CRTIMP 319 int 320 __cdecl 321 _wunlink( 322 _In_z_ const wchar_t *_Filename); 323 324 _Check_return_ 325 _CRTIMP 326 int 327 __cdecl 328 _wrename( 329 _In_z_ const wchar_t *_OldFilename, 330 _In_z_ const wchar_t *_NewFilename); 331 332 _CRTIMP 333 wchar_t* 334 __cdecl 335 _wmktemp( 336 _Inout_z_ wchar_t *_TemplateName); 337 338 #if _INTEGRAL_MAX_BITS >= 64 339 340 _Check_return_ 341 _CRTIMP 342 intptr_t 343 __cdecl 344 _wfindfirst32i64( 345 _In_z_ const wchar_t *_Filename, 346 _Out_ struct _wfinddata32i64_t *_FindData); 347 348 _Check_return_ 349 _CRTIMP 350 intptr_t 351 __cdecl 352 _wfindfirst64i32( 353 _In_z_ const wchar_t *_Filename, 354 _Out_ struct _wfinddata64i32_t *_FindData); 355 356 _Check_return_ 357 _CRTIMP 358 intptr_t 359 __cdecl 360 _wfindfirst64( 361 _In_z_ const wchar_t *_Filename, 362 _Out_ struct _wfinddata64_t *_FindData); 363 364 _Check_return_ 365 _CRTIMP 366 int 367 __cdecl 368 _wfindnext32i64( 369 _In_ intptr_t _FindHandle, 370 _Out_ struct _wfinddata32i64_t *_FindData); 371 372 _Check_return_ 373 _CRTIMP 374 int 375 __cdecl 376 _wfindnext64i32( 377 _In_ intptr_t _FindHandle, 378 _Out_ struct _wfinddata64i32_t *_FindData); 379 380 _Check_return_ 381 _CRTIMP 382 int 383 __cdecl 384 _wfindnext64( 385 _In_ intptr_t _FindHandle, 386 _Out_ struct _wfinddata64_t *_FindData); 387 388 #endif /* _INTEGRAL_MAX_BITS >= 64 */ 389 390 _Check_return_wat_ 391 _CRTIMP 392 errno_t 393 __cdecl 394 _wsopen_s( 395 _Out_ int *_FileHandle, 396 _In_z_ const wchar_t *_Filename, 397 _In_ int _OpenFlag, 398 _In_ int _ShareFlag, 399 _In_ int _PermissionFlag); 400 401 #if !defined(__cplusplus) || !(defined(_X86_) && !defined(__x86_64)) 402 _CRTIMP int __cdecl _wopen(const wchar_t *_Filename,int _OpenFlag,...); 403 _CRTIMP int __cdecl _wsopen(const wchar_t *_Filename,int _OpenFlag,int _ShareFlag,...); 404 #else 405 extern "C++" _CRTIMP int __cdecl _wopen(const wchar_t *_Filename,int _OpenFlag,int _PermissionMode = 0); 406 extern "C++" _CRTIMP int __cdecl _wsopen(const wchar_t *_Filename,int _OpenFlag,int _ShareFlag,int _PermissionMode = 0); 407 #endif 408 409 #endif /* !_WIO_DEFINED */ 410 411 #ifndef _WLOCALE_DEFINED 412 #define _WLOCALE_DEFINED 413 _Check_return_opt_ 414 _CRTIMP 415 wchar_t* 416 __cdecl 417 _wsetlocale( 418 _In_ int _Category, 419 _In_opt_z_ const wchar_t *_Locale); 420 #endif 421 422 #ifndef _WPROCESS_DEFINED 423 #define _WPROCESS_DEFINED 424 425 _CRTIMP 426 intptr_t 427 __cdecl 428 _wexecl( 429 _In_z_ const wchar_t *_Filename, 430 _In_z_ const wchar_t *_ArgList, 431 ...); 432 433 _CRTIMP 434 intptr_t 435 __cdecl 436 _wexecle( 437 _In_z_ const wchar_t *_Filename, 438 _In_z_ const wchar_t *_ArgList, 439 ...); 440 441 _CRTIMP 442 intptr_t 443 __cdecl 444 _wexeclp( 445 _In_z_ const wchar_t *_Filename, 446 _In_z_ const wchar_t *_ArgList, 447 ...); 448 449 _CRTIMP 450 intptr_t 451 __cdecl 452 _wexeclpe( 453 _In_z_ const wchar_t *_Filename, 454 _In_z_ const wchar_t *_ArgList, 455 ...); 456 457 _CRTIMP 458 intptr_t 459 __cdecl 460 _wexecv( 461 _In_z_ const wchar_t *_Filename, 462 _In_z_ const wchar_t *const *_ArgList); 463 464 _CRTIMP 465 intptr_t 466 __cdecl 467 _wexecve( 468 _In_z_ const wchar_t *_Filename, 469 _In_z_ const wchar_t *const *_ArgList, 470 _In_opt_z_ const wchar_t *const *_Env); 471 472 _CRTIMP 473 intptr_t 474 __cdecl 475 _wexecvp( 476 _In_z_ const wchar_t *_Filename, 477 _In_z_ const wchar_t *const *_ArgList); 478 479 _CRTIMP 480 intptr_t 481 __cdecl 482 _wexecvpe( 483 _In_z_ const wchar_t *_Filename, 484 _In_z_ const wchar_t *const *_ArgList, 485 _In_opt_z_ const wchar_t *const *_Env); 486 487 _CRTIMP 488 intptr_t 489 __cdecl 490 _wspawnl( 491 _In_ int _Mode, 492 _In_z_ const wchar_t *_Filename, 493 _In_z_ const wchar_t *_ArgList, 494 ...); 495 496 _CRTIMP 497 intptr_t 498 __cdecl 499 _wspawnle( 500 _In_ int _Mode, 501 _In_z_ const wchar_t *_Filename, 502 _In_z_ const wchar_t *_ArgList, 503 ...); 504 505 _CRTIMP 506 intptr_t 507 __cdecl 508 _wspawnlp( 509 _In_ int _Mode, 510 _In_z_ const wchar_t *_Filename, 511 _In_z_ const wchar_t *_ArgList, 512 ...); 513 514 _CRTIMP 515 intptr_t 516 __cdecl 517 _wspawnlpe( 518 _In_ int _Mode, 519 _In_z_ const wchar_t *_Filename, 520 _In_z_ const wchar_t *_ArgList, 521 ...); 522 523 _CRTIMP 524 intptr_t 525 __cdecl 526 _wspawnv( 527 _In_ int _Mode, 528 _In_z_ const wchar_t *_Filename, 529 _In_z_ const wchar_t *const *_ArgList); 530 531 _CRTIMP 532 intptr_t 533 __cdecl 534 _wspawnve( 535 _In_ int _Mode, 536 _In_z_ const wchar_t *_Filename, 537 _In_z_ const wchar_t *const *_ArgList, 538 _In_opt_z_ const wchar_t *const *_Env); 539 540 _CRTIMP 541 intptr_t 542 __cdecl 543 _wspawnvp( 544 _In_ int _Mode, 545 _In_z_ const wchar_t *_Filename, 546 _In_z_ const wchar_t *const *_ArgList); 547 548 _CRTIMP 549 intptr_t 550 __cdecl 551 _wspawnvpe( 552 _In_ int _Mode, 553 _In_z_ const wchar_t *_Filename, 554 _In_z_ const wchar_t *const *_ArgList, 555 _In_opt_z_ const wchar_t *const *_Env); 556 557 #ifndef _CRT_WSYSTEM_DEFINED 558 #define _CRT_WSYSTEM_DEFINED 559 _CRTIMP 560 int 561 __cdecl 562 _wsystem( 563 _In_opt_z_ const wchar_t *_Command); 564 #endif /* !_CRT_WSYSTEM_DEFINED */ 565 566 #endif /* !_WPROCESS_DEFINED */ 567 568 #ifndef _WCTYPE_INLINE_DEFINED 569 #undef _CRT_WCTYPE_NOINLINE 570 #if !defined(__cplusplus) || defined(_CRT_WCTYPE_NOINLINE) 571 #define iswalpha(_c) (iswctype(_c,_ALPHA)) 572 #define iswupper(_c) (iswctype(_c,_UPPER)) 573 #define iswlower(_c) (iswctype(_c,_LOWER)) 574 #define iswdigit(_c) (iswctype(_c,_DIGIT)) 575 #define iswxdigit(_c) (iswctype(_c,_HEX)) 576 #define iswspace(_c) (iswctype(_c,_SPACE)) 577 #define iswpunct(_c) (iswctype(_c,_PUNCT)) 578 #define iswalnum(_c) (iswctype(_c,_ALPHA|_DIGIT)) 579 #define iswprint(_c) (iswctype(_c,_BLANK|_PUNCT|_ALPHA|_DIGIT)) 580 #define iswgraph(_c) (iswctype(_c,_PUNCT|_ALPHA|_DIGIT)) 581 #define iswcntrl(_c) (iswctype(_c,_CONTROL)) 582 #define iswascii(_c) ((unsigned)(_c) < 0x80) 583 584 #define _iswalpha_l(_c,_p) (_iswctype_l(_c,_ALPHA,_p)) 585 #define _iswupper_l(_c,_p) (_iswctype_l(_c,_UPPER,_p)) 586 #define _iswlower_l(_c,_p) (_iswctype_l(_c,_LOWER,_p)) 587 #define _iswdigit_l(_c,_p) (_iswctype_l(_c,_DIGIT,_p)) 588 #define _iswxdigit_l(_c,_p) (_iswctype_l(_c,_HEX,_p)) 589 #define _iswspace_l(_c,_p) (_iswctype_l(_c,_SPACE,_p)) 590 #define _iswpunct_l(_c,_p) (_iswctype_l(_c,_PUNCT,_p)) 591 #define _iswalnum_l(_c,_p) (_iswctype_l(_c,_ALPHA|_DIGIT,_p)) 592 #define _iswprint_l(_c,_p) (_iswctype_l(_c,_BLANK|_PUNCT|_ALPHA|_DIGIT,_p)) 593 #define _iswgraph_l(_c,_p) (_iswctype_l(_c,_PUNCT|_ALPHA|_DIGIT,_p)) 594 #define _iswcntrl_l(_c,_p) (_iswctype_l(_c,_CONTROL,_p)) 595 #ifndef _CTYPE_DISABLE_MACROS 596 #define isleadbyte(_c) (__PCTYPE_FUNC[(unsigned char)(_c)] & _LEADBYTE) 597 #endif 598 #endif 599 #define _WCTYPE_INLINE_DEFINED 600 #endif 601 602 #if !defined(_POSIX_) || defined(__GNUC__) 603 #ifndef _INO_T_DEFINED 604 #define _INO_T_DEFINED 605 typedef unsigned short _ino_t; 606 #ifndef NO_OLDNAMES 607 typedef unsigned short ino_t; 608 #endif 609 #endif 610 611 #ifndef _DEV_T_DEFINED 612 #define _DEV_T_DEFINED 613 typedef unsigned int _dev_t; 614 #ifndef NO_OLDNAMES 615 typedef unsigned int dev_t; 616 #endif 617 #endif 618 619 #ifndef _OFF_T_DEFINED 620 #define _OFF_T_DEFINED 621 typedef long _off_t; 622 #ifndef NO_OLDNAMES 623 typedef long off_t; 624 #endif 625 #endif 626 627 #ifndef _OFF64_T_DEFINED 628 #define _OFF64_T_DEFINED 629 __MINGW_EXTENSION typedef long long _off64_t; 630 #ifndef NO_OLDNAMES 631 __MINGW_EXTENSION typedef long long off64_t; 632 #endif 633 #endif 634 635 #ifndef _STAT_DEFINED 636 #define _STAT_DEFINED 637 638 struct _stat32 { 639 _dev_t st_dev; 640 _ino_t st_ino; 641 unsigned short st_mode; 642 short st_nlink; 643 short st_uid; 644 short st_gid; 645 _dev_t st_rdev; 646 _off_t st_size; 647 __time32_t st_atime; 648 __time32_t st_mtime; 649 __time32_t st_ctime; 650 }; 651 652 struct _stat { 653 _dev_t st_dev; 654 _ino_t st_ino; 655 unsigned short st_mode; 656 short st_nlink; 657 short st_uid; 658 short st_gid; 659 _dev_t st_rdev; 660 _off_t st_size; 661 time_t st_atime; 662 time_t st_mtime; 663 time_t st_ctime; 664 }; 665 666 #ifndef NO_OLDNAMES 667 struct stat { 668 _dev_t st_dev; 669 _ino_t st_ino; 670 unsigned short st_mode; 671 short st_nlink; 672 short st_uid; 673 short st_gid; 674 _dev_t st_rdev; 675 _off_t st_size; 676 time_t st_atime; 677 time_t st_mtime; 678 time_t st_ctime; 679 }; 680 #endif 681 682 #if _INTEGRAL_MAX_BITS >= 64 683 684 struct _stat32i64 { 685 _dev_t st_dev; 686 _ino_t st_ino; 687 unsigned short st_mode; 688 short st_nlink; 689 short st_uid; 690 short st_gid; 691 _dev_t st_rdev; 692 __MINGW_EXTENSION __int64 st_size; 693 __time32_t st_atime; 694 __time32_t st_mtime; 695 __time32_t st_ctime; 696 }; 697 698 struct _stat64i32 { 699 _dev_t st_dev; 700 _ino_t st_ino; 701 unsigned short st_mode; 702 short st_nlink; 703 short st_uid; 704 short st_gid; 705 _dev_t st_rdev; 706 _off_t st_size; 707 __time64_t st_atime; 708 __time64_t st_mtime; 709 __time64_t st_ctime; 710 }; 711 712 struct _stat64 { 713 _dev_t st_dev; 714 _ino_t st_ino; 715 unsigned short st_mode; 716 short st_nlink; 717 short st_uid; 718 short st_gid; 719 _dev_t st_rdev; 720 __MINGW_EXTENSION __int64 st_size; 721 __time64_t st_atime; 722 __time64_t st_mtime; 723 __time64_t st_ctime; 724 }; 725 #endif 726 727 #define __stat64 _stat64 728 729 #endif 730 731 #ifndef _WSTAT_DEFINED 732 #define _WSTAT_DEFINED 733 734 _CRTIMP 735 int 736 __cdecl 737 _wstat( 738 _In_z_ const wchar_t *_Name, 739 _Out_ struct _stat *_Stat); 740 741 _CRTIMP 742 int 743 __cdecl 744 _wstat32( 745 _In_z_ const wchar_t *_Name, 746 _Out_ struct _stat32 *_Stat); 747 748 #if _INTEGRAL_MAX_BITS >= 64 749 750 _CRTIMP 751 int 752 __cdecl 753 _wstat32i64( 754 _In_z_ const wchar_t *_Name, 755 _Out_ struct _stat32i64 *_Stat); 756 757 _CRTIMP 758 int 759 __cdecl 760 _wstat64i32( 761 _In_z_ const wchar_t *_Name, 762 _Out_ struct _stat64i32 *_Stat); 763 764 _CRTIMP 765 int 766 __cdecl 767 _wstat64( 768 _In_z_ const wchar_t *_Name, 769 _Out_ struct _stat64 *_Stat); 770 771 #endif /* _INTEGRAL_MAX_BITS >= 64 */ 772 773 #endif /* _WSTAT_DEFINED */ 774 775 #endif /* !defined(_POSIX_) || defined(__GNUC__) */ 776 777 #ifndef _WCONIO_DEFINED 778 #define _WCONIO_DEFINED 779 780 _CRTIMP 781 wchar_t* 782 _cgetws( 783 _Inout_z_ wchar_t *_Buffer); 784 785 _Check_return_ 786 _CRTIMP 787 wint_t 788 __cdecl 789 _getwch(void); 790 791 _Check_return_ 792 _CRTIMP 793 wint_t 794 __cdecl 795 _getwche(void); 796 797 _Check_return_ 798 _CRTIMP 799 wint_t 800 __cdecl 801 _putwch( 802 wchar_t _WCh); 803 804 _Check_return_ 805 _CRTIMP 806 wint_t 807 __cdecl 808 _ungetwch( 809 wint_t _WCh); 810 811 _Check_return_opt_ 812 _CRTIMP 813 int 814 __cdecl 815 _cputws( 816 _In_z_ const wchar_t *_String); 817 818 _Check_return_opt_ 819 _CRTIMP 820 int 821 __cdecl 822 _cwprintf( 823 _In_z_ _Printf_format_string_ const wchar_t *_Format, 824 ...); 825 826 _Check_return_opt_ 827 _CRTIMP 828 int 829 __cdecl 830 _cwscanf( 831 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 832 ...); 833 834 _Check_return_opt_ 835 _CRTIMP 836 int 837 __cdecl 838 _cwscanf_l( 839 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 840 _In_opt_ _locale_t _Locale, 841 ...); 842 843 _Check_return_opt_ 844 _CRTIMP 845 int 846 __cdecl 847 _vcwprintf( 848 _In_z_ _Printf_format_string_ const wchar_t *_Format, 849 va_list _ArgList); 850 851 _Check_return_opt_ 852 _CRTIMP 853 int 854 __cdecl 855 _cwprintf_p( 856 _In_z_ _Printf_format_string_ const wchar_t *_Format, 857 ...); 858 859 _Check_return_opt_ 860 _CRTIMP 861 int 862 __cdecl 863 _vcwprintf_p( 864 _In_z_ _Printf_format_string_ const wchar_t *_Format, 865 va_list _ArgList); 866 867 _CRTIMP 868 int 869 __cdecl 870 _cwprintf_l( 871 _In_z_ _Printf_format_string_ const wchar_t *_Format, 872 _In_opt_ _locale_t _Locale, 873 ...); 874 875 _CRTIMP 876 int 877 __cdecl 878 _vcwprintf_l( 879 _In_z_ _Printf_format_string_ const wchar_t *_Format, 880 _In_opt_ _locale_t _Locale, 881 va_list _ArgList); 882 883 _CRTIMP 884 int 885 __cdecl 886 _cwprintf_p_l( 887 _In_z_ _Printf_format_string_ const wchar_t *_Format, 888 _In_opt_ _locale_t _Locale, 889 ...); 890 891 _CRTIMP 892 int 893 __cdecl 894 _vcwprintf_p_l( 895 _In_z_ _Printf_format_string_ const wchar_t *_Format, 896 _In_opt_ _locale_t _Locale, 897 va_list _ArgList); 898 899 _Check_return_opt_ 900 wint_t 901 __cdecl 902 _putwch_nolock( 903 wchar_t _WCh); 904 905 _Check_return_ 906 wint_t 907 __cdecl 908 _getwch_nolock(void); 909 910 _Check_return_ 911 wint_t 912 __cdecl 913 _getwche_nolock(void); 914 915 _Check_return_opt_ 916 wint_t 917 __cdecl 918 _ungetwch_nolock( 919 wint_t _WCh); 920 921 #endif /* _WCONIO_DEFINED */ 922 923 #ifndef _WSTDIO_DEFINED 924 #define _WSTDIO_DEFINED 925 926 #ifdef _POSIX_ 927 _CRTIMP FILE *__cdecl _wfsopen(const wchar_t *_Filename,const wchar_t *_Mode); 928 #else 929 _Check_return_ 930 _CRTIMP 931 FILE* 932 __cdecl 933 _wfsopen( 934 _In_z_ const wchar_t *_Filename, 935 _In_z_ const wchar_t *_Mode, 936 _In_ int _ShFlag); 937 #endif 938 939 _Check_return_opt_ 940 _CRTIMP_ALT 941 wint_t 942 __cdecl 943 fgetwc( 944 _Inout_ FILE *_File); 945 946 _Check_return_opt_ 947 _CRTIMP 948 wint_t 949 __cdecl 950 _fgetwchar(void); 951 952 _Check_return_opt_ 953 _CRTIMP 954 wint_t 955 __cdecl 956 fputwc( 957 _In_ wchar_t _Ch, 958 _Inout_ FILE *_File); 959 960 _Check_return_opt_ 961 _CRTIMP 962 wint_t 963 __cdecl 964 _fputwchar( 965 _In_ wchar_t _Ch); 966 967 _Check_return_ 968 _CRTIMP 969 wint_t 970 __cdecl 971 getwc( 972 _Inout_ FILE *_File); 973 974 _Check_return_ 975 _CRTIMP 976 wint_t 977 __cdecl 978 getwchar(void); 979 980 _Check_return_opt_ 981 _CRTIMP 982 wint_t 983 __cdecl 984 putwc( 985 _In_ wchar_t _Ch, 986 _Inout_ FILE *_File); 987 988 _Check_return_opt_ 989 _CRTIMP 990 wint_t 991 __cdecl 992 putwchar( 993 _In_ wchar_t _Ch); 994 995 _Check_return_opt_ 996 _CRTIMP_ALT 997 wint_t 998 __cdecl 999 ungetwc( 1000 _In_ wint_t _Ch, 1001 _Inout_ FILE *_File); 1002 1003 _Check_return_opt_ 1004 _CRTIMP 1005 wchar_t* 1006 __cdecl 1007 fgetws( 1008 _Out_writes_z_(_SizeInWords) wchar_t *_Dst, 1009 _In_ int _SizeInWords, 1010 _Inout_ FILE *_File); 1011 1012 _Check_return_opt_ 1013 _CRTIMP 1014 int 1015 __cdecl 1016 fputws( 1017 _In_z_ const wchar_t *_Str, 1018 _Inout_ FILE *_File); 1019 1020 _CRTIMP 1021 wchar_t* 1022 __cdecl 1023 _getws( 1024 _Pre_notnull_ _Post_z_ wchar_t *_String); 1025 1026 _Check_return_opt_ 1027 _CRTIMP 1028 int 1029 __cdecl 1030 _putws( 1031 _In_z_ const wchar_t *_Str); 1032 1033 _Check_return_opt_ 1034 _CRTIMP 1035 int 1036 __cdecl 1037 fwprintf( 1038 _Inout_ FILE *_File, 1039 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1040 ...); 1041 1042 _Check_return_opt_ 1043 _CRTIMP 1044 int 1045 __cdecl 1046 wprintf( 1047 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1048 ...); 1049 1050 _Check_return_ 1051 _CRTIMP 1052 int 1053 __cdecl 1054 _scwprintf( 1055 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1056 ...); 1057 1058 _Check_return_opt_ 1059 _CRTIMP 1060 int 1061 __cdecl 1062 vfwprintf( 1063 _Inout_ FILE *_File, 1064 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1065 va_list _ArgList); 1066 1067 _Check_return_opt_ 1068 _CRTIMP 1069 int 1070 __cdecl 1071 vwprintf( 1072 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1073 va_list _ArgList); 1074 1075 #if defined __cplusplus || defined _CRT_NON_CONFORMING_SWPRINTFS 1076 _CRTIMP 1077 int 1078 __cdecl 1079 swprintf( 1080 _Out_ wchar_t*, 1081 const wchar_t*, 1082 ...); 1083 1084 _CRTIMP 1085 int 1086 __cdecl 1087 vswprintf( 1088 _Out_ wchar_t*, 1089 const wchar_t*, 1090 va_list); 1091 #endif 1092 1093 _Check_return_opt_ 1094 _CRTIMP 1095 int 1096 __cdecl 1097 _swprintf_c( 1098 _Out_writes_z_(_SizeInWords) wchar_t *_DstBuf, 1099 _In_ size_t _SizeInWords, 1100 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1101 ...); 1102 1103 _Check_return_opt_ 1104 _CRTIMP 1105 int 1106 __cdecl 1107 _vswprintf_c( 1108 _Out_writes_z_(_SizeInWords) wchar_t *_DstBuf, 1109 _In_ size_t _SizeInWords, 1110 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1111 va_list _ArgList); 1112 1113 _CRTIMP int __cdecl _snwprintf(wchar_t *_Dest,size_t _Count,const wchar_t *_Format,...); 1114 _CRTIMP int __cdecl _vsnwprintf(wchar_t *_Dest,size_t _Count,const wchar_t *_Format,va_list _Args); 1115 1116 #ifndef __NO_ISOCEXT /* externs in libmingwex.a */ 1117 _CRTIMP int __cdecl snwprintf (wchar_t *s, size_t n, const wchar_t * format, ...); 1118 __CRT_INLINE int __cdecl vsnwprintf (wchar_t *s, size_t n, const wchar_t *format, va_list arg) { return _vsnwprintf(s,n,format,arg); } 1119 _CRTIMP int __cdecl vwscanf (const wchar_t *, va_list); 1120 _CRTIMP int __cdecl vfwscanf (FILE *,const wchar_t *,va_list); 1121 _CRTIMP int __cdecl vswscanf (const wchar_t *,const wchar_t *,va_list); 1122 #endif 1123 1124 _Check_return_opt_ 1125 _CRTIMP 1126 int 1127 __cdecl 1128 _fwprintf_p( 1129 _Inout_ FILE *_File, 1130 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1131 ...); 1132 1133 _Check_return_opt_ 1134 _CRTIMP 1135 int 1136 __cdecl 1137 _wprintf_p( 1138 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1139 ...); 1140 1141 _Check_return_opt_ 1142 _CRTIMP 1143 int 1144 __cdecl 1145 _vfwprintf_p( 1146 _Inout_ FILE *_File, 1147 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1148 va_list _ArgList); 1149 1150 _Check_return_opt_ 1151 _CRTIMP 1152 int 1153 __cdecl 1154 _vwprintf_p( 1155 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1156 va_list _ArgList); 1157 1158 _Check_return_opt_ 1159 _CRTIMP 1160 int 1161 __cdecl 1162 _swprintf_p( 1163 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1164 _In_ size_t _MaxCount, 1165 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1166 ...); 1167 1168 _Check_return_opt_ 1169 _CRTIMP 1170 int 1171 __cdecl 1172 _vswprintf_p( 1173 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1174 _In_ size_t _MaxCount, 1175 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1176 va_list _ArgList); 1177 1178 _Check_return_ 1179 _CRTIMP 1180 int 1181 __cdecl 1182 _scwprintf_p( 1183 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1184 ...); 1185 1186 _Check_return_ 1187 _CRTIMP 1188 int 1189 __cdecl 1190 _vscwprintf_p( 1191 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1192 va_list _ArgList); 1193 1194 _Check_return_opt_ 1195 _CRTIMP 1196 int 1197 __cdecl 1198 _wprintf_l( 1199 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1200 _In_opt_ _locale_t _Locale, 1201 ...); 1202 1203 _Check_return_opt_ 1204 _CRTIMP 1205 int 1206 __cdecl 1207 _wprintf_p_l( 1208 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1209 _In_opt_ _locale_t _Locale, 1210 ...); 1211 1212 _Check_return_opt_ 1213 _CRTIMP 1214 int 1215 __cdecl 1216 _vwprintf_l( 1217 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1218 _In_opt_ _locale_t _Locale, 1219 va_list _ArgList); 1220 1221 _Check_return_opt_ 1222 _CRTIMP 1223 int 1224 __cdecl 1225 _vwprintf_p_l( 1226 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1227 _In_opt_ _locale_t _Locale, 1228 va_list _ArgList); 1229 1230 _Check_return_opt_ 1231 _CRTIMP 1232 int 1233 __cdecl 1234 _fwprintf_l( 1235 _Inout_ FILE *_File, 1236 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1237 _In_opt_ _locale_t _Locale, 1238 ...); 1239 1240 _Check_return_opt_ 1241 _CRTIMP 1242 int 1243 __cdecl 1244 _fwprintf_p_l( 1245 _Inout_ FILE *_File, 1246 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1247 _In_opt_ _locale_t _Locale, 1248 ...); 1249 1250 _Check_return_opt_ 1251 _CRTIMP 1252 int 1253 __cdecl 1254 _vfwprintf_l( 1255 _Inout_ FILE *_File, 1256 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1257 _In_opt_ _locale_t _Locale, 1258 va_list _ArgList); 1259 1260 _Check_return_opt_ 1261 _CRTIMP 1262 int 1263 __cdecl 1264 _vfwprintf_p_l( 1265 _Inout_ FILE *_File, 1266 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1267 _In_opt_ _locale_t _Locale, 1268 va_list _ArgList); 1269 1270 _Check_return_opt_ 1271 _CRTIMP 1272 int 1273 __cdecl 1274 _swprintf_c_l( 1275 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1276 _In_ size_t _MaxCount, 1277 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1278 _In_opt_ _locale_t _Locale, 1279 ...); 1280 1281 _Check_return_opt_ 1282 _CRTIMP 1283 int 1284 __cdecl 1285 _swprintf_p_l( 1286 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1287 _In_ size_t _MaxCount, 1288 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1289 _In_opt_ _locale_t _Locale, 1290 ...); 1291 1292 _Check_return_opt_ 1293 _CRTIMP 1294 int 1295 __cdecl 1296 _vswprintf_c_l( 1297 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1298 _In_ size_t _MaxCount, 1299 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1300 _In_opt_ _locale_t _Locale, 1301 va_list _ArgList); 1302 1303 _Check_return_opt_ 1304 _CRTIMP 1305 int 1306 __cdecl 1307 _vswprintf_p_l( 1308 _Out_writes_z_(_MaxCount) wchar_t *_DstBuf, 1309 _In_ size_t _MaxCount, 1310 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1311 _In_opt_ _locale_t _Locale, 1312 va_list _ArgList); 1313 1314 _Check_return_ 1315 _CRTIMP 1316 int 1317 __cdecl 1318 _scwprintf_l( 1319 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1320 _In_opt_ _locale_t _Locale, 1321 ...); 1322 1323 _Check_return_ 1324 _CRTIMP 1325 int 1326 __cdecl 1327 _scwprintf_p_l( 1328 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1329 _In_opt_ _locale_t _Locale, 1330 ...); 1331 1332 _Check_return_ 1333 _CRTIMP 1334 int 1335 __cdecl 1336 _vscwprintf_p_l( 1337 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1338 _In_opt_ _locale_t _Locale, 1339 va_list _ArgList); 1340 1341 _Check_return_opt_ 1342 _CRTIMP 1343 int 1344 __cdecl 1345 _snwprintf_l( 1346 _Out_writes_(_MaxCount) wchar_t *_DstBuf, 1347 _In_ size_t _MaxCount, 1348 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1349 _In_opt_ _locale_t _Locale, 1350 ...); 1351 1352 _Check_return_opt_ 1353 _CRTIMP 1354 int 1355 __cdecl 1356 _vsnwprintf_l( 1357 _Out_writes_(_MaxCount) wchar_t *_DstBuf, 1358 _In_ size_t _MaxCount, 1359 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1360 _In_opt_ _locale_t _Locale, 1361 va_list _ArgList); 1362 1363 _CRTIMP 1364 int 1365 __cdecl 1366 _swprintf( 1367 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 1368 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1369 ...); 1370 1371 _CRTIMP 1372 int 1373 __cdecl 1374 _vswprintf( 1375 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 1376 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1377 va_list _Args); 1378 1379 1380 _CRTIMP int __cdecl __swprintf_l(wchar_t *_Dest,const wchar_t *_Format,_locale_t _Plocinfo,...); 1381 _CRTIMP int __cdecl __vswprintf_l(wchar_t *_Dest,const wchar_t *_Format,_locale_t _Plocinfo,va_list _Args); 1382 1383 #ifndef _CRT_NON_CONFORMING_SWPRINTFS 1384 _Check_return_opt_ 1385 static inline 1386 int 1387 __cdecl 1388 swprintf( 1389 _Out_writes_z_(_SizeInWords) wchar_t* _DstBuf, 1390 _In_ size_t _SizeInWords, 1391 _In_z_ _Printf_format_string_ const wchar_t* _Format, 1392 ...) 1393 { 1394 int ret; 1395 va_list args; 1396 1397 va_start(args, _Format); 1398 ret = _vsnwprintf(_DstBuf, _SizeInWords, _Format, args); 1399 va_end(args); 1400 return ret; 1401 } 1402 1403 _Check_return_opt_ 1404 static inline 1405 int 1406 __cdecl 1407 vswprintf( 1408 _Out_writes_z_(_SizeInWords) wchar_t* _DstBuf, 1409 _In_ size_t _SizeInWords, 1410 _In_z_ _Printf_format_string_ const wchar_t* _Format, 1411 va_list _ArgList) 1412 { 1413 return _vsnwprintf(_DstBuf, _SizeInWords, _Format, _ArgList); 1414 } 1415 #endif 1416 1417 _Check_return_ 1418 _CRTIMP 1419 wchar_t* 1420 __cdecl 1421 _wtempnam( 1422 _In_opt_z_ const wchar_t *_Directory, 1423 _In_opt_z_ const wchar_t *_FilePrefix); 1424 1425 _Check_return_ 1426 _CRTIMP 1427 int 1428 __cdecl 1429 _vscwprintf( 1430 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1431 va_list _ArgList); 1432 1433 _Check_return_ 1434 _CRTIMP 1435 int 1436 __cdecl 1437 _vscwprintf_l( 1438 _In_z_ _Printf_format_string_ const wchar_t *_Format, 1439 _In_opt_ _locale_t _Locale, 1440 va_list _ArgList); 1441 1442 _Check_return_ 1443 int 1444 __cdecl 1445 fwscanf( 1446 _Inout_ FILE *_File, 1447 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1448 ...); 1449 1450 _Check_return_opt_ 1451 _CRTIMP 1452 int 1453 __cdecl 1454 _fwscanf_l( 1455 _Inout_ FILE *_File, 1456 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1457 _In_opt_ _locale_t _Locale, 1458 ...); 1459 1460 _Check_return_ 1461 int 1462 __cdecl 1463 swscanf( 1464 _In_z_ const wchar_t *_Src, 1465 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1466 ...); 1467 1468 _Check_return_opt_ 1469 _CRTIMP 1470 int 1471 __cdecl 1472 _swscanf_l( 1473 _In_z_ const wchar_t *_Src, 1474 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1475 _In_opt_ _locale_t _Locale, 1476 ...); 1477 1478 _Check_return_opt_ 1479 _CRTIMP 1480 int 1481 __cdecl 1482 _snwscanf( 1483 _In_reads_(_MaxCount) _Pre_z_ const wchar_t *_Src, 1484 _In_ size_t _MaxCount, 1485 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1486 ...); 1487 1488 _Check_return_opt_ 1489 _CRTIMP 1490 int 1491 __cdecl 1492 _snwscanf_l( 1493 _In_reads_(_MaxCount) _Pre_z_ const wchar_t *_Src, 1494 _In_ size_t _MaxCount, 1495 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1496 _In_opt_ _locale_t _Locale, 1497 ...); 1498 1499 _Check_return_ 1500 int 1501 __cdecl 1502 wscanf( 1503 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1504 ...); 1505 1506 _Check_return_opt_ 1507 _CRTIMP 1508 int 1509 __cdecl 1510 _wscanf_l( 1511 _In_z_ _Scanf_format_string_ const wchar_t *_Format, 1512 _In_opt_ _locale_t _Locale, 1513 ...); 1514 1515 _Check_return_ 1516 _CRTIMP 1517 FILE* 1518 __cdecl 1519 _wfdopen( 1520 _In_ int _FileHandle, 1521 _In_z_ const wchar_t *_Mode); 1522 1523 _Check_return_ 1524 _CRTIMP 1525 FILE* 1526 __cdecl 1527 _wfopen( 1528 _In_z_ const wchar_t *_Filename, 1529 _In_z_ const wchar_t *_Mode); 1530 1531 _Check_return_ 1532 _CRTIMP 1533 FILE* 1534 __cdecl 1535 _wfreopen( 1536 _In_z_ const wchar_t *_Filename, 1537 _In_z_ const wchar_t *_Mode, 1538 _Inout_ FILE *_OldFile); 1539 1540 #ifndef _CRT_WPERROR_DEFINED 1541 #define _CRT_WPERROR_DEFINED 1542 _CRTIMP 1543 void 1544 __cdecl 1545 _wperror( 1546 _In_opt_z_ const wchar_t *_ErrMsg); 1547 #endif 1548 1549 _Check_return_ 1550 _CRTIMP 1551 FILE* 1552 __cdecl 1553 _wpopen( 1554 _In_z_ const wchar_t *_Command, 1555 _In_z_ const wchar_t *_Mode); 1556 1557 #if !defined(NO_OLDNAMES) && !defined(wpopen) 1558 #define wpopen _wpopen 1559 #endif 1560 1561 _Check_return_ 1562 _CRTIMP 1563 int 1564 __cdecl 1565 _wremove( 1566 _In_z_ const wchar_t *_Filename); 1567 1568 _CRTIMP 1569 wchar_t* 1570 __cdecl 1571 _wtmpnam( 1572 _Pre_maybenull_ _Post_z_ wchar_t *_Buffer); 1573 1574 _Check_return_opt_ 1575 _CRTIMP 1576 wint_t 1577 __cdecl 1578 _fgetwc_nolock( 1579 _Inout_ FILE *_File); 1580 1581 _Check_return_opt_ 1582 _CRTIMP 1583 wint_t 1584 __cdecl 1585 _fputwc_nolock( 1586 _In_ wchar_t _Ch, 1587 _Inout_ FILE *_File); 1588 1589 _Check_return_opt_ 1590 _CRTIMP 1591 wint_t 1592 __cdecl 1593 _ungetwc_nolock( 1594 _In_ wint_t _Ch, 1595 _Inout_ FILE *_File); 1596 1597 #undef _CRT_GETPUTWCHAR_NOINLINE 1598 1599 #if !defined(__cplusplus) || defined(_CRT_GETPUTWCHAR_NOINLINE) 1600 #define getwchar() fgetwc(stdin) 1601 #define putwchar(_c) fputwc((_c),stdout) 1602 #else 1603 _Check_return_ __CRT_INLINE wint_t __cdecl getwchar() {return (fgetwc(stdin)); } 1604 _Check_return_opt_ __CRT_INLINE wint_t __cdecl putwchar(_In_ wchar_t _C) {return (fputwc(_C,stdout)); } 1605 #endif 1606 1607 #define getwc(_stm) fgetwc(_stm) 1608 #define putwc(_c,_stm) fputwc(_c,_stm) 1609 #define _putwc_nolock(_c,_stm) _fputwc_nolock(_c,_stm) 1610 #define _getwc_nolock(_c) _fgetwc_nolock(_c) 1611 1612 #endif /* _WSTDIO_DEFINED */ 1613 1614 #ifndef _WSTDLIB_DEFINED 1615 #define _WSTDLIB_DEFINED 1616 1617 _CRTIMP 1618 wchar_t* 1619 __cdecl 1620 _itow( 1621 _In_ int _Value, 1622 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 1623 _In_ int _Radix); 1624 1625 _CRTIMP 1626 wchar_t* 1627 __cdecl 1628 _ltow( 1629 _In_ long _Value, 1630 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 1631 _In_ int _Radix); 1632 1633 _CRTIMP 1634 wchar_t* 1635 __cdecl 1636 _ultow( 1637 _In_ unsigned long _Value, 1638 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 1639 _In_ int _Radix); 1640 1641 _Check_return_ 1642 double 1643 __cdecl 1644 wcstod( 1645 _In_z_ const wchar_t *_Str, 1646 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr); 1647 1648 _Check_return_ 1649 _CRTIMP 1650 double 1651 __cdecl 1652 _wcstod_l( 1653 _In_z_ const wchar_t *_Str, 1654 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1655 _In_opt_ _locale_t _Locale); 1656 1657 float __cdecl wcstof( const wchar_t *nptr, wchar_t **endptr); 1658 1659 #if !defined __NO_ISOCEXT /* in libmingwex.a */ 1660 float __cdecl wcstof (const wchar_t * __restrict__, wchar_t ** __restrict__); 1661 long double __cdecl wcstold (const wchar_t * __restrict__, wchar_t ** __restrict__); 1662 #endif /* __NO_ISOCEXT */ 1663 1664 _Check_return_ 1665 long 1666 __cdecl 1667 wcstol( 1668 _In_z_ const wchar_t *_Str, 1669 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1670 _In_ int _Radix); 1671 1672 _Check_return_ 1673 _CRTIMP 1674 long 1675 __cdecl 1676 _wcstol_l( 1677 _In_z_ const wchar_t *_Str, 1678 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1679 _In_ int _Radix, 1680 _In_opt_ _locale_t _Locale); 1681 1682 _Check_return_ 1683 unsigned long 1684 __cdecl 1685 wcstoul( 1686 _In_z_ const wchar_t *_Str, 1687 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1688 _In_ int _Radix); 1689 1690 _Check_return_ 1691 _CRTIMP 1692 unsigned long 1693 __cdecl 1694 _wcstoul_l( 1695 _In_z_ const wchar_t *_Str, 1696 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1697 _In_ int _Radix, 1698 _In_opt_ _locale_t _Locale); 1699 1700 _Check_return_ 1701 _CRTIMP 1702 wchar_t* 1703 __cdecl 1704 _wgetenv( 1705 _In_z_ const wchar_t *_VarName); 1706 1707 #ifndef _CRT_WSYSTEM_DEFINED 1708 #define _CRT_WSYSTEM_DEFINED 1709 _CRTIMP 1710 int 1711 __cdecl 1712 _wsystem( 1713 _In_opt_z_ const wchar_t *_Command); 1714 #endif 1715 1716 _Check_return_ 1717 _CRTIMP 1718 double 1719 __cdecl 1720 _wtof( 1721 _In_z_ const wchar_t *_Str); 1722 1723 _Check_return_ 1724 _CRTIMP 1725 double 1726 __cdecl 1727 _wtof_l( 1728 _In_z_ const wchar_t *_Str, 1729 _In_opt_ _locale_t _Locale); 1730 1731 _Check_return_ 1732 _CRTIMP 1733 int 1734 __cdecl 1735 _wtoi( 1736 _In_z_ const wchar_t *_Str); 1737 1738 _Check_return_ 1739 _CRTIMP 1740 int 1741 __cdecl 1742 _wtoi_l( 1743 _In_z_ const wchar_t *_Str, 1744 _In_opt_ _locale_t _Locale); 1745 1746 _Check_return_ 1747 _CRTIMP 1748 long 1749 __cdecl 1750 _wtol( 1751 _In_z_ const wchar_t *_Str); 1752 1753 _Check_return_ 1754 _CRTIMP 1755 long 1756 __cdecl 1757 _wtol_l( 1758 _In_z_ const wchar_t *_Str, 1759 _In_opt_ _locale_t _Locale); 1760 1761 #if _INTEGRAL_MAX_BITS >= 64 1762 1763 __MINGW_EXTENSION 1764 _CRTIMP 1765 wchar_t* 1766 __cdecl 1767 _i64tow( 1768 _In_ __int64 _Val, 1769 _Pre_notnull_ _Post_z_ wchar_t *_DstBuf, 1770 _In_ int _Radix); 1771 1772 __MINGW_EXTENSION 1773 _CRTIMP 1774 wchar_t* 1775 __cdecl 1776 _ui64tow( 1777 _In_ unsigned __int64 _Val, 1778 _Pre_notnull_ _Post_z_ wchar_t *_DstBuf, 1779 _In_ int _Radix); 1780 1781 __MINGW_EXTENSION 1782 _Check_return_ 1783 _CRTIMP 1784 __int64 1785 __cdecl 1786 _wtoi64( 1787 _In_z_ const wchar_t *_Str); 1788 1789 __MINGW_EXTENSION 1790 _Check_return_ 1791 _CRTIMP 1792 __int64 1793 __cdecl 1794 _wtoi64_l( 1795 _In_z_ const wchar_t *_Str, 1796 _In_opt_ _locale_t _Locale); 1797 1798 __MINGW_EXTENSION 1799 _Check_return_ 1800 _CRTIMP 1801 __int64 1802 __cdecl 1803 _wcstoi64( 1804 _In_z_ const wchar_t *_Str, 1805 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1806 _In_ int _Radix); 1807 1808 __MINGW_EXTENSION 1809 _Check_return_ 1810 _CRTIMP 1811 __int64 1812 __cdecl 1813 _wcstoi64_l( 1814 _In_z_ const wchar_t *_Str, 1815 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1816 _In_ int _Radix, 1817 _In_opt_ _locale_t _Locale); 1818 1819 __MINGW_EXTENSION 1820 _Check_return_ 1821 _CRTIMP 1822 unsigned __int64 1823 __cdecl 1824 _wcstoui64( 1825 _In_z_ const wchar_t *_Str, 1826 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1827 _In_ int _Radix); 1828 1829 __MINGW_EXTENSION 1830 _Check_return_ 1831 _CRTIMP 1832 unsigned __int64 1833 __cdecl 1834 _wcstoui64_l( 1835 _In_z_ const wchar_t *_Str, 1836 _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, 1837 _In_ int _Radix, 1838 _In_opt_ _locale_t _Locale); 1839 1840 #endif /* _INTEGRAL_MAX_BITS >= 64 */ 1841 1842 #endif /* _WSTDLIB_DEFINED */ 1843 1844 #ifndef _POSIX_ 1845 1846 #ifndef _WSTDLIBP_DEFINED 1847 #define _WSTDLIBP_DEFINED 1848 1849 _Check_return_ 1850 _CRTIMP 1851 wchar_t* 1852 __cdecl 1853 _wfullpath( 1854 _Out_writes_opt_z_(_SizeInWords) wchar_t *_FullPath, 1855 _In_z_ const wchar_t *_Path, 1856 _In_ size_t _SizeInWords); 1857 1858 _CRTIMP 1859 void 1860 __cdecl 1861 _wmakepath( 1862 _Pre_notnull_ _Post_z_ wchar_t *_ResultPath, 1863 _In_opt_z_ const wchar_t *_Drive, 1864 _In_opt_z_ const wchar_t *_Dir, 1865 _In_opt_z_ const wchar_t *_Filename, 1866 _In_opt_z_ const wchar_t *_Ext); 1867 1868 #ifndef _CRT_WPERROR_DEFINED 1869 #define _CRT_WPERROR_DEFINED 1870 _CRTIMP 1871 void 1872 __cdecl 1873 _wperror( 1874 _In_opt_z_ const wchar_t *_ErrMsg); 1875 #endif 1876 1877 _Check_return_ 1878 _CRTIMP 1879 int 1880 __cdecl 1881 _wputenv( 1882 _In_z_ const wchar_t *_EnvString); 1883 1884 _CRTIMP 1885 void 1886 __cdecl 1887 _wsearchenv( 1888 _In_z_ const wchar_t *_Filename, 1889 _In_z_ const wchar_t *_EnvVar, 1890 _Pre_notnull_ _Post_z_ wchar_t *_ResultPath); 1891 1892 _CRTIMP 1893 void 1894 __cdecl 1895 _wsplitpath( 1896 _In_z_ const wchar_t *_FullPath, 1897 _Pre_maybenull_ _Post_z_ wchar_t *_Drive, 1898 _Pre_maybenull_ _Post_z_ wchar_t *_Dir, 1899 _Pre_maybenull_ _Post_z_ wchar_t *_Filename, 1900 _Pre_maybenull_ _Post_z_ wchar_t *_Ext); 1901 1902 #endif /* _WSTDLIBP_DEFINED */ 1903 1904 #endif /* _POSIX_ */ 1905 1906 #ifndef _WSTRING_DEFINED 1907 #define _WSTRING_DEFINED 1908 1909 _Check_return_ 1910 _CRTIMP 1911 wchar_t* 1912 __cdecl 1913 _wcsdup( 1914 _In_z_ const wchar_t *_Str); 1915 1916 wchar_t* 1917 __cdecl 1918 wcscat( 1919 _Inout_updates_z_(_String_length_(_Dest) + _String_length_(_Source) + 1) wchar_t *_Dest, 1920 _In_z_ const wchar_t *_Source); 1921 1922 _CONST_RETURN 1923 wchar_t* 1924 __cdecl 1925 wcschr( 1926 _In_z_ const wchar_t *_Str, 1927 wchar_t _Ch); 1928 1929 _Check_return_ 1930 int 1931 __cdecl 1932 wcscmp( 1933 _In_z_ const wchar_t *_Str1, 1934 _In_z_ const wchar_t *_Str2); 1935 1936 wchar_t* 1937 __cdecl 1938 wcscpy( 1939 _Out_writes_z_(_String_length_(_Source) + 1) wchar_t *_Dest, 1940 _In_z_ const wchar_t *_Source); 1941 1942 _Check_return_ 1943 size_t 1944 __cdecl 1945 wcscspn( 1946 _In_z_ const wchar_t *_Str, 1947 _In_z_ const wchar_t *_Control); 1948 1949 _CRTIMP 1950 size_t 1951 __cdecl 1952 wcslen( 1953 _In_z_ const wchar_t *_Str); 1954 1955 _When_(_MaxCount > _String_length_(_Src), 1956 _Post_satisfies_(return == _String_length_(_Src))) 1957 _When_(_MaxCount <= _String_length_(_Src), 1958 _Post_satisfies_(return == _MaxCount)) 1959 size_t 1960 __cdecl 1961 wcsnlen( 1962 _In_reads_or_z_(_MaxCount) const wchar_t *_Src, 1963 _In_ size_t _MaxCount); 1964 1965 wchar_t* 1966 __cdecl 1967 wcsncat( 1968 wchar_t *_Dest, 1969 const wchar_t *_Source, 1970 size_t _Count); 1971 1972 _Check_return_ 1973 int 1974 __cdecl 1975 wcsncmp( 1976 _In_reads_or_z_(_MaxCount) const wchar_t *_Str1, 1977 _In_reads_or_z_(_MaxCount) const wchar_t *_Str2, 1978 _In_ size_t _MaxCount); 1979 1980 wchar_t* 1981 __cdecl 1982 wcsncpy( 1983 wchar_t *_Dest, 1984 const wchar_t *_Source, 1985 size_t _Count); 1986 1987 _Check_return_ 1988 _CONST_RETURN 1989 wchar_t* 1990 __cdecl 1991 wcspbrk( 1992 _In_z_ const wchar_t *_Str, 1993 _In_z_ const wchar_t *_Control); 1994 1995 _Check_return_ 1996 _CONST_RETURN 1997 wchar_t* 1998 __cdecl 1999 wcsrchr( 2000 _In_z_ const wchar_t *_Str, 2001 _In_ wchar_t _Ch); 2002 2003 _Check_return_ 2004 size_t 2005 __cdecl 2006 wcsspn( 2007 _In_z_ const wchar_t *_Str, 2008 _In_z_ const wchar_t *_Control); 2009 2010 _CONST_RETURN 2011 wchar_t* 2012 __cdecl 2013 wcsstr( 2014 _In_z_ const wchar_t *_Str, 2015 _In_z_ const wchar_t *_SubStr); 2016 2017 _Check_return_ 2018 wchar_t* 2019 __cdecl 2020 wcstok( 2021 _Inout_opt_z_ wchar_t *_Str, 2022 _In_z_ const wchar_t *_Delim); 2023 2024 _Check_return_ 2025 _CRTIMP 2026 wchar_t* 2027 __cdecl 2028 _wcserror( 2029 _In_ int _ErrNum); 2030 2031 _Check_return_ 2032 _CRTIMP 2033 wchar_t* 2034 __cdecl 2035 __wcserror( 2036 _In_opt_z_ const wchar_t *_Str); 2037 2038 _Check_return_ 2039 _CRTIMP 2040 int 2041 __cdecl 2042 _wcsicmp( 2043 _In_z_ const wchar_t *_Str1, 2044 _In_z_ const wchar_t *_Str2); 2045 2046 _Check_return_ 2047 _CRTIMP 2048 int 2049 __cdecl 2050 _wcsicmp_l( 2051 _In_z_ const wchar_t *_Str1, 2052 _In_z_ const wchar_t *_Str2, 2053 _In_opt_ _locale_t _Locale); 2054 2055 _Check_return_ 2056 _CRTIMP 2057 int 2058 __cdecl 2059 _wcsnicmp( 2060 _In_reads_or_z_(_MaxCount) const wchar_t *_Str1, 2061 _In_reads_or_z_(_MaxCount) const wchar_t *_Str2, 2062 _In_ size_t _MaxCount); 2063 2064 _Check_return_ 2065 _CRTIMP 2066 int 2067 __cdecl 2068 _wcsnicmp_l( 2069 _In_reads_or_z_(_MaxCount) const wchar_t *_Str1, 2070 _In_reads_or_z_(_MaxCount) const wchar_t *_Str2, 2071 _In_ size_t _MaxCount, 2072 _In_opt_ _locale_t _Locale); 2073 2074 _CRTIMP 2075 wchar_t* 2076 __cdecl 2077 _wcsnset( 2078 wchar_t *_Str, 2079 wchar_t _Val, 2080 size_t _MaxCount); 2081 2082 _CRTIMP 2083 wchar_t* 2084 __cdecl 2085 _wcsrev( 2086 _Inout_z_ wchar_t *_Str); 2087 2088 _CRTIMP 2089 wchar_t* 2090 __cdecl 2091 _wcsset( 2092 wchar_t *_Str, 2093 wchar_t _Val); 2094 2095 _CRTIMP 2096 wchar_t* 2097 __cdecl 2098 _wcslwr( 2099 _Inout_z_ wchar_t *_String); 2100 2101 _CRTIMP 2102 wchar_t* 2103 _wcslwr_l( 2104 wchar_t *_String, 2105 _locale_t _Locale); 2106 2107 _CRTIMP 2108 wchar_t* 2109 __cdecl 2110 _wcsupr( 2111 _Inout_z_ wchar_t *_String); 2112 2113 _CRTIMP 2114 wchar_t* 2115 _wcsupr_l( 2116 wchar_t *_String, 2117 _locale_t _Locale); 2118 2119 _Check_return_opt_ 2120 size_t 2121 __cdecl 2122 wcsxfrm( 2123 _Out_writes_opt_(_MaxCount) _Post_maybez_ wchar_t *_Dst, 2124 _In_z_ const wchar_t *_Src, 2125 _In_ size_t _MaxCount); 2126 2127 _Check_return_opt_ 2128 _CRTIMP 2129 size_t 2130 __cdecl 2131 _wcsxfrm_l( 2132 _Out_writes_opt_(_MaxCount) _Post_maybez_ wchar_t *_Dst, 2133 _In_z_ const wchar_t *_Src, 2134 _In_ size_t _MaxCount, 2135 _In_opt_ _locale_t _Locale); 2136 2137 _Check_return_ 2138 int 2139 __cdecl 2140 wcscoll( 2141 _In_z_ const wchar_t *_Str1, 2142 _In_z_ const wchar_t *_Str2); 2143 2144 _Check_return_ 2145 _CRTIMP 2146 int 2147 __cdecl 2148 _wcscoll_l( 2149 _In_z_ const wchar_t *_Str1, 2150 _In_z_ const wchar_t *_Str2, 2151 _In_opt_ _locale_t _Locale); 2152 2153 _Check_return_ 2154 _CRTIMP 2155 int 2156 __cdecl 2157 _wcsicoll( 2158 _In_z_ const wchar_t *_Str1, 2159 _In_z_ const wchar_t *_Str2); 2160 2161 _Check_return_ 2162 _CRTIMP 2163 int 2164 __cdecl 2165 _wcsicoll_l( 2166 _In_z_ const wchar_t *_Str1, 2167 _In_z_ const wchar_t *_Str2, 2168 _In_opt_ _locale_t _Locale); 2169 2170 _Check_return_ 2171 _CRTIMP 2172 int 2173 __cdecl 2174 _wcsncoll( 2175 _In_z_ const wchar_t *_Str1, 2176 _In_z_ const wchar_t *_Str2, 2177 _In_ size_t _MaxCount); 2178 2179 _Check_return_ 2180 _CRTIMP 2181 int 2182 __cdecl 2183 _wcsncoll_l( 2184 _In_z_ const wchar_t *_Str1, 2185 _In_z_ const wchar_t *_Str2, 2186 _In_ size_t _MaxCount, 2187 _In_opt_ _locale_t _Locale); 2188 2189 _Check_return_ 2190 _CRTIMP 2191 int 2192 __cdecl 2193 _wcsnicoll( 2194 _In_z_ const wchar_t *_Str1, 2195 _In_z_ const wchar_t *_Str2, 2196 _In_ size_t _MaxCount); 2197 2198 _Check_return_ 2199 _CRTIMP 2200 int 2201 __cdecl 2202 _wcsnicoll_l( 2203 _In_z_ const wchar_t *_Str1, 2204 _In_z_ const wchar_t *_Str2, 2205 _In_ size_t _MaxCount, 2206 _In_opt_ _locale_t _Locale); 2207 2208 #ifndef NO_OLDNAMES 2209 2210 _Check_return_ 2211 _CRTIMP 2212 wchar_t* 2213 __cdecl 2214 wcsdup( 2215 _In_z_ const wchar_t *_Str); 2216 2217 #define wcswcs wcsstr 2218 2219 _Check_return_ 2220 _CRTIMP 2221 int 2222 __cdecl 2223 wcsicmp( 2224 _In_z_ const wchar_t *_Str1, 2225 _In_z_ const wchar_t *_Str2); 2226 2227 _Check_return_ 2228 _CRTIMP 2229 int 2230 __cdecl 2231 wcsnicmp( 2232 _In_reads_or_z_(_MaxCount) const wchar_t *_Str1, 2233 _In_reads_or_z_(_MaxCount) const wchar_t *_Str2, 2234 _In_ size_t _MaxCount); 2235 2236 _CRTIMP 2237 wchar_t* 2238 __cdecl 2239 wcsnset( 2240 _Inout_updates_z_(_MaxCount) wchar_t *_Str, 2241 _In_ wchar_t _Val, 2242 _In_ size_t _MaxCount); 2243 2244 _CRTIMP 2245 wchar_t* 2246 __cdecl 2247 wcsrev( 2248 _Inout_z_ wchar_t *_Str); 2249 2250 _CRTIMP 2251 wchar_t* 2252 __cdecl 2253 wcsset( 2254 _Inout_z_ wchar_t *_Str, 2255 wchar_t _Val); 2256 2257 _CRTIMP 2258 wchar_t* 2259 __cdecl 2260 wcslwr( 2261 _Inout_z_ wchar_t *_Str); 2262 2263 _CRTIMP 2264 wchar_t* 2265 __cdecl 2266 wcsupr( 2267 _Inout_z_ wchar_t *_Str); 2268 2269 _Check_return_ 2270 _CRTIMP 2271 int 2272 __cdecl 2273 wcsicoll( 2274 _In_z_ const wchar_t *_Str1, 2275 _In_z_ const wchar_t *_Str2); 2276 2277 #endif /* NO_OLDNAMES */ 2278 2279 #endif /* _WSTRING_DEFINED */ 2280 2281 #ifndef _TM_DEFINED 2282 #define _TM_DEFINED 2283 struct tm { 2284 int tm_sec; 2285 int tm_min; 2286 int tm_hour; 2287 int tm_mday; 2288 int tm_mon; 2289 int tm_year; 2290 int tm_wday; 2291 int tm_yday; 2292 int tm_isdst; 2293 }; 2294 #endif 2295 2296 #ifndef _WTIME_DEFINED 2297 #define _WTIME_DEFINED 2298 2299 _CRTIMP 2300 wchar_t* 2301 __cdecl 2302 _wasctime( 2303 _In_ const struct tm *_Tm); 2304 2305 _CRTIMP 2306 wchar_t* 2307 __cdecl 2308 _wctime32( 2309 _In_ const __time32_t *_Time); 2310 2311 _Success_(return > 0) 2312 size_t 2313 __cdecl 2314 wcsftime( 2315 _Out_writes_z_(_SizeInWords) wchar_t *_Buf, 2316 _In_ size_t _SizeInWords, 2317 _In_z_ _Printf_format_string_ const wchar_t *_Format, 2318 _In_ const struct tm *_Tm); 2319 2320 _Success_(return > 0) 2321 _CRTIMP 2322 size_t 2323 __cdecl 2324 _wcsftime_l( 2325 _Out_writes_z_(_SizeInWords) wchar_t *_Buf, 2326 _In_ size_t _SizeInWords, 2327 _In_z_ _Printf_format_string_ const wchar_t *_Format, 2328 _In_ const struct tm *_Tm, 2329 _In_opt_ _locale_t _Locale); 2330 2331 _CRTIMP 2332 wchar_t* 2333 __cdecl 2334 _wstrdate( 2335 _Out_writes_z_(9) wchar_t *_Buffer); 2336 2337 _CRTIMP 2338 wchar_t* 2339 __cdecl 2340 _wstrtime( 2341 _Out_writes_z_(9) wchar_t *_Buffer); 2342 2343 _CRTIMP 2344 errno_t 2345 __cdecl 2346 _wasctime_s( 2347 _Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf, 2348 _In_ size_t _SizeInWords, 2349 _In_ const struct tm *_Tm); 2350 2351 _CRTIMP 2352 errno_t 2353 __cdecl 2354 _wctime32_s( 2355 _Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf, 2356 _In_ size_t _SizeInWords, 2357 _In_ const __time32_t *_Time); 2358 2359 _CRTIMP 2360 errno_t 2361 __cdecl 2362 _wstrdate_s( 2363 _Out_writes_(_SizeInWords) _Post_readable_size_(9) wchar_t *_Buf, 2364 _In_range_(>=, 9) size_t _SizeInWords); 2365 2366 _CRTIMP 2367 errno_t 2368 __cdecl 2369 _wstrtime_s( 2370 _Out_writes_(_SizeInWords) _Post_readable_size_(9) wchar_t *_Buf, 2371 _In_ size_t _SizeInWords); 2372 2373 #if _INTEGRAL_MAX_BITS >= 64 2374 2375 _CRTIMP 2376 wchar_t* 2377 __cdecl 2378 _wctime64( 2379 _In_ const __time64_t *_Time); 2380 2381 _CRTIMP 2382 errno_t 2383 __cdecl 2384 _wctime64_s( 2385 _Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf, 2386 _In_ size_t _SizeInWords, 2387 _In_ const __time64_t *_Time); 2388 2389 #endif /* _INTEGRAL_MAX_BITS >= 64 */ 2390 2391 #if !defined (RC_INVOKED) && !defined (_INC_WTIME_INL) 2392 #define _INC_WTIME_INL 2393 #ifdef _USE_32BIT_TIME_T 2394 __CRT_INLINE wchar_t *__cdecl _wctime(const time_t *_Time) { return _wctime32(_Time); } 2395 #else /* !_USE_32BIT_TIME_T */ 2396 __CRT_INLINE wchar_t *__cdecl _wctime(const time_t *_Time) { return _wctime64(_Time); } 2397 #endif /* !_USE_32BIT_TIME_T */ 2398 #endif /* !defined (RC_INVOKED) && !defined (_INC_WTIME_INL) */ 2399 2400 #endif /* _WTIME_DEFINED */ 2401 2402 typedef int mbstate_t; 2403 typedef wchar_t _Wint_t; 2404 2405 wint_t 2406 __cdecl 2407 btowc( 2408 int); 2409 2410 size_t 2411 __cdecl 2412 mbrlen( 2413 _In_reads_bytes_opt_(_SizeInBytes) _Pre_opt_z_ const char *_Ch, 2414 _In_ size_t _SizeInBytes, 2415 _Out_opt_ mbstate_t *_State); 2416 2417 size_t 2418 __cdecl 2419 mbrtowc( 2420 _Pre_maybenull_ _Post_z_ wchar_t *_DstCh, 2421 _In_reads_bytes_opt_(_SizeInBytes) _Pre_opt_z_ const char *_SrcCh, 2422 _In_ size_t _SizeInBytes, 2423 _Out_opt_ mbstate_t *_State); 2424 2425 size_t 2426 __cdecl 2427 mbsrtowcs( 2428 _Pre_notnull_ _Post_z_ wchar_t *_Dest, 2429 _Inout_ _Deref_prepost_opt_valid_ const char **_PSrc, 2430 _In_ size_t _Count, 2431 _Inout_opt_ mbstate_t *_State); 2432 2433 size_t 2434 __cdecl 2435 wcrtomb( 2436 _Pre_maybenull_ _Post_z_ char *_Dest, 2437 _In_ wchar_t _Source, 2438 _Out_opt_ mbstate_t *_State); 2439 2440 size_t 2441 __cdecl 2442 wcsrtombs( 2443 _Pre_maybenull_ _Post_z_ char *_Dest, 2444 _Inout_ _Deref_prepost_z_ const wchar_t **_PSource, 2445 _In_ size_t _Count, 2446 _Out_opt_ mbstate_t *_State); 2447 2448 int 2449 __cdecl 2450 wctob( 2451 _In_ wint_t _WCh); 2452 2453 #ifndef __NO_ISOCEXT /* these need static lib libmingwex.a */ 2454 2455 wchar_t* 2456 __cdecl 2457 wmemset( 2458 _Out_writes_all_(_N) wchar_t *_S, 2459 _In_ wchar_t _C, 2460 _In_ size_t _N); 2461 2462 _CONST_RETURN 2463 wchar_t* 2464 __cdecl 2465 wmemchr( 2466 _In_reads_(_N) const wchar_t *_S, 2467 _In_ wchar_t _C, 2468 _In_ size_t _N); 2469 2470 int 2471 __cdecl 2472 wmemcmp( 2473 _In_reads_(_N) const wchar_t *_S1, 2474 _In_reads_(_N) const wchar_t *_S2, 2475 _In_ size_t _N); 2476 2477 _Post_equal_to_(_S1) 2478 _At_buffer_(_S1, _Iter_, _N, _Post_satisfies_(_S1[_Iter_] == _S2[_Iter_])) 2479 wchar_t* 2480 __cdecl 2481 wmemcpy( 2482 _Out_writes_all_(_N) wchar_t *_S1, 2483 _In_reads_(_N) const wchar_t *_S2, 2484 _In_ size_t _N); 2485 2486 wchar_t* 2487 __cdecl 2488 wmemmove( 2489 _Out_writes_all_opt_(_N) wchar_t *_S1, 2490 _In_reads_opt_(_N) const wchar_t *_S2, 2491 _In_ size_t _N); 2492 2493 __MINGW_EXTENSION 2494 long long 2495 __cdecl 2496 wcstoll( 2497 const wchar_t *nptr, 2498 wchar_t **endptr, 2499 int base); 2500 2501 __MINGW_EXTENSION 2502 unsigned long long 2503 __cdecl 2504 wcstoull( 2505 const wchar_t *nptr, 2506 wchar_t **endptr, 2507 int base); 2508 2509 #endif /* __NO_ISOCEXT */ 2510 2511 void* 2512 __cdecl 2513 memmove( 2514 _Out_writes_bytes_all_opt_(_MaxCount) void *_Dst, 2515 _In_reads_bytes_opt_(_MaxCount) const void *_Src, 2516 _In_ size_t _MaxCount); 2517 2518 _Post_equal_to_(_Dst) 2519 _At_buffer_((unsigned char*)_Dst, 2520 _Iter_, 2521 _MaxCount, 2522 _Post_satisfies_(((unsigned char*)_Dst)[_Iter_] == ((unsigned char*)_Src)[_Iter_])) 2523 void* 2524 __cdecl 2525 memcpy( 2526 _Out_writes_bytes_all_(_MaxCount) void *_Dst, 2527 _In_reads_bytes_(_MaxCount) const void *_Src, 2528 _In_ size_t _MaxCount); 2529 2530 __CRT_INLINE 2531 int 2532 __cdecl 2533 fwide( 2534 _In_opt_ FILE *_F, 2535 int _M) 2536 { 2537 (void)_F; 2538 return (_M); 2539 } 2540 2541 __CRT_INLINE 2542 int 2543 __cdecl 2544 mbsinit( 2545 _In_opt_ const mbstate_t *_P) 2546 { 2547 return (!_P || *_P==0); 2548 } 2549 2550 __CRT_INLINE 2551 _CONST_RETURN 2552 wchar_t* 2553 __cdecl 2554 wmemchr( 2555 _In_reads_(_N) const wchar_t *_S, 2556 _In_ wchar_t _C, 2557 _In_ size_t _N) 2558 { 2559 for (;0<_N;++_S,--_N) 2560 { 2561 if (*_S==_C) return (_CONST_RETURN wchar_t *)(_S); 2562 } 2563 return (0); 2564 } 2565 2566 __CRT_INLINE 2567 int 2568 __cdecl 2569 wmemcmp( 2570 _In_reads_(_N) const wchar_t *_S1, 2571 _In_reads_(_N) const wchar_t *_S2, 2572 _In_ size_t _N) 2573 { 2574 for (; 0 < _N; ++_S1,++_S2,--_N) 2575 { 2576 if (*_S1!=*_S2) return (*_S1 < *_S2 ? -1 : +1); 2577 } 2578 return (0); 2579 } 2580 2581 _Post_equal_to_(_S1) 2582 _At_buffer_(_S1, 2583 _Iter_, 2584 _N, 2585 _Post_satisfies_(_S1[_Iter_] == _S2[_Iter_])) 2586 __CRT_INLINE 2587 wchar_t* 2588 __cdecl 2589 wmemcpy( 2590 _Out_writes_all_(_N) wchar_t *_S1, 2591 _In_reads_(_N) const wchar_t *_S2, 2592 _In_ size_t _N) 2593 { 2594 return (wchar_t *)memcpy(_S1,_S2,_N*sizeof(wchar_t)); 2595 } 2596 2597 __CRT_INLINE 2598 wchar_t* 2599 __cdecl 2600 wmemmove( 2601 _Out_writes_all_opt_(_N) wchar_t *_S1, 2602 _In_reads_opt_(_N) const wchar_t *_S2, 2603 _In_ size_t _N) 2604 { 2605 return (wchar_t *)memmove(_S1,_S2,_N*sizeof(wchar_t)); 2606 } 2607 2608 __CRT_INLINE 2609 wchar_t* 2610 __cdecl 2611 wmemset( 2612 _Out_writes_all_(_N) wchar_t *_S, 2613 _In_ wchar_t _C, 2614 _In_ size_t _N) 2615 { 2616 wchar_t *_Su = _S; 2617 for (;0<_N;++_Su,--_N) { 2618 *_Su = _C; 2619 } 2620 return (_S); 2621 } 2622 2623 #ifdef _MSC_VER 2624 #pragma warning(pop) 2625 #endif 2626 2627 #ifdef __cplusplus 2628 } 2629 #endif 2630 2631 #pragma pack(pop) 2632 2633 #include <sec_api/wchar_s.h> 2634 #endif 2635