diff options
author | akashlal <unknown> | 2013-05-27 12:32:24 +0530 |
---|---|---|
committer | akashlal <unknown> | 2013-05-27 12:32:24 +0530 |
commit | 0b5af50545d93128256acabcd09ec09996f495f6 (patch) | |
tree | 77b193a330e4a09fa47c19959fa06c620c973984 /Test/AbsHoudini/pred5.bpl | |
parent | 21f72bdf46f12d214ac1f58bcc1041de2827ff40 (diff) |
AbsHoudini: Added support for quantifiers
Diffstat (limited to 'Test/AbsHoudini/pred5.bpl')
-rw-r--r-- | Test/AbsHoudini/pred5.bpl | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Test/AbsHoudini/pred5.bpl b/Test/AbsHoudini/pred5.bpl new file mode 100644 index 00000000..6940e820 --- /dev/null +++ b/Test/AbsHoudini/pred5.bpl @@ -0,0 +1,24 @@ +function {:existential true} b1(x: bool) : bool;
+
+procedure main()
+{
+ var i: int;
+ var x: int;
+ var arr: [int] int;
+
+ i := 0;
+
+ while(*)
+ invariant b1((i >= 0) && (forall j: int :: (0 <= j && j < i) ==> arr[j] == 0));
+ {
+ havoc x;
+ assume x == 0;
+
+ arr[i] := x;
+ i := i + 1;
+ }
+
+ havoc x;
+ assume x >= 0 && x < i;
+ assert b1(arr[x] == 0);
+}
|