public override Value Val(TAC.Context context) { if (this == self) { return(context.self); } return(context.GetVar(identifier)); }
public override Value Val(TAC.Context context, out ValMap valueFoundIn) { valueFoundIn = null; if (this == self) { return(context.self); } return(context.GetVar(identifier)); }
/// <summary> /// Get a value from the global namespace of this interpreter. /// </summary> /// <param name="varName">name of global variable to get</param> /// <returns>Value of the named variable, or null if not found</returns> public Value GetGlobalValue(string varName) { if (vm == null) { return(null); } TAC.Context c = vm.globalContext; if (c == null) { return(null); } try { return(c.GetVar(varName)); } catch (UndefinedIdentifierException) { return(null); } }
public override Value Val(TAC.Context context, out ValMap valueFoundIn) { valueFoundIn = null; return(context.GetVar(identifier)); }
public override Value Val(TAC.Context context) { return(context.GetVar(identifier)); }