2018-03-08 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / pr50712.c
blob26c00e1ef2ed86ce2db9a43b16fa9f935e31fe60
1 /* { dg-do compile } */
2 /* { dg-require-effective-target ia32 } */
3 /* { dg-options "-O2 -std=gnu89" } */
5 typedef __builtin_va_list __va_list;
6 typedef __va_list __gnuc_va_list;
7 typedef __gnuc_va_list va_list;
8 struct MSVCRT__iobuf { };
9 typedef struct MSVCRT__iobuf MSVCRT_FILE;
10 typedef union _printf_arg { } printf_arg;
11 MSVCRT_FILE MSVCRT__iob[20];
12 int pf_print_a (va_list *);
13 int __attribute__((__cdecl__))
14 MSVCRT_vfprintf_s(MSVCRT_FILE* file, const char *format, va_list valist)
16 if(!((file != ((void *)0))
17 || (MSVCRT__invalid_parameter(((void *)0), ((void *)0),
18 ((void *)0), 0, 0),0)))
19 return -1;
20 return pf_printf_a(&valist);
22 int __attribute__((__cdecl__))
23 MSVCRT_vprintf_s(const char *format, va_list valist)
25 return MSVCRT_vfprintf_s((MSVCRT__iob+1),format,valist);
27 int __attribute__((__cdecl__))
28 MSVCRT_fprintf_s(MSVCRT_FILE* file, const char *format, ...)
30 va_list valist;
31 va_start (valist, format);
32 return MSVCRT_vfprintf_s(file, format, valist);