summary refs log tree commit diff stats
path: root/tests/ccgbugs/t2procs.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ccgbugs/t2procs.nim')
-rw-r--r--tests/ccgbugs/t2procs.nim18
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/ccgbugs/t2procs.nim b/tests/ccgbugs/t2procs.nim
new file mode 100644
index 000000000..d8b7a2815
--- /dev/null
+++ b/tests/ccgbugs/t2procs.nim
@@ -0,0 +1,18 @@
+discard """
+  output: '''before
+1
+before
+2'''
+"""
+
+proc fn[T1, T2](a: T1, b: T2) =
+  a(1)
+  b(2)
+
+fn( (proc(x: int) =
+      echo "before" # example block, can span multiple lines
+      echo x),
+    (proc (y: int) =
+      echo "before"
+      echo y)
+)