4 instantiations of BoundConstantPattern
Microsoft.CodeAnalysis.CSharp (4)
Binder\Binder_Operators.cs (1)
4853
var boundConstantPattern = new
BoundConstantPattern
(
Binder\Binder_Patterns.cs (1)
451
return new
BoundConstantPattern
(
Binder\DecisionDagBuilder_CheckOrReachability.cs (1)
1088
var nullCheck = new
BoundConstantPattern
(node.Syntax,
Generated\BoundNodes.xml.Generated.cs (1)
8052
var result = new
BoundConstantPattern
(this.Syntax, value, constantValue, inputType, narrowedType, this.HasErrors);
35 references to BoundConstantPattern
Microsoft.CodeAnalysis.CSharp (35)
Binder\Binder_Operators.cs (1)
4853
var
boundConstantPattern = new BoundConstantPattern(
Binder\Binder_Patterns.cs (2)
76
case
BoundConstantPattern
_:
114
case
BoundConstantPattern
_:
Binder\DecisionDagBuilder.cs (2)
338
case
BoundConstantPattern
constant:
530
BoundConstantPattern
constant,
Binder\DecisionDagBuilder_CheckOrReachability.cs (4)
795
or
BoundConstantPattern
946
public override BoundNode? VisitConstantPattern(
BoundConstantPattern
node)
1005
if (pattern is
BoundConstantPattern
constantPattern)
1088
var
nullCheck = new BoundConstantPattern(node.Syntax,
Binder\SwitchBinder_Patterns.cs (2)
117
if (label.Pattern is
BoundConstantPattern
cp && !cp.ConstantValue.IsBad && FindMatchingSwitchCaseLabel(cp.ConstantValue, p) != label.Label)
298
if (pattern is
BoundConstantPattern
{ HasErrors: false } && IsUnderscore(expression))
BoundTree\BoundNode_Source.cs (1)
358
case
BoundConstantPattern
constantPattern:
FlowAnalysis\AbstractFlowPass.cs (6)
927
BoundDeclarationPattern or
BoundConstantPattern
or BoundNegatedPattern or BoundBinaryPattern or
988
case
BoundConstantPattern
{ ConstantValue: { IsNull: false } }:
992
case
BoundConstantPattern
{ ConstantValue: { IsNull: true } }:
1033
case
BoundConstantPattern
{ ConstantValue: { IsBoolean: true, BooleanValue: var boolValue } }:
1064
case
BoundConstantPattern
{ ConstantValue: { IsBoolean: false } }:
1107
public override BoundNode VisitConstantPattern(
BoundConstantPattern
node)
FlowAnalysis\DefiniteAssignment.cs (2)
1978
var
pat = (
BoundConstantPattern
)pattern;
FlowAnalysis\NullableWalker_Patterns.cs (2)
63
public override BoundNode VisitConstantPattern(
BoundConstantPattern
node)
166
case
BoundConstantPattern
cp:
FlowAnalysis\VariablesDeclaredWalker.cs (1)
100
case
BoundConstantPattern
constantPattern:
Generated\BoundNodes.xml.Generated.cs (9)
8048
public
BoundConstantPattern
Update(BoundExpression value, ConstantValue constantValue, TypeSymbol inputType, TypeSymbol narrowedType)
8052
var
result = new BoundConstantPattern(this.Syntax, value, constantValue, inputType, narrowedType, this.HasErrors);
9295
return VisitConstantPattern((
BoundConstantPattern
)node, arg);
9557
public virtual R VisitConstantPattern(
BoundConstantPattern
node, A arg) => this.DefaultVisit(node, arg);
9793
public virtual BoundNode? VisitConstantPattern(
BoundConstantPattern
node) => this.DefaultVisit(node);
10726
public override BoundNode? VisitConstantPattern(
BoundConstantPattern
node)
12235
public override BoundNode? VisitConstantPattern(
BoundConstantPattern
node)
14890
public override BoundNode? VisitConstantPattern(
BoundConstantPattern
node)
17079
public override TreeDumperNode VisitConstantPattern(
BoundConstantPattern
node, object? arg) => new TreeDumperNode("constantPattern", null, new TreeDumperNode[]
Operations\CSharpOperationFactory.cs (3)
225
return CreateBoundConstantPatternOperation((
BoundConstantPattern
)boundNode);
2506
private IConstantPatternOperation CreateBoundConstantPatternOperation(
BoundConstantPattern
boundConstantPattern)
2749
boundSwitchLabel.Pattern is
BoundConstantPattern
cp &&