summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-08-23 01:29:30 +0200
committerAndreas Rumpf <rumpf_a@web.de>2016-08-23 01:29:30 +0200
commit55e86184a5289ee61b6105ed4ddb2cc1ca4f76dc (patch)
tree1353c25e34cdef564f19499beaa1d3b9b47cf251 /tests
parente9e413552af0480747d025d422a0ea9500c582a2 (diff)
downloadNim-55e86184a5289ee61b6105ed4ddb2cc1ca4f76dc.tar.gz
fixes #4600
Diffstat (limited to 'tests')
-rw-r--r--tests/generics/ttempl_in_generic.nim8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/generics/ttempl_in_generic.nim b/tests/generics/ttempl_in_generic.nim
new file mode 100644
index 000000000..f04b9d216
--- /dev/null
+++ b/tests/generics/ttempl_in_generic.nim
@@ -0,0 +1,8 @@
+
+# bug #4600
+template foo(x: untyped): untyped = echo 1
+template foo(x,y: untyped): untyped = echo 2
+
+proc bar1[T](x: T) = foo(x)
+proc bar2(x: float) = foo(x,x)
+proc bar3[T](x: T) = foo(x,x)