aboutsummaryrefslogtreecommitdiff
path: root/tests/conformance/9-appendix-b/b2_15_duplicate_case.zc
blob: 63c30ec30d2f0914a63c799c909d28debda4a574 (plain) (blame)
1
2
3
4
5
6
// expect error: duplicate
// spec appendix b.2.15: duplicate case labels are not diagnosed (4.7.2 says they are allowed)
include rt;
void pn(int x) { rt.put_n(x); rt.put_c(10); }
fn main() { int k = 1; switch (k) { case 1: pn(1); case 1: pn(2); } return 0; }
// zc0: skip