summary refs log tree commit diff stats
path: root/tests/compile
diff options
context:
space:
mode:
Diffstat (limited to 'tests/compile')
-rw-r--r--tests/compile/tgeneric.nim8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/compile/tgeneric.nim b/tests/compile/tgeneric.nim
index 8bda15c42..9292b729f 100644
--- a/tests/compile/tgeneric.nim
+++ b/tests/compile/tgeneric.nim
@@ -8,4 +8,12 @@ proc foo(models: seq[TTable[string, float]]): seq[float] =
   for model in models.items:
     result.add model["foobar"]
 
+# bug #686
+type TType[T; A] = array[A, T]
+
+proc foo[T](p: TType[T, range[0..1]]) =
+  echo "foo"
+proc foo[T](p: TType[T, range[0..2]]) =
+  echo "bar"
+