Debian Codegraph @

gcc/testsuite/gcc.dg/Wfree-labels-1.c

raw
1 /* { dg-do compile } */
2 /* { dg-options "-Wfree-labels" } */
3
4 void
5 f (void)
6 {
7 goto l;
8 l: /* { dg-warning "label at end of compound statement" } */
9 }
10
11 int
12 g (void)
13 {
14 goto l;
15 l:
16 int x = 0; /* { dg-warning "a label can only be part of a statement" } */
17 return x;
18 }