29 writes to StateWhenTrue
Microsoft.CodeAnalysis.CSharp (29)
FlowAnalysis\AbstractFlowPass.cs (6)
135
StateWhenTrue
= whenTrue;
142
StateWhenTrue
= StateWhenFalse = default(TLocalState);
159
Join(ref
StateWhenTrue
, ref StateWhenFalse);
1679
StateWhenTrue
= unreachable;
2957
Join(ref
StateWhenTrue
, ref savedState);
3285
Join(ref this.
StateWhenTrue
, ref afterConsequenceWhenTrue);
FlowAnalysis\LocalDataFlowPass.cs (1)
137
Normalize(ref this.
StateWhenTrue
);
FlowAnalysis\NullableWalker.cs (13)
5242
LearnFromNullTest(operandComparedToNull, ref nonNullCase ? ref StateWhenFalse : ref
StateWhenTrue
);
5285
ref LocalState stateToUpdate = ref whenTrue ? ref this.
StateWhenTrue
: ref this.StateWhenFalse;
5821
LearnFromNonNullTest(slot, ref
StateWhenTrue
);
6448
LearnFromNullTest(right, ref
StateWhenTrue
);
6454
LearnFromNullTest(left, ref
StateWhenTrue
);
6460
LearnFromNonNullTest(left, ref
StateWhenTrue
);
6465
LearnFromNonNullTest(right, ref
StateWhenTrue
);
7150
applyMemberPostConditions(receiverSlot, type, notNullMembers, ref
StateWhenTrue
);
7162
applyMemberPostConditions(receiverSlot, type, notNullWhenTrueMembers, ref
StateWhenTrue
);
7714
LearnFromNonNullTest(argument, ref
StateWhenTrue
);
7724
LearnFromNullTest(argument, ref
StateWhenTrue
);
10795
SetState(ref this.
StateWhenTrue
, containingSlot, NullableFlowState.NotNull);
12168
Join(ref
StateWhenTrue
, ref otherIsConditional ? ref other.StateWhenTrue : ref other.State);
FlowAnalysis\NullableWalker_Patterns.cs (9)
601
learnFromNonNullTest(inputSlot, ref this.
StateWhenTrue
);
607
var inputMaybeNull = GetState(ref this.
StateWhenTrue
, inputSlot).MayBeNull();
616
learnFromNonNullTest(inputSlot, ref this.
StateWhenTrue
);
624
LearnFromNullTest(inputSlot, inputType, ref this.
StateWhenTrue
, markDependentSlotsNotNull: true);
645
learnFromNonNullTest(inputSlot, ref this.
StateWhenTrue
);
654
learnFromNonNullTest(inputSlot, ref this.
StateWhenTrue
);
780
Join(ref this.
StateWhenTrue
, ref stateAndReachable.state.StateWhenTrue);
785
Join(ref this.
StateWhenTrue
, ref stateAndReachable.state.State);
791
Join(ref this.
StateWhenTrue
, ref stateAndReachable.state.StateWhenTrue);
45 references to StateWhenTrue
Microsoft.CodeAnalysis.CSharp (45)
FlowAnalysis\AbstractFlowPass.cs (19)
160
SetState(
StateWhenTrue
);
229
? $"true: {Dump(this.
StateWhenTrue
)} false: {Dump(this.StateWhenFalse)}"
949
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
969
SetState(this.
StateWhenTrue
);
975
SetConditionalState(this.StateWhenFalse, this.
StateWhenTrue
);
1775
trueState =
StateWhenTrue
;
1976
SetState(
StateWhenTrue
);
2337
TLocalState bodyState =
StateWhenTrue
;
2479
var leftTrue = this.
StateWhenTrue
;
2513
var resultTrue = this.
StateWhenTrue
;
2654
var (stateWhenTrue, stateWhenFalse) = (
StateWhenTrue
.Clone(), StateWhenFalse.Clone());
2670
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
2761
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
2844
bodyState = this.
StateWhenTrue
;
3254
var consequenceState = this.
StateWhenTrue
;
3274
var (afterConsequenceWhenTrue, afterConsequenceWhenFalse) = conditionalAfterConsequence ? (
StateWhenTrue
, StateWhenFalse) : (State, State);
3323
SetState(this.
StateWhenTrue
);
3546
PendingBranches.Add(new PendingBranch(node, this.
StateWhenTrue
, node.Label));
3552
this.SetState(this.
StateWhenTrue
);
FlowAnalysis\AbstractFlowPass_Switch.cs (4)
62
SetState(
StateWhenTrue
);
66
SetState(
StateWhenTrue
);
165
SetState(
StateWhenTrue
);
174
SetState(
StateWhenTrue
);
FlowAnalysis\AlwaysAssignedWalker.cs (1)
126
_endOfRegionState =
StateWhenTrue
.Clone();
FlowAnalysis\DefiniteAssignment.cs (1)
1983
SetState(
StateWhenTrue
);
FlowAnalysis\DefinitelyAssignedWalker.cs (1)
77
this.ProcessState(definitelyAssigned, this.
StateWhenTrue
, this.StateWhenFalse);
FlowAnalysis\NullableWalker.cs (11)
487
return $"{{{GetType().Name} WhenTrue:{Dump(
StateWhenTrue
)} WhenFalse:{Dump(StateWhenFalse)}{"}"}";
2931
var joinedState = this.
StateWhenTrue
.Clone();
2933
PendingBranches.Add(new PendingBranch(node, joinedState, label: null, this.IsConditionalState, this.
StateWhenTrue
, this.StateWhenFalse));
5027
var (stateWhenTrue, stateWhenFalse) = (
StateWhenTrue
.Clone(), StateWhenFalse.Clone());
5043
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
5878
var consequenceState = this.
StateWhenTrue
;
6147
=> this.IsConditionalState ? (this.
StateWhenTrue
.Reachable || this.StateWhenFalse.Reachable) : this.State.Reachable;
7314
SetState(
StateWhenTrue
);
7609
SetState(
StateWhenTrue
);
11232
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
11247
SetConditionalState(StateWhenFalse,
StateWhenTrue
);
FlowAnalysis\NullableWalker_Patterns.cs (8)
362
? new PossiblyConditionalState(nullableWalker.
StateWhenTrue
, nullableWalker.StateWhenFalse)
603
gotoNode(p.WhenTrue, this.
StateWhenTrue
, nodeBelievedReachable);
618
gotoNode(p.WhenTrue, this.
StateWhenTrue
, nodeBelievedReachable);
627
gotoNode(p.WhenTrue, this.
StateWhenTrue
, nodeBelievedReachable);
648
gotoNode(p.WhenTrue, isFalseTest ? this.StateWhenFalse : this.
StateWhenTrue
, nodeBelievedReachable);
649
gotoNode(p.WhenFalse, isFalseTest ? this.
StateWhenTrue
: this.StateWhenFalse, nodeBelievedReachable);
656
gotoNode(p.WhenTrue, this.
StateWhenTrue
, nodeBelievedReachable);
709
gotoNode(w.WhenTrue, this.
StateWhenTrue
, nodeBelievedReachable);