3 writes to _variables
Microsoft.CodeAnalysis.CSharp (3)
FlowAnalysis\NullableWalker.cs (3)
468
_variables
= variables ?? Variables.Create(symbol);
3258
_variables
= GetOrCreateNestedFunctionVariables(_variables, lambdaOrFunctionSymbol);
3321
_variables
= _variables.Container!;
39 references to _variables
Microsoft.CodeAnalysis.CSharp (39)
FlowAnalysis\NullableWalker.cs (37)
441
_variables
.Free();
518
return
_variables
.TryGetValue(identifier, out slot);
523
return
_variables
.Add(identifier);
1760
finalNullableState = GetVariableState(walker.
_variables
, walker.State);
1784
Debug.Assert(walker.
_variables
.Id == initialState.Value.Id);
1815
state.TryAdd(key, new Data(
_variables
.GetTotalVariableCount(), requiredAnalysis));
1822
return new SharedWalkerState(
_variables
.CreateSnapshot());
1887
state.NormalizeIfNeeded(slot, this,
_variables
, useNotNullsAsDefault);
1895
state.Normalize(this,
_variables
);
1905
var variable =
_variables
[slot];
1913
if (!
_variables
.TryGetType(local, out TypeWithAnnotations localType))
1922
if (!
_variables
.TryGetType(parameter, out TypeWithAnnotations parameterType))
2152
|| (!constructor.IsStatic && containingSlot > 0 &&
_variables
[containingSlot].Symbol is ThisParameterSymbol))
2678
return
_variables
[slot].Symbol.GetTypeOrReturnType().Type;
2713
var actualType =
_variables
[targetSlot].Symbol.GetTypeOrReturnType().Type;
2728
_variables
.GetMembers(members, targetSlot);
2748
_variables
.GetMembers(members, valueSlot);
2760
var state = LocalState.ReachableState(
_variables
);
2767
return LocalState.UnreachableState(
_variables
);
2773
return LocalState.ReachableStateWithNotNulls(
_variables
);
2820
_variables
.SetType(parameter, parameterType);
3169
state.Normalize(this,
_variables
);
3178
_variables
);
3198
_variables
);
3258
_variables = GetOrCreateNestedFunctionVariables(
_variables
, lambdaOrFunctionSymbol);
3259
this.State = state.CreateNestedMethodState(
_variables
);
3321
_variables =
_variables
.Container!;
3514
_variables
.SetType(local, type);
7545
_variables
.SetType(local.LocalSymbol, varType);
7951
return getUnboundLambda((BoundLambda)argument, GetVariableState(
_variables
, lambdaState.Value));
10275
_variables
.SetType(local.LocalSymbol, operandType.ToAnnotatedTypeWithAnnotations(compilation));
10637
return
_variables
.TryGetType(local, out TypeWithAnnotations type) ?
10644
return
_variables
.TryGetType(parameter, out TypeWithAnnotations type) ?
11114
_variables
.SetType(iterationVariable, destinationType);
12121
return state.Dump(
_variables
);
12646
var variables = (symbol.ContainingSymbol is MethodSymbol containingMethod ?
_variables
.GetVariablesForMethodScope(containingMethod) : null) ??
12647
_variables
.GetRootScope();
FlowAnalysis\NullableWalker_Patterns.cs (2)
685
if (
_variables
.TryGetType(local, out var existingType))
690
_variables
.SetType(local, inferredType);