Class Environment
java.lang.Object
com.oracle.truffle.js.parser.env.Environment
- Direct Known Subclasses:
BlockEnvironment, DebugEnvironment, DerivedEnvironment, EvalEnvironment, FunctionEnvironment
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassclassclassclassclassstatic classclass -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddFrameSlotFromSymbol(Symbol symbol) voidaddFrameSlotsFromSymbols(Iterable<Symbol> symbols) voidaddFrameSlotsFromSymbols(Iterable<Symbol> symbols, boolean onlyBlockScoped, Predicate<Symbol> filter) final JavaScriptNodecreateLocal(JSFrameSlot frameSlot, int frameLevel, int scopeLevel) declareInternalSlot(Object name) declareLocalVar(Object name) findBlockFrameSlot(Object name) final Environment.VarReffindBlockScopedVar(com.oracle.truffle.api.strings.TruffleString name) findFunctionFrameSlot(Object name) final Environment.VarReffindInternalSlot(Object name) final Environment.VarReffindInternalSlot(Object name, boolean allowDebug) protected final Environment.VarReffindInternalSlot(Object name, boolean allowDebug, int skippedFrames) final Environment.VarReffindLocalVar(com.oracle.truffle.api.strings.TruffleString name) findTempVar(JSFrameSlot var) final Environment.VarReffindVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith) final Environment.VarReffindVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith, boolean skipEval, boolean skipBlockScoped, boolean skipGlobal, boolean skipMapped) final Environment.VarReffindVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith, boolean skipEval, boolean skipBlockScoped, boolean skipGlobal, boolean skipMapped, boolean skipVar) final FunctionEnvironmentfunction()final JSFrameSlotgetBlockScopeSlot(int frameLevel, int scopeLevel) final Environmentfinal EnvironmentgetParentAt(int frameLevel, int scopeLevel) getScope()intbooleanhasLocalVar(Object name) booleanbooleanbooleanEnvironment chain contains a dynamic scope (eval or with) that may shadow variables.booleanprotected static StringjoinElements(Iterable<? extends Object> keySet) voidvoidvoidvoidvoidtoString()protected StringtoStringImpl(Map<String, Integer> state)
-
Field Details
-
factory
-
context
-
-
Constructor Details
-
Environment
-
-
Method Details
-
declareLocalVar
-
hasLocalVar
-
findThisVar
-
reserveThisSlot
public void reserveThisSlot() -
findSuperVar
-
reserveSuperSlot
public void reserveSuperSlot() -
findArgumentsVar
-
reserveArgumentsSlot
public void reserveArgumentsSlot() -
findNewTargetVar
-
reserveNewTargetSlot
public void reserveNewTargetSlot() -
findAsyncContextVar
-
findAsyncResultVar
-
findYieldValueVar
-
findDynamicScopeVar
-
reserveDynamicScopeSlot
public void reserveDynamicScopeSlot() -
declareInternalSlot
-
createLocal
-
findInternalSlot
-
findInternalSlot
-
findInternalSlot
protected final Environment.VarRef findInternalSlot(Object name, boolean allowDebug, int skippedFrames) -
findLocalVar
-
findVar
public final Environment.VarRef findVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith) -
findBlockScopedVar
public final Environment.VarRef findBlockScopedVar(com.oracle.truffle.api.strings.TruffleString name) -
findVar
public final Environment.VarRef findVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith, boolean skipEval, boolean skipBlockScoped, boolean skipGlobal, boolean skipMapped) -
findVar
public final Environment.VarRef findVar(com.oracle.truffle.api.strings.TruffleString name, boolean skipWith, boolean skipEval, boolean skipBlockScoped, boolean skipGlobal, boolean skipMapped, boolean skipVar) -
findBlockFrameSlot
-
findFunctionFrameSlot
-
getBlockFrameDescriptor
-
getParent
-
function
-
getParentAt
-
createTempVar
-
findTempVar
-
getFunctionFrameDescriptor
-
isStrictMode
public boolean isStrictMode() -
getScopeLevel
public int getScopeLevel() -
hasScopeFrame
public boolean hasScopeFrame() -
getScope
-
getBlockScopeSlot
-
getCurrentBlockScopeSlot
-
addFrameSlotsFromSymbols
-
addFrameSlotsFromSymbols
-
addFrameSlotFromSymbol
-
isDynamicallyScoped
public boolean isDynamicallyScoped() -
isDynamicScopeContext
public boolean isDynamicScopeContext()Environment chain contains a dynamic scope (eval or with) that may shadow variables. -
getVariableEnvironment
-
findActiveModule
-
toStringImpl
-
joinElements
-
toString
-