1 /* Test declaration specifiers. Test checks on storage class
2 specifiers that can be made at parse time rather than for each
3 declarator. Note that __thread is tested in
4 gcc.dg/tls/diag-*.c. */
5 /* Origin: Joseph Myers <jsm@polyomino.org.uk> */
6 /* { dg-do compile } */
7 /* { dg-options "" } */
9 /* Duplicate specifiers. */
11 inline inline void f0 (void),
14 static static int a
, /* { dg-error "error: duplicate 'static'" } */
17 extern extern int c
, /* { dg-error "error: duplicate 'extern'" } */
20 typedef typedef int e
, /* { dg-error "error: duplicate 'typedef'" } */
26 auto auto int p
, /* { dg-error "error: duplicate 'auto'" } */
29 register register int r
, /* { dg-error "error: duplicate 'register'" } */
33 /* Multiple specifiers. */
35 static extern int x
, /* { dg-error "error: multiple storage classes in declaration specifiers" } */
38 extern typedef long z
, /* { dg-error "error: multiple storage classes in declaration specifiers" } */