quick bug fix (#7576)

This commit is contained in:
cooldome 2018-04-12 07:00:54 +01:00 • committed by Andreas Rumpf
commit 19aad4f547

View file

@ -572,6 +572,8 @@ proc genBreakStmt(p: BProc, t: PNode) =
lineF(p, cpsStmts, "goto $1;$n", [label]) lineF(p, cpsStmts, "goto $1;$n", [label])
proc genRaiseStmt(p: BProc, t: PNode) = proc genRaiseStmt(p: BProc, t: PNode) =
if p.module.compileToCpp:
discard cgsym(p.module, "popCurrentExceptionEx")
if p.nestedTryStmts.len > 0 and p.nestedTryStmts[^1].inExcept: if p.nestedTryStmts.len > 0 and p.nestedTryStmts[^1].inExcept:
# if the current try stmt have a finally block, # if the current try stmt have a finally block,
# we must execute it before reraising # we must execute it before reraising