]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/gcc.dg/c11-unproto-3.c
c: C2x removal of unprototyped functions
[thirdparty/gcc.git] / gcc / testsuite / gcc.dg / c11-unproto-3.c
1 /* Test function declarations without prototypes for C11. */
2 /* { dg-do compile } */
3 /* { dg-options "-std=c11 -pedantic-errors" } */
4
5 void f1 ();
6 void
7 f1a (void)
8 {
9 f1 (1, 2);
10 }
11
12 void f2 ();
13 void f2 (int);
14
15 void f3 ();
16
17 _Static_assert (_Generic (f3,
18 void (*) (int) : 1,
19 default : 3) == 1, "unprototyped test");