fix affecting templates with explicit generic params
This commit is contained in:
parent
05bfa47996
commit
672c24e4b8
4 changed files with 23 additions and 30 deletions
13
tests/template/tgenerictemplates.nim
Normal file
13
tests/template/tgenerictemplates.nim
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
type
|
||||
SomeObj = object of RootObj
|
||||
|
||||
Foo[T, U] = object
|
||||
x: T
|
||||
y: U
|
||||
|
||||
template someTemplate[T](): tuple[id: int32, obj: T] =
|
||||
var result: tuple[id: int32, obj: T] = (0'i32, T())
|
||||
result
|
||||
|
||||
let ret = someTemplate[SomeObj]()
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue