Fix ICE in substring-handling building 502.gcc_r (PR 87562)
[official-gcc.git] / gcc / testsuite / c-c++-common / Wswitch-unreachable-4.c
blobe7378a7cf18827bacc616c6410f2e81b4eaad3f8
1 /* { dg-do compile } */
3 void
4 foo (int a, int b)
6 switch (a)
8 { int c; }
9 { int d; }
10 { int e; }
11 b++; /* { dg-warning "statement will never be executed" } */
12 case 1:
13 break;
16 switch (a)
18 { int c; }
19 { int d = 1; } /* { dg-warning "statement will never be executed" } */
20 { int e; }
21 b++;
22 case 1:
23 break;