Update concepts branch to revision 131834
[official-gcc.git] / gcc / testsuite / gcc.dg / Werror-9.c
blob87051146a5b48fa0e1e582976b3936a547496dd8
1 /* { dg-do compile } */
2 /* { dg-options "-Wattributes" } */
4 /* Make sure #pragma can enable a warning as an error. */
6 #pragma GCC diagnostic error "-Waddress"
8 void __attribute__((dj)) bar() { } /* { dg-warning ".* attribute directive ignored" } */
10 int i;
12 void
13 foo ()
15 if (&i) /* { dg-error ".* will always evaluate as 'true'" } */
16 grill ();