This commit is contained in:
Yuriy Glukhov 2018-07-22 23:30:59 +03:00 • committed by Andreas Rumpf
commit 2094209837
4 changed files with 48 additions and 35 deletions

View file

@ -588,7 +588,7 @@ proc lowerStmtListExprs(ctx: var Ctx, n: PNode, needsSplit: var bool): PNode =
let branch = n[i]
case branch.kind
of nkOfBranch:
branch[1] = ctx.convertExprBodyToAsgn(branch[1], tmp)
branch[^1] = ctx.convertExprBodyToAsgn(branch[^1], tmp)
of nkElse:
branch[0] = ctx.convertExprBodyToAsgn(branch[0], tmp)
else: