summary refs log tree commit diff stats
path: root/compiler/semexprs.nim
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/semexprs.nim')
-rw-r--r--compiler/semexprs.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim
index 67373c303..fde09400d 100644
--- a/compiler/semexprs.nim
+++ b/compiler/semexprs.nim
@@ -1163,7 +1163,7 @@ proc semAsgn(c: PContext, n: PNode): PNode =
     if lhsIsResult:
       n.typ = EnforceVoidContext
       if lhs.sym.typ.kind == tyGenericParam:
-        if matchTypeClass(lhs.typ, rhs.typ):
+        if cmpTypes(c, lhs.typ, rhs.typ) == isGeneric:
           InternalAssert c.p.resultSym != nil
           lhs.typ = rhs.typ
           c.p.resultSym.typ = rhs.typ