repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Remove old autovect-branch by moving to "dead" directory.
[official-gcc.git]
/
old-autovect-branch
/
gcc
/
testsuite
/
g++.dg
/
other
/
stdarg1.C
blob
e005199d37a67f2bf8eae075b87faca77ebc9fe0
1
// Test stdarg function with anonymous argument
2
// { dg-do run }
3
4
#include <stdarg.h>
5
6
extern "C" void abort (void);
7
8
void baz (va_list list)
9
{
10
if (va_arg (list, long) != 3)
11
abort ();
12
}
13
14
void foo (long p1, long, long p2, ...)
15
{
16
va_list list;
17
va_start (list, p2);
18
baz (list);
19
va_end (list);
20
}
21
22
int main ()
23
{
24
foo (0, 1, 2, (long)3);
25
return 0;
26
}