2 writes to Method
Microsoft.CodeAnalysis.CSharp (2)
Binder\Semantics\Operators\BinaryOperatorSignature.cs (2)
38this.Method = null; 49this.Method = method;
54 references to Method
Microsoft.CodeAnalysis.CSharp (54)
Binder\Binder.ValueChecks.cs (4)
3716(compoundAssignmentOperator.Operator.Method is not { } compoundMethod || 4086(compoundAssignmentOperator.Operator.Method is not { } compoundMethod || 4497if (compound.Operator.Method is { } compoundMethod) 5291if (compound.Operator.Method is { } compoundMethod)
Binder\Binder_Operators.cs (16)
191CheckConstraintLanguageVersionAndRuntimeSupportForOperator(node, bestSignature.Method, 201bestSignature.Method, 771CheckConstraintLanguageVersionAndRuntimeSupportForOperator(node, signature.Method, 835signature.Method, 874bool isNullableEquality = (object)signature.Method == null && 1155_ = CheckConstraintLanguageVersionAndRuntimeSupportForOperator(node, signature.Method, isUnsignedRightShift: false, signature.ConstrainedToTypeOpt, diagnostics) && 1179signature.Method, 1194Debug.Assert(!(signature.Method?.ContainingType?.IsInterface ?? false)); 1202signature.Method, 1341NamedTypeSymbol t = (NamedTypeSymbol)signature.Method.ContainingType; 1351(t.IsInterface && (signature.Method.IsAbstract || signature.Method.IsVirtual) && 1352SourceUserDefinedOperatorSymbol.IsSelfConstrainedTypeParameter((definition = signature.Method.OriginalDefinition).ReturnType.StrippedType(), definition.ContainingType)); 1359Error(diagnostics, ErrorCode.ERR_BadBoolOp, syntax, signature.Method); 1384Error(diagnostics, ErrorCode.ERR_MustHaveOpTF, syntax, signature.Method, t); 1558if (possiblyBest is { HasValue: true, Signature: { Method: { } bestMethod } })
Binder\RefSafetyAnalysis.cs (1)
552if (!node.HasErrors && node.Operator.Method is { } compoundMethod)
Binder\Semantics\Operators\BinaryOperatorAnalysisResult.cs (1)
40MethodSymbol IMemberResolutionResultWithPriority<MethodSymbol>.MemberWithPriority => Signature.Method;
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (5)
944if (SourceMemberContainerTypeSymbol.DoOperatorsPair(signature1.Method, operators2[i].Method)) 1323if ((object)op1.Method != null) 1325var p = op1.Method.OriginalDefinition.GetParameters(); 1340if ((object)op2.Method != null) 1342var p = op2.Method.OriginalDefinition.GetParameters();
Binder\Semantics\Operators\BinaryOperatorSignature.cs (15)
66this.Method == other.Method; 89Hash.Combine(Method, (int)Kind)))); 96if ((object)Method != null && Method.IsStatic) 98Debug.Assert(Method.ParameterCount == 2); 100if (!Method.ParameterRefKinds.IsDefaultOrEmpty) 102Debug.Assert(Method.ParameterRefKinds.Length == 2); 104return Method.ParameterRefKinds[0]; 116if ((object)Method != null) 118int rightIndex = Method.IsStatic ? 1 : 0; 120Debug.Assert(Method.ParameterCount == rightIndex + 1); 122if (!Method.ParameterRefKinds.IsDefaultOrEmpty) 124Debug.Assert(Method.ParameterRefKinds.Length == rightIndex + 1); 126return Method.ParameterRefKinds[rightIndex];
BoundTree\BoundExpression.cs (1)
447get { return this.Operator.Method; }
Compilation\CSharpSemanticModel.cs (2)
3932GetSymbolsAndResultKind(compoundAssignment, compoundAssignment.Operator.Method, compoundAssignment.OriginalUserDefinedOperatorsOpt, out symbols, out resultKind); 3937Debug.Assert((object)compoundAssignment.Operator.Method == null && compoundAssignment.OriginalUserDefinedOperatorsOpt.IsDefaultOrEmpty);
FlowAnalysis\NullableWalker.cs (2)
10911if (node.Operator.Method is { } method) 10942node.Operator.Method,
Lowering\LocalRewriter\LocalRewriter_CompoundAssignmentOperator.cs (6)
26if (node.Operator.Method?.IsStatic == false) 38Debug.Assert(node.Operator.Method is { }); 44return BoundCall.Synthesized(syntax, VisitExpression(node.Left), initialBindingReceiverIsSubjectToCloning: ThreeState.False, node.Operator.Method, VisitExpression(node.Right)); 60sideEffects: [tempAssignment, BoundCall.Synthesized(syntax, targetOfCompoundOperation, initialBindingReceiverIsSubjectToCloning: ThreeState.False, node.Operator.Method, VisitExpression(node.Right))], 65return MakeInstanceCompoundAssignmentOperatorResult(node.Syntax, node.Left, node.Right, node.Operator.Method, node.Operator.Kind.IsChecked()); 199operand = MakeBinaryOperator(syntax, node.Operator.Kind, opLHS, loweredRight, node.Operator.ReturnType, node.Operator.Method, node.Operator.ConstrainedToTypeOpt, isCompoundAssignment: true);
Operations\CSharpOperationFactory.cs (1)
1363var method = boundCompoundAssignmentOperator.Operator.Method;