Skip to content

Commit 4928ef6

Browse files
Regression tests for Character.getNumericValue
This used to make CBMC crash but is now evaluated correctly.
1 parent c59e846 commit 4928ef6

File tree

3 files changed

+21
-0
lines changed

3 files changed

+21
-0
lines changed
Binary file not shown.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
CORE
2+
test.class
3+
--refine-strings
4+
^EXIT=10$
5+
^SIGNAL=0$
6+
assertion at file test.java line 8 .* SUCCESS$
7+
assertion at file test.java line 10 .* FAILURE$
8+
--
9+
^warning: ignoring
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
public class test
2+
{
3+
4+
public static void main(String[] args)
5+
{
6+
char c = 'a';
7+
if(args.length>1)
8+
assert Character.getNumericValue(c) == 10;
9+
else
10+
assert Character.getNumericValue(c) != 10;
11+
}
12+
}

0 commit comments

Comments
 (0)