diff options
author | wuestholz <unknown> | 2014-10-13 23:26:57 +0200 |
---|---|---|
committer | wuestholz <unknown> | 2014-10-13 23:26:57 +0200 |
commit | 1db1508be2b8206fd1a9051f887f2fb20970c4c0 (patch) | |
tree | 2fda3b8a2e1c34d0896a0be895c80482f10e2419 /Test/snapshots | |
parent | 446723cdee734937e3467d9d27ae90bfe088a19b (diff) |
Fix issue in verification result caching for assertions without subsumption.
Diffstat (limited to 'Test/snapshots')
-rw-r--r-- | Test/snapshots/Snapshots24.v0.bpl | 25 | ||||
-rw-r--r-- | Test/snapshots/Snapshots24.v1.bpl | 25 | ||||
-rw-r--r-- | Test/snapshots/runtest.snapshot | 2 | ||||
-rw-r--r-- | Test/snapshots/runtest.snapshot.expect | 8 |
4 files changed, 59 insertions, 1 deletions
diff --git a/Test/snapshots/Snapshots24.v0.bpl b/Test/snapshots/Snapshots24.v0.bpl new file mode 100644 index 00000000..1289399b --- /dev/null +++ b/Test/snapshots/Snapshots24.v0.bpl @@ -0,0 +1,25 @@ +procedure {:checksum "0"} M();
+
+implementation {:id "M"} {:checksum "1"} M()
+{
+ if (*)
+ {
+ assert {:subsumption 0} 1 != 1; // error
+ }
+ else if (*)
+ {
+ assert {:subsumption 1} 5 != 5; // error
+ }
+ else if (*)
+ {
+ assert {:subsumption 2} 6 != 6; // error
+ }
+ else
+ {
+ assert {:subsumption 1} 2 == 2;
+ assert {:subsumption 2} 4 == 4;
+ assert 5 == 5;
+ }
+
+ assert {:subsumption 0} 3 == 3;
+}
diff --git a/Test/snapshots/Snapshots24.v1.bpl b/Test/snapshots/Snapshots24.v1.bpl new file mode 100644 index 00000000..00d65961 --- /dev/null +++ b/Test/snapshots/Snapshots24.v1.bpl @@ -0,0 +1,25 @@ +procedure {:checksum "0"} M();
+
+implementation {:id "M"} {:checksum "2"} M()
+{
+ if (*)
+ {
+ assert {:subsumption 0} 1 == 1;
+ }
+ else if (*)
+ {
+ assert {:subsumption 1} 5 == 5;
+ }
+ else if (*)
+ {
+ assert {:subsumption 2} 6 != 6; // error
+ }
+ else
+ {
+ assert {:subsumption 1} 2 == 2;
+ assert {:subsumption 2} 4 == 4;
+ assert 5 == 5;
+ }
+
+ assert {:subsumption 0} 3 == 3;
+}
diff --git a/Test/snapshots/runtest.snapshot b/Test/snapshots/runtest.snapshot index 32c88216..04943c25 100644 --- a/Test/snapshots/runtest.snapshot +++ b/Test/snapshots/runtest.snapshot @@ -1,2 +1,2 @@ -// RUN: %boogie -errorTrace:0 -verifySnapshots:2 -verifySeparately Snapshots0.bpl Snapshots1.bpl Snapshots2.bpl Snapshots3.bpl Snapshots4.bpl Snapshots5.bpl Snapshots6.bpl Snapshots7.bpl Snapshots8.bpl Snapshots9.bpl Snapshots10.bpl Snapshots11.bpl Snapshots12.bpl Snapshots13.bpl Snapshots14.bpl Snapshots15.bpl Snapshots16.bpl Snapshots17.bpl Snapshots18.bpl Snapshots19.bpl Snapshots20.bpl Snapshots21.bpl Snapshots22.bpl Snapshots23.bpl > "%t" +// RUN: %boogie -errorTrace:0 -verifySnapshots:2 -verifySeparately Snapshots0.bpl Snapshots1.bpl Snapshots2.bpl Snapshots3.bpl Snapshots4.bpl Snapshots5.bpl Snapshots6.bpl Snapshots7.bpl Snapshots8.bpl Snapshots9.bpl Snapshots10.bpl Snapshots11.bpl Snapshots12.bpl Snapshots13.bpl Snapshots14.bpl Snapshots15.bpl Snapshots16.bpl Snapshots17.bpl Snapshots18.bpl Snapshots19.bpl Snapshots20.bpl Snapshots21.bpl Snapshots22.bpl Snapshots23.bpl Snapshots24.bpl > "%t" // RUN: %diff "%s.expect" "%t" diff --git a/Test/snapshots/runtest.snapshot.expect b/Test/snapshots/runtest.snapshot.expect index fd054579..899cd914 100644 --- a/Test/snapshots/runtest.snapshot.expect +++ b/Test/snapshots/runtest.snapshot.expect @@ -152,3 +152,11 @@ Boogie program verifier finished with 1 verified, 1 error Snapshots23.v0.bpl(7,9): Error BP5001: This assertion might not hold.
Boogie program verifier finished with 1 verified, 1 error
+Snapshots24.v0.bpl(7,9): Error BP5001: This assertion might not hold.
+Snapshots24.v0.bpl(11,9): Error BP5001: This assertion might not hold.
+Snapshots24.v0.bpl(15,9): Error BP5001: This assertion might not hold.
+
+Boogie program verifier finished with 0 verified, 3 errors
+Snapshots24.v0.bpl(15,9): Error BP5001: This assertion might not hold.
+
+Boogie program verifier finished with 0 verified, 1 error
|