summary refs log tree commit diff stats
path: root/tests/vm
diff options
context:
space:
mode:
Diffstat (limited to 'tests/vm')
-rw-r--r--tests/vm/tstaticprintseq.nim21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/vm/tstaticprintseq.nim b/tests/vm/tstaticprintseq.nim
new file mode 100644
index 000000000..99a56d161
--- /dev/null
+++ b/tests/vm/tstaticprintseq.nim
@@ -0,0 +1,21 @@
+discard """
+  msg: '''1
+2
+3
+1
+2
+3'''
+"""
+
+const s = @[1,2,3]
+
+macro foo: stmt =
+  for e in s:
+    echo e
+
+foo()
+
+static:
+  for e in s:
+    echo e
+