| 1 |
/* PR preprocessor/65238 */ |
| 2 |
/* { dg-do preprocess } */ |
| 3 |
/* { dg-options "-traditional-cpp" } */ |
| 4 |
|
| 5 |
#if __has_attribute( |
| 6 |
#endif |
| 7 |
#if __has_attribute(unused |
| 8 |
#endif |
| 9 |
#if __has_attribute(unused, unused) |
| 10 |
#endif |
| 11 |
#if __has_attribute(__has_attribute(unused)) |
| 12 |
#endif |
| 13 |
|
| 14 |
/* { dg-error "-:unterminated argument list invoking macro .__has_attribute." "" {target "*-*-*"} 5 } */ |
| 15 |
/* { dg-error "-:#if with no expression" "" {target "*-*-*"} 5 } */ |
| 16 |
/* { dg-error "-:unterminated argument list invoking macro .__has_attribute." "" {target "*-*-*"} 7 } */ |
| 17 |
/* { dg-error "-:macro .__has_attribute. passed 2 arguments, but takes just 1" "" {target "*-*-*"} 9 } */ |
| 18 |
/* { dg-error "-:missing ... in expression" "" {target "*-*-*"} 9 } */ |
| 19 |
/* { dg-error "-:macro .__has_attribute. requires an identifier" "" {target "*-*-*"} 11 } */ |