Skip to content

Commit

Permalink
END should fire even if Ruby has exception
Browse files Browse the repository at this point in the history
  • Loading branch information
enebo committed Oct 22, 2014
1 parent b533e58 commit 0b95ac1
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -157,12 +157,12 @@ protected IRubyObject execute(Ruby runtime, IRScriptBody irScope, IRubyObject se
try {
Interpreter.runBeginEndBlocks(irScope.getBeginBlocks(), context, self, scope, null);
retVal = Interpreter.INTERPRET_ROOT(context, self, ic, currModule, name);
Interpreter.runBeginEndBlocks(irScope.getEndBlocks(), context, self, scope, null);

Interpreter.dumpStats();
} catch (IRBreakJump bj) {
throw IRException.BREAK_LocalJumpError.getException(context.runtime);
} finally {
Interpreter.runBeginEndBlocks(irScope.getEndBlocks(), context, self, scope, null);
if (!ic.isDynscopeEliminated()) context.popScope();
}

Expand Down

0 comments on commit 0b95ac1

Please sign in to comment.