public class GlobalEnvironment extends Environment
Environment.AbstractFrameVarRef, Environment.FrameSlotVarRef, Environment.GlobalLexVarRef, Environment.GlobalVarRef, Environment.ImportBindingRef, Environment.VarRef, Environment.WrappedVarRefARGUMENTS_NAME, context, factory, NEW_TARGET_NAME, SUPER_NAME, THIS_NAME| Constructor and Description |
|---|
GlobalEnvironment(Environment parent,
NodeFactory factory,
JSContext context) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addLexicalDeclaration(String name,
boolean isConst) |
boolean |
addVarDeclaration(String name) |
com.oracle.truffle.api.frame.FrameSlot |
findBlockFrameSlot(String name) |
FunctionEnvironment |
function() |
com.oracle.truffle.api.frame.FrameDescriptor |
getBlockFrameDescriptor() |
com.oracle.truffle.api.frame.FrameSlot[] |
getParentSlots() |
boolean |
hasConstDeclaration(String name) |
boolean |
hasLexicalDeclaration(String name) |
boolean |
hasVarDeclaration(String name) |
static boolean |
isGlobalObjectConstant(String name)
Returns true for always-defined immutable value properties of the global object.
|
addFrameSlotFromSymbol, addFrameSlotsFromSymbols, addFrameSlotsFromSymbols, createLocal, createLocal, createTempVar, declareLocalVar, declareVar, findArgumentsVar, findAsyncContextVar, findAsyncResultVar, findDynamicScopeVar, findInternalSlot, findInternalSlot, findLocalVar, findNewTargetVar, findSuperVar, findTempVar, findThisVar, findVar, findVar, findYieldValueVar, getFunctionFrameDescriptor, getParent, getParentSlots, getScopeLevel, getVariableEnvironment, hasLocalVar, isDynamicallyScoped, isDynamicScopeContext, isStrictModepublic GlobalEnvironment(Environment parent, NodeFactory factory, JSContext context)
public FunctionEnvironment function()
function in class Environmentpublic com.oracle.truffle.api.frame.FrameSlot findBlockFrameSlot(String name)
findBlockFrameSlot in class Environmentpublic com.oracle.truffle.api.frame.FrameDescriptor getBlockFrameDescriptor()
getBlockFrameDescriptor in class Environmentpublic com.oracle.truffle.api.frame.FrameSlot[] getParentSlots()
getParentSlots in class Environmentpublic boolean addLexicalDeclaration(String name, boolean isConst)
public boolean hasLexicalDeclaration(String name)
public boolean hasConstDeclaration(String name)
public boolean addVarDeclaration(String name)
public boolean hasVarDeclaration(String name)
public static boolean isGlobalObjectConstant(String name)