public override ArmadaLValue GetLValue(IToken tok, ResolutionContext context) { var crashAvoidance = new UndefinedBehaviorAvoidanceConstraint(); var addr = $"({context.GetLValueTopStackFrame()}).{methodName}.AddrOf'{name}"; return(new AddressableArmadaLValue(tok, ty, new ArmadaRValue(crashAvoidance, addr))); }
public override ArmadaLValue GetLValue(IToken tok, ResolutionContext context) { var top = context.GetLValueTopStackFrame(); var correct_frame_type = AH.MakeExprDotName(top, $"Armada_StackFrame_{methodName}?", new BoolType()); var crashAvoidance = new UndefinedBehaviorAvoidanceConstraint(correct_frame_type); return(new UnaddressableFieldArmadaLValue(tok, ty, new TopStackFrameArmadaLValue(crashAvoidance), crashAvoidance, $"{methodName}'{name}", true)); }
public override Expression GetValueInLValueState(ResolutionContext context) { return(context.GetLValueTopStackFrame()); }
public override string GetValueInLValueState(ResolutionContext context) { return($"({context.GetLValueTopStackFrame()}).{methodName}"); }