
org.jruby.ir.interpreter.BeginEndInterpreterContext Maven / Gradle / Ivy
package org.jruby.ir.interpreter;
import java.util.List;
import java.util.concurrent.Callable;
import org.jruby.ir.IRClosure;
import org.jruby.ir.IRScope;
import org.jruby.ir.instructions.Instr;
/**
* Script body and Evals both have begin/end bodies and need the same state
* to interpret.
*/
public class BeginEndInterpreterContext extends InterpreterContext {
private List beginBlocks;
public BeginEndInterpreterContext(IRScope scope, List instructions) {
super(scope, instructions);
beginBlocks = scope.getBeginBlocks();
}
public BeginEndInterpreterContext(IRScope scope, Callable> instructions) throws Exception {
super(scope, instructions);
beginBlocks = scope.getBeginBlocks();
}
public List getBeginBlocks() {
return beginBlocks;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy