1 type derived from StateMachineFieldSymbol
Microsoft.CodeAnalysis.CSharp (1)
Lowering\StateMachineRewriter\StateMachineFieldSymbol.cs (1)
89internal sealed class StateMachineFieldSymbolForRegularParameter : StateMachineFieldSymbol
4 instantiations of StateMachineFieldSymbol
Microsoft.CodeAnalysis.CSharp (4)
Lowering\SyntheticBoundNodeFactory.cs (4)
173var result = new StateMachineFieldSymbol(CurrentType, type, name, isPublic, isThis); 181var result = new StateMachineFieldSymbol(CurrentType, TypeWithAnnotations.Create(type), name, isPublic, isThis); 197var result = new StateMachineFieldSymbol(CurrentType, type, name, synthesizedKind, slotIndex, isPublic: false); 205var result = new StateMachineFieldSymbol(CurrentType, type, name, slotDebugInfo, slotIndex, isPublic: false);
48 references to StateMachineFieldSymbol
Microsoft.CodeAnalysis.CSharp (48)
CodeGen\EmitStatement.cs (3)
817foreach (var field in scope.Fields) 1161var stateMachineField = left.FieldSymbol as StateMachineFieldSymbol;
Compiler\MethodCompiler.cs (1)
1661foreach (StateMachineFieldSymbol field in
Generated\BoundNodes.xml.Generated.cs (4)
3370public BoundStateMachineScope(SyntaxNode syntax, ImmutableArray<StateMachineFieldSymbol> fields, BoundStatement statement, bool hasErrors = false) 3381public ImmutableArray<StateMachineFieldSymbol> Fields { get; } 3387public BoundStateMachineScope Update(ImmutableArray<StateMachineFieldSymbol> fields, BoundStatement statement) 13406ImmutableArray<StateMachineFieldSymbol> fields = GetUpdatedArray(node, node.Fields);
Lowering\AsyncRewriter\AsyncIteratorMethodToStateMachineRewriter.cs (1)
93protected override BoundStatement GenerateCleanupForExit(ImmutableArray<StateMachineFieldSymbol> rootHoistedLocals)
Lowering\AsyncRewriter\AsyncMethodToStateMachineRewriter.cs (4)
141ImmutableArray<StateMachineFieldSymbol> rootScopeHoistedLocals; 213BoundCatchBlock generateExceptionHandling(LocalSymbol exceptionLocal, ImmutableArray<StateMachineFieldSymbol> rootHoistedLocals) 264protected virtual BoundStatement GenerateCleanupForExit(ImmutableArray<StateMachineFieldSymbol> rootHoistedLocals) 270foreach (var hoistedLocal in rootHoistedLocals)
Lowering\StateMachineRewriter\CapturedSymbol.cs (4)
49public readonly StateMachineFieldSymbol HoistedField; 51public CapturedToStateMachineFieldReplacement(StateMachineFieldSymbol hoistedField, bool isReusable) 68public readonly ImmutableArray<StateMachineFieldSymbol> HoistedFields; 70public CapturedToExpressionSymbolReplacement(BoundExpression replacement, ImmutableArray<StateMachineFieldSymbol> hoistedFields, bool isReusable)
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (17)
70private Dictionary<TypeSymbol, ArrayBuilder<StateMachineFieldSymbol>>? _lazyAvailableReusableHoistedFields; 304var hoistedLocalsWithDebugScopes = ArrayBuilder<StateMachineFieldSymbol>.GetInstance(); 368foreach (var field in ((CapturedToExpressionSymbolReplacement)proxy).HoistedFields) 403internal BoundBlock MakeStateMachineScope(ImmutableArray<StateMachineFieldSymbol> hoistedLocals, BoundStatement statement) 411internal static bool TryUnwrapBoundStateMachineScope(ref BoundStatement statement, out ImmutableArray<StateMachineFieldSymbol> hoistedLocals) 426hoistedLocals = ImmutableArray<StateMachineFieldSymbol>.Empty; 462private StateMachineFieldSymbol GetOrAllocateReusableHoistedField(TypeSymbol type, out bool reused, LocalSymbol? local = null) 464ArrayBuilder<StateMachineFieldSymbol>? fields; 476StateMachineFieldSymbol createdField; 492private void FreeReusableHoistedField(StateMachineFieldSymbol field) 494ArrayBuilder<StateMachineFieldSymbol> fields; 499_lazyAvailableReusableHoistedFields = new Dictionary<TypeSymbol, ArrayBuilder<StateMachineFieldSymbol>>(Symbols.SymbolEqualityComparer.IgnoringDynamicTupleNamesAndNullability); 502_lazyAvailableReusableHoistedFields.Add(field.Type, fields = new ArrayBuilder<StateMachineFieldSymbol>()); 526var hoistedFields = ArrayBuilder<StateMachineFieldSymbol>.GetInstance(); 580ArrayBuilder<StateMachineFieldSymbol> hoistedFields, 679StateMachineFieldSymbol hoistedField; 751var hoistedLocalsWithDebugScopes = ArrayBuilder<StateMachineFieldSymbol>.GetInstance();
Lowering\StateMachineRewriter\StateMachineRewriter.cs (5)
180StateMachineFieldSymbol field = null; 240var proxyField = F.StateMachineField(containingType, GeneratedNames.ThisProxyFieldName(), isPublic: true, isThis: true); 245var initialThis = containingType.IsStructType() ? 255var proxyField = F.StateMachineFieldForRegularParameter(typeMap.SubstituteType(parameter.Type).Type, parameter.Name, parameter, isPublic: !PreserveInitialParameterValuesAndThreadId); 260var field = F.StateMachineFieldForRegularParameter(typeMap.SubstituteType(parameter.Type).Type, GeneratedNames.StateMachineParameterProxyFieldName(parameter.Name), parameter, isPublic: true);
Lowering\SyntheticBoundNodeFactory.cs (9)
170public StateMachineFieldSymbol StateMachineField(TypeWithAnnotations type, string name, bool isPublic = false, bool isThis = false) 173var result = new StateMachineFieldSymbol(CurrentType, type, name, isPublic, isThis); 178public StateMachineFieldSymbol StateMachineField(TypeSymbol type, string name, bool isPublic = false, bool isThis = false) 181var result = new StateMachineFieldSymbol(CurrentType, TypeWithAnnotations.Create(type), name, isPublic, isThis); 186public StateMachineFieldSymbol StateMachineFieldForRegularParameter(TypeSymbol type, string name, ParameterSymbol parameter, bool isPublic) 194public StateMachineFieldSymbol StateMachineField(TypeSymbol type, string name, SynthesizedLocalKind synthesizedKind, int slotIndex) 197var result = new StateMachineFieldSymbol(CurrentType, type, name, synthesizedKind, slotIndex, isPublic: false); 202public StateMachineFieldSymbol StateMachineField(TypeSymbol type, string name, LocalSlotDebugInfo slotDebugInfo, int slotIndex) 205var result = new StateMachineFieldSymbol(CurrentType, type, name, slotDebugInfo, slotIndex, isPublic: false);