6 instantiations of BoundSwitchLabel
Microsoft.CodeAnalysis.CSharp (6)
Binder\SwitchBinder_Patterns.cs (5)
134newLabel = new BoundSwitchLabel(label.Syntax, label.Label, label.Pattern, label.WhenClause, hasErrors: true); 255return new BoundSwitchLabel(node, label, pattern, null, pattern.HasErrors); 266return new BoundSwitchLabel(node, label, pattern, null, hasErrors); 272return defaultLabel = new BoundSwitchLabel(node, label, pattern, null, hasErrors); 287return new BoundSwitchLabel(node, label, pattern,
Generated\BoundNodes.xml.Generated.cs (1)
5719var result = new BoundSwitchLabel(this.Syntax, label, pattern, whenClause, this.HasErrors);
50 references to BoundSwitchLabel
Microsoft.CodeAnalysis.CSharp (50)
Binder\DecisionDagBuilder.cs (1)
151foreach (BoundSwitchLabel label in section.SwitchLabels)
Binder\DecisionDagBuilder_CheckOrReachability.cs (2)
174foreach (BoundSwitchLabel label in section.SwitchLabels) 191foreach (BoundSwitchLabel label in section.SwitchLabels)
Binder\SwitchBinder_Patterns.cs (12)
42ImmutableArray<BoundSwitchSection> switchSections = BindSwitchSections(originalBinder, diagnostics, out BoundSwitchLabel defaultLabel); 85static bool isSubsumed(BoundSwitchLabel switchLabel, ImmutableHashSet<LabelSymbol> reachableLabels) 100var labelBuilder = ArrayBuilder<BoundSwitchLabel>.GetInstance(oldSection.SwitchLabels.Length); 101foreach (var label in oldSection.SwitchLabels) 103var newLabel = label; 158BoundSwitchLabel defaultLabel = null; 173out BoundSwitchLabel defaultLabel) 193ref BoundSwitchLabel defaultLabel, 197var boundLabelsBuilder = ArrayBuilder<BoundSwitchLabel>.GetInstance(node.Labels.Count); 205BoundSwitchLabel boundLabel = BindSwitchSectionLabel(sectionBinder, labelSyntax, label, ref defaultLabel, diagnostics); 237private BoundSwitchLabel BindSwitchSectionLabel( 241ref BoundSwitchLabel defaultLabel,
BoundTree\BoundNode_Source.cs (2)
276foreach (var label in section.SwitchLabels) 297case BoundSwitchLabel label:
BoundTree\BoundStatementExtensions.cs (1)
43foreach (var boundSwitchLabel in ((BoundSwitchSection)node).SwitchLabels)
FlowAnalysis\AbstractFlowPass.cs (1)
863foreach (var label in sec.SwitchLabels)
FlowAnalysis\AbstractFlowPass_Switch.cs (2)
49foreach (var label in section.SwitchLabels) 123foreach (var label in node.SwitchLabels)
FlowAnalysis\ControlFlowPass.cs (1)
389foreach (var label in section.SwitchLabels)
FlowAnalysis\NullableWalker_Patterns.cs (3)
282foreach (var label in section.SwitchLabels) 303foreach (var label in section.SwitchLabels) 320foreach (var label in node.SwitchLabels)
FlowAnalysis\VariablesDeclaredWalker.cs (1)
59foreach (var label in node.SwitchLabels)
Generated\BoundNodes.xml.Generated.cs (20)
3778public BoundSwitchStatement(SyntaxNode syntax, BoundExpression expression, ImmutableArray<LocalSymbol> innerLocals, ImmutableArray<MethodSymbol> innerLocalFunctions, ImmutableArray<BoundSwitchSection> switchSections, BoundDecisionDag reachabilityDecisionDag, BoundSwitchLabel? defaultLabel, LabelSymbol breakLabel, bool hasErrors = false) 3803public BoundSwitchLabel? DefaultLabel { get; } 3809public BoundSwitchStatement Update(BoundExpression expression, ImmutableArray<LocalSymbol> innerLocals, ImmutableArray<MethodSymbol> innerLocalFunctions, ImmutableArray<BoundSwitchSection> switchSections, BoundDecisionDag reachabilityDecisionDag, BoundSwitchLabel? defaultLabel, LabelSymbol breakLabel) 5664public BoundSwitchSection(SyntaxNode syntax, ImmutableArray<LocalSymbol> locals, ImmutableArray<BoundSwitchLabel> switchLabels, ImmutableArray<BoundStatement> statements, bool hasErrors = false) 5677public ImmutableArray<BoundSwitchLabel> SwitchLabels { get; } 5682public BoundSwitchSection Update(ImmutableArray<LocalSymbol> locals, ImmutableArray<BoundSwitchLabel> switchLabels, ImmutableArray<BoundStatement> statements) 5715public BoundSwitchLabel Update(LabelSymbol label, BoundPattern pattern, BoundExpression? whenClause) 5719var result = new BoundSwitchLabel(this.Syntax, label, pattern, whenClause, this.HasErrors); 9179return VisitSwitchLabel((BoundSwitchLabel)node, arg); 9500public virtual R VisitSwitchLabel(BoundSwitchLabel node, A arg) => this.DefaultVisit(node, arg); 9736public virtual BoundNode? VisitSwitchLabel(BoundSwitchLabel node) => this.DefaultVisit(node); 10441public override BoundNode? VisitSwitchLabel(BoundSwitchLabel node) 11459BoundSwitchLabel? defaultLabel = (BoundSwitchLabel?)this.Visit(node.DefaultLabel); 11804ImmutableArray<BoundSwitchLabel> switchLabels = this.VisitList(node.SwitchLabels); 11808public override BoundNode? VisitSwitchLabel(BoundSwitchLabel node) 13581BoundSwitchLabel? defaultLabel = (BoundSwitchLabel?)this.Visit(node.DefaultLabel); 13908ImmutableArray<BoundSwitchLabel> switchLabels = this.VisitList(node.SwitchLabels); 16433public override TreeDumperNode VisitSwitchLabel(BoundSwitchLabel node, object? arg) => new TreeDumperNode("switchLabel", null, new TreeDumperNode[]
Lowering\LocalRewriter\LocalRewriter_PatternSwitchStatement.cs (1)
135foreach (BoundSwitchLabel switchLabel in section.SwitchLabels)
Operations\CSharpOperationFactory.cs (3)
249return CreateBoundSwitchLabelOperation((BoundSwitchLabel)boundNode); 2688ImmutableArray<ICaseClauseOperation> clauses = CreateFromArray<BoundSwitchLabel, ICaseClauseOperation>(boundSwitchSection.SwitchLabels); 2736private ICaseClauseOperation CreateBoundSwitchLabelOperation(BoundSwitchLabel boundSwitchLabel)