public void pushBlockScope() { currentScope = getRuntime().getStaticScopeFactory().newBlockScope(currentScope); }
public void pushBlockScope() { currentScope = configuration.getRuntime().getStaticScopeFactory().newBlockScope(currentScope); }
public void pushBlockScope() { currentScope = getRuntime().getStaticScopeFactory().newBlockScope(currentScope); }
public void pushBlockScope() { currentScope = configuration.getRuntime().getStaticScopeFactory().newBlockScope(currentScope); }
public void pushBlockScope() { currentScope = configuration.getRuntime().getStaticScopeFactory().newBlockScope(currentScope, lexer.getFile()); }
public void pushBlockScope() { currentScope = configuration.getRuntime().getStaticScopeFactory().newBlockScope(currentScope, lexer.getFile()); }
public static StaticScope decodeScope(ThreadContext context, StaticScope parent, String scopeString) { String[][] decodedScope = decodeScopeDescriptor(scopeString); StaticScope scope = null; switch (StaticScope.Type.valueOf(decodedScope[0][0])) { case BLOCK: scope = context.runtime.getStaticScopeFactory().newBlockScope(parent, decodedScope[1]); break; case EVAL: scope = context.runtime.getStaticScopeFactory().newEvalScope(parent, decodedScope[1]); break; case LOCAL: scope = context.runtime.getStaticScopeFactory().newLocalScope(parent, decodedScope[1]); break; } setAritiesFromDecodedScope(scope, decodedScope[0]); return scope; }
public static StaticScope decodeScope(ThreadContext context, StaticScope parent, String scopeString) { String[][] decodedScope = decodeScopeDescriptor(scopeString); StaticScope scope = null; switch (StaticScope.Type.valueOf(decodedScope[0][0])) { case BLOCK: scope = context.runtime.getStaticScopeFactory().newBlockScope(parent, decodedScope[1]); break; case EVAL: scope = context.runtime.getStaticScopeFactory().newEvalScope(parent, decodedScope[1]); break; case LOCAL: scope = context.runtime.getStaticScopeFactory().newLocalScope(parent, decodedScope[1]); break; } setAritiesFromDecodedScope(scope, decodedScope[0]); return scope; }
@SuppressWarnings("deprecation") static StaticScope decodeScope(ThreadContext context, StaticScope parent, String scopeString) { String[][] decodedScope = decodeScopeDescriptor(scopeString); String scopeTypeName = decodedScope[0][0]; String[] names = decodedScope[1]; StaticScope scope = null; switch (StaticScope.Type.valueOf(scopeTypeName)) { case BLOCK: scope = context.runtime.getStaticScopeFactory().newBlockScope(parent, names); break; case EVAL: scope = context.runtime.getStaticScopeFactory().newEvalScope(parent, names); break; case LOCAL: scope = context.runtime.getStaticScopeFactory().newLocalScope(parent, names); break; } setAritiesFromDecodedScope(scope, decodedScope[0][2]); scope.setScopeType(IRScopeType.valueOf(decodedScope[0][3])); return scope; }
@SuppressWarnings("deprecation") static StaticScope decodeScope(ThreadContext context, StaticScope parent, String scopeString) { String[][] decodedScope = decodeScopeDescriptor(scopeString); String scopeTypeName = decodedScope[0][0]; String[] names = decodedScope[1]; StaticScope scope = null; switch (StaticScope.Type.valueOf(scopeTypeName)) { case BLOCK: scope = context.runtime.getStaticScopeFactory().newBlockScope(parent, names); break; case EVAL: scope = context.runtime.getStaticScopeFactory().newEvalScope(parent, names); break; case LOCAL: scope = context.runtime.getStaticScopeFactory().newLocalScope(parent, names); break; } setAritiesFromDecodedScope(scope, decodedScope[0][2]); scope.setScopeType(IRScopeType.valueOf(decodedScope[0][3])); return scope; }
public void preExecuteUnder(IRubyObject executeUnderObj, RubyModule executeUnderClass, Block block) { Frame frame = getCurrentFrame(); DynamicScope scope = getCurrentScope(); StaticScope sScope = runtime.getStaticScopeFactory().newBlockScope(scope.getStaticScope()); sScope.setModule(executeUnderClass); pushScope(DynamicScope.newDynamicScope(sScope, scope)); pushCallFrame(frame.getKlazz(), frame.getName(), executeUnderObj, block); getCurrentFrame().setVisibility(getPreviousFrame().getVisibility()); }
public void preExecuteUnder(IRubyObject executeUnderObj, RubyModule executeUnderClass, Block block) { Frame frame = getCurrentFrame(); DynamicScope scope = getCurrentScope(); StaticScope sScope = runtime.getStaticScopeFactory().newBlockScope(scope.getStaticScope()); sScope.setModule(executeUnderClass); pushScope(DynamicScope.newDynamicScope(sScope, scope)); pushCallFrame(frame.getKlazz(), frame.getName(), executeUnderObj, block); getCurrentFrame().setVisibility(getPreviousFrame().getVisibility()); }
public void preExecuteUnder(RubyModule executeUnderClass, Block block) { Frame frame = getCurrentFrame(); pushRubyClass(executeUnderClass); DynamicScope scope = getCurrentScope(); StaticScope sScope = runtime.getStaticScopeFactory().newBlockScope(scope.getStaticScope()); sScope.setModule(executeUnderClass); pushScope(DynamicScope.newDynamicScope(sScope, scope)); pushCallFrame(frame.getKlazz(), frame.getName(), frame.getSelf(), block); getCurrentFrame().setVisibility(getPreviousFrame().getVisibility()); }
public void preExecuteUnder(RubyModule executeUnderClass, Block block) { Frame frame = getCurrentFrame(); pushRubyClass(executeUnderClass); DynamicScope scope = getCurrentScope(); StaticScope sScope = runtime.getStaticScopeFactory().newBlockScope(scope.getStaticScope()); sScope.setModule(executeUnderClass); pushScope(DynamicScope.newDynamicScope(sScope, scope)); pushCallFrame(frame.getKlazz(), frame.getName(), frame.getSelf(), block); getCurrentFrame().setVisibility(getPreviousFrame().getVisibility()); }
StaticScope newScope = getRuntime().getStaticScopeFactory().newBlockScope(oldScope.getEnclosingScope(), oldScope.getVariables()); newScope.setPreviousCRefScope(oldScope.getPreviousCRefScope()); newScope.setModule(oldScope.getModule());
StaticScope newScope = getRuntime().getStaticScopeFactory().newBlockScope(oldScope.getEnclosingScope(), oldScope.getVariables()); newScope.setPreviousCRefScope(oldScope.getPreviousCRefScope()); newScope.setModule(oldScope.getModule());