System\Data\Services\Client\ALinq\ExpressionNormalizer.cs (22)
115if (visited.NodeType == ExpressionType.Equal)
121visited = CreateRelationalOperator(ExpressionType.Equal, normalizedLeft, normalizedRight);
170if ((visited.NodeType == ExpressionType.Convert || visited.NodeType == ExpressionType.TypeAs) && visited.Type.IsAssignableFrom(visited.Operand.Type))
195if (input.NodeType == ExpressionType.Constant && input.Type == typeof(object))
208while (ExpressionType.Convert == input.NodeType && typeof(object) == input.Type)
221return expression.NodeType == ExpressionType.Constant &&
349return CreateRelationalOperator(ExpressionType.Equal, visited.Object, visited.Arguments[0]);
471if (expression.NodeType == ExpressionType.Quote)
481else if (expression.NodeType == ExpressionType.Lambda)
489if (lambda.Body.NodeType == ExpressionType.Coalesce && lambda.Body.Type == typeof(bool))
492if (coalesce.Right.NodeType == ExpressionType.Constant && false.Equals(((ConstantExpression)coalesce.Right).Value))
518private static BinaryExpression CreateRelationalOperator(ExpressionType op, Expression left, Expression right)
533private static bool TryCreateRelationalOperator(ExpressionType op, Expression left, Expression right, out BinaryExpression result)
539case ExpressionType.Equal:
543case ExpressionType.NotEqual:
547case ExpressionType.LessThan:
551case ExpressionType.LessThanOrEqual:
555case ExpressionType.GreaterThan:
559case ExpressionType.GreaterThanOrEqual:
582CreateRelationalOperator(ExpressionType.Equal, left, right),
585CreateRelationalOperator(ExpressionType.GreaterThan, left, right),