Esempio n. 1
0
        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)));
        }
Esempio n. 2
0
        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));
        }
Esempio n. 3
0
 public override Expression GetValueInLValueState(ResolutionContext context)
 {
     return(context.GetLValueTopStackFrame());
 }
Esempio n. 4
0
 public override string GetValueInLValueState(ResolutionContext context)
 {
     return($"({context.GetLValueTopStackFrame()}).{methodName}");
 }