42 references to LambdaMethod
Microsoft.CodeAnalysis.CodeStyle (1)
SymbolSpecification.cs (1)
434CodeAnalysis.MethodKind.AnonymousFunction => nameof(CodeAnalysis.MethodKind.LambdaMethod),
Microsoft.CodeAnalysis.CSharp (9)
Compilation\CSharpSemanticModel.cs (1)
1784case MethodSymbol { MethodKind: MethodKind.LambdaMethod }:
Compilation\MemberSemanticModel.cs (1)
2306Debug.Assert(symbol is LocalSymbol or ParameterSymbol or MethodSymbol { MethodKind: MethodKind.LambdaMethod });
Compilation\SyntaxTreeSemanticModel.cs (1)
2381Debug.Assert(symbol is LocalSymbol or ParameterSymbol or MethodSymbol { MethodKind: MethodKind.LambdaMethod });
Lowering\ClosureConversion\ClosureConversion.cs (2)
429originalMethod.MethodKind == MethodKind.LambdaMethod && 843var loweredSymbol = (node.Method.MethodKind is MethodKind.LambdaMethod or MethodKind.LocalFunction) ?
Symbols\Source\ParameterHelpers.cs (1)
208Debug.Assert(methodOwner?.MethodKind != MethodKind.LambdaMethod);
Symbols\Source\SourceComplexParameterSymbol.cs (1)
1336if (!ContainingSymbol.RequiresInstanceReceiver() || ContainingSymbol is MethodSymbol { MethodKind: MethodKind.Constructor or MethodKind.DelegateInvoke or MethodKind.LambdaMethod })
Symbols\Source\SourceMethodSymbolWithAttributes.cs (1)
1114if (this.MethodKind != MethodKind.LambdaMethod)
Symbols\Symbol_Attributes.cs (1)
652Debug.Assert(!binder.InAttributeArgument || this is MethodSymbol { MethodKind: MethodKind.LambdaMethod or MethodKind.LocalFunction }, "Possible cycle in attribute binding");
Microsoft.CodeAnalysis.CSharp.CodeStyle (1)
CastSimplifier.cs (1)
1028method.MethodKind is not (MethodKind.LocalFunction or MethodKind.LambdaMethod) &&
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (4)
Semantics\DelegateTypeTests.cs (3)
902Assert.Equal(MethodKind.LambdaMethod, method.MethodKind); 945Assert.Equal(MethodKind.LambdaMethod, method.MethodKind); 5343Assert.Equal(MethodKind.LambdaMethod, method.MethodKind);
Semantics\LambdaTests.cs (1)
5606Assert.Equal(MethodKind.LambdaMethod, method.MethodKind);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (3)
Symbols\Source\NullablePublicAPITests.cs (3)
3492Assert.Equal(MethodKind.LambdaMethod, lambdaSymbol.MethodKind); 3545Assert.Equal(MethodKind.LambdaMethod, innerLambdaSymbol.MethodKind); 3606Assert.Equal(MethodKind.LambdaMethod, innerLambdaSymbol.MethodKind);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (1)
Syntax\LambdaUtilitiesTests.cs (1)
49bool expected = enclosingMethod.MethodKind == MethodKind.LambdaMethod && enclosingSyntax.Span.Contains(span.Value);
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
CastSimplifier.cs (1)
1028method.MethodKind is not (MethodKind.LocalFunction or MethodKind.LambdaMethod) &&
Microsoft.CodeAnalysis.Features (1)
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (1)
5530if (containingLambda?.MethodKind is MethodKind.LambdaMethod or MethodKind.LocalFunction)
Microsoft.CodeAnalysis.VisualBasic (15)
Analysis\FlowAnalysis\DataFlowPass.vb (3)
1257Debug.Assert(MethodSymbol.MethodKind = MethodKind.Ordinary OrElse MethodSymbol.MethodKind = MethodKind.LambdaMethod) 1269Debug.Assert(MethodSymbol.MethodKind = MethodKind.Ordinary OrElse MethodSymbol.MethodKind = MethodKind.LambdaMethod) 1315Case MethodKind.LambdaMethod
Binding\Binder_Statements.vb (6)
1844If DirectCast(altSymbol.ContainingSymbol, MethodSymbol).MethodKind = MethodKind.LambdaMethod Then 5010Debug.Assert(Me.ContainingMember.Kind = SymbolKind.Method AndAlso DirectCast(Me.ContainingMember, MethodSymbol).MethodKind = MethodKind.LambdaMethod) 5021Debug.Assert(Me.ContainingMember.Kind = SymbolKind.Method AndAlso DirectCast(Me.ContainingMember, MethodSymbol).MethodKind = MethodKind.LambdaMethod) 5051Debug.Assert(Me.ContainingMember.Kind = SymbolKind.Method AndAlso DirectCast(Me.ContainingMember, MethodSymbol).MethodKind = MethodKind.LambdaMethod) 5119Debug.Assert(Me.ContainingMember.Kind = SymbolKind.Method AndAlso DirectCast(Me.ContainingMember, MethodSymbol).MethodKind = MethodKind.LambdaMethod) 5131Debug.Assert(Me.ContainingMember.Kind = SymbolKind.Method AndAlso DirectCast(Me.ContainingMember, MethodSymbol).MethodKind = MethodKind.LambdaMethod)
Lowering\Diagnostics\DiagnosticsPass.vb (1)
109If _containingSymbol.MethodKind = MethodKind.LambdaMethod Then
Lowering\LambdaRewriter\LambdaRewriter.Analysis.vb (2)
405If _currentParent.MethodKind <> MethodKind.LambdaMethod Then 432Loop While parent.MethodKind = MethodKind.LambdaMethod AndAlso parent IsNot container
Symbols\Source\LambdaSymbol.vb (1)
274Return MethodKind.LambdaMethod
Symbols\Source\LocalSymbol.vb (1)
155Debug.Assert((Me.IsFunctionValue AndAlso _container.Kind = SymbolKind.Method AndAlso DirectCast(_container, MethodSymbol).MethodKind = MethodKind.LambdaMethod) OrElse type.Equals(ComputeType()))
Symbols\Source\OverrideHidingHelper.vb (1)
497Case MethodKind.LambdaMethod, MethodKind.Constructor, MethodKind.SharedConstructor
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (4)
DeclaringSyntaxNodeTests.vb (1)
134Assert.Equal(MethodKind.LambdaMethod, sym.MethodKind)
Semantics\AnonymousTypesTests.vb (3)
1501Assert.Equal(MethodKind.LambdaMethod, lambda2.MethodKind) 1546Assert.Equal(MethodKind.LambdaMethod, lambda2.MethodKind) 1591Assert.Equal(MethodKind.LambdaMethod, lambda2.MethodKind)
Microsoft.CodeAnalysis.Workspaces (1)
SymbolSpecification.cs (1)
434CodeAnalysis.MethodKind.AnonymousFunction => nameof(CodeAnalysis.MethodKind.LambdaMethod),
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
CodeStyle\NamingStylePreferencesUpgradeTests.cs (1)
191[InlineData(typeof(MethodKind), nameof(MethodKind.AnonymousFunction), nameof(MethodKind.LambdaMethod), nameof(MethodKind.SharedConstructor), nameof(MethodKind.StaticConstructor))]