2 va-arg-14.c from the execute part of the gcc torture tests.
9 #pragma disable_warning 84 // suppress 'auto' variable may be used before initialization
13 void vat(va_list param
, ...)
17 va_start (local
, param
);
18 va_copy (global
, local
);
19 va_copy (param
, local
);
20 ASSERT (va_arg (local
, int) == 1);
22 ASSERT (va_arg (global
, int) == 1);
24 ASSERT (va_arg (param
, int) == 1);
27 va_start (param
, param
);
28 va_start (global
, param
);
29 va_copy (local
, param
);
30 ASSERT (va_arg (local
, int) == 1);
32 va_copy (local
, global
);
33 ASSERT (va_arg (local
, int) == 1);
35 ASSERT (va_arg (global
, int) == 1);
37 ASSERT (va_arg (param
, int) == 1);
42 testTortureExecute (void)
44 va_list t
; /* since the va_list type is undefined in C, 't' cannot be initialized */