annotate gcc/testsuite/c-c++-common/pr69558.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* PR c/69558 */
kono
parents:
diff changeset
2 /* { dg-do compile } */
kono
parents:
diff changeset
3 /* { dg-options "-Wdeprecated-declarations" } */
kono
parents:
diff changeset
4
kono
parents:
diff changeset
5 /* TODO: XFAIL for g++ (works for C). */
kono
parents:
diff changeset
6
kono
parents:
diff changeset
7 #define A \
kono
parents:
diff changeset
8 _Pragma ("GCC diagnostic push") \
kono
parents:
diff changeset
9 _Pragma ("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
kono
parents:
diff changeset
10 #define B \
kono
parents:
diff changeset
11 _Pragma ("GCC diagnostic pop")
kono
parents:
diff changeset
12 #define C(x) \
kono
parents:
diff changeset
13 A \
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
14 static inline void bar (void) { x (); } /* { dg-bogus "in definition of|deprecated" "" } */ \
111
kono
parents:
diff changeset
15 B
kono
parents:
diff changeset
16
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
17 __attribute__((deprecated)) void foo (void); /* { dg-bogus "declared here" "" } */
111
kono
parents:
diff changeset
18
kono
parents:
diff changeset
19 C (foo) /* { dg-bogus "is deprecated" } */