Require target lra in gcc.dg/pr108095.c
[official-gcc.git] / gcc / testsuite / gcc.dg / c2x-has-c-attribute-4.c
blobacd35d2d5ac4067dc571f5bbc61373274b7769f4
1 /* Test __has_c_attribute. Test syntax errors. */
2 /* { dg-do preprocess } */
3 /* { dg-options "-std=c2x -pedantic-errors" } */
5 #if __has_c_attribute /* { dg-error "missing '\\('" } */
6 #endif
8 #if __has_c_attribute 0 /* { dg-error "missing '\\('" } */
9 #endif
11 #if __has_c_attribute (0 /* { dg-error "requires an identifier" } */
12 #endif
14 #if __has_c_attribute (x /* { dg-error "missing '\\)'" } */
15 #endif
17 #if __has_c_attribute (x::0) /* { dg-error "required after scope" } */
18 #endif