Skip to content

Commit

Permalink
Fix NPEs in full builds
Browse files Browse the repository at this point in the history
  • Loading branch information
subbuss committed Mar 5, 2015
1 parent 699c833 commit 566a3b6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/src/main/java/org/jruby/ir/IRScope.java
Expand Up @@ -388,6 +388,9 @@ public boolean canReceiveNonlocalReturns() {
}

public CFG getCFG() {
if (getFullInterpreterContext() == null) {
prepareFullBuildCommon();
}
return fullInterpreterContext.getCFG();
}

Expand Down
Expand Up @@ -31,6 +31,10 @@ public String getLabel() {

@Override
public Object previouslyRun(IRScope scope) {
if (scope.getFullInterpreterContext() == null) {
scope.prepareFullBuildCommon();
}

return scope.getFullInterpreterContext().getDataFlowProblems().get(LiveVariablesProblem.NAME);
}

Expand Down

0 comments on commit 566a3b6

Please sign in to comment.