summaryrefslogtreecommitdiff
path: root/Test/dafny0/Reads.dfy
diff options
context:
space:
mode:
authorGravatar Rustan Leino <unknown>2015-06-15 16:19:11 -0700
committerGravatar Rustan Leino <unknown>2015-06-15 16:19:11 -0700
commit58d639bff25a2d4dadf6febb81b1438e957c43cd (patch)
tree255610eee4a6f550dc4943278949bb95b2fe179a /Test/dafny0/Reads.dfy
parent7f89a05ae627b7c5498b82deaea34cabc465aaa6 (diff)
Do postponsed reads checking also for the body of functions -- see Test/dafny0/Reads.dfy for benefits.
(Unfortunately, this loses track of the "postcondition might not hold on this return path" locations, see Test/dafny0/FunctionSpecifications.dfy.)
Diffstat (limited to 'Test/dafny0/Reads.dfy')
-rw-r--r--Test/dafny0/Reads.dfy2
1 files changed, 1 insertions, 1 deletions
diff --git a/Test/dafny0/Reads.dfy b/Test/dafny0/Reads.dfy
index f1c840c3..7e0ca1c4 100644
--- a/Test/dafny0/Reads.dfy
+++ b/Test/dafny0/Reads.dfy
@@ -123,6 +123,6 @@ function FunctionInQuantifier2(): int
requires exists f: int -> int :: f.reads(10) == {} && f.requires(10) && f(10) == 100
ensures FunctionInQuantifier2() == 100
{
- var f: int -> int :| f.reads(10) == {} && f.requires(10) && f(10) == 100; // error: insufficient reads for f.reads(10)
+ var f: int -> int :| f.reads(10) == {} && f.requires(10) && f(10) == 100; // fine :) :)
f(10)
}