fixes some regressions
This commit is contained in:
parent
5aaf2f0c31
commit
bf698fbc2a
4 changed files with 18 additions and 5 deletions
|
|
@ -1461,6 +1461,8 @@ proc evalConstExprAux(module, prc: PSym, n: PNode, mode: TEvalMode): PNode =
|
|||
let n = transformExpr(module, n)
|
||||
setupGlobalCtx(module)
|
||||
var c = globalCtx
|
||||
let oldMode = c.mode
|
||||
defer: c.mode = oldMode
|
||||
c.mode = mode
|
||||
let start = genExpr(c, n, requiresValue = mode!=emStaticStmt)
|
||||
if c.code[start].opcode == opcEof: return emptyNode
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue