fixes a C code generator regression, no need to backport, only the 1.4 line is affected (#15569)
This commit is contained in:
parent
09cad44be9
commit
8978112457
2 changed files with 19 additions and 1 deletions
|
|
@ -249,7 +249,7 @@ proc openArrayLoc(p: BProc, formalType: PType, n: PNode): Rope =
|
|||
else: internalError(p.config, "openArrayLoc: " & typeToString(a.t))
|
||||
|
||||
proc withTmpIfNeeded(p: BProc, a: TLoc, needsTmp: bool): TLoc =
|
||||
if needsTmp:
|
||||
if needsTmp and a.lode.typ != nil:
|
||||
var tmp: TLoc
|
||||
getTemp(p, a.lode.typ, tmp, needsInit=false)
|
||||
genAssignment(p, tmp, a, {})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue