1 write to Method
Microsoft.CodeAnalysis.CSharp (1)
Generated\BoundNodes.xml.Generated.cs (1)
6041this.Method = method;
109 references to Method
Microsoft.CodeAnalysis.CSharp (109)
Binder\Binder.ValueChecks.cs (17)
705return CheckMethodReturnValueKind(call.Method, call.Syntax, node, valueKind, checkingReceiver, diagnostics); 723return CheckMethodReturnValueKind(sliceAccess.Method, sliceAccess.Syntax, node, valueKind, checkingReceiver, diagnostics); 3013var methodSymbol = call.Method; 3020call.Method, 3092var methodSymbol = call.Method; 3099call.Method, 3258var methodSymbol = call.Method; 3338var methodSymbol = call.Method; 3584call.Method, 3586call.Method.Parameters, 3650call.Method, 3652call.Method.Parameters, 4007var methodSymbol = call.Method; 4091var methodSymbol = call.Method; 4533if (part is not BoundCall { Method.Name: BoundInterpolatedString.AppendFormattedMethod } call) 4547call.Method.Parameters[0].EffectiveScope == ScopedKind.ScopedValue) 4640var methodRefKind = ((BoundCall)expression).Method.RefKind;
Binder\Binder_Await.cs (4)
95if ((object)call.Method != null && call.Method.IsAsync) 347var getAwaiterMethod = ((BoundCall)getAwaiterCall).Method; 454getResultMethod = ((BoundCall)getAwaiterGetResultCall).Method;
Binder\Binder_Deconstruct.cs (1)
683var deconstructMethod = ((BoundCall)result).Method;
Binder\Binder_Expressions.cs (1)
5552boundCall.Method,
Binder\Binder_InterpolatedString.cs (1)
815if (call is BoundCall { Method: { ReturnType: var returnType } method })
Binder\Binder_Invocation.cs (3)
886if (call.ReceiverOpt.Type.IsRestrictedType() && !TypeSymbol.Equals(call.Method.ContainingType, call.ReceiverOpt.Type, TypeCompareKind.ConsiderEverything2)) 888SymbolDistinguisher distinguisher = new SymbolDistinguisher(compilation, call.ReceiverOpt.Type, call.Method.ContainingType); 894SymbolDistinguisher distinguisher = new SymbolDistinguisher(compilation, this.ContainingType, call.Method.ContainingType);
Binder\Binder_Query.cs (4)
328result.ReceiverOpt, result.Method, arguments.ToImmutableAndFree(), argumentNamesOpt: default, 472invocation = invocation.Update(invocation.ReceiverOpt, invocation.Method, arguments); 541invocation = invocation.Update(invocation.ReceiverOpt, invocation.Method, arguments); 631invocation.Method,
Binder\Binder_Statements.cs (2)
1716BoundImplicitIndexerAccess { IndexerOrSliceAccess: BoundCall call } => call.Method, 4061var patternMethodSymbol = call.Method;
Binder\RefSafetyAnalysis.cs (2)
588var method = node.Method; 752var deconstructMethod = invocation.Method;
Binder\Semantics\Conversions\Conversion.cs (1)
439return call.Method;
BoundTree\BoundExpression.cs (1)
238return this.Method;
BoundTree\BoundExpressionExtensions.cs (1)
34return ((BoundCall)node).Method.RefKind;
BoundTree\BoundNode_Source.cs (1)
206append(call.Method.Name);
BoundTree\BoundNodeExtensions.cs (1)
60MethodSymbol method = call!.Method;
BoundTree\BoundTreeWalker.cs (3)
38if (call != null && (object)call.Method != null) 41if (call.Method.Name == "Select") 45else if (call.Method.Name == "GroupBy")
BoundTree\Constructors.cs (1)
155return this.Update(ReceiverOpt, Method, arguments, ArgumentNamesOpt, ArgumentRefKindsOpt, IsDelegateCall, Expanded, InvokedAsExtensionMethod, ArgsToParamsOpt, DefaultArguments, ResultKind, OriginalMethodsOpt, Type);
CodeGen\EmitAddress.cs (1)
114var methodRefKind = call.Method.RefKind;
CodeGen\EmitExpression.cs (8)
1580if (call.Method.IsDefaultValueTypeConstructor()) 1584else if (!call.Method.RequiresInstanceReceiver) 1597var method = call.Method; 1617var method = call.Method; 1648var method = call.Method; 2000return ((BoundCall)receiver).Method.RefKind != RefKind.None; 2713Debug.Assert(left.Method.RefKind != RefKind.None); 2915Debug.Assert(((BoundCall)expression).Method.RefKind != RefKind.None);
CodeGen\Optimizer.cs (4)
1056Debug.Assert(((BoundCall)lhs).Method.RefKind == RefKind.Ref, "only ref returning methods are assignable"); 1110MethodSymbol method = node.Method; 2138if (node.Method.RequiresInstanceReceiver) 2159return node.Update(receiverOpt, node.Method, arguments, node.ArgumentNamesOpt, node.ArgumentRefKindsOpt, node.IsDelegateCall, node.Expanded, node.InvokedAsExtensionMethod, node.ArgsToParamsOpt, node.DefaultArguments, node.ResultKind, node.OriginalMethodsOpt, type);
Compilation\CSharpSemanticModel.cs (3)
3434if ((object)call.Method != null) 4251if (invocation != null && invocation.Expression.SkipParens() == ((ExpressionSyntax)boundNode.Syntax).SkipParens() && (object)call.Method != null) 4761var method = call.Method;
Compiler\MethodCompiler.cs (4)
1902expressionStatement.Expression is BoundCall { Method: var initMethod } && initMethod.IsDefaultValueTypeConstructor(); 2298if (ctorCall != null && !ctorCall.HasAnyErrors && ctorCall.Method != method && TypeSymbol.Equals(ctorCall.Method.ContainingType, method.ContainingType, TypeCompareKind.ConsiderEverything2)) 2301compilationState.ReportCtorInitializerCycles(method, ctorCall.Method, ctorCall.Syntax, diagnostics);
FlowAnalysis\AbstractFlowPass.cs (5)
1280bool callsAreOmitted = node.Method.CallsAreOmitted(node.SyntaxTree); 1289VisitReceiverBeforeCall(node.ReceiverOpt, node.Method); 1292if (node.Method?.OriginalDefinition is LocalFunctionSymbol localFunc) 1297VisitArgumentsAfterCall(node.Arguments, node.ArgumentRefKindsOpt, node.Method); 1298VisitReceiverAfterCall(node.ReceiverOpt, node.Method);
FlowAnalysis\NullableWalker.cs (6)
1413return constructorBody is BoundConstructorMethodBody { Initializer: BoundExpressionStatement { Expression: BoundCall { Method: { MethodKind: MethodKind.Constructor } initializerMethod } } } 5688var method = node.Method; 5712SetUpdatedSymbol(node, node.Method, method); 5967var method = node.Method; 6283if (node is BoundCall { Method: { OriginalDefinition: LocalFunctionSymbol localFunction } }) 9273var deconstructMethod = invocation?.Method;
FlowAnalysis\NullableWalker_Patterns.cs (1)
811BoundCall call => AsMemberOfType(inputType, call.Method).GetTypeOrReturnType(),
Generated\BoundNodes.xml.Generated.cs (4)
6073if (receiverOpt != this.ReceiverOpt || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(method, this.Method) || arguments != this.Arguments || argumentNamesOpt != this.ArgumentNamesOpt || argumentRefKindsOpt != this.ArgumentRefKindsOpt || isDelegateCall != this.IsDelegateCall || expanded != this.Expanded || invokedAsExtensionMethod != this.InvokedAsExtensionMethod || argsToParamsOpt != this.ArgsToParamsOpt || defaultArguments != this.DefaultArguments || resultKind != this.ResultKind || originalMethodsOpt != this.OriginalMethodsOpt || !TypeSymbol.Equals(type, this.Type, TypeCompareKind.ConsiderEverything)) 11347return node.Update(receiverOpt, node.Method, arguments, node.ArgumentNamesOpt, node.ArgumentRefKindsOpt, node.IsDelegateCall, node.Expanded, node.InvokedAsExtensionMethod, node.ArgsToParamsOpt, node.DefaultArguments, node.ResultKind, node.OriginalMethodsOpt, type); 13463MethodSymbol method = GetUpdatedSymbol(node, node.Method); 15826new TreeDumperNode("method", node.Method, null),
Lowering\ClosureConversion\ClosureConversion.Analysis.Tree.cs (2)
442if (node.Method.MethodKind == MethodKind.LocalFunction) 445AddIfCaptured(node.Method.OriginalDefinition, node.Syntax);
Lowering\ClosureConversion\ClosureConversion.cs (2)
1056if (node.Method.MethodKind == MethodKind.LocalFunction) 1066node.Method,
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (1)
576var method = node.Method;
Lowering\DiagnosticsPass_ExpressionTrees.cs (2)
441VisitCall(node.Method, null, node.Arguments, node.ArgumentRefKindsOpt, node.ArgumentNamesOpt, node.DefaultArguments, node); 443CheckReferenceToMethodIfLocalFunction(node, node.Method);
Lowering\LocalRewriter\LocalRewriter.cs (1)
960return ((BoundCall)expr).Method.RefKind != RefKind.None;
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (2)
155node.Method.MethodKind == MethodKind.LocalFunction || 159MethodMayMutateReceiver(node.ReceiverOpt, node.Method);
Lowering\LocalRewriter\LocalRewriter_Call.cs (2)
149node.Method, 158method: node.Method,
Lowering\LocalRewriter\LocalRewriter_CompoundAssignmentOperator.cs (2)
687Debug.Assert(((BoundCall)originalLHS).Method.RefKind != RefKind.None); 900var method = call.Method;
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (2)
1229if (call.Method.ReturnType.IsValidNullableTypeArgument()) 1231Debug.Assert(resultType.IsNullableType() && TypeSymbol.Equals(resultType.GetNullableUnderlyingType(), call.Method.ReturnType, TypeCompareKind.ConsiderEverything2));
Lowering\LocalRewriter\LocalRewriter_ExpressionStatement.cs (1)
64if (call.Method.CallsAreOmitted(call.SyntaxTree))
Lowering\LocalRewriter\LocalRewriter_NullCoalescingOperator.cs (1)
190var method = boundCall.Method;
Lowering\LocalRewriter\LocalRewriter_StringConcat.cs (1)
160var method = boundCall.Method;
Lowering\MethodToClassRewriter.cs (3)
231var rewrittenMethodSymbol = VisitMethodSymbol(node.Method); 236Debug.Assert(rewrittenMethodSymbol.IsMetadataVirtual() == node.Method.IsMetadataVirtual()); 240if (BaseReferenceInReceiverWasRewritten(node.ReceiverOpt, rewrittenReceiver) && node.Method.IsMetadataVirtual())
Lowering\SpillSequenceSpiller.cs (2)
955else if (node.Method.RequiresInstanceReceiver) 997return UpdateExpression(builder, node.Update(receiver, node.Method, arguments));
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (2)
608Debug.Assert(call.Method.RefKind != RefKind.None); 609F.Diagnostics.Add(ErrorCode.ERR_RefReturningCallAndAwait, F.Syntax.Location, call.Method);
Operations\CSharpOperationFactory.cs (2)
439MethodSymbol targetMethod = boundCall.Method; 2333BoundCall { Method.Name: var name } => name,
Operations\CSharpOperationFactory_Methods.cs (1)
243return DeriveArguments(boundCall.Method,