#pragma once
#include <corecrt.h>
#include <corecrt_stdio_config.h>
_CRT_BEGIN_C_HEADER
__pragma
(pack(push,
8
))
extern
"C"
{
#define WEOF ((wint_t)(0xFFFF))
#ifdef _CRT_USE_WINAPI_FAMILY_DESKTOP_APP
_Check_return_wat_
_Success_(_BufferCount > 0)
_DCRTIMP errno_t __cdecl _cgetws_s(
__declspec
(dllimport)
__cdecl
(
_Out_writes_to_(_BufferCount, *_SizeRead) wchar_t* _Buffer,
_In_ size_t _BufferCount,
);
__DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_1(
_Success_(return == 0)
errno_t, _cgetws_s,
_Out_writes_z_(*_Buffer) wchar_t, _Buffer,
_In_ size_t*, _SizeRead
)
extern
"C++"
{
template
<
>
inline
__cdecl
(
wchar_t
(&
)[
],
*
)
throw
() {
return
(
,
,
); } }
_Check_return_opt_
_DCRTIMP int __cdecl _cputws(
__declspec
(dllimport)
int
__cdecl
(
_In_z_ wchar_t const* _Buffer
);
_Check_return_ _DCRTIMP wint_t __cdecl _getwch (void);
__declspec
(dllimport)
__cdecl
(
void
);
_Check_return_ _DCRTIMP wint_t __cdecl _getwche (void);
__declspec
(dllimport)
__cdecl
(
void
);
_Check_return_opt_ _DCRTIMP wint_t __cdecl _putwch (_In_ wchar_t _Character);
__declspec
(dllimport)
__cdecl
(
wchar_t
);
_Check_return_opt_ _DCRTIMP wint_t __cdecl _ungetwch(_In_ wint_t _Character);
__declspec
(dllimport)
__cdecl
(
);
_Check_return_ _DCRTIMP wint_t __cdecl _getwch_nolock (void);
__declspec
(dllimport)
__cdecl
(
void
);
_Check_return_ _DCRTIMP wint_t __cdecl _getwche_nolock (void);
__declspec
(dllimport)
__cdecl
(
void
);
_Check_return_opt_ _DCRTIMP wint_t __cdecl _putwch_nolock (_In_ wchar_t _Character);
__declspec
(dllimport)
__cdecl
(
wchar_t
);
_Check_return_opt_ _DCRTIMP wint_t __cdecl _ungetwch_nolock(_In_ wint_t _Character);
__declspec
(dllimport)
__cdecl
(
);
_Check_return_opt_
_DCRTIMP int __cdecl __conio_common_vcwprintf(
__declspec
(dllimport)
int
__cdecl
(
_In_ unsigned __int64 _Options,
_In_z_ _Printf_format_string_params_(2) wchar_t const* _Format,
_In_opt_ _locale_t _Locale,
);
_Check_return_opt_
_DCRTIMP int __cdecl __conio_common_vcwprintf_s(
__declspec
(dllimport)
int
__cdecl
__conio_common_vcwprintf_s
(
_In_ unsigned __int64 _Options,
_In_z_ _Printf_format_string_params_(2) wchar_t const* _Format,
_In_opt_ _locale_t _Locale,
);
_Check_return_opt_
_DCRTIMP int __cdecl __conio_common_vcwprintf_p(
__declspec
(dllimport)
int
__cdecl
__conio_common_vcwprintf_p
(
_In_ unsigned __int64 _Options,
_In_z_ _Printf_format_string_params_(2) wchar_t const* _Format,
_In_opt_ _locale_t _Locale,
);
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf_l(
_In_z_ _Printf_format_string_params_(2) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return __conio_common_vcwprintf(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _Format, _Locale, _ArgList);
return
((*
__local_stdio_printf_options
()),
,
,
);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf(
_In_z_ _Printf_format_string_ wchar_t const* const _Format,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return _vcwprintf_l(_Format, NULL, _ArgList);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf_s_l(
_In_z_ _Printf_format_string_params_(2) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return __conio_common_vcwprintf_s(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _Format, _Locale, _ArgList);
return
__conio_common_vcwprintf_s
((*
__local_stdio_printf_options
()),
,
,
);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf_s(
_In_z_ _Printf_format_string_ wchar_t const* const _Format,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return _vcwprintf_s_l(_Format, NULL, _ArgList);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf_p_l(
_In_z_ _Printf_format_string_params_(2) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return __conio_common_vcwprintf_p(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _Format, _Locale, _ArgList);
return
__conio_common_vcwprintf_p
((*
__local_stdio_printf_options
()),
,
,
);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwprintf_p(
_In_z_ _Printf_format_string_ const wchar_t* const _Format,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return _vcwprintf_p_l(_Format, NULL, _ArgList);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf_l(
_In_z_ _Printf_format_string_params_(0) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Locale);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result
=
(
,
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf(
_In_z_ _Printf_format_string_ wchar_t const* const _Format,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Format);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result = _vcwprintf_l(_Format, NULL, _ArgList);
_Result
=
(
,
0
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf_s_l(
_In_z_ _Printf_format_string_params_(0) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Locale);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result
=
(
,
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf_s(
_In_z_ _Printf_format_string_ wchar_t const* const _Format,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Format);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result = _vcwprintf_s_l(_Format, NULL, _ArgList);
_Result
=
(
,
0
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf_p_l(
_In_z_ _Printf_format_string_params_(0) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Locale);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result
=
(
,
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwprintf_p(
_In_z_ _Printf_format_string_ wchar_t const* const _Format,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Format);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result = _vcwprintf_p_l(_Format, NULL, _ArgList);
_Result
=
(
,
0
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_DCRTIMP int __cdecl __conio_common_vcwscanf(
__declspec
(dllimport)
int
__cdecl
(
_In_ unsigned __int64 _Options,
_In_z_ _Scanf_format_string_params_(2) wchar_t const* _Format,
_In_opt_ _locale_t _Locale,
);
_Check_return_opt_ _CRT_INSECURE_DEPRECATE(_vcwscanf_s_l)
__declspec
(deprecated(
"This function or variable may be unsafe. Consider using "
"_vcwscanf_s_l"
" instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. "
"See online help for details."
))
_CRT_STDIO_INLINE int __CRTDECL _vcwscanf_l(
_In_z_ _Scanf_format_string_params_(2) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return
(
_CRT_INTERNAL_LOCAL_SCANF_OPTIONS,
(*
__local_stdio_scanf_options
()),
,
,
);
}
#endif
_Check_return_opt_ _CRT_INSECURE_DEPRECATE(_vcwscanf_s)
__declspec
(deprecated(
"This function or variable may be unsafe. Consider using "
"_vcwscanf_s"
" instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. "
"See online help for details."
))
_CRT_STDIO_INLINE int __CRTDECL _vcwscanf(
_In_z_ _Scanf_format_string_params_(1) wchar_t const* const _Format,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
#pragma warning(push)
#pragma warning(push)
#pragma warning(disable: 4996) // Deprecation
#pragma warning(disable:
4996
)
return _vcwscanf_l(_Format, NULL, _ArgList);
#pragma warning(pop)
#pragma warning(pop)
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwscanf_s_l(
_In_z_ _Scanf_format_string_params_(2) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return
(
_CRT_INTERNAL_LOCAL_SCANF_OPTIONS | _CRT_INTERNAL_SCANF_SECURECRT,
(*
__local_stdio_scanf_options
()) | (
1ULL
<<
0
),
,
,
);
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _vcwscanf_s(
_In_z_ _Scanf_format_string_params_(1) wchar_t const* const _Format,
)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
return _vcwscanf_s_l(_Format, NULL, _ArgList);
}
#endif
_Check_return_opt_ _CRT_INSECURE_DEPRECATE(_cwscanf_s_l)
__declspec
(deprecated(
"This function or variable may be unsafe. Consider using "
"_cwscanf_s_l"
" instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. "
"See online help for details."
))
_CRT_STDIO_INLINE int __CRTDECL _cwscanf_l(
_In_z_ _Scanf_format_string_params_(0) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Locale);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
#pragma warning(push)
#pragma warning(push)
#pragma warning(disable: 4996) // Deprecation
#pragma warning(disable:
4996
)
_Result
=
(
,
,
_ArgList
);
#pragma warning(pop)
#pragma warning(pop)
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_ _CRT_INSECURE_DEPRECATE(_cwscanf_s)
__declspec
(deprecated(
"This function or variable may be unsafe. Consider using "
"_cwscanf_s"
" instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. "
"See online help for details."
))
_CRT_STDIO_INLINE int __CRTDECL _cwscanf(
_In_z_ _Scanf_format_string_ wchar_t const* const _Format,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Format);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
#pragma warning(push)
#pragma warning(push)
#pragma warning(disable: 4996) // Deprecation
#pragma warning(disable:
4996
)
_Result = _vcwscanf_l(_Format, NULL, _ArgList);
_Result
=
(
,
0
,
_ArgList
);
#pragma warning(pop)
#pragma warning(pop)
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwscanf_s_l(
_In_z_ _Scanf_format_string_params_(0) wchar_t const* const _Format,
_In_opt_ _locale_t const _Locale,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Locale);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result
=
(
,
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
_Check_return_opt_
_CRT_STDIO_INLINE int __CRTDECL _cwscanf_s(
_In_z_ _Scanf_format_string_ wchar_t const* const _Format,
...)
#if defined _NO_CRT_STDIO_INLINE
;
#else
{
int
;
;
__crt_va_start(_ArgList, _Format);
((
void
)(
__vcrt_assert_va_start_is_not_reference
<
decltype
(
)>(), ((
void
)(
_ArgList
= (
)(&
const_cast
<
char
&>(
reinterpret_cast
<
const
volatile
char
&>(
))) + ((
sizeof
(
) +
sizeof
(
int
) -
1
) & ~(
sizeof
(
int
) -
1
))))));
_Result = _vcwscanf_s_l(_Format, NULL, _ArgList);
_Result
=
(
,
0
,
_ArgList
);
__crt_va_end(_ArgList);
((
void
)(
_ArgList
= (
)
0
));
return
_Result
;
}
#endif
#endif // _CRT_USE_WINAPI_FAMILY_DESKTOP_APP