blob: 12175f5bbf302c25b320624b49d3b688c2ad7a61 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
/* { dg-do run } */
/* Not all platforms support TImode integers. */
#if defined(__LP64__) || defined(__sparc__)
typedef int TItype __attribute__ ((mode (TI))); /* { dg-error "no data type for mode" "TI" { target sparc-sun-solaris2.[0-6] sparc-sun-solaris2.[0-6].* } } */
#else
typedef long TItype;
#endif
#include <stdarg.h>
extern void abort(void);
void foo(int i, ...)
{
TItype q;
va_list va;
va_start(va, i);
q = va_arg(va, TItype);
va_end(va);
if (q != 5)
abort();
}
int main(void)
{
TItype q = 5;
foo(1, q);
return 0;
}
|