diff options
Diffstat (limited to 'Chalice/tests/regressions/workitem-10198.chalice')
-rw-r--r-- | Chalice/tests/regressions/workitem-10198.chalice | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Chalice/tests/regressions/workitem-10198.chalice b/Chalice/tests/regressions/workitem-10198.chalice new file mode 100644 index 00000000..fd51977d --- /dev/null +++ b/Chalice/tests/regressions/workitem-10198.chalice @@ -0,0 +1,17 @@ +class Cell { var x: int } + +class Test { + method get() returns (c: Cell) + ensures c != null + lockchange c /* previosly, this introduced errors */ + { + c := new Cell + } + + /* method was needed to get Boogie errors */ + method testRd() // expected ERROR: method might lock/unlock more than allowed + { + var x: Cell + call x := get() + } +}
\ No newline at end of file |