194 references to LocalFunctionStatement
Microsoft.CodeAnalysis.CSharp (20)
Binder\Binder_Statements.cs (3)
47
if (node.Kind() == SyntaxKind.
LocalFunctionStatement
)
69
case SyntaxKind.
LocalFunctionStatement
:
343
case SyntaxKind.
LocalFunctionStatement
:
Binder\LocalBinderFactory.cs (1)
1043
case SyntaxKind.
LocalFunctionStatement
:
Binder\LocalScopeBinder.cs (2)
225
case SyntaxKind.
LocalFunctionStatement
:
318
if (innerStatement.Kind() == SyntaxKind.
LocalFunctionStatement
)
Compilation\CSharpSemanticModel.cs (1)
5087
case SyntaxKind.
LocalFunctionStatement
:
Compilation\MemberSemanticModel.cs (3)
251
else if (kind == SyntaxKind.
LocalFunctionStatement
)
850
else if (paramList.Parent.Kind() == SyntaxKind.
LocalFunctionStatement
)
1554
if (current.Parent == null || current.Parent.Kind() != SyntaxKind.
LocalFunctionStatement
)
Parser\LanguageParser.cs (1)
2861
case SyntaxKind.
LocalFunctionStatement
:
Syntax\LambdaUtilities.cs (5)
31
case SyntaxKind.
LocalFunctionStatement
:
61
Debug.Assert(lambda.IsKind(SyntaxKind.
LocalFunctionStatement
));
115
case SyntaxKind.
LocalFunctionStatement
:
155
case SyntaxKind.
LocalFunctionStatement
:
349
case SyntaxKind.
LocalFunctionStatement
:
Syntax\LookupPosition.cs (2)
365
case SyntaxKind.
LocalFunctionStatement
:
441
case SyntaxKind.
LocalFunctionStatement
:
Syntax\SyntaxFacts.cs (2)
187
case
LocalFunctionStatement
:
566
=> kind is SyntaxKind.
LocalFunctionStatement
Microsoft.CodeAnalysis.CSharp.CodeStyle (9)
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticDiagnosticAnalyzer.cs (1)
33
context.RegisterSyntaxNodeAction(AnalyzeSyntax, SyntaxKind.
LocalFunctionStatement
);
src\Analyzers\CSharp\Analyzers\NamingStyle\CSharpNamingStyleDiagnosticAnalyzer.cs (1)
23
SyntaxKind.
LocalFunctionStatement
,
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\RemoveUnreachableCodeHelpers.cs (1)
76
if (currentStatement.IsKind(SyntaxKind.
LocalFunctionStatement
))
src\Analyzers\CSharp\Analyzers\UseExpressionBody\Helpers\UseExpressionBodyForLocalFunctionHelper.cs (1)
28
[SyntaxKind.
LocalFunctionStatement
])
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ILocalSymbolExtensions.cs (1)
17
.FirstOrDefault(node => node.Kind() is SyntaxKind.
LocalFunctionStatement
or SyntaxKind.MethodDeclaration);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxNodeExtensions.cs (1)
431
case SyntaxKind.
LocalFunctionStatement
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\NewLineUserSettingFormattingRule.cs (2)
198
if (currentToken.IsKind(SyntaxKind.OpenBraceToken) && currentTokenParentParent.IsKind(SyntaxKind.
LocalFunctionStatement
))
412
if (currentToken.IsKind(SyntaxKind.OpenBraceToken) && currentTokenParentParent.IsKind(SyntaxKind.
LocalFunctionStatement
))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
145
public int? LocalFunctionStatement => (int)SyntaxKind.
LocalFunctionStatement
;
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\Analyzers\CSharp\CodeFixes\Nullable\CSharpDeclareAsNullableCodeFixProvider.cs (1)
125
SyntaxKind.
LocalFunctionStatement
or
Microsoft.CodeAnalysis.CSharp.Features (24)
ChangeSignature\CSharpChangeSignatureService.cs (2)
49
SyntaxKind.
LocalFunctionStatement
,
88
SyntaxKind.
LocalFunctionStatement
,
ConvertLinq\ConvertForEachToLinqQuery\CSharpConvertForEachToLinqQueryProvider.cs (1)
299
.Where(statement => statement.Kind() != SyntaxKind.
LocalFunctionStatement
).ToArray();
ConvertLinq\CSharpConvertLinqQueryToForEachProvider.cs (1)
936
case SyntaxKind.
LocalFunctionStatement
:
EditAndContinue\BreakpointSpans.cs (1)
418
case SyntaxKind.
LocalFunctionStatement
:
EditAndContinue\SyntaxComparer.cs (4)
542
case SyntaxKind.
LocalFunctionStatement
:
892
case SyntaxKind.
LocalFunctionStatement
:
1017
case SyntaxKind.
LocalFunctionStatement
:
1068
case SyntaxKind.
LocalFunctionStatement
:
IntroduceVariable\CSharpIntroduceVariableService_IntroduceLocal.cs (1)
386
var localFunctions = innermostCommonBlock.DescendantNodes().Where(node => node.IsKind(SyntaxKind.
LocalFunctionStatement
) && matches.Any(match => match.Span.OverlapsWith(node.Span)));
LanguageServices\CSharpSymbolDisplayService.SymbolDescriptionBuilder.cs (1)
199
if (syntax.IsKind(SyntaxKind.
LocalFunctionStatement
) || syntax is AnonymousFunctionExpressionSyntax)
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticDiagnosticAnalyzer.cs (1)
33
context.RegisterSyntaxNodeAction(AnalyzeSyntax, SyntaxKind.
LocalFunctionStatement
);
src\Analyzers\CSharp\Analyzers\NamingStyle\CSharpNamingStyleDiagnosticAnalyzer.cs (1)
23
SyntaxKind.
LocalFunctionStatement
,
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\RemoveUnreachableCodeHelpers.cs (1)
76
if (currentStatement.IsKind(SyntaxKind.
LocalFunctionStatement
))
src\Analyzers\CSharp\Analyzers\UseExpressionBody\Helpers\UseExpressionBodyForLocalFunctionHelper.cs (1)
28
[SyntaxKind.
LocalFunctionStatement
])
src\Analyzers\CSharp\CodeFixes\Nullable\CSharpDeclareAsNullableCodeFixProvider.cs (1)
125
SyntaxKind.
LocalFunctionStatement
or
src\Compilers\CSharp\Portable\Syntax\LambdaUtilities.cs (5)
31
case SyntaxKind.
LocalFunctionStatement
:
61
Debug.Assert(lambda.IsKind(SyntaxKind.
LocalFunctionStatement
));
115
case SyntaxKind.
LocalFunctionStatement
:
155
case SyntaxKind.
LocalFunctionStatement
:
349
case SyntaxKind.
LocalFunctionStatement
:
Structure\Providers\ArrowExpressionClauseStructureProvider.cs (1)
30
autoCollapse: !node.IsParentKind(SyntaxKind.
LocalFunctionStatement
)));
Structure\Providers\BlockSyntaxStructureProvider.cs (2)
96
if (parentKind == SyntaxKind.
LocalFunctionStatement
)
218
SyntaxKind.
LocalFunctionStatement
=> BlockTypes.Statement,
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (3)
Semantics\LocalFunctionTests.cs (3)
1924
var localDecl = tree.FindNodeOrTokenByKind(SyntaxKind.
LocalFunctionStatement
);
1974
var localDecl = tree.FindNodeOrTokenByKind(SyntaxKind.
LocalFunctionStatement
);
5105
var localDecl = (LocalFunctionStatementSyntax)tree.FindNodeOrTokenByKind(SyntaxKind.
LocalFunctionStatement
).AsNode();
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (5)
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (1)
3587
Assert.Equal(SyntaxKind.
LocalFunctionStatement
, methodDecl.Kind());
SymbolDisplay\SymbolDisplayTests.cs (4)
6438
.Where(n => n.Kind() == SyntaxKind.
LocalFunctionStatement
)
6481
.Where(n => n.Kind() == SyntaxKind.
LocalFunctionStatement
)
6515
.Where(n => n.Kind() == SyntaxKind.
LocalFunctionStatement
)
6610
.Where(n => n.Kind() == SyntaxKind.
LocalFunctionStatement
)
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (121)
Parsing\CollectionExpressionParsingTests.cs (23)
323
N(SyntaxKind.
LocalFunctionStatement
);
450
N(SyntaxKind.
LocalFunctionStatement
);
583
N(SyntaxKind.
LocalFunctionStatement
);
12077
N(SyntaxKind.
LocalFunctionStatement
);
12423
N(SyntaxKind.
LocalFunctionStatement
);
12490
N(SyntaxKind.
LocalFunctionStatement
);
12557
N(SyntaxKind.
LocalFunctionStatement
);
12640
N(SyntaxKind.
LocalFunctionStatement
);
12737
N(SyntaxKind.
LocalFunctionStatement
);
15586
N(SyntaxKind.
LocalFunctionStatement
);
15653
N(SyntaxKind.
LocalFunctionStatement
);
15740
N(SyntaxKind.
LocalFunctionStatement
);
15819
N(SyntaxKind.
LocalFunctionStatement
);
15918
N(SyntaxKind.
LocalFunctionStatement
);
16001
N(SyntaxKind.
LocalFunctionStatement
);
16104
N(SyntaxKind.
LocalFunctionStatement
);
16195
N(SyntaxKind.
LocalFunctionStatement
);
16306
N(SyntaxKind.
LocalFunctionStatement
);
16402
N(SyntaxKind.
LocalFunctionStatement
);
16518
N(SyntaxKind.
LocalFunctionStatement
);
16601
N(SyntaxKind.
LocalFunctionStatement
);
16704
N(SyntaxKind.
LocalFunctionStatement
);
16785
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\DeclarationParsingTests.cs (22)
7256
N(SyntaxKind.
LocalFunctionStatement
);
7292
N(SyntaxKind.
LocalFunctionStatement
);
7330
N(SyntaxKind.
LocalFunctionStatement
);
7367
N(SyntaxKind.
LocalFunctionStatement
);
7404
N(SyntaxKind.
LocalFunctionStatement
);
7440
N(SyntaxKind.
LocalFunctionStatement
);
7472
N(SyntaxKind.
LocalFunctionStatement
);
7504
N(SyntaxKind.
LocalFunctionStatement
);
7536
N(SyntaxKind.
LocalFunctionStatement
);
7581
N(SyntaxKind.
LocalFunctionStatement
);
7643
N(SyntaxKind.
LocalFunctionStatement
);
7696
N(SyntaxKind.
LocalFunctionStatement
);
7729
N(SyntaxKind.
LocalFunctionStatement
);
7766
N(SyntaxKind.
LocalFunctionStatement
);
7803
N(SyntaxKind.
LocalFunctionStatement
);
7840
N(SyntaxKind.
LocalFunctionStatement
);
7877
N(SyntaxKind.
LocalFunctionStatement
);
7914
N(SyntaxKind.
LocalFunctionStatement
);
7951
N(SyntaxKind.
LocalFunctionStatement
);
7988
N(SyntaxKind.
LocalFunctionStatement
);
8025
N(SyntaxKind.
LocalFunctionStatement
);
8062
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\DeclarationScopeParsingTests.cs (9)
320
N(SyntaxKind.
LocalFunctionStatement
);
345
N(SyntaxKind.
LocalFunctionStatement
);
374
N(SyntaxKind.
LocalFunctionStatement
);
395
N(SyntaxKind.
LocalFunctionStatement
);
437
N(SyntaxKind.
LocalFunctionStatement
);
466
N(SyntaxKind.
LocalFunctionStatement
);
5348
N(SyntaxKind.
LocalFunctionStatement
);
8224
N(SyntaxKind.
LocalFunctionStatement
);
8287
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\DeconstructionTests.cs (8)
2412
N(SyntaxKind.
LocalFunctionStatement
);
2477
N(SyntaxKind.
LocalFunctionStatement
);
2555
N(SyntaxKind.
LocalFunctionStatement
);
2618
N(SyntaxKind.
LocalFunctionStatement
);
2681
N(SyntaxKind.
LocalFunctionStatement
);
2743
N(SyntaxKind.
LocalFunctionStatement
);
2802
N(SyntaxKind.
LocalFunctionStatement
);
2870
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\ExpressionParsingTests.cs (2)
3610
N(SyntaxKind.
LocalFunctionStatement
);
3683
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\FieldKeywordParsingTests.cs (1)
1778
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\FileModifierParsingTests.cs (4)
3036
N(SyntaxKind.
LocalFunctionStatement
);
3097
N(SyntaxKind.
LocalFunctionStatement
);
3305
N(SyntaxKind.
LocalFunctionStatement
);
3437
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\FunctionPointerTests.cs (8)
2358
N(SyntaxKind.
LocalFunctionStatement
);
2402
N(SyntaxKind.
LocalFunctionStatement
);
3361
N(SyntaxKind.
LocalFunctionStatement
);
3435
N(SyntaxKind.
LocalFunctionStatement
);
3514
N(SyntaxKind.
LocalFunctionStatement
);
3587
N(SyntaxKind.
LocalFunctionStatement
);
3887
N(SyntaxKind.
LocalFunctionStatement
);
3975
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\LambdaReturnTypeParsingTests.cs (1)
5021
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\LocalFunctionParsingTests.cs (27)
168
N(SyntaxKind.
LocalFunctionStatement
);
209
N(SyntaxKind.
LocalFunctionStatement
);
292
N(SyntaxKind.
LocalFunctionStatement
);
324
N(SyntaxKind.
LocalFunctionStatement
);
396
N(SyntaxKind.
LocalFunctionStatement
);
426
N(SyntaxKind.
LocalFunctionStatement
);
461
N(SyntaxKind.
LocalFunctionStatement
);
495
N(SyntaxKind.
LocalFunctionStatement
);
659
N(SyntaxKind.
LocalFunctionStatement
);
750
N(SyntaxKind.
LocalFunctionStatement
);
836
N(SyntaxKind.
LocalFunctionStatement
);
1232
s => Assert.Equal(SyntaxKind.
LocalFunctionStatement
, s.Kind()));
1289
Assert.True(file.DescendantNodes().Any(n => n.Kind() == SyntaxKind.
LocalFunctionStatement
&& !n.ContainsDiagnostics));
1427
N(SyntaxKind.
LocalFunctionStatement
);
1577
N(SyntaxKind.
LocalFunctionStatement
);
1766
N(SyntaxKind.
LocalFunctionStatement
);
1881
N(SyntaxKind.
LocalFunctionStatement
);
1899
N(SyntaxKind.
LocalFunctionStatement
);
2066
N(SyntaxKind.
LocalFunctionStatement
);
2084
N(SyntaxKind.
LocalFunctionStatement
);
2162
N(SyntaxKind.
LocalFunctionStatement
);
2245
N(SyntaxKind.
LocalFunctionStatement
);
2335
N(SyntaxKind.
LocalFunctionStatement
);
2432
N(SyntaxKind.
LocalFunctionStatement
);
2617
N(SyntaxKind.
LocalFunctionStatement
);
2972
N(SyntaxKind.
LocalFunctionStatement
);
3099
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\MemberDeclarationParsingTests.cs (1)
9388
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\ParsingErrorRecoveryTests.cs (4)
137
N(SyntaxKind.
LocalFunctionStatement
);
166
N(SyntaxKind.
LocalFunctionStatement
);
188
N(SyntaxKind.
LocalFunctionStatement
);
209
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\PatternParsingTests.cs (2)
9819
N(SyntaxKind.
LocalFunctionStatement
);
11458
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\RecordParsing.cs (1)
127
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\StatementParsingTests.cs (1)
4646
N(SyntaxKind.
LocalFunctionStatement
);
Parsing\TopLevelStatementsParsingTests.cs (7)
471
N(SyntaxKind.
LocalFunctionStatement
);
745
N(SyntaxKind.
LocalFunctionStatement
);
1286
N(SyntaxKind.
LocalFunctionStatement
);
1342
N(SyntaxKind.
LocalFunctionStatement
);
1687
N(SyntaxKind.
LocalFunctionStatement
);
2592
N(SyntaxKind.
LocalFunctionStatement
);
2632
N(SyntaxKind.
LocalFunctionStatement
);
Microsoft.CodeAnalysis.CSharp.Workspaces (11)
CodeGeneration\CSharpSyntaxGenerator.cs (6)
1591
case SyntaxKind.
LocalFunctionStatement
:
2244
case SyntaxKind.
LocalFunctionStatement
:
2308
case SyntaxKind.
LocalFunctionStatement
:
2364
case SyntaxKind.
LocalFunctionStatement
:
2487
SyntaxKind.
LocalFunctionStatement
=> ((LocalFunctionStatementSyntax)declaration).Body?.Statements,
2518
case SyntaxKind.
LocalFunctionStatement
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ILocalSymbolExtensions.cs (1)
17
.FirstOrDefault(node => node.Kind() is SyntaxKind.
LocalFunctionStatement
or SyntaxKind.MethodDeclaration);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxNodeExtensions.cs (1)
431
case SyntaxKind.
LocalFunctionStatement
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\NewLineUserSettingFormattingRule.cs (2)
198
if (currentToken.IsKind(SyntaxKind.OpenBraceToken) && currentTokenParentParent.IsKind(SyntaxKind.
LocalFunctionStatement
))
412
if (currentToken.IsKind(SyntaxKind.OpenBraceToken) && currentTokenParentParent.IsKind(SyntaxKind.
LocalFunctionStatement
))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
145
public int? LocalFunctionStatement => (int)SyntaxKind.
LocalFunctionStatement
;