123 references to ProtectedKeyword
Microsoft.AspNetCore.Components.Analyzers (1)
ComponentParametersShouldBePublicCodeFixProvider.cs (1)
73modifier.IsKind(SyntaxKind.ProtectedKeyword) ||
Microsoft.AspNetCore.Components.SdkAnalyzers (1)
ComponentParametersShouldBePublicCodeFixProvider.cs (1)
73modifier.IsKind(SyntaxKind.ProtectedKeyword) ||
Microsoft.CodeAnalysis.CSharp (18)
Parser\LanguageParser.cs (5)
350case SyntaxKind.ProtectedKeyword: 1301case SyntaxKind.ProtectedKeyword: 2324case SyntaxKind.ProtectedKeyword: 10355case SyntaxKind.ProtectedKeyword: 10372case SyntaxKind.ProtectedKeyword:
SymbolDisplay\SymbolDisplayVisitor.cs (3)
397AddKeyword(SyntaxKind.ProtectedKeyword); 400AddKeyword(SyntaxKind.ProtectedKeyword); 403AddKeyword(SyntaxKind.ProtectedKeyword);
Symbols\Source\ModifierUtils.cs (4)
290return SyntaxFacts.GetText(SyntaxKind.ProtectedKeyword); 294return SyntaxFacts.GetText(SyntaxKind.ProtectedKeyword) + " " + SyntaxFacts.GetText(SyntaxKind.InternalKeyword); 298return SyntaxFacts.GetText(SyntaxKind.PrivateKeyword) + " " + SyntaxFacts.GetText(SyntaxKind.ProtectedKeyword); 348case SyntaxKind.ProtectedKeyword:
Syntax\SyntaxFacts.cs (3)
367return SyntaxFacts.GetText(PrivateKeyword) + " " + SyntaxFacts.GetText(ProtectedKeyword); 371return SyntaxFacts.GetText(ProtectedKeyword); 373return SyntaxFacts.GetText(ProtectedKeyword) + " " + SyntaxFacts.GetText(InternalKeyword);
Syntax\SyntaxKindFacts.cs (3)
70case SyntaxKind.ProtectedKeyword: 937return SyntaxKind.ProtectedKeyword; 1585case SyntaxKind.ProtectedKeyword:
Microsoft.CodeAnalysis.CSharp.CodeStyle (8)
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertProgramAnalysis_TopLevelStatements.cs (1)
132if (member.Modifiers.Any(m => m.Kind() is SyntaxKind.PublicKeyword or SyntaxKind.ProtectedKeyword or SyntaxKind.InternalKeyword))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
68public static readonly SyntaxToken ProtectedKeyword = Token(SyntaxKind.ProtectedKeyword);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeStyle\CSharpCodeStyleOptions.cs (1)
152SyntaxKind.ProtectedKeyword,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (2)
85case SyntaxKind.ProtectedKeyword: 323case SyntaxKind.ProtectedKeyword:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpAccessibilityFacts.cs (3)
121(SyntaxKind.ProtectedKeyword, Accessibility.Private) => Accessibility.ProtectedAndInternal, 122(SyntaxKind.ProtectedKeyword, Accessibility.Internal) => Accessibility.ProtectedOrInternal, 123(SyntaxKind.ProtectedKeyword, _) => Accessibility.Protected,
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (5)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\CSharpDeclarationComparer.cs (1)
320else if (ContainsToken(modifiers, SyntaxKind.ProtectedKeyword))
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTokenExtensions.cs (1)
572SyntaxKind.ProtectedKeyword or
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Utilities\SyntaxKindSet.cs (3)
19SyntaxKind.ProtectedKeyword, 37SyntaxKind.ProtectedKeyword, 65SyntaxKind.ProtectedKeyword,
Microsoft.CodeAnalysis.CSharp.Features (50)
Completion\CompletionProviders\DeclarationName\DeclarationNameInfo.cs (1)
601case SyntaxKind.ProtectedKeyword:
Completion\CompletionProviders\OverrideCompletionProvider.cs (1)
168case SyntaxKind.ProtectedKeyword:
Completion\CompletionProviders\PartialMethodCompletionProvider.cs (1)
44case SyntaxKind.ProtectedKeyword:
Completion\KeywordRecommenders\AbstractKeywordRecommender.cs (3)
20SyntaxKind.ProtectedKeyword, 31SyntaxKind.ProtectedKeyword, 43SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\ClassKeywordRecommender.cs (1)
18SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\ConstKeywordRecommender.cs (1)
18SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\DelegateKeywordRecommender.cs (1)
20SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\EnumKeywordRecommender.cs (1)
19SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\EventKeywordRecommender.cs (1)
19SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\ExternKeywordRecommender.cs (1)
22SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\FixedKeywordRecommender.cs (1)
18SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\InterfaceKeywordRecommender.cs (1)
19SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\NewKeywordRecommender.cs (2)
24SyntaxKind.ProtectedKeyword, 39SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\OverrideKeywordRecommender.cs (2)
19SyntaxKind.ProtectedKeyword, 43return !modifiers.Contains(SyntaxKind.PrivateKeyword) || modifiers.Contains(SyntaxKind.ProtectedKeyword);
Completion\KeywordRecommenders\ProtectedKeywordRecommender.cs (2)
15: base(SyntaxKind.ProtectedKeyword) 72!precedingModifiers.Contains(SyntaxKind.ProtectedKeyword);
Completion\KeywordRecommenders\PublicKeywordRecommender.cs (1)
58!precedingModifiers.Contains(SyntaxKind.ProtectedKeyword) &&
Completion\KeywordRecommenders\ReadOnlyKeywordRecommender.cs (1)
20SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\RecordKeywordRecommender.cs (1)
18SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\RefKeywordRecommender.cs (1)
35SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\SealedKeywordRecommender.cs (3)
21SyntaxKind.ProtectedKeyword, 32SyntaxKind.ProtectedKeyword, 43SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\StaticKeywordRecommender.cs (3)
21SyntaxKind.ProtectedKeyword, 34SyntaxKind.ProtectedKeyword, 49SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\StructKeywordRecommender.cs (1)
20SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\UnsafeKeywordRecommender.cs (2)
21SyntaxKind.ProtectedKeyword, 36SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\VirtualKeywordRecommender.cs (3)
20SyntaxKind.ProtectedKeyword, 31SyntaxKind.ProtectedKeyword, 59return !modifiers.Contains(SyntaxKind.PrivateKeyword) || modifiers.Contains(SyntaxKind.ProtectedKeyword);
Completion\KeywordRecommenders\VoidKeywordRecommender.cs (1)
19SyntaxKind.ProtectedKeyword,
Completion\KeywordRecommenders\VolatileKeywordRecommender.cs (1)
19SyntaxKind.ProtectedKeyword,
EncapsulateField\CSharpEncapsulateFieldService.cs (1)
71var modifierKinds = new[] { SyntaxKind.PrivateKeyword, SyntaxKind.ProtectedKeyword, SyntaxKind.InternalKeyword, SyntaxKind.PublicKeyword };
Organizing\Organizers\MemberDeclarationsOrganizer.Comparer.cs (2)
126else if (xModifiers.Any(SyntaxKind.ProtectedKeyword) && xModifiers.Any(SyntaxKind.InternalKeyword)) 134else if (xModifiers.Any(SyntaxKind.ProtectedKeyword))
Organizing\Organizers\ModifiersOrganizer.Comparer.cs (1)
46case SyntaxKind.ProtectedKeyword:
Snippets\CSharpClassSnippetProvider.cs (1)
29SyntaxKind.ProtectedKeyword,
Snippets\CSharpConstructorSnippetProvider.cs (1)
34SyntaxKind.ProtectedKeyword,
Snippets\CSharpEnumSnippetProvider.cs (1)
30SyntaxKind.ProtectedKeyword,
Snippets\CSharpInterfaceSnippetProvider.cs (1)
30SyntaxKind.ProtectedKeyword,
Snippets\CSharpProprSnippetProvider.cs (2)
43if (precedingModifiers.IsSupersetOf([SyntaxKind.ProtectedKeyword, SyntaxKind.InternalKeyword])) 47if (precedingModifiers.Any(syntaxKind => syntaxKind is SyntaxKind.PrivateKeyword or SyntaxKind.ProtectedKeyword))
Snippets\CSharpStructSnippetProvider.cs (1)
30SyntaxKind.ProtectedKeyword,
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertProgramAnalysis_TopLevelStatements.cs (1)
132if (member.Modifiers.Any(m => m.Kind() is SyntaxKind.PublicKeyword or SyntaxKind.ProtectedKeyword or SyntaxKind.InternalKeyword))
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (14)
Parsing\DeclarationParsingTests.cs (13)
1815Assert.Equal(SyntaxKind.ProtectedKeyword, cs.Modifiers[0].Kind()); 1856Assert.Equal(SyntaxKind.ProtectedKeyword, cs.Modifiers[0].Kind()); 1899Assert.Equal(SyntaxKind.ProtectedKeyword, cs.Modifiers[1].Kind()); 2723TestClassMethodModifiers(SyntaxKind.ProtectedKeyword); 2731TestClassMethodModifiers(SyntaxKind.InternalKeyword, SyntaxKind.ProtectedKeyword, SyntaxKind.VirtualKeyword); 2732TestClassMethodModifiers(SyntaxKind.InternalKeyword, SyntaxKind.VirtualKeyword, SyntaxKind.ProtectedKeyword); 3554TestClassConstructorWithModifier(SyntaxKind.ProtectedKeyword); 3743TestClassFieldModifier(SyntaxKind.ProtectedKeyword); 3798TestClassEventFieldModifier(SyntaxKind.ProtectedKeyword); 4649TestClassPropertyWithModifier(SyntaxKind.ProtectedKeyword); 4664TestClassPropertyWithModifier(SyntaxKind.ProtectedKeyword); 4844TestClassEventPropertyWithModifier(SyntaxKind.ProtectedKeyword); 4857TestClassEventPropertyWithModifier(SyntaxKind.ProtectedKeyword);
Parsing\ScriptParsingTests.cs (1)
957NewModifier_WithOtherModifier("protected", SyntaxKind.ProtectedKeyword);
Microsoft.CodeAnalysis.CSharp.Workspaces (13)
FindSymbols\CSharpDeclaredSymbolInfoFactoryService.cs (1)
606case SyntaxKind.ProtectedKeyword: return Accessibility.Protected;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeGeneration\CSharpSyntaxTokens.cs (1)
68public static readonly SyntaxToken ProtectedKeyword = Token(SyntaxKind.ProtectedKeyword);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\CodeStyle\CSharpCodeStyleOptions.cs (1)
152SyntaxKind.ProtectedKeyword,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTokenExtensions.cs (2)
85case SyntaxKind.ProtectedKeyword: 323case SyntaxKind.ProtectedKeyword:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpAccessibilityFacts.cs (3)
121(SyntaxKind.ProtectedKeyword, Accessibility.Private) => Accessibility.ProtectedAndInternal, 122(SyntaxKind.ProtectedKeyword, Accessibility.Internal) => Accessibility.ProtectedOrInternal, 123(SyntaxKind.ProtectedKeyword, _) => Accessibility.Protected,
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\CSharpDeclarationComparer.cs (1)
320else if (ContainsToken(modifiers, SyntaxKind.ProtectedKeyword))
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTokenExtensions.cs (1)
572SyntaxKind.ProtectedKeyword or
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Utilities\SyntaxKindSet.cs (3)
19SyntaxKind.ProtectedKeyword, 37SyntaxKind.ProtectedKeyword, 65SyntaxKind.ProtectedKeyword,
Microsoft.Gen.Logging.Unit.Tests (3)
ParserUtilitiesTests.cs (3)
33SyntaxFactory.Token(SyntaxKind.ProtectedKeyword), 53var result = ParserUtilities.PropertyHasModifier(symbolMock.Object, SyntaxKind.ProtectedKeyword, CancellationToken.None); 74var result = ParserUtilities.PropertyHasModifier(symbolMock.Object, SyntaxKind.ProtectedKeyword, CancellationToken.None);
Microsoft.Interop.SourceGeneration (1)
SyntaxExtensions.cs (1)
89if (tokenList[i].Kind() is SyntaxKind.PublicKeyword or SyntaxKind.InternalKeyword or SyntaxKind.ProtectedKeyword or SyntaxKind.PrivateKeyword)
Microsoft.ML.InternalCodeAnalyzer (1)
NameAnalyzer.cs (1)
153else if (mod.IsKind(SyntaxKind.PublicKeyword) || mod.IsKind(SyntaxKind.ProtectedKeyword) || mod.IsKind(SyntaxKind.InternalKeyword))
Microsoft.VisualStudio.LanguageServices.CSharp (8)
CodeModel\CSharpCodeModelService.cs (2)
1061else if (modifiers.Any(SyntaxKind.ProtectedKeyword) && modifiers.Any(SyntaxKind.InternalKeyword)) 1069else if (modifiers.Any(SyntaxKind.ProtectedKeyword))
CodeModel\ModifierFlagsExtensions.cs (2)
20{ ModifierFlags.Protected, SyntaxKind.ProtectedKeyword }, 49case SyntaxKind.ProtectedKeyword:
LanguageService\CSharpHelpContextService.cs (4)
425case SyntaxKind.PrivateKeyword when ModifiersContains(token, SyntaxKind.ProtectedKeyword): 426case SyntaxKind.ProtectedKeyword when ModifiersContains(token, SyntaxKind.PrivateKeyword): 430case SyntaxKind.ProtectedKeyword when ModifiersContains(token, SyntaxKind.InternalKeyword): 431case SyntaxKind.InternalKeyword when ModifiersContains(token, SyntaxKind.ProtectedKeyword):