78 references to Operator
Microsoft.CodeAnalysis.CSharp (78)
Binder\Binder_Operators.cs (9)
35BinaryOperatorKind kindOperator = kind.Operator(); 180isUnsignedRightShift: bestSignature.Kind.Operator() == BinaryOperatorKind.UnsignedRightShift, bestSignature.ConstrainedToTypeOpt, diagnostics); 627isUnsignedRightShift: resultOperatorKind.Operator() == BinaryOperatorKind.UnsignedRightShift, signature.ConstrainedToTypeOpt, diagnostics); 700(signature.Kind.Operator() == BinaryOperatorKind.Equal || signature.Kind.Operator() == BinaryOperatorKind.NotEqual) && 1712BinaryOperatorKind newKind = kind.Operator().WithType(newLeftOperand.Type!.SpecialType); 1714switch (newKind.Operator()) 1734throw ExceptionUtilities.UnexpectedValue(newKind.Operator()); 1912BinaryOperatorKind op = kind.Operator();
Binder\DecisionDagBuilder.cs (3)
684var values = fac?.Related(rel.Relation.Operator(), rel.ConstantValue); 1113IValueSet fromTestPassing = valueFac.Related(relation.Operator(), value); 1718var operatorName = r.Relation.Operator() switch
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (4)
376switch (OperatorKindExtensions.Operator(kind)) 734if (kind.Operator() is BinaryOperatorKind.Addition && 804Debug.Assert(op.Signature.Kind.Operator() == existingSignature.Kind.Operator());
Binder\Semantics\Operators\OperatorKindExtensions.cs (8)
129return ((int)kind.Operator() >> 8) - 16; 202switch (kind.Operator()) 227switch (kind.Operator()) 251switch (kind.Operator()) 332BinaryOperatorKind type = kind.Operator(); 340switch (kind.Operator()) 356switch (kind.Operator()) 377throw ExceptionUtilities.UnexpectedValue(kind.Operator());
BoundTree\BoundDagRelationalTest.cs (1)
9public BinaryOperatorKind Relation => OperatorKind.Operator();
BoundTree\BoundDagTest.cs (1)
92var operatorName = r.Relation.Operator() switch
BoundTree\BoundDecisionDag.cs (1)
189return f.Related(d.Relation.Operator(), inputConstant, d.Value);
CodeGen\EmitOperators.cs (7)
177switch (expression.OperatorKind.Operator()) 245throw ExceptionUtilities.UnexpectedValue(expression.OperatorKind.Operator()); 577switch (expression.OperatorKind.Operator() | expression.OperatorKind.OperandTypes()) 628switch (expression.OperatorKind.Operator()) 664throw ExceptionUtilities.UnexpectedValue(expression.OperatorKind.Operator()); 670switch (kind.Operator()) 707Debug.Assert(opKind.Operator() != BinaryOperatorKind.UnsignedRightShift);
CodeGen\EmitStatement.cs (3)
230var opKind = condition.OperatorKind.Operator(); 303switch (op.OperatorKind.Operator()) 330throw ExceptionUtilities.UnexpectedValue(op.OperatorKind.Operator());
Compilation\BuiltInOperators.cs (1)
708switch (kind.Operator())
Compilation\CSharpSemanticModel.cs (2)
3831BinaryOperatorKind op = binaryOperator.OperatorKind.Operator(); 3904BinaryOperatorKind op = compoundAssignment.Operator.Kind.Operator();
FlowAnalysis\AbstractFlowPass.cs (3)
2281var op = kind.Operator(); 2432return kind.Operator() is BinaryOperatorKind.Equal or BinaryOperatorKind.NotEqual 2444=> binary.OperatorKind.Operator() == BinaryOperatorKind.Equal;
FlowAnalysis\NullableWalker.cs (6)
4432switch (operatorKind.Operator() | operatorKind.OperandTypes()) 4465&& binary.OperatorKind.Operator() is BinaryOperatorKind.Equal or BinaryOperatorKind.NotEqual) 4536=> binary.OperatorKind.Operator() == BinaryOperatorKind.Equal; 4568if (binary.OperatorKind.Operator() is not (BinaryOperatorKind.Equal or BinaryOperatorKind.NotEqual)) 4729&& binary.OperatorKind.Operator() is BinaryOperatorKind.GreaterThan or BinaryOperatorKind.GreaterThanOrEqual or BinaryOperatorKind.LessThan or BinaryOperatorKind.LessThanOrEqual) 4774BinaryOperatorKind op = binary.OperatorKind.Operator();
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (2)
393switch (opKind.Operator()) 412throw ExceptionUtilities.UnexpectedValue(opKind.Operator());
Lowering\DiagnosticsPass_ExpressionTrees.cs (1)
643var unary = node.OperatorKind.Operator() == BinaryOperatorKind.And ? node.FalseOperator : node.TrueOperator;
Lowering\DiagnosticsPass_Warnings.cs (5)
278if (_inExpressionLambda && node.OperatorKind.Operator() == BinaryOperatorKind.UnsignedRightShift) 756switch (node.OperatorKind.Operator()) 765string always = node.OperatorKind.Operator() == BinaryOperatorKind.NotEqual ? "true" : "false"; 789switch (node.OperatorKind.Operator()) 814string always = node.OperatorKind.Operator() == BinaryOperatorKind.NotEqual ? "true" : "false";
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (1)
649op = op.Operator();
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.ValueDispatchNode.cs (2)
95public override string ToString() => $"RelationalDispatch.{Height}({Left} {Operator.Operator()} {Value} {Right})"; 100private static bool IsReversed(BinaryOperatorKind op) => op.Operator() switch { BinaryOperatorKind.GreaterThan => true, BinaryOperatorKind.GreaterThanOrEqual => true, _ => false };
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (1)
406Debug.Assert(operatorKind.Operator() == BinaryOperatorKind.Equal);
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (12)
87operatorKind.Operator() == BinaryOperatorKind.And ? node.FalseOperator : node.TrueOperator, boundTemp); 204switch (operatorKind.Operator() | operatorKind.OperandTypes()) 564if (operatorKind.Operator() == BinaryOperatorKind.NotEqual || 565operatorKind.Operator() == BinaryOperatorKind.Equal) 604Debug.Assert(operatorKind.Operator() == BinaryOperatorKind.And || operatorKind.Operator() == BinaryOperatorKind.Or); 615bool isAnd = operatorKind.Operator() == BinaryOperatorKind.And; 803return MakeLiteral(syntax, ConstantValue.Create(kind.Operator() == BinaryOperatorKind.Equal), boolType); 826BinaryOperatorKind operatorKind = kind.Operator(); 987BinaryOperatorKind operatorKind = kind.Operator(); 1140BinaryOperatorKind operatorKind = kind.Operator(); 2191Debug.Assert(kind.Operator() == BinaryOperatorKind.Addition);
Lowering\LocalRewriter\LocalRewriter_CompoundAssignmentOperator.cs (1)
33var binaryOperator = kind.Operator();
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (2)
793switch (oper.Operator()) 798throw ExceptionUtilities.UnexpectedValue(oper.Operator());
Operations\CSharpOperationFactory.cs (2)
1420IMethodSymbol unaryOperatorMethod = boundBinaryOperator.OperatorKind.Operator() == CSharp.BinaryOperatorKind.And ? 1431GetConstrainedToTypeForOperator(boundBinaryOperator.OperatorKind.Operator() == CSharp.BinaryOperatorKind.And ?