blob: f2d0ce1c6930dc1f913a9444ff2d33b828cb4560 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
// PR c/7652
// { dg-do compile { target c++11 } }
// { dg-options "-Wextra -Wall -Wpedantic" }
extern void bar (int);
void
f (int i)
{
switch (i)
{
case 1:
bar (1);
[[fallthrough]];
case 3:
bar (1);
[[gnu::fallthrough, gnu::fallthrough]]; // { dg-warning ".fallthrough. attribute specified multiple times" }
case 2:
bar (2);
}
}
|