4 instantiations of BoundPatternWithUnionMatching
Microsoft.CodeAnalysis.CSharp (4)
Binder\UnionMatchingRewriter.cs (3)
69return new BoundPatternWithUnionMatching( 358leftOfPendingConjunction = new BoundPatternWithUnionMatching( 381return new BoundPatternWithUnionMatching(
Generated\BoundNodes.xml.Generated.cs (1)
8218var result = new BoundPatternWithUnionMatching(this.Syntax, unionMatchingInputType, leftOfPendingConjunction, exclusiveInstancePattern, valueProperty, exclusiveValuePattern, sharedRightOfPendingConjunction, inputType, narrowedType, this.HasErrors);
33 references to BoundPatternWithUnionMatching
Microsoft.CodeAnalysis.CSharp (33)
Binder\UnionMatchingRewriter.cs (16)
17/// a <see cref="BoundPatternWithUnionMatching"/> node created during the rewrite. Rewriter keeps a 18/// <see cref="BoundPatternWithUnionMatching"/> node at the top of the result until we reach a point 55private static BoundPatternWithUnionMatching CreatePatternWithUnionMatching(NamedTypeSymbol unionMatchingInputType, BoundPattern exclusiveValuePattern) 60private static BoundPatternWithUnionMatching CreatePatternWithUnionMatching(NamedTypeSymbol unionMatchingInputType, BoundPattern? exclusiveInstancePattern, BoundPattern exclusiveValuePattern) 94BoundPatternWithUnionMatching underlyingValueMatching = CreatePatternWithUnionMatching( 247if (result is BoundPatternWithUnionMatching unionPattern) 314narrowedTypeCandidates.Add(result is BoundPatternWithUnionMatching unionResult ? getDisjunctionType(unionResult) : result.NarrowedType); 327if (right is BoundPatternWithUnionMatching rightUnionPattern) 342var stack = ArrayBuilder<BoundPatternWithUnionMatching>.GetInstance(); 346while (rightUnionPattern.LeftOfPendingConjunction is BoundPatternWithUnionMatching other) 352Debug.Assert(rightUnionPattern.LeftOfPendingConjunction is not BoundPatternWithUnionMatching); 376if (left is BoundPatternWithUnionMatching leftUnionPattern) 405static TypeSymbol getDisjunctionType(BoundPatternWithUnionMatching unionPattern) 410while (unionPattern.LeftOfPendingConjunction is BoundPatternWithUnionMatching leftUnionPattern) 441if (pattern is BoundPatternWithUnionMatching unionPattern) 514if (leftOfPendingConjunction is BoundPatternWithUnionMatching leftUnionPattern)
BoundTree\BoundBinaryPattern.cs (2)
14Debug.Assert(Left is not BoundPatternWithUnionMatching); 15Debug.Assert(Right is not BoundPatternWithUnionMatching);
BoundTree\BoundListPattern.cs (1)
21Debug.Assert(!Subpatterns.Any(p => p is BoundPatternWithUnionMatching));
BoundTree\BoundNegatedPattern.cs (1)
16Debug.Assert(Negated is not BoundPatternWithUnionMatching);
BoundTree\BoundPatternWithUnionMatching.cs (2)
18Debug.Assert(ExclusiveValuePattern is not BoundPatternWithUnionMatching); 19Debug.Assert(SharedRightOfPendingConjunction is not BoundPatternWithUnionMatching);
BoundTree\BoundSlicePattern.cs (1)
18Debug.Assert(Pattern is not BoundPatternWithUnionMatching);
BoundTree\BoundSubpattern.cs (1)
13Debug.Assert(Pattern is not BoundPatternWithUnionMatching);
Generated\BoundNodes.xml.Generated.cs (9)
8214public BoundPatternWithUnionMatching Update(TypeSymbol unionMatchingInputType, BoundPattern? leftOfPendingConjunction, BoundPattern? exclusiveInstancePattern, BoundPropertySubpatternMember valueProperty, BoundPattern exclusiveValuePattern, BoundPattern? sharedRightOfPendingConjunction, TypeSymbol inputType, TypeSymbol narrowedType) 8218var result = new BoundPatternWithUnionMatching(this.Syntax, unionMatchingInputType, leftOfPendingConjunction, exclusiveInstancePattern, valueProperty, exclusiveValuePattern, sharedRightOfPendingConjunction, inputType, narrowedType, this.HasErrors); 9506return VisitPatternWithUnionMatching((BoundPatternWithUnionMatching)node, arg); 9774public virtual R VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node, A arg) => this.DefaultVisit(node, arg); 10015public virtual BoundNode? VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node) => this.DefaultVisit(node); 10979public override BoundNode? VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node) 12523public override BoundNode? VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node) 15219public override BoundNode? VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node) 17471public override TreeDumperNode VisitPatternWithUnionMatching(BoundPatternWithUnionMatching node, object? arg) => new TreeDumperNode("patternWithUnionMatching", null, new TreeDumperNode[]