STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
yvals.h
Go to the documentation of this file.
1 /* yvals.h internal header for Microsoft C/C++ */
2 #pragma once
3 #ifndef _YVALS
4 #define _YVALS
5 #ifndef RC_INVOKED
6 
7 #include <xkeycheck.h>
8 #include <crtdefs.h>
9 
10 #pragma pack(push,_CRT_PACKING)
11 #pragma push_macro("new")
12 #undef new
13 
14 #define _CPPLIB_VER 650
15 
16  #ifndef _HAS_VARIABLE_TEMPLATES
17  #ifdef __EDG__
18  #define _HAS_VARIABLE_TEMPLATES 0 // TRANSITION
19  #else /* __EDG__ */
20  #define _HAS_VARIABLE_TEMPLATES 1
21  #endif /* __EDG__ */
22  #endif /* _HAS_VARIABLE_TEMPLATES */
23 
24  #if _HAS_EXCEPTIONS
25  #define _NOEXCEPT noexcept
26  #define _NOEXCEPT_OP(x) noexcept(x)
27  #else /* _HAS_EXCEPTIONS */
28  #define _NOEXCEPT throw ()
29  #define _NOEXCEPT_OP(x)
30  #endif /* _HAS_EXCEPTIONS */
31 
32 
33 // _HAS_CXX17 directly controls:
34 // P0025R1 clamp()
35 // P0185R1 is_swappable, is_nothrow_swappable
36 // P0272R1 Non-const basic_string::data()
37 
38 // _HAS_CXX17 indirectly controls:
39 // N4190 Removing auto_ptr, random_shuffle(), And Old <functional> Stuff
40 // P0004R1 Removing Deprecated Iostreams Aliases
41 // LWG 2385 function::assign allocator argument doesn't make sense
42 // The non-Standard std::tr1 namespace and TR1-only machinery
43 // The non-Standard std::identity struct
44 
45  #ifndef _HAS_CXX17
46  #ifdef _MSVC_LANG
47  #if _MSVC_LANG > 201402
48  #define _HAS_CXX17 1
49  #else /* _MSVC_LANG > 201402 */
50  #define _HAS_CXX17 0
51  #endif /* _MSVC_LANG > 201402 */
52  #else /* _MSVC_LANG */
53  #if __cplusplus > 201402
54  #define _HAS_CXX17 1
55  #else /* __cplusplus > 201402 */
56  #define _HAS_CXX17 0
57  #endif /* __cplusplus > 201402 */
58  #endif /* _MSVC_LANG */
59  #endif /* _HAS_CXX17 */
60 
61 // N4190 Removing auto_ptr, random_shuffle(), And Old <functional> Stuff
62  #ifndef _HAS_AUTO_PTR_ETC
63  #if _HAS_CXX17
64  #define _HAS_AUTO_PTR_ETC 0
65  #else /* _HAS_CXX17 */
66  #define _HAS_AUTO_PTR_ETC 1
67  #endif /* _HAS_CXX17 */
68  #endif /* _HAS_AUTO_PTR_ETC */
69 
70 // P0004R1 Removing Deprecated Iostreams Aliases
71  #ifndef _HAS_OLD_IOSTREAMS_MEMBERS
72  #if _HAS_CXX17
73  #define _HAS_OLD_IOSTREAMS_MEMBERS 0
74  #else /* _HAS_CXX17 */
75  #define _HAS_OLD_IOSTREAMS_MEMBERS 1
76  #endif /* _HAS_CXX17 */
77  #endif /* _HAS_OLD_IOSTREAMS_MEMBERS */
78 
79 // LWG 2385 function::assign allocator argument doesn't make sense
80  #ifndef _HAS_FUNCTION_ASSIGN
81  #if _HAS_CXX17
82  #define _HAS_FUNCTION_ASSIGN 0
83  #else /* _HAS_CXX17 */
84  #define _HAS_FUNCTION_ASSIGN 1
85  #endif /* _HAS_CXX17 */
86  #endif /* _HAS_FUNCTION_ASSIGN */
87 
88 // The non-Standard std::tr1 namespace and TR1-only machinery
89  #ifndef _HAS_TR1_NAMESPACE
90  #if _HAS_CXX17
91  #define _HAS_TR1_NAMESPACE 0
92  #else /* _HAS_CXX17 */
93  #define _HAS_TR1_NAMESPACE 1
94  #endif /* _HAS_CXX17 */
95  #endif /* _HAS_TR1_NAMESPACE */
96 
97 // The non-Standard std::identity struct
98  #ifndef _HAS_IDENTITY_STRUCT
99  #if _HAS_CXX17
100  #define _HAS_IDENTITY_STRUCT 0
101  #else /* _HAS_CXX17 */
102  #define _HAS_IDENTITY_STRUCT 1
103  #endif /* _HAS_CXX17 */
104  #endif /* _HAS_IDENTITY_STRUCT */
105 
106 
107  #ifdef _RTC_CONVERSION_CHECKS_ENABLED
108  #ifndef _ALLOW_RTCc_IN_STL
109 static_assert(false, "/RTCc rejects conformant code, "
110  "so it isn't supported by the C++ Standard Library. "
111  "Either remove this compiler option, or define _ALLOW_RTCc_IN_STL "
112  "to acknowledge that you have received this warning.");
113  #endif /* _ALLOW_RTCc_IN_STL */
114  #endif /* _RTC_CONVERSION_CHECKS_ENABLED */
115 
116 /* Note on use of "deprecate":
117  * Various places in this header and other headers use __declspec(deprecate) or macros that
118  * have the term DEPRECATE in them. We use deprecate here ONLY to signal the compiler to
119  * emit a warning about these items. The use of deprecate should NOT be taken to imply that
120  * any standard committee has deprecated these functions from the relevant standards.
121  * In fact, these functions are NOT deprecated from the standard.
122  *
123  * Full details can be found in our documentation by searching for "Checked Iterators".
124 */
125 
126 #if defined(MRTDLL) && defined(_CRTBLD)
127 /*
128 process-global is the default for code built with /clr or /clr:oldSyntax.
129 appdomain-global is the default for code built with /clr:pure.
130 Code in MSVCM is built with /clr, but is used by user code built with /clr:pure
131 so it must conform to the expectations of /clr:pure clients.
132 Use __PURE_APPDOMAIN_GLOBAL when a global needs to be appdomain-global for pure
133 clients and process-global for mixed clients.
134 */
135 #define __PURE_APPDOMAIN_GLOBAL __declspec(appdomain)
136 #else
137 #define __PURE_APPDOMAIN_GLOBAL
138 #endif
139 
140  /* CURRENT DLL NAMES */
141 #ifndef _CRT_MSVCP_CURRENT
142  #ifdef _CRT_WINDOWS
143  /* Windows */
144  #ifdef _DEBUG
145  #define _CRT_MSVCP_CURRENT "msvcpd_win.dll"
146  #else
147  #define _CRT_MSVCP_CURRENT "msvcp_win.dll"
148  #endif
149  #else
150  /* Visual Studio */
151  #ifdef _DEBUG
152  #define _CRT_MSVCP_CURRENT "msvcp140d.dll"
153  #else
154  #define _CRT_MSVCP_CURRENT "msvcp140.dll"
155  #endif
156  #endif
157 #endif
158 
159  /* THREAD AND LOCALE CONTROL */
160 #define _MULTI_THREAD 1 /* nontrivial locks if multithreaded */
161 
162 #define _GLOBAL_USING 1
163 
164  #ifndef _NO_LOCALES
165  #define _NO_LOCALES 0
166  #endif /* _NO_LOCALES */
167 
168 #ifdef _ITERATOR_DEBUG_LEVEL /* A. _ITERATOR_DEBUG_LEVEL is already defined. */
169 
170  /* A1. Validate _ITERATOR_DEBUG_LEVEL. */
171  #if _ITERATOR_DEBUG_LEVEL > 2 && defined(_DEBUG)
172  #error _ITERATOR_DEBUG_LEVEL > 2 is not supported in debug mode.
173  #elif _ITERATOR_DEBUG_LEVEL > 1 && !defined(_DEBUG)
174  #error _ITERATOR_DEBUG_LEVEL > 1 is not supported in release mode.
175  #endif
176 
177  /* A2. Inspect _HAS_ITERATOR_DEBUGGING. */
178  #ifdef _HAS_ITERATOR_DEBUGGING /* A2i. _HAS_ITERATOR_DEBUGGING is already defined, validate it. */
179  #if _ITERATOR_DEBUG_LEVEL == 2 && _HAS_ITERATOR_DEBUGGING != 1
180  #error _ITERATOR_DEBUG_LEVEL == 2 must imply _HAS_ITERATOR_DEBUGGING == 1 .
181  #elif _ITERATOR_DEBUG_LEVEL < 2 && _HAS_ITERATOR_DEBUGGING != 0
182  #error _ITERATOR_DEBUG_LEVEL < 2 must imply _HAS_ITERATOR_DEBUGGING == 0 .
183  #endif
184  #else /* A2ii. _HAS_ITERATOR_DEBUGGING is not yet defined, derive it. */
185  #if _ITERATOR_DEBUG_LEVEL == 2
186  #define _HAS_ITERATOR_DEBUGGING 1
187  #else
188  #define _HAS_ITERATOR_DEBUGGING 0
189  #endif
190  #endif /* _HAS_ITERATOR_DEBUGGING */
191 
192  /* A3. Inspect _SECURE_SCL. */
193  #ifdef _SECURE_SCL /* A3i. _SECURE_SCL is already defined, validate it. */
194  #if _ITERATOR_DEBUG_LEVEL > 0 && _SECURE_SCL != 1
195  #error _ITERATOR_DEBUG_LEVEL > 0 must imply _SECURE_SCL == 1 .
196  #elif _ITERATOR_DEBUG_LEVEL == 0 && _SECURE_SCL != 0
197  #error _ITERATOR_DEBUG_LEVEL == 0 must imply _SECURE_SCL == 0 .
198  #endif
199  #else /* A3ii. _SECURE_SCL is not yet defined, derive it. */
200  #if _ITERATOR_DEBUG_LEVEL > 0
201  #define _SECURE_SCL 1
202  #else
203  #define _SECURE_SCL 0
204  #endif
205  #endif /* _SECURE_SCL */
206 
207 #else /* B. _ITERATOR_DEBUG_LEVEL is not yet defined. */
208 
209  /* B1. Inspect _HAS_ITERATOR_DEBUGGING. */
210  #ifdef _HAS_ITERATOR_DEBUGGING /* B1i. _HAS_ITERATOR_DEBUGGING is already defined, validate it. */
211  #if _HAS_ITERATOR_DEBUGGING > 1
212  #error _HAS_ITERATOR_DEBUGGING must be either 0 or 1 .
213  #elif _HAS_ITERATOR_DEBUGGING == 1 && !defined(_DEBUG)
214  #error _HAS_ITERATOR_DEBUGGING == 1 is not supported in release mode.
215  #endif
216  #else /* B1ii. _HAS_ITERATOR_DEBUGGING is not yet defined, default it. */
217  #ifdef _DEBUG
218  #define _HAS_ITERATOR_DEBUGGING 1
219  #else
220  #define _HAS_ITERATOR_DEBUGGING 0
221  #endif
222  #endif /* _HAS_ITERATOR_DEBUGGING */
223 
224  /* B2. Inspect _SECURE_SCL. */
225  #ifdef _SECURE_SCL /* B2i. _SECURE_SCL is already defined, validate it. */
226  #if _SECURE_SCL > 1
227  #error _SECURE_SCL must be either 0 or 1 .
228  #endif
229  #else /* B2ii. _SECURE_SCL is not yet defined, default it. */
230  #if _HAS_ITERATOR_DEBUGGING == 1
231  #define _SECURE_SCL 1
232  #else
233  #define _SECURE_SCL 0
234  #endif
235  #endif /* _SECURE_SCL */
236 
237  /* B3. Derive _ITERATOR_DEBUG_LEVEL. */
238  #if _HAS_ITERATOR_DEBUGGING
239  #define _ITERATOR_DEBUG_LEVEL 2
240  #elif _SECURE_SCL
241  #define _ITERATOR_DEBUG_LEVEL 1
242  #else
243  #define _ITERATOR_DEBUG_LEVEL 0
244  #endif
245 
246 #endif /* _ITERATOR_DEBUG_LEVEL */
247 
248 #define _STRINGIZEX(x) #x
249 #define _STRINGIZE(x) _STRINGIZEX(x)
250 
251 #ifdef __cplusplus
252  #ifndef _ALLOW_MSC_VER_MISMATCH
253  #pragma detect_mismatch("_MSC_VER", "1900")
254  #endif /* _ALLOW_MSC_VER_MISMATCH */
255 
256  #ifndef _ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH
257  #pragma detect_mismatch("_ITERATOR_DEBUG_LEVEL", _STRINGIZE(_ITERATOR_DEBUG_LEVEL))
258  #endif /* _ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH */
259 
260  #ifndef _ALLOW_RUNTIME_LIBRARY_MISMATCH
261  #if !defined(_DLL) && !defined(_DEBUG)
262  #pragma detect_mismatch("RuntimeLibrary", "MT_StaticRelease")
263  #elif !defined(_DLL) && defined(_DEBUG)
264  #pragma detect_mismatch("RuntimeLibrary", "MTd_StaticDebug")
265  #elif defined(_DLL) && !defined(_DEBUG)
266  #pragma detect_mismatch("RuntimeLibrary", "MD_DynamicRelease")
267  #elif defined(_DLL) && defined(_DEBUG)
268  #pragma detect_mismatch("RuntimeLibrary", "MDd_DynamicDebug")
269  #endif /* defined(_DLL) etc. */
270  #endif /* _ALLOW_RUNTIME_LIBRARY_MISMATCH */
271 #endif /* __cplusplus */
272 
273 #ifdef _ITERATOR_DEBUG_ARRAY_OVERLOADS
274  #if _ITERATOR_DEBUG_ARRAY_OVERLOADS != 0 && _ITERATOR_DEBUG_ARRAY_OVERLOADS != 1
275  #error _ITERATOR_DEBUG_ARRAY_OVERLOADS must be either 0 or 1 .
276  #elif _ITERATOR_DEBUG_LEVEL == 0 && _ITERATOR_DEBUG_ARRAY_OVERLOADS == 1
277  #error _ITERATOR_DEBUG_LEVEL == 0 must imply _ITERATOR_DEBUG_ARRAY_OVERLOADS == 0 .
278  #endif
279 #else /* _ITERATOR_DEBUG_ARRAY_OVERLOADS */
280  #if _ITERATOR_DEBUG_LEVEL == 0
281  #define _ITERATOR_DEBUG_ARRAY_OVERLOADS 0
282  #else
283  #define _ITERATOR_DEBUG_ARRAY_OVERLOADS 1
284  #endif
285 #endif /* _ITERATOR_DEBUG_ARRAY_OVERLOADS */
286 
287 /* See note on use of deprecate at the top of this file */
288 #if !defined(_SCL_SECURE_NO_WARNINGS) && defined(_SCL_SECURE_NO_DEPRECATE)
289 #define _SCL_SECURE_NO_WARNINGS
290 #endif
291 
292 #if !defined (_SECURE_SCL_DEPRECATE)
293 #if defined(_SCL_SECURE_NO_WARNINGS)
294 #define _SECURE_SCL_DEPRECATE 0
295 #else
296 #define _SECURE_SCL_DEPRECATE 1
297 #endif
298 #endif
299 
300 /* _SECURE_SCL switches: helper macros */
301 /* See note on use of deprecate at the top of this file */
302 
303 #if _ITERATOR_DEBUG_LEVEL > 0 && _SECURE_SCL_DEPRECATE
304 #define _SCL_INSECURE_DEPRECATE_FN(_Func) \
305  _CRT_DEPRECATE_TEXT( \
306  "Call to 'std::" #_Func "' with parameters that may be unsafe - " \
307  "this call relies on the caller to check that the passed values are correct. " \
308  "To disable this warning, use -D_SCL_SECURE_NO_WARNINGS. " \
309  "See documentation on how to use Visual C++ 'Checked Iterators'")
310 #else
311 #define _SCL_INSECURE_DEPRECATE_FN(_Func)
312 #endif
313 
314 #ifndef _SCL_SECURE_INVALID_PARAMETER
315  #define _SCL_SECURE_INVALID_PARAMETER(expr) _CRT_SECURE_INVALID_PARAMETER(expr)
316 #endif
317 
318  #define _SCL_SECURE_INVALID_ARGUMENT_NO_ASSERT _SCL_SECURE_INVALID_PARAMETER("invalid argument")
319  #define _SCL_SECURE_OUT_OF_RANGE_NO_ASSERT _SCL_SECURE_INVALID_PARAMETER("out of range")
320 
321  #define _SCL_SECURE_ALWAYS_VALIDATE(cond) \
322  { \
323  if (!(cond)) \
324  { \
325  _ASSERTE(#cond && 0); \
326  _SCL_SECURE_INVALID_ARGUMENT_NO_ASSERT; \
327  } \
328  _Analysis_assume_(cond); \
329  }
330 
331  #define _SCL_SECURE_ALWAYS_VALIDATE_RANGE(cond) \
332  { \
333  if (!(cond)) \
334  { \
335  _ASSERTE(#cond && 0); \
336  _SCL_SECURE_OUT_OF_RANGE_NO_ASSERT; \
337  } \
338  _Analysis_assume_(cond); \
339  }
340 
341  #define _SCL_SECURE_CRT_VALIDATE(cond, retvalue) \
342  { \
343  if (!(cond)) \
344  { \
345  _ASSERTE(#cond && 0); \
346  _SCL_SECURE_INVALID_PARAMETER(cond); \
347  return (retvalue); \
348  } \
349  }
350 
351  #if _ITERATOR_DEBUG_LEVEL > 0
352 
353  #define _SCL_SECURE_VALIDATE(cond) \
354  { \
355  if (!(cond)) \
356  { \
357  _ASSERTE(#cond && 0); \
358  _SCL_SECURE_INVALID_ARGUMENT_NO_ASSERT; \
359  } \
360  _Analysis_assume_(cond); \
361  }
362 
363  #define _SCL_SECURE_VALIDATE_RANGE(cond) \
364  { \
365  if (!(cond)) \
366  { \
367  _ASSERTE(#cond && 0); \
368  _SCL_SECURE_OUT_OF_RANGE_NO_ASSERT; \
369  } \
370  _Analysis_assume_(cond); \
371  }
372 
373  #define _SCL_SECURE_INVALID_ARGUMENT \
374  { \
375  _ASSERTE("Standard C++ Libraries Invalid Argument" && 0); \
376  _SCL_SECURE_INVALID_ARGUMENT_NO_ASSERT; \
377  }
378  #define _SCL_SECURE_OUT_OF_RANGE \
379  { \
380  _ASSERTE("Standard C++ Libraries Out of Range" && 0); \
381  _SCL_SECURE_OUT_OF_RANGE_NO_ASSERT; \
382  }
383 
384  #else /* _ITERATOR_DEBUG_LEVEL > 0 */
385 
386 /* when users disable _SECURE_SCL to get performance, we don't want analysis warnings from SCL headers */
387 #if _ITERATOR_DEBUG_LEVEL == 2
388  #define _SCL_SECURE_VALIDATE(cond) _Analysis_assume_(cond)
389  #define _SCL_SECURE_VALIDATE_RANGE(cond) _Analysis_assume_(cond)
390 #else
391  #define _SCL_SECURE_VALIDATE(cond)
392  #define _SCL_SECURE_VALIDATE_RANGE(cond)
393 #endif
394 
395  #define _SCL_SECURE_INVALID_ARGUMENT
396  #define _SCL_SECURE_OUT_OF_RANGE
397 
398  #endif /* _ITERATOR_DEBUG_LEVEL > 0 */
399 
400 #if __STDC_WANT_SECURE_LIB__
401 #define _CRT_SECURE_MEMCPY(dest, destsize, source, count) ::memcpy_s((dest), (destsize), (source), (count))
402 #define _CRT_SECURE_MEMMOVE(dest, destsize, source, count) ::memmove_s((dest), (destsize), (source), (count))
403 #define _CRT_SECURE_WMEMCPY(dest, destsize, source, count) ::wmemcpy_s((dest), (destsize), (source), (count))
404 #define _CRT_SECURE_WMEMMOVE(dest, destsize, source, count) ::wmemmove_s((dest), (destsize), (source), (count))
405 #else
406 #define _CRT_SECURE_MEMCPY(dest, destsize, source, count) ::memcpy((dest), (source), (count))
407 #define _CRT_SECURE_MEMMOVE(dest, destsize, source, count) ::memmove((dest), (source), (count))
408 #define _CRT_SECURE_WMEMCPY(dest, destsize, source, count) ::wmemcpy((dest), (source), (count))
409 #define _CRT_SECURE_WMEMMOVE(dest, destsize, source, count) ::wmemmove((dest), (source), (count))
410 #endif
411 
412 #include <use_ansi.h>
413 
414 #if defined(_M_CEE) && defined(_STATIC_CPPLIB)
415 #error _STATIC_CPPLIB is not supported while building with /clr or /clr:pure
416 #endif
417 
418 #if defined(_DLL) && defined(_STATIC_CPPLIB) && !defined(_DISABLE_DEPRECATE_STATIC_CPPLIB)
419 #pragma _CRT_WARNING("_STATIC_CPPLIB is deprecated")
420 #endif
421 
422 /* Define _CRTIMP2 */
423  #ifndef _CRTIMP2
424  #if defined(CRTDLL2) && defined(_CRTBLD)
425  #define _CRTIMP2 __declspec(dllexport)
426  #else /* ndef CRTDLL2 && _CRTBLD */
427 
428  #if defined(_DLL) && !defined(_STATIC_CPPLIB)
429  #define _CRTIMP2 __declspec(dllimport)
430 
431  #else /* ndef _DLL && !STATIC_CPPLIB */
432  #define _CRTIMP2
433  #endif /* _DLL && !STATIC_CPPLIB */
434 
435  #endif /* CRTDLL2 && _CRTBLD */
436  #endif /* _CRTIMP2 */
437 
438 /* Define _CRTIMP2_NCEEPURE */
439  #ifndef _CRTIMP2_NCEEPURE
440  #if defined(_M_CEE_PURE)
441  #define _CRTIMP2_NCEEPURE
442  #else
443  #define _CRTIMP2_NCEEPURE _CRTIMP2
444  #endif
445  #endif
446 
447  #ifndef _MRTIMP2_PURE
448  #if defined(_M_CEE_PURE)
449  #define _MRTIMP2_PURE
450  #else
451  #define _MRTIMP2_PURE _MRTIMP2
452  #endif
453  #endif
454 
455  #ifndef _MRTIMP2_PURE_NPURE
456  #if defined(_M_CEE_PURE)
457  #define _MRTIMP2_PURE_NPURE
458  #else
459  #define _MRTIMP2_PURE_NPURE _MRTIMP2_NPURE
460  #endif
461  #endif
462 
463 /* Define _MRTIMP2_NPURE */
464  #ifndef _MRTIMP2_NPURE
465  #if defined(MRTDLL) && defined(_CRTBLD)
466  #if !defined(_M_CEE_PURE)
467  #define _MRTIMP2_NPURE __declspec(dllexport)
468  #else
469  #define _MRTIMP2_NPURE
470  #endif
471  #else /* ndef MRTDLL && _CRTBLD */
472 
473  #if defined(_DLL) && defined(_M_CEE_PURE)
474  #define _MRTIMP2_NPURE __declspec(dllimport)
475 
476  #else
477  #define _MRTIMP2_NPURE
478  #endif
479 
480  #endif /* MRTDLL && _CRTBLD */
481  #endif /* _MRTIMP2_NPURE */
482 
483  #if defined(_DLL) && !defined(_STATIC_CPPLIB) && !defined(_M_CEE_PURE)
484  #define _DLL_CPPLIB
485  #endif
486 
487  #ifndef _CRTIMP2_PURE
488  #if defined(MRTDLL) && defined(_CRTBLD)
489  #define _CRTIMP2_PURE
490  #else
491  #ifdef _M_CEE_PURE
492  #define _CRTIMP2_PURE
493  #else
494  #define _CRTIMP2_PURE _CRTIMP2
495  #endif
496  #endif
497  #endif
498 
499  #ifdef _CRTBLD
500  #if !defined(_CRTDATA2)
501  #if !defined(MRTDLL)
502  #define _CRTDATA2 _CRTIMP2
503  #else
504  #define _CRTDATA2
505  #endif
506  #endif
507 
508 /* Define _CRTBLD_NATIVE_WCHAR_T */
509 
510  #if defined(__cplusplus)
511  #ifndef _NATIVE_WCHAR_T_DEFINED
512  #error Native wchar_t must be defined
513 
514  #else /* _NATIVE_WCHAR_T_DEFINED */
515  #define _CRTBLD_NATIVE_WCHAR_T
516  #endif /* _NATIVE_WCHAR_T_DEFINED */
517 
518  #endif /* defined(__cplusplus) */
519 
520 /* These functions are for enabling STATIC_CPPLIB functionality */
521  #define _cpp_stdin (__acrt_iob_func(0))
522  #define _cpp_stdout (__acrt_iob_func(1))
523  #define _cpp_stderr (__acrt_iob_func(2))
524  #define _cpp_isleadbyte(c) (__pctype_func()[(unsigned char)(c)] & _LEADBYTE)
525  #else /* _CRTBLD */
526  #if !defined(_CRTDATA2)
527  #define _CRTDATA2 _CRTIMP2
528  #endif
529  #endif /* _CRTBLD */
530 
531  /* NAMESPACE */
532 
533  #if defined(__cplusplus)
534  #define _STD_BEGIN namespace std {
535  #define _STD_END }
536  #define _STD ::std::
537 
538 /*
539 We use the stdext (standard extension) namespace to contain extensions that are not part of the current standard
540 */
541  #define _STDEXT_BEGIN namespace stdext {
542  #define _STDEXT_END }
543  #define _STDEXT ::stdext::
544 
545  #ifdef _STD_USING
546  #define _C_STD_BEGIN namespace std { /* only if *.c compiled as C++ */
547  #define _C_STD_END }
548  #define _CSTD ::std::
549 
550  #else /* _STD_USING */
551 /* #define _GLOBAL_USING *.h in global namespace, c* imports to std */
552 
553  #define _C_STD_BEGIN
554  #define _C_STD_END
555  #define _CSTD ::
556  #endif /* _STD_USING */
557 
558  #define _C_LIB_DECL extern "C" { /* C has extern "C" linkage */
559  #define _END_C_LIB_DECL }
560  #define _EXTERN_C extern "C" {
561  #define _END_EXTERN_C }
562 
563  #else /* __cplusplus */
564  #define _STD_BEGIN
565  #define _STD_END
566  #define _STD
567 
568  #define _C_STD_BEGIN
569  #define _C_STD_END
570  #define _CSTD
571 
572  #define _C_LIB_DECL
573  #define _END_C_LIB_DECL
574  #define _EXTERN_C
575  #define _END_EXTERN_C
576  #endif /* __cplusplus */
577 
578  /* VC++ COMPILER PARAMETERS */
579 #define _LONGLONG long long
580 #define _ULONGLONG unsigned long long
581 #define _LLONG_MAX 0x7fffffffffffffff
582 #define _ULLONG_MAX 0xffffffffffffffff
583 
584  /* INTEGER PROPERTIES */
585 #define _C2 1 /* 0 if not 2's complement */
586 
587 #define _MAX_EXP_DIG 8 /* for parsing numerics */
588 #define _MAX_INT_DIG 32
589 #define _MAX_SIG_DIG_V1 36
590 #define _MAX_SIG_DIG_V2 768
591 
594 
595  /* STDIO PROPERTIES */
596 #define _Filet FILE
597 
598 #define _IOBASE _base
599 #define _IOPTR _ptr
600 #define _IOCNT _cnt
601 
602  /* MULTITHREAD PROPERTIES */
603  /* LOCK MACROS */
604 #define _LOCK_LOCALE 0
605 #define _LOCK_MALLOC 1
606 #define _LOCK_STREAM 2
607 #define _LOCK_DEBUG 3
608 #define _LOCK_AT_THREAD_EXIT 4
609 
610  #ifdef __cplusplus
612 enum _Uninitialized
613  { // tag for suppressing initialization
614  _Noinit
615  };
616 
617  // CLASS _Lockit
618 // warning 4412 is benign here
619 #pragma warning(push)
620 #pragma warning(disable:4412)
621 class _CRTIMP2_PURE _Lockit
622  { // lock while object in existence -- MUST NEST
623 public:
624  #if _MULTI_THREAD
625 
626  #if defined(_M_CEE_PURE) || defined(MRTDLL)
627  __CLR_OR_THIS_CALL _Lockit()
628  : _Locktype(0)
629  { // default construct
630  _Lockit_ctor(this);
631  }
632 
633  explicit __CLR_OR_THIS_CALL _Lockit(int _Kind)
634  { // set the lock
635  _Lockit_ctor(this, _Kind);
636  }
637 
638  __CLR_OR_THIS_CALL ~_Lockit() _NOEXCEPT
639  { // clear the lock
640  _Lockit_dtor(this);
641  }
642 
643  #else /* defined(_M_CEE_PURE) || defined(MRTDLL) */
644  __thiscall _Lockit(); // default construct
645  explicit __thiscall _Lockit(int); // set the lock
646  __thiscall ~_Lockit() _NOEXCEPT; // clear the lock
647  #endif /* defined(_M_CEE_PURE) || defined(MRTDLL) */
648 
649  static _MRTIMP2_NPURE void __cdecl _Lockit_ctor(int);
650  static _MRTIMP2_NPURE void __cdecl _Lockit_dtor(int);
651 
652 private:
653  static _MRTIMP2_NPURE void __cdecl _Lockit_ctor(_Lockit *);
654  static _MRTIMP2_NPURE void __cdecl _Lockit_ctor(_Lockit *, int);
655  static _MRTIMP2_NPURE void __cdecl _Lockit_dtor(_Lockit *);
656 
657 public:
658  __CLR_OR_THIS_CALL _Lockit(const _Lockit&) = delete;
659  _Lockit& __CLR_OR_THIS_CALL operator=(const _Lockit&) = delete;
660 
661 private:
662  int _Locktype;
663 
664  #else /* _MULTI_THREAD */
665  _Lockit()
666  { // do nothing
667  }
668 
669  explicit _Lockit(int)
670  { // do nothing
671  }
672 
673  ~_Lockit() _NOEXCEPT
674  { // do nothing
675  }
676  #endif /* _MULTI_THREAD */
677  };
678 
679  #ifdef _M_CEE
680 class _CRTIMP2_PURE _EmptyLockit
681  { // empty lock class used for bin compat
682 public:
683  #if _MULTI_THREAD
684 private:
685  int _Locktype;
686  #endif /* _MULTI_THREAD */
687  };
688 
689  #if defined(__cplusplus_cli)
690  #define _M_CEE_FINALLY finally
691  #else /* defined(__cplusplus_cli) */
692  #define _M_CEE_FINALLY __finally
693  #endif /* defined(__cplusplus_cli) */
694 
695  #define _BEGIN_LOCK(_Kind) \
696  { \
697  typedef int _TmpTestType; \
698  __if_exists(_TmpTestType::ToString) \
699  { \
700  bool _MustReleaseLock = false; \
701  int _LockKind = _Kind; \
702  System::Runtime::CompilerServices::RuntimeHelpers::PrepareConstrainedRegions(); \
703  try \
704  } \
705  { \
706  __if_exists(_TmpTestType::ToString) \
707  { \
708  System::Runtime::CompilerServices::RuntimeHelpers::PrepareConstrainedRegions(); \
709  try { } _M_CEE_FINALLY \
710  { \
711  _STD _Lockit::_Lockit_ctor(_LockKind); \
712  _MustReleaseLock = true; \
713  } \
714  } \
715  __if_not_exists(_TmpTestType::ToString) \
716  { \
717  _STD _Lockit _Lock(_Kind); \
718  }
719 
720  #define _END_LOCK() \
721  } \
722  __if_exists(_TmpTestType::ToString) \
723  { \
724  _M_CEE_FINALLY \
725  { \
726  if (_MustReleaseLock) \
727  { \
728  _STD _Lockit::_Lockit_dtor(_LockKind); \
729  } \
730  } \
731  } \
732  }
733 
734  #define _BEGIN_LOCINFO(_VarName) \
735  _BEGIN_LOCK(_LOCK_LOCALE) \
736  _Locinfo _VarName;
737 
738  #define _END_LOCINFO() \
739  _END_LOCK()
740 
741  #define _RELIABILITY_CONTRACT \
742  [System::Runtime::ConstrainedExecution::ReliabilityContract( \
743  System::Runtime::ConstrainedExecution::Consistency::WillNotCorruptState, \
744  System::Runtime::ConstrainedExecution::Cer::Success)]
745 
746  #else /* _M_CEE */
747  #define _BEGIN_LOCK(_Kind) \
748  { \
749  _STD _Lockit _Lock(_Kind);
750 
751  #define _END_LOCK() \
752  }
753 
754  #define _BEGIN_LOCINFO(_VarName) \
755  { \
756  _Locinfo _VarName;
757 
758  #define _END_LOCINFO() \
759  }
760 
761  #define _RELIABILITY_CONTRACT
762  #endif /* _M_CEE */
763 
764 class _CRTIMP2_PURE _Init_locks
765  { // initialize mutexes
766 public:
767  #if _MULTI_THREAD
768  #if defined(_M_CEE_PURE) || defined(MRTDLL)
769  __CLR_OR_THIS_CALL _Init_locks()
770  { // default construct
771  _Init_locks_ctor(this);
772  }
773 
774  __CLR_OR_THIS_CALL ~_Init_locks() _NOEXCEPT
775  { // destroy the object
776  _Init_locks_dtor(this);
777  }
778 
779  #else /* defined(_M_CEE_PURE) || defined(MRTDLL) */
780  __thiscall _Init_locks();
781  __thiscall ~_Init_locks() _NOEXCEPT;
782  #endif /* defined(_M_CEE_PURE) || defined(MRTDLL) */
783 
784 private:
785  static _MRTIMP2_NPURE void __cdecl _Init_locks_ctor(_Init_locks *);
786  static _MRTIMP2_NPURE void __cdecl _Init_locks_dtor(_Init_locks *);
787 
788  #else /* _MULTI_THREAD */
789  _Init_locks()
790  { // do nothing
791  }
792 
793  ~_Init_locks() _NOEXCEPT
794  { // do nothing
795  }
796  #endif /* _MULTI_THREAD */
797  };
798 
799 #pragma warning(pop)
800 _STD_END
801  #endif /* __cplusplus */
802 
803 #ifndef _RELIABILITY_CONTRACT
804  #define _RELIABILITY_CONTRACT
805 #endif /* _RELIABILITY_CONTRACT */
806 
807  /* MISCELLANEOUS MACROS AND TYPES */
809 _MRTIMP2 void __cdecl _Atexit(void (__cdecl *)(void));
810 
811 typedef unsigned long _Uint32t;
812 
813 #define _Mbstinit(x) mbstate_t x = {}
815 
816  #pragma pop_macro("new")
817  #pragma pack(pop)
818 #endif /* RC_INVOKED */
819 #endif /* _YVALS */
820 
821 /*
822  * Copyright (c) by P.J. Plauger. All rights reserved.
823  * Consult your license regarding permissions and restrictions.
824 V6.50:0009 */
#define _C_STD_BEGIN
Definition: yvals.h:568
_C_STD_BEGIN _MRTIMP2 void __cdecl _Atexit(void(__cdecl *)(void))
#define _ULONGLONG
Definition: yvals.h:580
#define _STD_BEGIN
Definition: yvals.h:564
#define _MRTIMP2
Definition: crtdefs.h:62
unsigned long _Uint32t
Definition: yvals.h:811
#define _NOEXCEPT
Definition: yvals.h:25
#define _C_STD_END
Definition: yvals.h:569
#define __CLR_OR_THIS_CALL
Definition: vcruntime.h:147
#define _LONGLONG
Definition: yvals.h:579
_LONGLONG _Longlong
Definition: yvals.h:592
#define _STD_END
Definition: yvals.h:565
#define _MRTIMP2_NPURE
Definition: yvals.h:477
#define _CRTIMP2_PURE
Definition: yvals.h:494
_ULONGLONG _ULonglong
Definition: yvals.h:593