36 instantiations of BoundDagTemp
Microsoft.CodeAnalysis.CSharp (36)
Binder\DecisionDagBuilder.cs (5)
337
var valueAsITuple = new
BoundDagTemp
(syntax, iTupleType, valueAsITupleEvaluation);
475
input = new
BoundDagTemp
(syntax, type, evaluation);
541
var element = new
BoundDagTemp
(syntax, method.Parameters[i + extensionExtra].Type, evaluation, i);
565
var element = new
BoundDagTemp
(syntax, field.Type, evaluation);
631
input = new
BoundDagTemp
(member.Syntax, member.Type, evaluation);
Binder\DecisionDagBuilder_ListPatterns.cs (2)
67
var sliceTemp = new
BoundDagTemp
(slicePattern.Syntax, slicePattern.InputType, sliceEvaluation);
82
var indexTemp = new
BoundDagTemp
(subpattern.Syntax, subpattern.InputType, indexEvaluation);
Binder\PatternExplainer.cs (9)
344
var typedTemp = new
BoundDagTemp
(te.Syntax, te.Type, te);
359
var typedTemp = new
BoundDagTemp
(te.Syntax, te.Type, te);
403
var lengthTemp = new
BoundDagTemp
(lengthOrCount.Syntax, lengthOrCount.Property.Type, lengthOrCount);
431
var indexerTemp = new
BoundDagTemp
(e.Syntax, e.IndexerType, e);
450
var sliceTemp = new
BoundDagTemp
(slice.Syntax, slice.SliceType, slice);
479
var elementTemp = new
BoundDagTemp
(e.Syntax, e.Field.Type, e);
547
var elementTemp = new
BoundDagTemp
(e.Syntax, method.Parameters[j + extensionExtra].Type, e, j);
566
var subInput = new
BoundDagTemp
(e.Syntax, e.Field.Type, e);
573
var subInput = new
BoundDagTemp
(e.Syntax, e.Property.Type, e);
BoundTree\BoundDagTemp.cs (1)
21
public static BoundDagTemp ForOriginalInput(SyntaxNode syntax, TypeSymbol type) => new
BoundDagTemp
(syntax, type, source: null, 0);
BoundTree\Constructors.cs (1)
637
public static BoundDagTemp ForOriginalInput(BoundExpression expr) => new
BoundDagTemp
(expr.Syntax, expr.Type!, source: null);
FlowAnalysis\NullableWalker_Patterns.cs (7)
452
var output = new
BoundDagTemp
(e.Syntax, parameterType.Type, e, i);
461
var output = new
BoundDagTemp
(e.Syntax, e.Type, e);
490
var output = new
BoundDagTemp
(e.Syntax, type.Type, e);
536
var output = new
BoundDagTemp
(e.Syntax, type.Type, e);
561
var output = new
BoundDagTemp
(e.Syntax, type.Type, e);
573
var output = new
BoundDagTemp
(e.Syntax, type.Type, e);
840
var output = new
BoundDagTemp
(e.Syntax, type.Type, e, index: index);
Generated\BoundNodes.xml.Generated.cs (1)
5222
var result = new
BoundDagTemp
(this.Syntax, type, source, index, this.HasErrors);
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (10)
143
var outputTemp = new
BoundDagTemp
(f.Syntax, field.Type, f);
153
var outputTemp = new
BoundDagTemp
(p.Syntax, property.Type, p);
190
var outputTemp = new
BoundDagTemp
(d.Syntax, parameter.Type, d, i - extensionExtra);
210
var outputTemp = new
BoundDagTemp
(t.Syntax, type, t);
247
var outputTemp = new
BoundDagTemp
(e.Syntax, type, e);
272
var outputTemp = new
BoundDagTemp
(e.Syntax, e.IndexerType, e);
298
var outputTemp = new
BoundDagTemp
(e.Syntax, e.SliceType, e);
476
BoundExpression output = _tempAllocator.GetTemp(new
BoundDagTemp
(evaluation.Syntax, typeEvaluation1.Type, evaluation));
492
BoundExpression output = _tempAllocator.GetTemp(new
BoundDagTemp
(evaluation.Syntax, baseType, evaluation));
629
var temp = new
BoundDagTemp
(expr.Syntax, expr.Type, fieldFetchEvaluation);
239 references to BoundDagTemp
Microsoft.CodeAnalysis.CSharp (239)
Binder\DecisionDagBuilder.cs (74)
133
var
rootIdentifier =
BoundDagTemp
.ForOriginalInput(inputExpression);
146
var
rootIdentifier =
BoundDagTemp
.ForOriginalInput(switchGoverningExpression);
171
var
rootIdentifier =
BoundDagTemp
.ForOriginalInput(switchExpressionInput);
186
BoundDagTemp
input,
196
BoundDagTemp
input,
217
BoundDagTemp
temp = binding.TempContainingValue;
269
BoundDagTemp
input,
282
BoundDagTemp
input,
284
out
BoundDagTemp
output,
319
BoundDagTemp
input,
321
out
BoundDagTemp
output,
337
var
valueAsITuple = new BoundDagTemp(syntax, iTupleType, valueAsITupleEvaluation);
342
var
lengthTemp = new BoundDagTemp(syntax, this._compilation.GetSpecialType(SpecialType.System_Int32), lengthEvaluation);
345
var
getItemPropertyInput = OriginalInput(valueAsITuple, getItemProperty);
350
var
indexTemp = new BoundDagTemp(syntax, objectType, indexEvaluation);
363
private
BoundDagTemp
OriginalInput(
BoundDagTemp
input, Symbol symbol)
379
private static
BoundDagTemp
OriginalInput(
BoundDagTemp
input)
392
BoundDagTemp
input,
394
out
BoundDagTemp
output,
420
BoundDagTemp
input,
422
out
BoundDagTemp
output)
431
BoundDagTemp
input,
448
private
BoundDagTemp
MakeConvertToType(
449
BoundDagTemp
input,
483
BoundDagTemp
input,
485
out
BoundDagTemp
output)
517
BoundDagTemp
input,
519
out
BoundDagTemp
output,
541
var
element = new BoundDagTemp(syntax, method.Parameters[i + extensionExtra].Type, evaluation, i);
565
var
element = new BoundDagTemp(syntax, field.Type, evaluation);
584
BoundDagTemp
currentInput = input;
605
bool tryMakeTestsForSubpatternMember([NotNullWhen(true)] BoundPropertySubpatternMember? member, ref
BoundDagTemp
input, bool isLengthOrCount)
636
private Tests MakeTestsAndBindingsForNegatedPattern(
BoundDagTemp
input, BoundNegatedPattern neg, ArrayBuilder<BoundPatternBinding> bindings)
643
BoundDagTemp
input,
645
out
BoundDagTemp
output,
671
static Tests makeTestsAndBindingsForBinaryPattern(DecisionDagBuilder @this, Tests leftTests,
BoundDagTemp
leftOutput,
BoundDagTemp
input, BoundBinaryPattern bin, out
BoundDagTemp
output, ArrayBuilder<BoundPatternBinding> bindings)
695
builder.Add(@this.MakeTestsAndBindings(leftOutput, bin.Right, out
var
rightOutput, bindings));
704
BoundDagTemp
input,
706
out
BoundDagTemp
output)
828
DagState uniquifyState(FrozenArrayBuilder<StateForCase> cases, ImmutableDictionary<
BoundDagTemp
, IValueSet> remainingValues)
841
var newRemainingValues = ImmutableDictionary.CreateBuilder<
BoundDagTemp
, IValueSet>();
887
ImmutableDictionary<
BoundDagTemp
, IValueSet>.Empty);
1088
out ImmutableDictionary<
BoundDagTemp
, IValueSet> whenTrueValues,
1090
out ImmutableDictionary<
BoundDagTemp
, IValueSet> whenFalseValues,
1125
ImmutableDictionary<
BoundDagTemp
, IValueSet> whenTrueValues,
1126
ImmutableDictionary<
BoundDagTemp
, IValueSet> whenFalseValues,
1130
ImmutableDictionary<
BoundDagTemp
, IValueSet> values,
1149
ImmutableDictionary<
BoundDagTemp
, IValueSet> whenTrueValues,
1150
ImmutableDictionary<
BoundDagTemp
, IValueSet> whenFalseValues,
1155
var
input = test.Input;
1175
private static (
BoundDagTemp
? lengthTemp, int offset) TryGetTopLevelLengthTemp(BoundDagPropertyEvaluation e)
1179
BoundDagTemp
input = e.Input;
1180
BoundDagTemp
? lengthTemp = null;
1191
private static (
BoundDagTemp
input,
BoundDagTemp
lengthTemp, int index) GetCanonicalInput(BoundDagIndexerEvaluation e)
1194
BoundDagTemp
input = e.Input;
1195
BoundDagTemp
lengthTemp = e.LengthTemp;
1436
BoundDagTemp
s1Input = OriginalInput(test.Input);
1437
BoundDagTemp
s2Input = OriginalInput(other.Input);
1468
(s1Input,
BoundDagTemp
s1LengthTemp, int s1Index) = GetCanonicalInput(s1);
1469
(s2Input,
BoundDagTemp
s2LengthTemp, int s2Index) = GetCanonicalInput(s2);
1670
string tempName(
BoundDagTemp
t)
1852
/// A <see cref="
BoundDagTemp
"/> absent from this dictionary means that all values of the type are possible.
1854
public ImmutableDictionary<
BoundDagTemp
, IValueSet> RemainingValues { get; private set; } = null!;
1883
public static DagState GetInstance(FrozenArrayBuilder<StateForCase> cases, ImmutableDictionary<
BoundDagTemp
, IValueSet> remainingValues)
1927
internal void UpdateRemainingValues(ImmutableDictionary<
BoundDagTemp
, IValueSet> newRemainingValues)
2232
if (TryGetTopLevelLengthTemp(e) is (
BoundDagTemp
lengthTemp, int offset))
Binder\DecisionDagBuilder_ListPatterns.cs (5)
13
private Tests MakeTestsAndBindingsForListPattern(
BoundDagTemp
input, BoundListPattern list, out
BoundDagTemp
output, ArrayBuilder<BoundPatternBinding> bindings)
43
var
lengthTemp = new BoundDagTemp(syntax, _compilation.GetSpecialType(SpecialType.System_Int32), lengthEvaluation);
67
var
sliceTemp = new BoundDagTemp(slicePattern.Syntax, slicePattern.InputType, sliceEvaluation);
82
var
indexTemp = new BoundDagTemp(subpattern.Syntax, subpattern.InputType, indexEvaluation);
Binder\PatternExplainer.cs (22)
180
BoundDagTemp
rootIdentifier,
210
static string samplePatternFromOtherPaths(
BoundDagTemp
rootIdentifier, BoundDecisionDagNode rootNode,
245
out Dictionary<
BoundDagTemp
, ArrayBuilder<(BoundDagTest, bool)>> constraints,
246
out Dictionary<
BoundDagTemp
, ArrayBuilder<BoundDagEvaluation>> evaluations)
248
constraints = new Dictionary<
BoundDagTemp
, ArrayBuilder<(BoundDagTest, bool)>>();
249
evaluations = new Dictionary<
BoundDagTemp
, ArrayBuilder<BoundDagEvaluation>>();
260
BoundDagTemp
temp = test.Input;
278
BoundDagTemp
temp = e.Evaluation.Input;
292
BoundDagTemp
input,
293
Dictionary<
BoundDagTemp
, ArrayBuilder<(BoundDagTest test, bool sense)>> constraintMap,
294
Dictionary<
BoundDagTemp
, ArrayBuilder<BoundDagEvaluation>> evaluationMap,
311
static ImmutableArray<T> getArray<T>(Dictionary<
BoundDagTemp
, ArrayBuilder<T>> map,
BoundDagTemp
temp)
344
var
typedTemp = new BoundDagTemp(te.Syntax, te.Type, te);
359
var
typedTemp = new BoundDagTemp(te.Syntax, te.Type, te);
403
var
lengthTemp = new BoundDagTemp(lengthOrCount.Syntax, lengthOrCount.Property.Type, lengthOrCount);
431
var
indexerTemp = new BoundDagTemp(e.Syntax, e.IndexerType, e);
450
var
sliceTemp = new BoundDagTemp(slice.Syntax, slice.SliceType, slice);
479
var
elementTemp = new BoundDagTemp(e.Syntax, e.Field.Type, e);
547
var
elementTemp = new BoundDagTemp(e.Syntax, method.Parameters[j + extensionExtra].Type, e, j);
566
var
subInput = new BoundDagTemp(e.Syntax, e.Field.Type, e);
573
var
subInput = new BoundDagTemp(e.Syntax, e.Property.Type, e);
Binder\SwitchExpressionBinder.cs (1)
96
BoundDagTemp
.ForOriginalInput(boundInputExpression), nodes, n, nullPaths: false, out bool requiresFalseWhenClause, out bool unnamedEnumValue);
BoundTree\BoundDagTemp.cs (4)
21
public static
BoundDagTemp
ForOriginalInput(SyntaxNode syntax, TypeSymbol type) => new BoundDagTemp(syntax, type, source: null, 0);
23
public override bool Equals(object? obj) => obj is
BoundDagTemp
other && this.Equals(other);
25
public bool Equals(
BoundDagTemp
other)
36
public bool IsEquivalentTo(
BoundDagTemp
other)
BoundTree\BoundPatternBinding.cs (2)
15
public readonly
BoundDagTemp
TempContainingValue;
16
public BoundPatternBinding(BoundExpression variableAccess,
BoundDagTemp
tempContainingValue)
BoundTree\Constructors.cs (1)
637
public static
BoundDagTemp
ForOriginalInput(BoundExpression expr) => new BoundDagTemp(expr.Syntax, expr.Type!, source: null);
FlowAnalysis\NullableWalker_Patterns.cs (14)
385
var
rootTemp =
BoundDagTemp
.ForOriginalInput(expression);
409
var tempMap = PooledDictionary<
BoundDagTemp
, (int slot, TypeSymbol type)>.GetInstance();
452
var
output = new BoundDagTemp(e.Syntax, parameterType.Type, e, i);
461
var
output = new BoundDagTemp(e.Syntax, e.Type, e);
490
var
output = new BoundDagTemp(e.Syntax, type.Type, e);
536
var
output = new BoundDagTemp(e.Syntax, type.Type, e);
561
var
output = new BoundDagTemp(e.Syntax, type.Type, e);
573
var
output = new BoundDagTemp(e.Syntax, type.Type, e);
675
var
tempSource = binding.TempContainingValue;
740
void addToTempMap(
BoundDagTemp
output, int slot, TypeSymbol type)
831
int makeDagTempSlot(TypeWithAnnotations type,
BoundDagTemp
temp)
840
var
output = new BoundDagTemp(e.Syntax, type.Type, e, index: index);
903
BoundDagTemp
.ForOriginalInput(node.Expression), nodes, leaf, nullPaths: true, out bool requiresFalseWhenClause, out _);
Generated\BoundNodes.xml.Generated.cs (94)
5186
protected BoundDagTest(BoundKind kind, SyntaxNode syntax,
BoundDagTemp
input, bool hasErrors = false)
5195
public
BoundDagTemp
Input { get; }
5218
public
BoundDagTemp
Update(TypeSymbol type, BoundDagEvaluation? source, int index)
5222
var
result = new BoundDagTemp(this.Syntax, type, source, index, this.HasErrors);
5232
public BoundDagTypeTest(SyntaxNode syntax, TypeSymbol type,
BoundDagTemp
input, bool hasErrors = false)
5247
public BoundDagTypeTest Update(TypeSymbol type,
BoundDagTemp
input)
5261
public BoundDagNonNullTest(SyntaxNode syntax, bool isExplicitTest,
BoundDagTemp
input, bool hasErrors = false)
5275
public BoundDagNonNullTest Update(bool isExplicitTest,
BoundDagTemp
input)
5289
public BoundDagExplicitNullTest(SyntaxNode syntax,
BoundDagTemp
input, bool hasErrors = false)
5301
public BoundDagExplicitNullTest Update(
BoundDagTemp
input)
5315
public BoundDagValueTest(SyntaxNode syntax, ConstantValue value,
BoundDagTemp
input, bool hasErrors = false)
5330
public BoundDagValueTest Update(ConstantValue value,
BoundDagTemp
input)
5344
public BoundDagRelationalTest(SyntaxNode syntax, BinaryOperatorKind operatorKind, ConstantValue value,
BoundDagTemp
input, bool hasErrors = false)
5361
public BoundDagRelationalTest Update(BinaryOperatorKind operatorKind, ConstantValue value,
BoundDagTemp
input)
5375
protected BoundDagEvaluation(BoundKind kind, SyntaxNode syntax,
BoundDagTemp
input, bool hasErrors = false)
5387
public BoundDagDeconstructEvaluation(SyntaxNode syntax, MethodSymbol deconstructMethod,
BoundDagTemp
input, bool hasErrors = false)
5402
public BoundDagDeconstructEvaluation Update(MethodSymbol deconstructMethod,
BoundDagTemp
input)
5416
public BoundDagTypeEvaluation(SyntaxNode syntax, TypeSymbol type,
BoundDagTemp
input, bool hasErrors = false)
5431
public BoundDagTypeEvaluation Update(TypeSymbol type,
BoundDagTemp
input)
5445
public BoundDagFieldEvaluation(SyntaxNode syntax, FieldSymbol field,
BoundDagTemp
input, bool hasErrors = false)
5460
public BoundDagFieldEvaluation Update(FieldSymbol field,
BoundDagTemp
input)
5474
public BoundDagPropertyEvaluation(SyntaxNode syntax, PropertySymbol property, bool isLengthOrCount,
BoundDagTemp
input, bool hasErrors = false)
5491
public BoundDagPropertyEvaluation Update(PropertySymbol property, bool isLengthOrCount,
BoundDagTemp
input)
5505
public BoundDagIndexEvaluation(SyntaxNode syntax, PropertySymbol property, int index,
BoundDagTemp
input, bool hasErrors = false)
5522
public BoundDagIndexEvaluation Update(PropertySymbol property, int index,
BoundDagTemp
input)
5536
public BoundDagIndexerEvaluation(SyntaxNode syntax, TypeSymbol indexerType,
BoundDagTemp
lengthTemp, int index, BoundExpression indexerAccess, BoundListPatternReceiverPlaceholder receiverPlaceholder, BoundListPatternIndexPlaceholder argumentPlaceholder,
BoundDagTemp
input, bool hasErrors = false)
5560
public
BoundDagTemp
LengthTemp { get; }
5569
public BoundDagIndexerEvaluation Update(TypeSymbol indexerType,
BoundDagTemp
lengthTemp, int index, BoundExpression indexerAccess, BoundListPatternReceiverPlaceholder receiverPlaceholder, BoundListPatternIndexPlaceholder argumentPlaceholder,
BoundDagTemp
input)
5583
public BoundDagSliceEvaluation(SyntaxNode syntax, TypeSymbol sliceType,
BoundDagTemp
lengthTemp, int startIndex, int endIndex, BoundExpression indexerAccess, BoundSlicePatternReceiverPlaceholder receiverPlaceholder, BoundSlicePatternRangePlaceholder argumentPlaceholder,
BoundDagTemp
input, bool hasErrors = false)
5608
public
BoundDagTemp
LengthTemp { get; }
5618
public BoundDagSliceEvaluation Update(TypeSymbol sliceType,
BoundDagTemp
lengthTemp, int startIndex, int endIndex, BoundExpression indexerAccess, BoundSlicePatternReceiverPlaceholder receiverPlaceholder, BoundSlicePatternRangePlaceholder argumentPlaceholder,
BoundDagTemp
input)
5632
public BoundDagAssignmentEvaluation(SyntaxNode syntax,
BoundDagTemp
target,
BoundDagTemp
input, bool hasErrors = false)
5642
public
BoundDagTemp
Target { get; }
5647
public BoundDagAssignmentEvaluation Update(
BoundDagTemp
target,
BoundDagTemp
input)
9142
return VisitDagTemp((
BoundDagTemp
)node, arg);
9478
public virtual R VisitDagTemp(
BoundDagTemp
node, A arg) => this.DefaultVisit(node, arg);
9714
public virtual BoundNode? VisitDagTemp(
BoundDagTemp
node) => this.DefaultVisit(node);
10348
public override BoundNode? VisitDagTemp(
BoundDagTemp
node)
11703
public override BoundNode? VisitDagTemp(
BoundDagTemp
node)
11711
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11717
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11722
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11727
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11732
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11738
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11743
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11750
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11756
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11762
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11767
BoundDagTemp
lengthTemp = (
BoundDagTemp
)this.Visit(node.LengthTemp);
11771
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11777
BoundDagTemp
lengthTemp = (
BoundDagTemp
)this.Visit(node.LengthTemp);
11781
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
11787
BoundDagTemp
target = (
BoundDagTemp
)this.Visit(node.Target);
11788
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13862
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13869
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13876
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13883
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13890
BoundDagTemp
lengthTemp = (
BoundDagTemp
)this.Visit(node.LengthTemp);
13894
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
13901
BoundDagTemp
lengthTemp = (
BoundDagTemp
)this.Visit(node.LengthTemp);
13905
BoundDagTemp
input = (
BoundDagTemp
)this.Visit(node.Input);
16325
public override TreeDumperNode VisitDagTemp(
BoundDagTemp
node, object? arg) => new TreeDumperNode("dagTemp", null, new TreeDumperNode[]
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (4)
360
BoundExpression inputTemp = _tempAllocator.GetTemp(
BoundDagTemp
.ForOriginalInput(loweredSwitchGoverningExpression));
504
var
input = ((BoundTestDecisionDagNode)node).Test.Input;
552
BoundDagTemp
input)
561
BoundDagTemp
input,
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (17)
56
private readonly PooledDictionary<
BoundDagTemp
, BoundExpression> _map = PooledDictionary<
BoundDagTemp
, BoundExpression>.GetInstance();
94
public BoundExpression GetTemp(
BoundDagTemp
dagTemp)
115
public bool TrySetTemp(
BoundDagTemp
dagTemp, BoundExpression translation)
143
var
outputTemp = new BoundDagTemp(f.Syntax, field.Type, f);
153
var
outputTemp = new BoundDagTemp(p.Syntax, property.Type, p);
190
var
outputTemp = new BoundDagTemp(d.Syntax, parameter.Type, d, i - extensionExtra);
210
var
outputTemp = new BoundDagTemp(t.Syntax, type, t);
247
var
outputTemp = new BoundDagTemp(e.Syntax, type, e);
272
var
outputTemp = new BoundDagTemp(e.Syntax, e.IndexerType, e);
298
var
outputTemp = new BoundDagTemp(e.Syntax, e.SliceType, e);
520
var
inputDagTemp =
BoundDagTemp
.ForOriginalInput(loweredInput);
621
var
originalInput =
BoundDagTemp
.ForOriginalInput(loweredInput.Syntax, loweredInput.Type);
629
var
temp = new BoundDagTemp(expr.Syntax, expr.Type, fieldFetchEvaluation);
642
void storeToTemp(
BoundDagTemp
temp, BoundExpression expr)
Utilities\ValueSetFactory.cs (1)
64
public static IValueSetFactory? ForInput(
BoundDagTemp
input)