Skip to content

Commit 1837fa2

Browse files
author
klaas
committed
Added clarification to function_check_05 test.
1 parent 486fd49 commit 1837fa2

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

regression/contracts/function_check_05/main.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ __CPROVER_ensures(__CPROVER_return_value == 1)
1010
int main() {
1111
int y = 0;
1212
int z = foo(&y);
13+
// This assert should fail.
1314
assert(y == 0);
15+
// This one should succeed.
1416
assert(z == 1);
1517
return 0;
1618
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
KNOWNBUG # Contract checking does not properly havoc function calls
22
main.c
33
--check-code-contracts
4-
^\[main.assertion.1\] assertion x == 0: FAILURE$
5-
^\[main.assertion.2\] assertion y == 1: SUCCESS$
4+
^\[main.assertion.1\] assertion y == 0: FAILURE$
5+
^\[main.assertion.2\] assertion z == 1: SUCCESS$
66
^\[foo.1\] : SUCCESS$
77

88
^VERIFICATION SUCCESSFUL$

0 commit comments

Comments
 (0)