Fix ICE in substring-handling building 502.gcc_r (PR 87562)
[official-gcc.git] / gcc / testsuite / c-c++-common / Wimplicit-fallthrough-12.c
blob91a68ab0771f511e92ba8b7213f335b22702a362
1 /* PR c/7652 */
2 /* { dg-do compile } */
3 /* { dg-options "-Wimplicit-fallthrough -O2" } */
5 /* Don't let optimizations preclude the warning. */
7 extern void bar (int);
9 void
10 f (int i)
12 switch (i)
14 case 1:
15 if (i > 1)
16 bar (1);
17 else
18 goto D;
19 break;
20 case 2:
21 bar (2); /* { dg-warning "statement may fall through" } */
23 default:
24 bar (33);