summary refs log tree commit diff stats
path: root/tests/parser/tcommand_as_expr.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/parser/tcommand_as_expr.nim')
-rw-r--r--tests/parser/tcommand_as_expr.nim12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/parser/tcommand_as_expr.nim b/tests/parser/tcommand_as_expr.nim
new file mode 100644
index 000000000..f6868a2fc
--- /dev/null
+++ b/tests/parser/tcommand_as_expr.nim
@@ -0,0 +1,12 @@
+discard """
+  output: "12"
+"""
+
+proc foo(x: int): int = x-1
+proc foo(x, y: int): int = x-y
+
+let x = foo 7.foo,  # comment here
+            foo(1, foo 8)
+#  12 =       6     -     -6
+echo x
+