1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
/* { dg-do compile } */ /* { dg-options "-O" } */ struct S { int i; }; int invalid[] = 0; /* { dg-error "invalid initializer" } */ void foo (void) { if (((struct S *)undeclared)->i); /* { dg-error "undeclared" } */ } /* { dg-message "reported only once" "" { target *-*-* } 13 } */