Skip to content

Commit ba34966

Browse files
author
Daniel Kroening
committed
test signed left-shift overflow for C99
The semantics of signed left shifts are contentious for the case that a '1' is shifted into the signed bit. This tests the C99 case.
1 parent 651f60d commit ba34966

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
CORE
2+
main.c
3+
--signed-overflow-check --c99
4+
^EXIT=10$
5+
^SIGNAL=0$
6+
^\[.*\] line 6 arithmetic overflow on signed shl in .*: FAILURE$
7+
^\[.*\] line 9 arithmetic overflow on signed shl in .*: SUCCESS$
8+
^\[.*\] line 15 arithmetic overflow on signed shl in .*: SUCCESS$
9+
^\[.*\] line 18 arithmetic overflow on signed shl in .*: FAILURE$
10+
^\[.*\] line 24 arithmetic overflow on signed shl in .*: FAILURE$
11+
^\*\* 3 of 6 failed
12+
^VERIFICATION FAILED$
13+
--
14+
^warning: ignoring
15+
^\[.*\] line 12 arithmetic overflow on signed shl in .*: .*
16+
^\[.*\] line 21 arithmetic overflow on signed shl in .*: .*

0 commit comments

Comments
 (0)