207 references to DelegateKeyword
Microsoft.CodeAnalysis.CSharp (29)
Parser\LanguageParser.cs (22)
342
case SyntaxKind.
DelegateKeyword
:
979
var isAliasToFunctionPointer = alias != null && this.CurrentToken.Kind == SyntaxKind.
DelegateKeyword
;
1393
nextToken.Kind is SyntaxKind.EnumKeyword or SyntaxKind.
DelegateKeyword
||
1703
case SyntaxKind.
DelegateKeyword
:
2001
!(kind == SyntaxKind.
DelegateKeyword
&& this.PeekToken(1).Kind is SyntaxKind.OpenBraceToken or SyntaxKind.OpenParenToken))
2251
SyntaxKind.
DelegateKeyword
=>
2309
case SyntaxKind.
DelegateKeyword
:
2359
case SyntaxKind.
DelegateKeyword
when !IsFunctionPointerStart():
2518
case SyntaxKind.
DelegateKeyword
:
4613
case SyntaxKind.
DelegateKeyword
when IsFunctionPointerStart(): // Function pointer type
5452
Debug.Assert(this.CurrentToken.Kind == SyntaxKind.
DelegateKeyword
);
5454
var delegateToken = this.EatToken(SyntaxKind.
DelegateKeyword
);
7041
_ = EatToken(SyntaxKind.
DelegateKeyword
);
7637
var @delegate = EatToken(SyntaxKind.
DelegateKeyword
);
7795
=> CurrentToken.Kind == SyntaxKind.
DelegateKeyword
&& PeekToken(1).Kind == SyntaxKind.AsteriskToken;
10583
case SyntaxKind.
DelegateKeyword
:
10859
case SyntaxKind.
DelegateKeyword
:
11505
case SyntaxKind.
DelegateKeyword
:
11723
return this.PeekToken(tokenIndex).Kind == SyntaxKind.
DelegateKeyword
&&
13143
var @delegate = this.EatToken(SyntaxKind.
DelegateKeyword
);
13219
case SyntaxKind.
DelegateKeyword
:
13363
case SyntaxKind.
DelegateKeyword
:
SymbolDisplay\SymbolDisplayVisitor.Members.cs (1)
576
AddKeyword(SyntaxKind.
DelegateKeyword
);
SymbolDisplay\SymbolDisplayVisitor.Types.cs (1)
731
AddKeyword(SyntaxKind.
DelegateKeyword
);
Syntax\AnonymousMethodExpressionSyntax.cs (1)
44
Token(SyntaxKind.
DelegateKeyword
),
Syntax\SyntaxFactory.cs (1)
2771
? AnonymousMethodExpression(default(SyntaxTokenList), SyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), parameterList, block, null)
Syntax\SyntaxKindFacts.cs (2)
1001
return SyntaxKind.
DelegateKeyword
;
1649
case SyntaxKind.
DelegateKeyword
:
Syntax\SyntaxNormalizer.cs (1)
741
if (next.IsKind(SyntaxKind.AsteriskToken) && token.IsKind(SyntaxKind.
DelegateKeyword
))
Microsoft.CodeAnalysis.CSharp.CodeStyle (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SemanticModelExtensions.cs (1)
154
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (1)
318
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SpacingFormattingRule.cs (1)
367
if (currentKind == SyntaxKind.AsteriskToken && previousKind == SyntaxKind.
DelegateKeyword
)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxFacts.cs (1)
512
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
67
public int DelegateKeyword => (int)SyntaxKind.
DelegateKeyword
;
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (2)
src\Analyzers\CSharp\CodeFixes\FixIncorrectConstraint\CSharpFixIncorrectConstraintCodeFixProvider.cs (1)
60
return enumOrDelegateKeyword.Kind() is SyntaxKind.EnumKeyword or SyntaxKind.
DelegateKeyword
;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (1)
1170
if (token.IsKind(SyntaxKind.
DelegateKeyword
) &&
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (1)
Formatting\Indentation\SmartTokenFormatterFormatRangeTests.cs (1)
2231
SyntaxKind.
DelegateKeyword
);
Microsoft.CodeAnalysis.CSharp.Features (3)
QuickInfo\CSharpSemanticQuickInfoProvider.cs (1)
45
else if (token.IsKind(SyntaxKind.
DelegateKeyword
) && token.Parent.IsKind(SyntaxKind.AnonymousMethodExpression))
SignatureHelp\InvocationExpressionSignatureHelpProviderBase_DelegateAndFunctionPointerInvoke.cs (1)
66
displayParts.Add(Keyword(SyntaxKind.
DelegateKeyword
));
src\Analyzers\CSharp\CodeFixes\FixIncorrectConstraint\CSharpFixIncorrectConstraintCodeFixProvider.cs (1)
60
return enumOrDelegateKeyword.Kind() is SyntaxKind.EnumKeyword or SyntaxKind.
DelegateKeyword
;
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (161)
Generated\Syntax.Test.xml.Generated.cs (12)
41
=> InternalSyntaxFactory.FunctionPointerType(InternalSyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), InternalSyntaxFactory.Token(SyntaxKind.AsteriskToken), null, GenerateFunctionPointerParameterList());
176
=> InternalSyntaxFactory.AnonymousMethodExpression(new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList<Syntax.InternalSyntax.SyntaxToken>(), InternalSyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), null, GenerateBlock(), null);
518
=> InternalSyntaxFactory.DelegateDeclaration(new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList<Syntax.InternalSyntax.AttributeListSyntax>(), new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList<Syntax.InternalSyntax.SyntaxToken>(), InternalSyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), GenerateIdentifierName(), InternalSyntaxFactory.Identifier("Identifier"), null, GenerateParameterList(), new Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList<Syntax.InternalSyntax.TypeParameterConstraintClauseSyntax>(), InternalSyntaxFactory.Token(SyntaxKind.SemicolonToken));
853
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind);
1378
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind);
2870
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind);
10257
=> SyntaxFactory.FunctionPointerType(SyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), SyntaxFactory.Token(SyntaxKind.AsteriskToken), default(FunctionPointerCallingConventionSyntax), GenerateFunctionPointerParameterList());
10392
=> SyntaxFactory.AnonymousMethodExpression(new SyntaxTokenList(), SyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), default(ParameterListSyntax), GenerateBlock(), default(ExpressionSyntax));
10734
=> SyntaxFactory.DelegateDeclaration(new SyntaxList<AttributeListSyntax>(), new SyntaxTokenList(), SyntaxFactory.Token(SyntaxKind.
DelegateKeyword
), GenerateIdentifierName(), SyntaxFactory.Identifier("Identifier"), default(TypeParameterListSyntax), GenerateParameterList(), new SyntaxList<TypeParameterConstraintClauseSyntax>(), SyntaxFactory.Token(SyntaxKind.SemicolonToken));
11069
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind());
11594
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind());
13086
Assert.Equal(SyntaxKind.
DelegateKeyword
, node.DelegateKeyword.Kind());
Parsing\AnonymousFunctionParsingTests.cs (15)
87
N(SyntaxKind.
DelegateKeyword
);
187
N(SyntaxKind.
DelegateKeyword
);
285
N(SyntaxKind.
DelegateKeyword
);
386
N(SyntaxKind.
DelegateKeyword
);
487
N(SyntaxKind.
DelegateKeyword
);
1126
N(SyntaxKind.
DelegateKeyword
);
1454
N(SyntaxKind.
DelegateKeyword
);
1772
N(SyntaxKind.
DelegateKeyword
);
1839
N(SyntaxKind.
DelegateKeyword
);
1933
N(SyntaxKind.
DelegateKeyword
);
2062
N(SyntaxKind.
DelegateKeyword
);
2140
N(SyntaxKind.
DelegateKeyword
);
2166
N(SyntaxKind.
DelegateKeyword
);
2226
N(SyntaxKind.
DelegateKeyword
);
2252
N(SyntaxKind.
DelegateKeyword
);
Parsing\AsyncParsingTests.cs (3)
1210
N(SyntaxKind.
DelegateKeyword
);
1371
N(SyntaxKind.
DelegateKeyword
);
1391
N(SyntaxKind.
DelegateKeyword
);
Parsing\AwaitParsingTests.cs (1)
2047
N(SyntaxKind.
DelegateKeyword
);
Parsing\CollectionExpressionParsingTests.cs (1)
3149
N(SyntaxKind.
DelegateKeyword
);
Parsing\DeclarationParsingTests.cs (2)
8283
N(SyntaxKind.
DelegateKeyword
);
8322
N(SyntaxKind.
DelegateKeyword
);
Parsing\DeclarationScopeParsingTests.cs (6)
9547
N(SyntaxKind.
DelegateKeyword
);
9599
N(SyntaxKind.
DelegateKeyword
);
11299
N(SyntaxKind.
DelegateKeyword
);
11364
N(SyntaxKind.
DelegateKeyword
);
11415
N(SyntaxKind.
DelegateKeyword
);
11484
N(SyntaxKind.
DelegateKeyword
);
Parsing\FileModifierParsingTests.cs (4)
599
N(SyntaxKind.
DelegateKeyword
);
756
N(SyntaxKind.
DelegateKeyword
);
1692
N(SyntaxKind.
DelegateKeyword
);
1952
N(SyntaxKind.
DelegateKeyword
);
Parsing\FunctionPointerTests.cs (80)
27
N(SyntaxKind.
DelegateKeyword
);
83
N(SyntaxKind.
DelegateKeyword
);
155
N(SyntaxKind.
DelegateKeyword
);
205
N(SyntaxKind.
DelegateKeyword
);
248
N(SyntaxKind.
DelegateKeyword
);
300
N(SyntaxKind.
DelegateKeyword
);
351
N(SyntaxKind.
DelegateKeyword
);
394
N(SyntaxKind.
DelegateKeyword
);
442
N(SyntaxKind.
DelegateKeyword
);
540
N(SyntaxKind.
DelegateKeyword
);
605
N(SyntaxKind.
DelegateKeyword
);
656
N(SyntaxKind.
DelegateKeyword
);
665
N(SyntaxKind.
DelegateKeyword
);
715
N(SyntaxKind.
DelegateKeyword
);
764
N(SyntaxKind.
DelegateKeyword
);
809
N(SyntaxKind.
DelegateKeyword
);
886
N(SyntaxKind.
DelegateKeyword
);
930
N(SyntaxKind.
DelegateKeyword
);
972
N(SyntaxKind.
DelegateKeyword
);
1017
N(SyntaxKind.
DelegateKeyword
);
1067
N(SyntaxKind.
DelegateKeyword
);
1121
N(SyntaxKind.
DelegateKeyword
);
1172
N(SyntaxKind.
DelegateKeyword
);
1226
N(SyntaxKind.
DelegateKeyword
);
1277
N(SyntaxKind.
DelegateKeyword
);
1352
N(SyntaxKind.
DelegateKeyword
);
1396
N(SyntaxKind.
DelegateKeyword
);
1444
N(SyntaxKind.
DelegateKeyword
);
1502
N(SyntaxKind.
DelegateKeyword
);
1566
N(SyntaxKind.
DelegateKeyword
);
1622
N(SyntaxKind.
DelegateKeyword
);
1669
N(SyntaxKind.
DelegateKeyword
);
1723
N(SyntaxKind.
DelegateKeyword
);
1754
N(SyntaxKind.
DelegateKeyword
);
1784
N(SyntaxKind.
DelegateKeyword
);
1838
N(SyntaxKind.
DelegateKeyword
);
1896
N(SyntaxKind.
DelegateKeyword
);
1950
N(SyntaxKind.
DelegateKeyword
);
1980
N(SyntaxKind.
DelegateKeyword
);
2035
N(SyntaxKind.
DelegateKeyword
);
2066
N(SyntaxKind.
DelegateKeyword
);
2111
N(SyntaxKind.
DelegateKeyword
);
2167
N(SyntaxKind.
DelegateKeyword
);
2221
N(SyntaxKind.
DelegateKeyword
);
2224
N(SyntaxKind.
DelegateKeyword
);
2260
N(SyntaxKind.
DelegateKeyword
);
2310
N(SyntaxKind.
DelegateKeyword
);
2380
N(SyntaxKind.
DelegateKeyword
);
2406
N(SyntaxKind.
DelegateKeyword
);
2439
N(SyntaxKind.
DelegateKeyword
);
2483
N(SyntaxKind.
DelegateKeyword
);
2517
N(SyntaxKind.
DelegateKeyword
);
2571
N(SyntaxKind.
DelegateKeyword
);
2605
N(SyntaxKind.
DelegateKeyword
);
2686
N(SyntaxKind.
DelegateKeyword
);
2719
N(SyntaxKind.
DelegateKeyword
);
2790
N(SyntaxKind.
DelegateKeyword
);
2847
N(SyntaxKind.
DelegateKeyword
);
2900
N(SyntaxKind.
DelegateKeyword
);
2952
N(SyntaxKind.
DelegateKeyword
);
2995
N(SyntaxKind.
DelegateKeyword
);
3045
N(SyntaxKind.
DelegateKeyword
);
3081
N(SyntaxKind.
DelegateKeyword
);
3141
N(SyntaxKind.
DelegateKeyword
);
3185
N(SyntaxKind.
DelegateKeyword
);
3236
N(SyntaxKind.
DelegateKeyword
);
3278
N(SyntaxKind.
DelegateKeyword
);
3317
N(SyntaxKind.
DelegateKeyword
);
3383
N(SyntaxKind.
DelegateKeyword
);
3456
N(SyntaxKind.
DelegateKeyword
);
3536
N(SyntaxKind.
DelegateKeyword
);
3608
N(SyntaxKind.
DelegateKeyword
);
3666
N(SyntaxKind.
DelegateKeyword
);
3710
N(SyntaxKind.
DelegateKeyword
);
3767
N(SyntaxKind.
DelegateKeyword
);
3827
N(SyntaxKind.
DelegateKeyword
);
3908
N(SyntaxKind.
DelegateKeyword
);
3996
N(SyntaxKind.
DelegateKeyword
);
4088
N(SyntaxKind.
DelegateKeyword
);
4146
N(SyntaxKind.
DelegateKeyword
);
Parsing\LambdaParameterParsingTests.cs (9)
2376
N(SyntaxKind.
DelegateKeyword
);
2780
N(SyntaxKind.
DelegateKeyword
);
2895
N(SyntaxKind.
DelegateKeyword
);
2988
N(SyntaxKind.
DelegateKeyword
);
3060
N(SyntaxKind.
DelegateKeyword
);
3138
N(SyntaxKind.
DelegateKeyword
);
3230
N(SyntaxKind.
DelegateKeyword
);
3351
N(SyntaxKind.
DelegateKeyword
);
3479
N(SyntaxKind.
DelegateKeyword
);
Parsing\LambdaReturnTypeParsingTests.cs (8)
300
N(SyntaxKind.
DelegateKeyword
);
330
N(SyntaxKind.
DelegateKeyword
);
561
N(SyntaxKind.
DelegateKeyword
);
600
N(SyntaxKind.
DelegateKeyword
);
623
N(SyntaxKind.
DelegateKeyword
);
1541
N(SyntaxKind.
DelegateKeyword
);
1588
N(SyntaxKind.
DelegateKeyword
);
5755
N(SyntaxKind.
DelegateKeyword
);
Parsing\LocalFunctionParsingTests.cs (1)
2779
N(SyntaxKind.
DelegateKeyword
);
Parsing\MemberDeclarationParsingTests.cs (4)
1985
N(SyntaxKind.
DelegateKeyword
);
2184
N(SyntaxKind.
DelegateKeyword
);
9304
N(SyntaxKind.
DelegateKeyword
);
12180
N(SyntaxKind.
DelegateKeyword
);
Parsing\PatternParsingTests.cs (1)
10318
N(SyntaxKind.
DelegateKeyword
);
Parsing\ScriptParsingTests.cs (4)
1427
N(SyntaxKind.
DelegateKeyword
);
1464
N(SyntaxKind.
DelegateKeyword
);
1500
N(SyntaxKind.
DelegateKeyword
);
2452
N(SyntaxKind.
DelegateKeyword
);
Parsing\StatementAttributeParsingTests.cs (3)
3306
N(SyntaxKind.
DelegateKeyword
);
3389
N(SyntaxKind.
DelegateKeyword
);
3469
N(SyntaxKind.
DelegateKeyword
);
Parsing\TopLevelStatementsParsingTests.cs (3)
1017
N(SyntaxKind.
DelegateKeyword
);
2480
N(SyntaxKind.
DelegateKeyword
);
2690
N(SyntaxKind.
DelegateKeyword
);
Parsing\UsingDirectiveParsingTests.cs (4)
123
N(SyntaxKind.
DelegateKeyword
);
417
N(SyntaxKind.
DelegateKeyword
);
735
N(SyntaxKind.
DelegateKeyword
);
795
N(SyntaxKind.
DelegateKeyword
);
Microsoft.CodeAnalysis.CSharp.Workspaces (6)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SemanticModelExtensions.cs (1)
154
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (1)
318
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SpacingFormattingRule.cs (1)
367
if (currentKind == SyntaxKind.AsteriskToken && previousKind == SyntaxKind.
DelegateKeyword
)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxFacts.cs (1)
512
case SyntaxKind.
DelegateKeyword
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
67
public int DelegateKeyword => (int)SyntaxKind.
DelegateKeyword
;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (1)
1170
if (token.IsKind(SyntaxKind.
DelegateKeyword
) &&