private void CheckAndCastOperands() { if (this.expr == null || this.refference == null) { return; } Symatic.PostfixOperator t_op = Symatic.PostfixOperator.DOT; switch (this.op.type) { case Token.Type.OP_REF: t_op = Symatic.PostfixOperator.REF; break; case Token.Type.OP_DOT: t_op = Symatic.PostfixOperator.DOT; break; case Token.Type.LBRACKET: t_op = Symatic.PostfixOperator.INDEX; break; default: throw new NotImplementedException(); } Symatic.BinaryConvertResult res = Symatic .PostfixConvertResult(this.expr, this.refference, t_op); this.type = res.type; this.lvalue = res.lvalue; }
public void SetOperand(Expression operand) { Object.CheckObject(operand); this.operand = operand; Symatic.UnaryConvertResult res = Symatic.ConvertUnaryOperand(this.operand, this.op); this.lvalue = res.lvalue; this.type = res.type; }
private void Check() { if (this.arguments == null || this.operand == null) { return; } Symatic.CheckCallFunction(this.operand, this.arguments); }
public override Expression Modified() { Symatic.BinaryConvertResult res = Symatic.ConvertBinaryOperands(this.left_operand, this.right_operand, this.op); this.left_operand = res.left.Modified(); this.right_operand = res.right.Modified(); this.op = res.op; return(this); }
private void CheckAndCastOperands() { if (this.left_operand == null || this.right_operand == null) { return; } Symatic.BinaryConvertResult res = Symatic .ConvertBinaryOperands(this.left_operand, this.right_operand, this.op); this.type = res.type; this.lvalue = res.lvalue; }