UnhandledBinary() static private method

ArgumentException with message like "Unhandled binary: {0}"
static private UnhandledBinary ( object p0, string paramName ) : Exception
p0 object
paramName string
return Exception
        /// <summary>
        /// Creates an expression representing a binary assignment operation.
        /// </summary>
        /// <param name="binaryType">The type of assignment represented.</param>
        /// <param name="left">The left operand of the assignment operation, i.e. the assignment target.</param>
        /// <param name="right">The right operation of the assignment operation.</param>
        /// <param name="method">The method implementing the assignment operation.</param>
        /// <param name="leftConversion">The conversion function used to convert the left hand side of the compound assignment prior to use by the underlying operation.</param>
        /// <param name="finalConversion">The conversion function used to convert the result of the underlying operation prior to assignment to the left hand side of the compound assignment operation.</param>
        /// <returns>A new <see cref="AssignBinaryCSharpExpression"/> instance representing the binary assignment.</returns>
        public static AssignBinaryCSharpExpression MakeBinaryAssign(CSharpExpressionType binaryType, Expression left, Expression right, MethodInfo method, LambdaExpression leftConversion, LambdaExpression finalConversion)
        {
            switch (binaryType)
            {
            case CSharpExpressionType.Assign:
                return(Assign(left, right));

            case CSharpExpressionType.AddAssign:
                return(AddAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.AndAssign:
                return(AndAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.DivideAssign:
                return(DivideAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.ExclusiveOrAssign:
                return(ExclusiveOrAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.LeftShiftAssign:
                return(LeftShiftAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.ModuloAssign:
                return(ModuloAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.MultiplyAssign:
                return(MultiplyAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.OrAssign:
                return(OrAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.RightShiftAssign:
                return(RightShiftAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.SubtractAssign:
                return(SubtractAssign(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.AddAssignChecked:
                return(AddAssignChecked(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.MultiplyAssignChecked:
                return(MultiplyAssignChecked(left, right, method, leftConversion, finalConversion));

            case CSharpExpressionType.SubtractAssignChecked:
                return(SubtractAssignChecked(left, right, method, leftConversion, finalConversion));
            }

            throw LinqError.UnhandledBinary(binaryType);
        }
        internal static BinaryExpression FunctionalOp(CSharpExpressionType binaryType, Expression left, Expression right, MethodInfo method)
        {
            switch (binaryType)
            {
            case CSharpExpressionType.Assign:
                return(Expression.Assign(left, right));

            case CSharpExpressionType.AddAssign:
                return(Expression.Add(left, right, method));

            case CSharpExpressionType.AndAssign:
                return(Expression.And(left, right, method));

            case CSharpExpressionType.DivideAssign:
                return(Expression.Divide(left, right, method));

            case CSharpExpressionType.ExclusiveOrAssign:
                return(Expression.ExclusiveOr(left, right, method));

            case CSharpExpressionType.LeftShiftAssign:
                return(Expression.LeftShift(left, right, method));

            case CSharpExpressionType.ModuloAssign:
                return(Expression.Modulo(left, right, method));

            case CSharpExpressionType.MultiplyAssign:
                return(Expression.Multiply(left, right, method));

            case CSharpExpressionType.OrAssign:
                return(Expression.Or(left, right, method));

            case CSharpExpressionType.RightShiftAssign:
                return(Expression.RightShift(left, right, method));

            case CSharpExpressionType.SubtractAssign:
                return(Expression.Subtract(left, right, method));

            case CSharpExpressionType.AddAssignChecked:
                return(Expression.AddChecked(left, right, method));

            case CSharpExpressionType.MultiplyAssignChecked:
                return(Expression.MultiplyChecked(left, right, method));

            case CSharpExpressionType.SubtractAssignChecked:
                return(Expression.SubtractChecked(left, right, method));
            }

            throw LinqError.UnhandledBinary(binaryType);
        }