internal static BinaryExpr Bound(Expr Left, Token t, Expr Right, BinaryOperatorKind kind, bool logic, BindOptions options) { var e = new BinaryExpr(Left, t, Right); e.Symbol = Binder.BindBinaryOperation(e, kind, options); e.Datatype = e.Symbol.Type(); return(e); }
internal static new BinaryExpr Bound(Expr Left, Token t, Expr Right, BinaryOperatorKind kind, BindOptions options) { Left.RequireGetAccess(); Right.RequireGetAccess(); var e = new BinaryExpr(Left, t, Right); e.Symbol = Binder.BindBinaryOperation(e, kind, options | BindOptions.Logic); e.Datatype = e.Symbol.Type(); return(e); }
internal override Node Bind(Binder b) { b.Bind(ref Left); b.Bind(ref Right); Left.RequireGetAccess(); Right.RequireGetAccess(); if (BinaryOperatorSymbol.OperatorIsLogic(Kind)) { Symbol = b.BindBinaryLogicOperation(this, BinaryOperatorSymbol.OperatorKind(Kind)); } else { Symbol = b.BindBinaryOperation(this, BinaryOperatorSymbol.OperatorKind(Kind)); } Datatype = Symbol.Type(); return(null); }