Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ GetMethodBasedAssignOperator()

static BinaryExpression System.Linq.Expressions.Expression< TDelegate >.GetMethodBasedAssignOperator ( ExpressionType binaryType,
Expression< TDelegate > left,
Expression< TDelegate > right,
MethodInfo method,
LambdaExpression< TDelegate > conversion,
bool liftToNull )
inlinestaticprivateinherited

Definition at line 768 of file Expression.cs.

769 {
771 if (conversion == null)
772 {
774 {
775 throw Error.UserDefinedOpMustHaveValidReturnType(binaryType, binaryExpression.Method.Name);
776 }
777 }
778 else
779 {
781 binaryExpression = new OpAssignMethodConversionBinaryExpression(binaryExpression.NodeType, binaryExpression.Left, binaryExpression.Right, binaryExpression.Left.Type, binaryExpression.Method, conversion);
782 }
783 return binaryExpression;
784 }
static bool AreReferenceAssignable(Type dest, Type src)
Definition TypeUtils.cs:673
static void ValidateOpAssignConversionLambda(LambdaExpression conversion, Expression left, MethodInfo method, ExpressionType nodeType)
static BinaryExpression GetMethodBasedBinaryOperator(ExpressionType binaryType, Expression left, Expression right, MethodInfo method, bool liftToNull)

References System.Dynamic.Utils.TypeUtils.AreReferenceAssignable(), System.Linq.Expressions.Expression< TDelegate >.GetMethodBasedBinaryOperator(), System.Linq.Expressions.Error.UserDefinedOpMustHaveValidReturnType(), and System.Linq.Expressions.Expression< TDelegate >.ValidateOpAssignConversionLambda().

Referenced by System.Linq.Expressions.Expression< TDelegate >.AddAssign(), System.Linq.Expressions.Expression< TDelegate >.AddAssignChecked(), System.Linq.Expressions.Expression< TDelegate >.AndAssign(), System.Linq.Expressions.Expression< TDelegate >.DivideAssign(), System.Linq.Expressions.Expression< TDelegate >.ExclusiveOrAssign(), System.Linq.Expressions.Expression< TDelegate >.LeftShiftAssign(), System.Linq.Expressions.Expression< TDelegate >.ModuloAssign(), System.Linq.Expressions.Expression< TDelegate >.MultiplyAssign(), System.Linq.Expressions.Expression< TDelegate >.MultiplyAssignChecked(), System.Linq.Expressions.Expression< TDelegate >.OrAssign(), System.Linq.Expressions.Expression< TDelegate >.PowerAssign(), System.Linq.Expressions.Expression< TDelegate >.RightShiftAssign(), System.Linq.Expressions.Expression< TDelegate >.SubtractAssign(), and System.Linq.Expressions.Expression< TDelegate >.SubtractAssignChecked().