51 references to CaseKeyword
Microsoft.CodeAnalysis.CSharp (26)
_generated\0\Syntax.xml.Main.Generated.cs (6)
4202case SyntaxKind.CaseKeyword: 4629if (keyword.Kind() != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword)); 4637=> SyntaxFactory.CasePatternSwitchLabel(SyntaxFactory.Token(SyntaxKind.CaseKeyword), pattern, whenClause, colonToken); 4641=> SyntaxFactory.CasePatternSwitchLabel(SyntaxFactory.Token(SyntaxKind.CaseKeyword), pattern, default, colonToken); 4646if (keyword.Kind() != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword)); 4654=> SyntaxFactory.CaseSwitchLabel(SyntaxFactory.Token(SyntaxKind.CaseKeyword), value, colonToken);
_generated\1\Syntax.xml.Internal.Generated.cs (6)
31186case SyntaxKind.CaseKeyword: 31606if (keyword.Kind != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword)); 31618if (keyword.Kind != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword)); 36613case SyntaxKind.CaseKeyword: 37033if (keyword.Kind != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword)); 37045if (keyword.Kind != SyntaxKind.CaseKeyword) throw new ArgumentException(nameof(keyword));
Parser\LanguageParser.cs (9)
8390case SyntaxKind.CaseKeyword: // error recovery case. 9268case SyntaxKind.CaseKeyword: // for parsing an errant case without a switch. 9998if (this.CurrentToken.Kind is SyntaxKind.CaseKeyword or SyntaxKind.DefaultKeyword) 10001if (caseOrDefault.Kind == SyntaxKind.CaseKeyword) 10203Debug.Assert(this.CurrentToken.Kind is SyntaxKind.SwitchKeyword or SyntaxKind.CaseKeyword); 10228if (this.CurrentToken.Kind is SyntaxKind.CaseKeyword) 10273return this.CurrentToken.Kind == SyntaxKind.CaseKeyword || 10288if (this.CurrentToken.Kind == SyntaxKind.CaseKeyword) 11190case SyntaxKind.CaseKeyword:
Parser\LanguageParser_Patterns.cs (1)
615var errantCase = this.CurrentToken.Kind == SyntaxKind.CaseKeyword
Syntax\SyntaxFactory.cs (1)
2477return SyntaxFactory.CaseSwitchLabel(SyntaxFactory.Token(SyntaxKind.CaseKeyword), value, SyntaxFactory.Token(SyntaxKind.ColonToken));
Syntax\SyntaxKindFacts.cs (3)
843case SyntaxKind.CaseKeyword: 939return SyntaxKind.CaseKeyword; 1640case SyntaxKind.CaseKeyword:
Microsoft.CodeAnalysis.CSharp.CodeStyle (2)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
19public static readonly SyntaxToken CaseKeyword = Token(SyntaxKind.CaseKeyword);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\TokenBasedFormattingRule.cs (1)
183(currentToken.Kind() == SyntaxKind.CaseKeyword || currentToken.Kind() == SyntaxKind.DefaultKeyword || currentToken.Kind() == SyntaxKind.ElseKeyword))
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (4)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (4)
740syntaxTree.IsAfterKeyword(position, SyntaxKind.CaseKeyword, cancellationToken) || 1392if (leftToken.Kind() is SyntaxKind.CaseKeyword or SyntaxKind.IsKeyword) 2076if (token.IsKind(SyntaxKind.CaseKeyword) && 2907if (tokenBeforeName.Kind() == SyntaxKind.CaseKeyword)
Microsoft.CodeAnalysis.CSharp.Features (3)
Completion\KeywordRecommenders\CaseKeywordRecommender.cs (1)
12internal sealed class CaseKeywordRecommender() : AbstractSyntacticSingleKeywordRecommender(SyntaxKind.CaseKeyword)
GoToDefinition\CSharpGoToDefinitionSymbolService.cs (1)
74case SyntaxKind.CaseKeyword:
Highlighting\KeywordHighlighters\SwitchStatementHighlighter.cs (1)
29or SyntaxKind.CaseKeyword
Microsoft.CodeAnalysis.CSharp.Workspaces (7)
Classification\ClassificationHelpers.cs (1)
74case SyntaxKind.CaseKeyword:
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
19public static readonly SyntaxToken CaseKeyword = Token(SyntaxKind.CaseKeyword);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\TokenBasedFormattingRule.cs (1)
183(currentToken.Kind() == SyntaxKind.CaseKeyword || currentToken.Kind() == SyntaxKind.DefaultKeyword || currentToken.Kind() == SyntaxKind.ElseKeyword))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (4)
740syntaxTree.IsAfterKeyword(position, SyntaxKind.CaseKeyword, cancellationToken) || 1392if (leftToken.Kind() is SyntaxKind.CaseKeyword or SyntaxKind.IsKeyword) 2076if (token.IsKind(SyntaxKind.CaseKeyword) && 2907if (tokenBeforeName.Kind() == SyntaxKind.CaseKeyword)
Microsoft.CodeAnalysis.Razor.Compiler (3)
Language\Legacy\CSharpCodeParser.cs (2)
87CSharpSyntaxKind.CaseKeyword, 2260Debug.Assert(result is CSharpSyntaxKind.CaseKeyword or CSharpSyntaxKind.DefaultKeyword);
Language\Legacy\NativeCSharpTokenizer.cs (1)
52CSharpSyntaxKind.CaseKeyword,
Roslyn.Diagnostics.CSharp.Analyzers (6)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
19public static readonly SyntaxToken CaseKeyword = Token(SyntaxKind.CaseKeyword);
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\TokenBasedFormattingRule.cs (1)
183(currentToken.Kind() == SyntaxKind.CaseKeyword || currentToken.Kind() == SyntaxKind.DefaultKeyword || currentToken.Kind() == SyntaxKind.ElseKeyword))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs (4)
740syntaxTree.IsAfterKeyword(position, SyntaxKind.CaseKeyword, cancellationToken) || 1392if (leftToken.Kind() is SyntaxKind.CaseKeyword or SyntaxKind.IsKeyword) 2076if (token.IsKind(SyntaxKind.CaseKeyword) && 2907if (tokenBeforeName.Kind() == SyntaxKind.CaseKeyword)