summary refs log tree commit diff stats
path: root/tests/generics/t5707.nim
diff options
context:
space:
mode:
authorVindaar <basti90@gmail.com>2018-10-14 08:44:57 +0200
committerAndreas Rumpf <rumpf_a@web.de>2018-10-14 08:44:57 +0200
commitafd5abdfc254f14bfb818f1a8bee892bd77dbf14 (patch)
tree7cdc5e618daa7997ea8496f137100199323b4853 /tests/generics/t5707.nim
parent38454c6951a09b6e94414683774da9322f4a6d7e (diff)
downloadNim-afd5abdfc254f14bfb818f1a8bee892bd77dbf14.tar.gz
add issue #5707 as test case (#9361)
Diffstat (limited to 'tests/generics/t5707.nim')
-rw-r--r--tests/generics/t5707.nim6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/generics/t5707.nim b/tests/generics/t5707.nim
new file mode 100644
index 000000000..a155e1597
--- /dev/null
+++ b/tests/generics/t5707.nim
@@ -0,0 +1,6 @@
+import sugar
+
+proc foo[T]: seq[int] =
+    return lc[x | (x <- 1..10, x mod 2 == 0), int]
+
+doAssert foo[float32]() == @[2, 4, 6, 8, 10]