Fix ICE in substring-handling building 502.gcc_r (PR 87562)
[official-gcc.git] / gcc / testsuite / c-c++-common / pr69558.c
bloba930653111751a1c4cdd0250453aa224d0cc0feb
1 /* PR c/69558 */
2 /* { dg-do compile } */
3 /* { dg-options "-Wdeprecated-declarations" } */
5 /* TODO: XFAIL for g++ (works for C). */
7 #define A \
8 _Pragma ("GCC diagnostic push") \
9 _Pragma ("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
10 #define B \
11 _Pragma ("GCC diagnostic pop")
12 #define C(x) \
13 A \
14 static inline void bar (void) { x (); } /* { dg-bogus "in definition of|deprecated" "" } */ \
17 __attribute__((deprecated)) void foo (void); /* { dg-bogus "declared here" "" } */
19 C (foo) /* { dg-bogus "is deprecated" } */