diff --git a/compiler/sigmatch.nim b/compiler/sigmatch.nim index 902b3bd614..fa27a8c95d 100644 --- a/compiler/sigmatch.nim +++ b/compiler/sigmatch.nim @@ -158,11 +158,15 @@ proc sumGeneric(t: PType): int = t = t.sons[0] inc result inc isvar + of tyTypeDesc: + t = t.lastSon + if t.kind == tyEmpty: break + inc result of tyGenericInvocation, tyTuple: result += ord(t.kind == tyGenericInvocation) for i in 0 ..