Binder\Binder_Expressions.cs (11)
437FieldSymbol field,
2003FieldSymbol possibleField = null;
2017possibleField = lookupResult.SingleSymbolOrDefault as FieldSymbol;
2089(this.ContainingMember() is FieldSymbol || (object)primaryCtor == this.ContainingMember()) ||
2177return BindFieldAccess(node, receiver, (FieldSymbol)symbol, diagnostics, resultKind, indexed, hasErrors: isError);
5869var fieldSymbol = ((BoundFieldAccess)boundMember).FieldSymbol;
8172resultType = ((FieldSymbol)symbolOpt).GetFieldType(this.FieldsBeingBound).Type;
8324result = BindFieldAccess(node, left, (FieldSymbol)symbol, diagnostics, lookupResult.Kind, indexed, hasErrors: wasError);
8513FieldSymbol fieldSymbol,
9020expr.Type.HasInlineArrayAttribute(out int length) && expr.Type.TryGetPossiblyUnsupportedByLanguageInlineArrayElementField() is FieldSymbol elementField)
9089BoundExpression bindInlineArrayElementAccess(ExpressionSyntax node, BoundExpression expr, int length, AnalyzedArguments analyzedArguments, BoundExpression convertedIndex, WellKnownType indexOrRangeWellknownType, FieldSymbol elementField, BindingDiagnosticBag diagnostics)
FlowAnalysis\NullableWalker.cs (17)
721FieldSymbol? field;
725case FieldSymbol f:
815case FieldSymbol { OriginalDefinition: SynthesizedPrimaryConstructorParameterBackingFieldSymbol }:
818case FieldSymbol { IsConst: true }:
820case FieldSymbol { AssociatedSymbol: SourcePropertySymbolBase { UsesFieldKeyword: false } prop }:
953if (requiredMember is FieldSymbol)
1949var fieldSymbol = fieldAccess.FieldSymbol;
2126primaryConstructor.GetCapturedParameters().TryGetValue(parameter, out FieldSymbol? field))
2602foreach (var field in _emptyStructTypeCache.GetStructInstanceFields(targetType))
3603(FieldSymbol { ContainingType: { IsTupleType: true }, TupleElementIndex: var oi } originalField, FieldSymbol { ContainingType: { IsTupleType: true }, TupleElementIndex: var ui } updatedField) =>
8489tupleType.GetMembers(NamedTypeSymbol.ValueTupleRestFieldName).FirstOrDefault() is FieldSymbol restField)
8496void trackState(BoundExpression value, FieldSymbol field, TypeWithState valueType)
8554void trackConvertedValue(FieldSymbol targetField, Conversion conversion, FieldSymbol valueField)
10049private static FlowAnalysisAnnotations GetFieldAnnotations(FieldSymbol field)
10065var annotations = memberSymbol switch { PropertySymbol prop => prop.GetFlowAnalysisAnnotations(), FieldSymbol field => GetFieldAnnotations(field), _ => FlowAnalysisAnnotations.None };
Generated\BoundNodes.xml.Generated.cs (32)
308public BoundFieldEqualsValue(SyntaxNode syntax, FieldSymbol field, ImmutableArray<LocalSymbol> locals, BoundExpression value, bool hasErrors = false)
319public FieldSymbol Field { get; }
324public BoundFieldEqualsValue Update(FieldSymbol field, ImmutableArray<LocalSymbol> locals, BoundExpression value)
2333public BoundLocalId(SyntaxNode syntax, LocalSymbol local, FieldSymbol? hoistedField, TypeSymbol type, bool hasErrors)
2344public BoundLocalId(SyntaxNode syntax, LocalSymbol local, FieldSymbol? hoistedField, TypeSymbol type)
2357public FieldSymbol? HoistedField { get; }
2362public BoundLocalId Update(LocalSymbol local, FieldSymbol? hoistedField, TypeSymbol type)
2376public BoundParameterId(SyntaxNode syntax, ParameterSymbol parameter, FieldSymbol? hoistedField, TypeSymbol type, bool hasErrors)
2387public BoundParameterId(SyntaxNode syntax, ParameterSymbol parameter, FieldSymbol? hoistedField, TypeSymbol type)
2400public FieldSymbol? HoistedField { get; }
2405public BoundParameterId Update(ParameterSymbol parameter, FieldSymbol? hoistedField, TypeSymbol type)
2750public BoundFieldInfo(SyntaxNode syntax, FieldSymbol field, MethodSymbol? getFieldFromHandle, TypeSymbol type, bool hasErrors)
2761public BoundFieldInfo(SyntaxNode syntax, FieldSymbol field, MethodSymbol? getFieldFromHandle, TypeSymbol type)
2773public FieldSymbol Field { get; }
2779public BoundFieldInfo Update(FieldSymbol field, MethodSymbol? getFieldFromHandle, TypeSymbol type)
5442public BoundDagFieldEvaluation(SyntaxNode syntax, FieldSymbol field, BoundDagTemp input, bool hasErrors = false)
5452public FieldSymbol Field { get; }
5457public BoundDagFieldEvaluation Update(FieldSymbol field, BoundDagTemp input)
7257public BoundFieldAccess(SyntaxNode syntax, BoundExpression? receiverOpt, FieldSymbol fieldSymbol, ConstantValue? constantValueOpt, LookupResultKind resultKind, bool isByValue, bool isDeclaration, TypeSymbol type, bool hasErrors = false)
7274public FieldSymbol FieldSymbol { get; }
7283public BoundFieldAccess Update(BoundExpression? receiverOpt, FieldSymbol fieldSymbol, ConstantValue? constantValueOpt, LookupResultKind resultKind, bool isByValue, bool isDeclaration, TypeSymbol type)
7297public BoundHoistedFieldAccess(SyntaxNode syntax, FieldSymbol fieldSymbol, TypeSymbol type, bool hasErrors)
7307public BoundHoistedFieldAccess(SyntaxNode syntax, FieldSymbol fieldSymbol, TypeSymbol type)
7318public FieldSymbol FieldSymbol { get; }
7323public BoundHoistedFieldAccess Update(FieldSymbol fieldSymbol, TypeSymbol type)
12230FieldSymbol field = GetUpdatedSymbol(node, node.Field);
13016FieldSymbol? hoistedField = GetUpdatedSymbol(node, node.HoistedField);
13034FieldSymbol? hoistedField = GetUpdatedSymbol(node, node.HoistedField);
13165FieldSymbol field = GetUpdatedSymbol(node, node.Field);
13682FieldSymbol field = GetUpdatedSymbol(node, node.Field);
14414FieldSymbol fieldSymbol = GetUpdatedSymbol(node, node.FieldSymbol);
14432FieldSymbol fieldSymbol = GetUpdatedSymbol(node, node.FieldSymbol);
Symbols\Compilation_WellKnownMembers.cs (13)
245internal static Symbol? GetRuntimeMember(NamedTypeSymbol declaringType, in MemberDescriptor descriptor, SignatureComparer<MethodSymbol, FieldSymbol, PropertySymbol, TypeSymbol, ParameterSymbol> comparer, AssemblySymbol? accessWithinOpt)
251internal static Symbol? GetRuntimeMember(ImmutableArray<Symbol> members, in MemberDescriptor descriptor, SignatureComparer<MethodSymbol, FieldSymbol, PropertySymbol, TypeSymbol, ParameterSymbol> comparer, AssemblySymbol? accessWithinOpt)
345if (!comparer.MatchFieldSignature((FieldSymbol)member, descriptor.Signature))
720var ignoreSymbolStoreDebuggingMode = (FieldSymbol?)GetWellKnownTypeMember(WellKnownMember.System_Diagnostics_DebuggableAttribute_DebuggingModes__IgnoreSymbolStoreSequencePoints);
736var defaultDebuggingMode = (FieldSymbol?)GetWellKnownTypeMember(WellKnownMember.System_Diagnostics_DebuggableAttribute_DebuggingModes__Default);
742var disableOptimizationsDebuggingMode = (FieldSymbol?)GetWellKnownTypeMember(WellKnownMember.System_Diagnostics_DebuggableAttribute_DebuggingModes__DisableOptimizations);
754var enableEncDebuggingMode = (FieldSymbol?)GetWellKnownTypeMember(WellKnownMember.System_Diagnostics_DebuggableAttribute_DebuggingModes__EnableEditAndContinue);
1061internal class SpecialMembersSignatureComparer : SignatureComparer<MethodSymbol, FieldSymbol, PropertySymbol, TypeSymbol, ParameterSymbol>
1085protected override TypeSymbol GetFieldType(FieldSymbol field)