21 #error ERROR: Only Win32 target supported!
31 #pragma pack(push,_CRT_PACKING)
38 #error varargs.h incompatible with ANSI (use stdarg.h)
42 #if !defined (__midl) && (defined (_X86_) || defined (_M_IX86))
49 #ifndef _UINTPTR_T_DEFINED
55 #define _UINTPTR_T_DEFINED
58 #ifndef _VA_LIST_DEFINED
60 typedef System::ArgIterator
va_list;
64 #define _VA_LIST_DEFINED
71 #error varargs.h not supported when targetting _M_CEE (use stdarg.h)
73 #elif defined (_M_IX86)
81 #define _INTSIZEOF(n) ( (sizeof(n) + sizeof(int) - 1) & ~(sizeof(int) - 1) )
83 #define va_dcl va_list va_alist;
84 #define va_start(ap) ap = (va_list)&va_alist
85 #define va_arg(ap,t) ( *(t *)((ap += _INTSIZEOF(t)) - _INTSIZEOF(t)) )
86 #define va_end(ap) ap = (va_list)0
88 #elif defined (_M_ARM)
91 #define _APALIGN(t,ap) ( ((va_list)0 - (ap)) & (__alignof(t) - 1) )
92 #define va_dcl va_list va_alist;
94 #define _SLOTSIZEOF(t) ( (sizeof(t) + _VA_ALIGN - 1) & ~(_VA_ALIGN - 1) )
95 #define va_start(ap) ( ap = (va_list)&va_alist )
96 #define va_arg(ap,t) (*(t *)((ap += _SLOTSIZEOF(t) + _APALIGN(t,ap)) \
98 #define va_end(ap) ( ap = (va_list)0 )
100 #elif defined (_M_X64)
102 extern void __cdecl __va_start(va_list *, ...);
103 #define va_dcl va_list va_alist;
104 #define va_start(ap) ( __va_start(&ap, 0) )
105 #define va_arg(ap, t) \
106 ( ( sizeof(t) > sizeof(__int64) || ( sizeof(t) & (sizeof(t) - 1) ) != 0 ) \
107 ? **(t **)( ( ap += sizeof(__int64) ) - sizeof(__int64) ) \
108 : *(t *)( ( ap += sizeof(__int64) ) - sizeof(__int64) ) )
109 #define va_end(ap) ( ap = (va_list)0 )
115 #define _INTSIZEOF(n) ( (sizeof(n) + sizeof(int) - 1) & ~(sizeof(int) - 1) )
117 #define va_dcl va_list va_alist;
118 #define va_start(ap) ap = (va_list)&va_alist
119 #define va_arg(ap,t) ( *(t *)((ap += _INTSIZEOF(t)) - _INTSIZEOF(t)) )
120 #define va_end(ap) ap = (va_list)0
_W64 unsigned int uintptr_t
Definition: crtdefs.h:521
#define _W64
Definition: crtdefs.h:100
char * va_list
Definition: crtdefs.h:550