summaryrefslogtreecommitdiff
path: root/Test/dafny4/Bug108.dfy
diff options
context:
space:
mode:
authorGravatar qunyanm <unknown>2015-11-18 11:05:48 -0800
committerGravatar qunyanm <unknown>2015-11-18 11:05:48 -0800
commit9b2dea60e57be8ddb39b36ed8a282e3826cd4092 (patch)
treeda041a2765c74d4a5dba3738b6e0a49de2f2ef19 /Test/dafny4/Bug108.dfy
parent5630200c12094d86d3ff75ce251f0776b8dfb265 (diff)
Fix issue 108. Use idGenerator to create a new collection name for each
occurrence of Set/MapComprehension when translating it to c#.
Diffstat (limited to 'Test/dafny4/Bug108.dfy')
-rw-r--r--Test/dafny4/Bug108.dfy11
1 files changed, 11 insertions, 0 deletions
diff --git a/Test/dafny4/Bug108.dfy b/Test/dafny4/Bug108.dfy
new file mode 100644
index 00000000..17cb9f12
--- /dev/null
+++ b/Test/dafny4/Bug108.dfy
@@ -0,0 +1,11 @@
+// RUN: %dafny /compile:3 "%s" > "%t"
+// RUN: %diff "%s.expect" "%t"
+
+method Main() {
+ var A := map[0 := 1];
+ var B := map x | x in (set y | y in A) :: A[x];
+ print A, "\n";
+ print B, "\n";
+}
+
+