1 implementation of ILabelSymbol
Microsoft.CodeAnalysis.CSharp (1)
Symbols\PublicModel\LabelSymbol.cs (1)
9internal sealed class LabelSymbol : Symbol, ILabelSymbol
175 references to ILabelSymbol
GenerateDocumentationAndConfigFiles (11)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis (44)
Generated\Operations.Generated.cs (36)
135ILabelSymbol ExitLabel { get; } 168ILabelSymbol ContinueLabel { get; } 172ILabelSymbol ExitLabel { get; } 344ILabelSymbol Label { get; } 373ILabelSymbol Target { get; } 490ILabelSymbol? ExitLabel { get; } 2682ILabelSymbol? Label { get; } 2717new ILabelSymbol Label { get; } 4151internal SwitchOperation(ImmutableArray<ILocalSymbol> locals, IOperation value, ImmutableArray<ISwitchCaseOperation> cases, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4162public ILabelSymbol ExitLabel { get; } 4221protected BaseLoopOperation(IOperation body, ImmutableArray<ILocalSymbol> locals, ILabelSymbol continueLabel, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4232public ILabelSymbol ContinueLabel { get; } 4233public ILabelSymbol ExitLabel { get; } 4237internal ForEachLoopOperation(IOperation loopControlVariable, IOperation collection, ImmutableArray<IOperation> nextVariables, ForEachLoopOperationInfo? info, bool isAsynchronous, IOperation body, ImmutableArray<ILocalSymbol> locals, ILabelSymbol continueLabel, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4327internal ForLoopOperation(ImmutableArray<IOperation> before, ImmutableArray<ILocalSymbol> conditionLocals, IOperation? condition, ImmutableArray<IOperation> atLoopBottom, IOperation body, ImmutableArray<ILocalSymbol> locals, ILabelSymbol continueLabel, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4419internal ForToLoopOperation(IOperation loopControlVariable, IOperation initialValue, IOperation limitValue, IOperation stepValue, bool isChecked, ImmutableArray<IOperation> nextVariables, (ILocalSymbol LoopObject, ForToLoopOperationUserDefinedInfo UserDefinedInfo) info, IOperation body, ImmutableArray<ILocalSymbol> locals, ILabelSymbol continueLabel, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4531internal WhileLoopOperation(IOperation? condition, bool conditionIsTop, bool conditionIsUntil, IOperation? ignoredCondition, IOperation body, ImmutableArray<ILocalSymbol> locals, ILabelSymbol continueLabel, ILabelSymbol exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4555internal LabeledOperation(ILabelSymbol label, IOperation? operation, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4561public ILabelSymbol Label { get; } 4608internal BranchOperation(ILabelSymbol target, BranchKind branchKind, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4614public ILabelSymbol Target { get; } 4758internal TryOperation(IBlockOperation body, ImmutableArray<ICatchClauseOperation> catches, IBlockOperation? @finally, ILabelSymbol? exitLabel, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 4769public ILabelSymbol? ExitLabel { get; } 8164protected BaseCaseClauseOperation(ILabelSymbol? label, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8170public ILabelSymbol? Label { get; } 8174internal DefaultCaseClauseOperation(ILabelSymbol? label, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8188internal PatternCaseClauseOperation(ILabelSymbol label, IPatternOperation pattern, IOperation? guard, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8194public new ILabelSymbol Label => base.Label!; 8251internal RangeCaseClauseOperation(IOperation minimumValue, IOperation maximumValue, ILabelSymbol? label, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8313internal RelationalCaseClauseOperation(IOperation value, BinaryOperatorKind relation, ILabelSymbol? label, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8366internal SingleValueCaseClauseOperation(IOperation value, ILabelSymbol? label, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit)
Operations\ControlFlowGraphBuilder.cs (5)
37private PooledDictionary<ILabelSymbol, BasicBlockBuilder>? _labeledBlocks; 1194private static void CheckUnresolvedBranches(ArrayBuilder<BasicBlockBuilder> blocks, PooledDictionary<ILabelSymbol, BasicBlockBuilder>? labeledBlocks) 3873public void VisitLabel(ILabelSymbol operation) 3886private BasicBlockBuilder GetLabeledOrNewBlock(ILabelSymbol? labelOpt) 3897_labeledBlocks = PooledDictionary<ILabelSymbol, BasicBlockBuilder>.GetInstance();
Symbols\SymbolVisitor.cs (1)
53public virtual void VisitLabel(ILabelSymbol symbol)
Symbols\SymbolVisitor`1.cs (1)
56public virtual TResult? VisitLabel(ILabelSymbol symbol)
Symbols\SymbolVisitor`2.cs (1)
61public virtual TResult VisitLabel(ILabelSymbol symbol, TArgument argument)
Microsoft.CodeAnalysis.Analyzers (11)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis.AnalyzerUtilities (11)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis.CodeStyle (11)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis.CSharp (28)
Compilation\CSharpSemanticModel.cs (2)
3186public abstract ILabelSymbol GetDeclaredSymbol(LabeledStatementSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken)); 3194public abstract ILabelSymbol GetDeclaredSymbol(SwitchLabelSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken));
Compilation\MemberSemanticModel.cs (2)
759public override ILabelSymbol GetDeclaredSymbol(LabeledStatementSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken)) 785public override ILabelSymbol GetDeclaredSymbol(SwitchLabelSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken))
Compilation\SpeculativeSemanticModelWithMemberModel.cs (2)
345public override ILabelSymbol GetDeclaredSymbol(LabeledStatementSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken)) 350public override ILabelSymbol GetDeclaredSymbol(SwitchLabelSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken))
Compilation\SyntaxTreeSemanticModel.cs (2)
1904public override ILabelSymbol GetDeclaredSymbol(LabeledStatementSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken)) 1918public override ILabelSymbol GetDeclaredSymbol(SwitchLabelSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken))
CSharpExtensions.cs (2)
1576public static ILabelSymbol? GetDeclaredSymbol(this SemanticModel? semanticModel, LabeledStatementSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken)) 1585public static ILabelSymbol? GetDeclaredSymbol(this SemanticModel? semanticModel, SwitchLabelSyntax declarationSyntax, CancellationToken cancellationToken = default(CancellationToken))
Operations\CSharpOperationFactory.cs (14)
1847ILabelSymbol target = boundContinueStatement.Label.GetPublicSymbol(); 1856ILabelSymbol target = boundBreakStatement.Label.GetPublicSymbol(); 1873ILabelSymbol target = boundGotoStatement.Label.GetPublicSymbol(); 1934ILabelSymbol continueLabel = boundWhileStatement.ContinueLabel.GetPublicSymbol(); 1935ILabelSymbol exitLabel = boundWhileStatement.BreakLabel.GetPublicSymbol(); 1947ILabelSymbol continueLabel = boundDoStatement.ContinueLabel.GetPublicSymbol(); 1948ILabelSymbol exitLabel = boundDoStatement.BreakLabel.GetPublicSymbol(); 1965ILabelSymbol continueLabel = boundForStatement.ContinueLabel.GetPublicSymbol(); 1966ILabelSymbol exitLabel = boundForStatement.BreakLabel.GetPublicSymbol(); 2072ILabelSymbol continueLabel = boundForEachStatement.ContinueLabel.GetPublicSymbol(); 2073ILabelSymbol exitLabel = boundForEachStatement.BreakLabel.GetPublicSymbol(); 2276ILabelSymbol label = boundLabelStatement.Label.GetPublicSymbol(); 2284ILabelSymbol label = boundLabeledStatement.Label.GetPublicSymbol(); 2774ILabelSymbol exitLabel = boundSwitchStatement.BreakLabel.GetPublicSymbol();
SymbolDisplay\SymbolDisplayVisitor.cs (1)
327public override void VisitLabel(ILabelSymbol symbol)
Symbols\PublicModel\LabelSymbol.cs (1)
21IMethodSymbol ILabelSymbol.ContainingMethod
Symbols\SymbolExtensions.cs (2)
629internal static ILabelSymbol? GetPublicSymbol(this LabelSymbol? symbol) 631return symbol.GetPublicSymbol<ILabelSymbol>();
Microsoft.CodeAnalysis.CSharp.CodeStyle (5)
src\roslyn\src\Analyzers\CSharp\Analyzers\UseLabeledJumpStatements\CSharpUseLabeledJumpStatementsHelpers.cs (5)
40if (!TryResolveLabel(gotoStatement, semanticModel, cancellationToken, out var label, out var declaration)) 92if (TryResolveLabel(gotoStatement, semanticModel, cancellationToken, out var label, out var declaration) && 115[NotNullWhen(true)] out ILabelSymbol? label, 124label = semanticModel.GetSymbolInfo(labelReference, cancellationToken).Symbol as ILabelSymbol; 132ILabelSymbol label,
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\roslyn\src\Analyzers\CSharp\CodeFixes\UseLabeledJumpStatements\CSharpUseLabeledJumpStatementsCodeFixProvider.cs (1)
125if (semanticModel.GetDeclaredSymbol(labelDeclaration, cancellationToken) is ILabelSymbol label)
Microsoft.CodeAnalysis.CSharp.Features (7)
GoToDefinition\CSharpGoToDefinitionSymbolService.cs (1)
71var target = gotoOperation.Target;
src\roslyn\src\Analyzers\CSharp\Analyzers\UseLabeledJumpStatements\CSharpUseLabeledJumpStatementsHelpers.cs (5)
40if (!TryResolveLabel(gotoStatement, semanticModel, cancellationToken, out var label, out var declaration)) 92if (TryResolveLabel(gotoStatement, semanticModel, cancellationToken, out var label, out var declaration) && 115[NotNullWhen(true)] out ILabelSymbol? label, 124label = semanticModel.GetSymbolInfo(labelReference, cancellationToken).Symbol as ILabelSymbol; 132ILabelSymbol label,
src\roslyn\src\Analyzers\CSharp\CodeFixes\UseLabeledJumpStatements\CSharpUseLabeledJumpStatementsCodeFixProvider.cs (1)
125if (semanticModel.GetDeclaredSymbol(labelDeclaration, cancellationToken) is ILabelSymbol label)
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
Classification\SyntaxClassification\NameSyntaxClassifier.cs (1)
223case ILabelSymbol:
Microsoft.CodeAnalysis.Extensions.Package (6)
Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis.Features (4)
FindUsages\AbstractFindUsagesService_FindReferences.cs (1)
209if (symbol is ILabelSymbol)
LanguageServices\AnonymousTypeDisplayService\AbstractStructuralTypeDisplayService.StructuralTypeCollectorVisitor.cs (1)
40public override void VisitLabel(ILabelSymbol symbol)
LanguageServices\SymbolDisplayService\AbstractSymbolDisplayService.AbstractSymbolDescriptionBuilder.cs (2)
418else if (symbol is ILabelSymbol label) 708private void AddDescriptionForLabel(ILabelSymbol symbol)
Microsoft.CodeAnalysis.ResxSourceGenerator (11)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Microsoft.CodeAnalysis.Workspaces (12)
FindSymbols\FindReferences\Finders\LabelSymbolReferenceFinder.cs (1)
7internal sealed class LabelSymbolReferenceFinder : AbstractMemberScopedReferenceFinder<ILabelSymbol>
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)
Roslyn.Diagnostics.Analyzers (12)
AbstractDoNotCopyValue.cs (1)
294public override void VisitLabel(ILabelSymbol symbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.cs (2)
75/// Interior-method-level symbols (i.e. <see cref="ILabelSymbol"/>, <see cref="ILocalSymbol"/>, <see 320ILabelSymbol => true,
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.SymbolKeyWriter.cs (1)
353public override void VisitLabel(ILabelSymbol labelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AbstractSpeculationAnalyzer.cs (2)
462if (symbol is ILabelSymbol && newSymbol is ILabelSymbol)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.EquivalenceVisitor.cs (4)
122SymbolKind.Label => LabelsAreEquivalent((ILabelSymbol)x, (ILabelSymbol)y), 160private static bool LabelsAreEquivalent(ILabelSymbol x, ILabelSymbol y)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Extensions\Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (2)
66SymbolKind.Label => CombineHashCodes((ILabelSymbol)x, currentHash), 99private static int CombineHashCodes(ILabelSymbol x, int currentHash)