summaryrefslogtreecommitdiff
path: root/Test
diff options
context:
space:
mode:
authorGravatar leino <unknown>2014-11-01 13:59:06 -0700
committerGravatar leino <unknown>2014-11-01 13:59:06 -0700
commite200c1f9a8b5e7873b17abc71e4a8c1f953ed31c (patch)
tree084f3b080f42bf90e3ce15c19a91c72737b65a64 /Test
parentf21cde811e9194934eb30f196ad19c2cfbeb8ff9 (diff)
parent02e2b99ab18659ea2626e2be5fa369b7f1795334 (diff)
Merge
Diffstat (limited to 'Test')
-rw-r--r--Test/dafny0/DirtyLoops.dfy17
-rw-r--r--Test/dafny0/DirtyLoops.dfy.expect2
-rw-r--r--Test/dafny2/SnapshotableTrees.dfy4
3 files changed, 19 insertions, 4 deletions
diff --git a/Test/dafny0/DirtyLoops.dfy b/Test/dafny0/DirtyLoops.dfy
index 6a49e733..5d356f0a 100644
--- a/Test/dafny0/DirtyLoops.dfy
+++ b/Test/dafny0/DirtyLoops.dfy
@@ -1,6 +1,21 @@
// RUN: %dafny /compile:0 /dprint:"%t.dprint.dfy" "%s" > "%t"; %dafny /noVerify /compile:0 "%t.dprint.dfy" >> "%t"
// RUN: %diff "%s.expect" "%t"
-method M(S: set<int>) {
+method M0(S: set<int>) {
forall s | s in S ensures s < 0;
}
+
+method M1(x: int)
+{
+ var i := x;
+ while (0 < i)
+ invariant i <= x;
+}
+
+method M2(x: int)
+{
+ var i := x;
+ while (0 < i)
+ invariant i <= x;
+ decreases i;
+}
diff --git a/Test/dafny0/DirtyLoops.dfy.expect b/Test/dafny0/DirtyLoops.dfy.expect
index 5c12e1ef..060f3287 100644
--- a/Test/dafny0/DirtyLoops.dfy.expect
+++ b/Test/dafny0/DirtyLoops.dfy.expect
@@ -1,4 +1,4 @@
-Dafny program verifier finished with 2 verified, 0 errors
+Dafny program verifier finished with 6 verified, 0 errors
Dafny program verifier finished with 0 verified, 0 errors
diff --git a/Test/dafny2/SnapshotableTrees.dfy b/Test/dafny2/SnapshotableTrees.dfy
index 96d3707f..b64660b3 100644
--- a/Test/dafny2/SnapshotableTrees.dfy
+++ b/Test/dafny2/SnapshotableTrees.dfy
@@ -1,4 +1,4 @@
-// RUN: %dafny /compile:0 /dprint:"%t.dprint" /vcsMaxKeepGoingSplits:10 "%s" > "%t"
+// RUN: %dafny /compile:0 /dprint:"%t.dprint" "%s" > "%t"
// RUN: %diff "%s.expect" "%t"
// Rustan Leino, September 2011.
@@ -266,7 +266,7 @@ class Node
if (left == n.left) {
r, pos := n, -1;
} else {
- // assert n.left != null ==> forall e :: e in n.left.Contents ==> e < n.data;
+ assert n.left != null ==> forall e :: e in n.left.Contents ==> e < n.data;
// assert forall e :: e in left.Contents ==> e < n.data;
r := new Node.Build(left, n.data, n.right);
}