This commit is contained in:
Araq
2018-04-06 13:10:22 +02:00
parent 824092be31
commit aa6353e4fa
2 changed files with 30 additions and 1 deletions

View File

@@ -271,7 +271,7 @@ proc genAssignment(p: BProc, dest, src: TLoc, flags: TAssignmentFlags) =
# little HACK to support the new 'var T' as return type:
linefmt(p, cpsStmts, "$1 = $2;$n", rdLoc(dest), rdLoc(src))
return
let ty = skipTypes(dest.t, abstractRange + tyUserTypeClasses)
let ty = skipTypes(dest.t, abstractRange + tyUserTypeClasses + {tyStatic})
case ty.kind
of tyRef:
genRefAssign(p, dest, src, flags)