Skip to content

Commit bc2ee97

Browse files
Add problematic program
1 parent a6aa225 commit bc2ee97

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

test/small1/c11-caserange.c

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#include "testharness.h"
2+
3+
int pr(const char val)
4+
{
5+
switch (val) {
6+
case '0' ... '7':
7+
case 'd': /* KERN_DEFAULT */
8+
return 5;
9+
default:
10+
return 1;
11+
}
12+
13+
return 2;
14+
}
15+
16+
int main() {
17+
pr('a');
18+
SUCCESS;
19+
}

test/testcil.pl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -694,6 +694,7 @@ sub addToGroup {
694694
addBadComment("combinec99inline", "C99 inline semantic not fully supported.");
695695

696696
addTest("testrunc11/c11-generic");
697+
addTest("testrunc11/c11-const-range");
697698
addTest("testrunc11/gcc-c11-generic-1");
698699
# TODO: these messages are not even checked?
699700
addTestFail("testc11/gcc-c11-generic-2-1", "Multiple defaults in generic");

0 commit comments

Comments
 (0)