fixes #6073
This commit is contained in:
parent
3fdb78fe80
commit
a9ac241691
2 changed files with 14 additions and 1 deletions
13
tests/types/tyet_another_generic_regression.nim
Normal file
13
tests/types/tyet_another_generic_regression.nim
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
import system
|
||||
|
||||
type Bar[T] = ref object
|
||||
value: T
|
||||
|
||||
type types = int32|int64 # if I change this to just int32 or int64 it works (compiles)
|
||||
|
||||
# if I replace Bar everywhere with seq it also compiles fine
|
||||
proc Foo[T: Bar[types]](): T =
|
||||
when T is Bar: nil
|
||||
|
||||
discard Foo[Bar[int32]]()
|
||||
#bug #6073
|
||||
Loading…
Add table
Add a link
Reference in a new issue