summaryrefslogtreecommitdiff
path: root/Chalice/tests/predicates/test.chalice
diff options
context:
space:
mode:
Diffstat (limited to 'Chalice/tests/predicates/test.chalice')
-rw-r--r--Chalice/tests/predicates/test.chalice35
1 files changed, 0 insertions, 35 deletions
diff --git a/Chalice/tests/predicates/test.chalice b/Chalice/tests/predicates/test.chalice
deleted file mode 100644
index 9477caa6..00000000
--- a/Chalice/tests/predicates/test.chalice
+++ /dev/null
@@ -1,35 +0,0 @@
-class List
-{
- var value:int;
- var next:List;
-
- predicate inv { acc(value) && acc(next) && (next!=null ==> next.inv) }
-
- function len():int
- requires inv;
- {
- unfolding inv in (next==null) ? 1 : (1+next.len())
- }
-
- predicate P { acc(value,50) }
-
- method skip()
- requires P; ensures P
- {}
-
- method goo()
- requires acc(value);
- {
- // mask: value=100, secmask: -
- fold P;
- // mask: value=50,p=100, secmask: value=50
- call skip();
- // mask: value=50,p=100, secmask: -
- fold P;
- // mask: value=0,p=200, secmask: value=50
- fork t:=skip();
- // mask: value=0,p=100, secmask: -
- assert unfolding P in value==old(value);
- }
-
-}