PR target/55146
[official-gcc.git] / gcc / testsuite / gcc.dg / Wcxx-compat-15.c
blob82a76ec4d0f1088e6fbab78889a9ec0863aed9ed
1 /* { dg-do compile } */
2 /* { dg-options "-Wc++-compat" } */
4 typedef int myint1;
5 typedef int myint2;
6 typedef int myint3;
7 struct s1
9 myint1 myint1; /* { dg-warning "invalid in C\[+\]\[+\]" } */
10 myint2 *myint2; /* { dg-warning "invalid in C\[+\]\[+\]" } */
11 int myint3;
12 struct s2
14 myint3 f2; /* { dg-warning "C\[+\]\[+\]" } */
15 } f1;
18 struct s3
20 int myint1;
21 struct s4
23 int myint1;
24 } f1;
25 struct s5
27 int myint1;
28 struct s6
30 myint1 f4; /* { dg-warning "C\[+\]\[+\]" } */
31 } f3;
32 } f2;