4 types derived from CSharpAttributeData
Microsoft.CodeAnalysis.CSharp (4)
Symbols\Attributes\PEAttributeData.cs (1)
18internal sealed class PEAttributeData : CSharpAttributeData
Symbols\Attributes\RetargetingAttributeData.cs (1)
15internal sealed class RetargetingAttributeData : CSharpAttributeData
Symbols\Attributes\SourceAttributeData.cs (1)
18internal sealed class SourceAttributeData : CSharpAttributeData
Symbols\Source\SynthesizedAttributeData.cs (1)
15internal abstract class SynthesizedAttributeData : CSharpAttributeData
471 references to CSharpAttributeData
Microsoft.CodeAnalysis.CSharp (471)
Binder\Binder_Attributes.cs (3)
75CSharpAttributeData?[] attributeDataArray, 126internal (CSharpAttributeData, BoundAttribute) GetAttribute( 282private CSharpAttributeData GetAttribute(BoundAttribute boundAttribute, BindingDiagnosticBag diagnostics)
Binder\EarlyWellKnownAttributeBinder.cs (2)
26internal (CSharpAttributeData, BoundAttribute) GetAttribute( 42internal new (CSharpAttributeData, BoundAttribute) GetAttribute(
Compiler\ClsComplianceChecker.cs (8)
144foreach (CSharpAttributeData assemblyLevelAttribute in peModule.GetAssemblyAttributes()) 342foreach (CSharpAttributeData attribute in symbol.GetAttributes()) 599private void CheckForAttributeWithArrayArgumentInternal(ImmutableArray<CSharpAttributeData> attributes) 601foreach (CSharpAttributeData attribute in attributes) 655private bool TryGetAttributeWarningLocation(CSharpAttributeData attribute, out Location location) 766private bool TryGetClsComplianceAttributeLocation(ImmutableArray<CSharpAttributeData> attributes, out Location attributeLocation) 768foreach (CSharpAttributeData data in attributes) 1187foreach (CSharpAttributeData data in symbol.GetAttributes())
Emitter\Model\MethodSymbolAdapter.cs (2)
512ImmutableArray<CSharpAttributeData> userDefined = AdaptedMethodSymbol.GetReturnTypeAttributes(); 513ArrayBuilder<CSharpAttributeData> synthesized = null;
Emitter\Model\SourceAssemblySymbolAdapter.cs (3)
16internal IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder, bool emittingRefAssembly, bool emittingAssemblyAttributesInNetModule) 20ImmutableArray<CSharpAttributeData> userDefined = this.GetAttributes(); 21ArrayBuilder<CSharpAttributeData> synthesized = null;
Emitter\Model\SymbolAdapter.cs (12)
85internal virtual IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 93internal IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder, bool emittingAssemblyAttributesInNetModule) 98ImmutableArray<CSharpAttributeData> userDefined; 99ArrayBuilder<CSharpAttributeData> synthesized = null; 112internal IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit( 113ImmutableArray<CSharpAttributeData> userDefined, 114ArrayBuilder<CSharpAttributeData> synthesized, 123return SpecializedCollections.EmptyEnumerable<CSharpAttributeData>(); 129private IEnumerable<CSharpAttributeData> GetCustomAttributesToEmitIterator( 130ImmutableArray<CSharpAttributeData> userDefined, 131ArrayBuilder<CSharpAttributeData> synthesized, 151CSharpAttributeData attribute = userDefined[i];
Emitter\NoPia\EmbeddedEvent.cs (2)
23protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 73foreach (var attrData in underlyingContainingType.GetAttributes())
Emitter\NoPia\EmbeddedField.cs (1)
34protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Emitter\NoPia\EmbeddedMethod.cs (1)
35protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Emitter\NoPia\EmbeddedParameter.cs (1)
39protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Emitter\NoPia\EmbeddedProperty.cs (1)
25protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Emitter\NoPia\EmbeddedType.cs (2)
243protected override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 248protected override CSharpAttributeData CreateTypeIdentifierAttribute(bool hasGuid, SyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics)
Emitter\NoPia\EmbeddedTypesManager.cs (5)
32EmbeddedTypesManager<PEModuleBuilder, ModuleCompilationState, EmbeddedTypesManager, SyntaxNode, CSharpAttributeData, 118internal override int GetTargetAttributeSignatureIndex(CSharpAttributeData attrData, AttributeDescription description) 123internal override CSharpAttributeData CreateSynthesizedAttribute(WellKnownMember constructor, ImmutableArray<TypedConstant> constructorArguments, ImmutableArray<KeyValuePair<string, TypedConstant>> namedArguments, SyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics) 155internal override bool TryGetAttributeArguments(CSharpAttributeData attrData, out ImmutableArray<TypedConstant> constructorArguments, out ImmutableArray<KeyValuePair<string, TypedConstant>> namedArguments, SyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics) 634protected override CSharpAttributeData CreateCompilerGeneratedAttribute()
Errors\MessageProvider.cs (3)
263diagnostics.Add(ErrorCode.ERR_InvalidAttributeArgument, ((CSharpAttributeData)attribute).GetAttributeArgumentLocation(parameterIndex), node.GetErrorDisplayName()); 280diagnostics.Add(ErrorCode.ERR_MarshalUnmanagedTypeNotValidForFields, ((CSharpAttributeData)attribute).GetAttributeArgumentLocation(parameterIndex), unmanagedTypeName); 285diagnostics.Add(ErrorCode.ERR_MarshalUnmanagedTypeOnlyValidForFields, ((CSharpAttributeData)attribute).GetAttributeArgumentLocation(parameterIndex), unmanagedTypeName);
FlowAnalysis\DefiniteAssignment.cs (1)
1918private void VisitAttributes(ImmutableArray<(CSharpAttributeData, BoundAttribute)> boundAttributes)
Lowering\ClosureConversion\LambdaCapturedVariable.cs (2)
185internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 190foreach (CSharpAttributeData attr in definition.GetAttributes())
Lowering\IteratorRewriter\IteratorConstructor.cs (1)
31internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Lowering\LocalRewriter\LocalRewriter_Event.cs (1)
28foreach (var attrData in @interface.GetAttributes())
Lowering\StateMachineRewriter\StateMachineFieldSymbol.cs (2)
100internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 105foreach (CSharpAttributeData attr in definition.GetAttributes())
Lowering\StateMachineRewriter\StateMachineTypeSymbol.cs (7)
18private ImmutableArray<CSharpAttributeData> _attributes; 53public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 59ArrayBuilder<CSharpAttributeData> builder = null; 63foreach (var attribute in kickoffType.GetAttributes()) 70builder = ArrayBuilder<CSharpAttributeData>.GetInstance(2); // only 2 different attributes are inherited at the moment 78builder == null ? ImmutableArray<CSharpAttributeData>.Empty : builder.ToImmutableAndFree(), 79default(ImmutableArray<CSharpAttributeData>));
Lowering\StateMachineRewriter\SynthesizedStateMachineMethod.cs (8)
63private ImmutableArray<CSharpAttributeData> _attributes; 70public override ImmutableArray<CSharpAttributeData> GetAttributes() 76ArrayBuilder<CSharpAttributeData> builder = null; 80foreach (var attribute in kickoffMethod.GetAttributes()) 89builder = ArrayBuilder<CSharpAttributeData>.GetInstance(4); // only 4 different attributes are inherited at the moment 97builder == null ? ImmutableArray<CSharpAttributeData>.Empty : builder.ToImmutableAndFree(), 98default(ImmutableArray<CSharpAttributeData>)); 121internal sealed override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Lowering\SynthesizedMethodBaseSymbol.cs (4)
150public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 155: ImmutableArray<CSharpAttributeData>.Empty; 158public sealed override ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes() 161return InheritsBaseMethodAttributes ? BaseMethod.GetReturnTypeAttributes() : ImmutableArray<CSharpAttributeData>.Empty;
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.DelegateTemplateSymbol.cs (1)
247internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.FieldSymbol.cs (1)
146internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.PropertyAccessorSymbol.cs (1)
86internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.SynthesizedMethodBase.cs (1)
168internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.TemplateSymbol.cs (1)
160internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Attributes\AttributeData.cs (7)
213internal void DecodeSecurityAttribute<T>(Symbol targetSymbol, CSharpCompilation compilation, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 239internal static void DecodeSkipLocalsInitAttribute<T>(CSharpCompilation compilation, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 250internal static void DecodeMemberNotNullAttribute<T>(TypeSymbol type, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 286private static void ReportBadNotNullMemberIfNeeded(TypeSymbol type, DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, string memberName) 300internal static void DecodeMemberNotNullWhenAttribute<T>(TypeSymbol type, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 790internal static int IndexOfAttribute(this ImmutableArray<CSharpAttributeData> attributes, AttributeDescription description) 803internal static string? DecodeNotNullIfNotNullAttribute(this CSharpAttributeData attribute)
Symbols\Attributes\RetargetingAttributeData.cs (2)
17private readonly CSharpAttributeData _underlying; 24CSharpAttributeData underlying,
Symbols\Attributes\SourceAttributeData.cs (1)
114/// If the <see cref="CSharpAttributeData.ConstructorArguments"/> contains any named constructor arguments or default value arguments,
Symbols\EventSymbol.cs (2)
115public ImmutableArray<CSharpAttributeData> GetFieldAttributes() 118ImmutableArray<CSharpAttributeData>.Empty :
Symbols\Extensions\RewrittenMethodSymbol.cs (1)
84public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Extensions\SourceExtensionImplementationMethodSymbol.cs (4)
70internal sealed override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 75foreach (CSharpAttributeData attr in extensionProperty.GetAttributes()) 87internal override void AddSynthesizedReturnTypeAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 202internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Metadata\PE\PEAssemblySymbol.cs (2)
65private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 140public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Metadata\PE\PEEventSymbol.cs (3)
33private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 360public override ImmutableArray<CSharpAttributeData> GetAttributes() 370internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Metadata\PE\PEFieldSymbol.cs (4)
120private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 580public override ImmutableArray<CSharpAttributeData> GetAttributes() 607internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 609foreach (CSharpAttributeData attribute in GetAttributes())
Symbols\Metadata\PE\PEMethodSymbol.cs (10)
308public ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 351retVal._lazyCustomAttributes = ImmutableArray<CSharpAttributeData>.Empty; 991public override ImmutableArray<CSharpAttributeData> GetAttributes() 996var attributeData = default(ImmutableArray<CSharpAttributeData>); 1067return ImmutableArray<CSharpAttributeData>.Empty; 1073? InterlockedOperations.Initialize(ref uncommonFields._lazyCustomAttributes, ImmutableArray<CSharpAttributeData>.Empty) 1078internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) => GetAttributes(); 1080public override ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes() => Signature.ReturnParam.GetAttributes(); 1717internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 1722internal override void AddSynthesizedReturnTypeAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Metadata\PE\PEModuleSymbol.cs (21)
86private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 91private ImmutableArray<CSharpAttributeData> _lazyAssemblyAttributes; 242public override ImmutableArray<CSharpAttributeData> GetAttributes() 251internal ImmutableArray<CSharpAttributeData> GetAssemblyAttributes() 255ArrayBuilder<CSharpAttributeData> moduleAssemblyAttributesBuilder = null; 277moduleAssemblyAttributesBuilder = new ArrayBuilder<CSharpAttributeData>(); 290(moduleAssemblyAttributesBuilder != null) ? moduleAssemblyAttributesBuilder.ToImmutableAndFree() : ImmutableArray<CSharpAttributeData>.Empty, 291default(ImmutableArray<CSharpAttributeData>)); 296internal void LoadCustomAttributes(EntityHandle token, ref ImmutableArray<CSharpAttributeData> customAttributes) 303ref ImmutableArray<CSharpAttributeData> customAttributes) 309internal ImmutableArray<CSharpAttributeData> GetCustomAttributesForToken(EntityHandle token, 316internal ImmutableArray<CSharpAttributeData> GetCustomAttributesForToken(EntityHandle token, 329internal ImmutableArray<CSharpAttributeData> GetCustomAttributesForToken(EntityHandle token, 349ArrayBuilder<CSharpAttributeData> customAttributesBuilder = null; 396customAttributesBuilder = ArrayBuilder<CSharpAttributeData>.GetInstance(); 410return ImmutableArray<CSharpAttributeData>.Empty; 416internal ImmutableArray<CSharpAttributeData> GetCustomAttributesForToken(EntityHandle token) 428internal ImmutableArray<CSharpAttributeData> GetCustomAttributesForToken(EntityHandle token, 466private ImmutableArray<CSharpAttributeData> GetCustomAttributesFilterCompilerAttributes(EntityHandle token, out bool foundExtension, out bool foundReadOnly) 667ImmutableArray<CSharpAttributeData> assemblyAttributes = GetAssemblyAttributes(); 680ImmutableArray<CSharpAttributeData> assemblyAttributes = GetAssemblyAttributes();
Symbols\Metadata\PE\PENamedTypeSymbol.cs (4)
139internal ImmutableArray<CSharpAttributeData> lazyCustomAttributes; 890public override ImmutableArray<CSharpAttributeData> GetAttributes() 895return ImmutableArray<CSharpAttributeData>.Empty; 934internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Metadata\PE\PEParameterSymbol.cs (11)
159private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 185private ImmutableArray<CSharpAttributeData> _lazyHiddenAttributes; 270_lazyCustomAttributes = ImmutableArray<CSharpAttributeData>.Empty; 271_lazyHiddenAttributes = ImmutableArray<CSharpAttributeData>.Empty; 1057public override ImmutableArray<CSharpAttributeData> GetAttributes() 1091ImmutableArray<CSharpAttributeData> attributes = 1109var builder = ArrayBuilder<CSharpAttributeData>.GetInstance(); 1130ImmutableInterlocked.InterlockedInitialize(ref _lazyHiddenAttributes, ImmutableArray<CSharpAttributeData>.Empty); 1162internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 1164foreach (CSharpAttributeData attribute in GetAttributes()) 1170foreach (CSharpAttributeData attribute in _lazyHiddenAttributes)
Symbols\Metadata\PE\PEPropertySymbol.cs (7)
179public ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 367retVal._lazyCustomAttributes = ImmutableArray<CSharpAttributeData>.Empty; 730public override ImmutableArray<CSharpAttributeData> GetAttributes() 736ImmutableArray<CSharpAttributeData> attributes = containingPEModuleSymbol.GetCustomAttributesForToken( 755return ImmutableArray<CSharpAttributeData>.Empty; 762result = ImmutableArray<CSharpAttributeData>.Empty; 770internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Metadata\PE\PETypeParameterSymbol.cs (2)
45private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 640public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\MethodSymbol.cs (4)
389public virtual ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes() 396return ImmutableArray<CSharpAttributeData>.Empty; 1151internal virtual void AddSynthesizedReturnTypeAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 1269protected static void AddRequiredMembersMarkerAttributes(ref ArrayBuilder<CSharpAttributeData> attributes, MethodSymbol methodToAttribute)
Symbols\PublicModel\MethodSymbol.cs (1)
268return _underlying.GetReturnTypeAttributes().Cast<CSharpAttributeData, AttributeData>();
Symbols\ReducedExtensionMethodSymbol.cs (1)
457public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Retargeting\RetargetingAssemblySymbol.cs (2)
91private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 210public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Retargeting\RetargetingEventSymbol.cs (2)
156public override ImmutableArray<CSharpAttributeData> GetAttributes() 161internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Retargeting\RetargetingFieldSymbol.cs (3)
31private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 78public override ImmutableArray<CSharpAttributeData> GetAttributes() 83internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Retargeting\RetargetingMethodSymbol.cs (5)
45private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 50private ImmutableArray<CSharpAttributeData> _lazyReturnTypeCustomAttributes; 211public override ImmutableArray<CSharpAttributeData> GetAttributes() 216internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder) 222public override ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes()
Symbols\Retargeting\RetargetingModuleSymbol.cs (2)
69private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 276public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Retargeting\RetargetingNamedTypeSymbol.cs (3)
38private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 259public override ImmutableArray<CSharpAttributeData> GetAttributes() 264internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Retargeting\RetargetingParameterSymbol.cs (3)
25private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 65public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 70internal sealed override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Retargeting\RetargetingPropertySymbol.cs (3)
32private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 216public override ImmutableArray<CSharpAttributeData> GetAttributes() 221internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\Retargeting\RetargetingSymbolTranslator.cs (13)
344foreach (var attrData in type.GetAttributes()) 1143private ImmutableArray<CSharpAttributeData> RetargetAttributes(ImmutableArray<CSharpAttributeData> oldAttributes) 1148internal IEnumerable<CSharpAttributeData> RetargetAttributes(IEnumerable<CSharpAttributeData> attributes) 1150foreach (var attributeData in attributes) 1156private CSharpAttributeData RetargetAttributeData(CSharpAttributeData oldAttributeData) 1302internal ImmutableArray<CSharpAttributeData> GetRetargetedAttributes( 1303ImmutableArray<CSharpAttributeData> underlyingAttributes, 1304ref ImmutableArray<CSharpAttributeData> lazyCustomAttributes) 1309ImmutableArray<CSharpAttributeData> retargetedAttributes = this.RetargetAttributes(underlyingAttributes); 1311ImmutableInterlocked.InterlockedCompareExchange(ref lazyCustomAttributes, retargetedAttributes, default(ImmutableArray<CSharpAttributeData>));
Symbols\Retargeting\RetargetingTypeParameterSymbol.cs (2)
36private ImmutableArray<CSharpAttributeData> _lazyCustomAttributes; 63public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Source\FieldSymbolWithAttributesAndModifiers.cs (10)
21private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 71public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 81private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 117internal sealed override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 119CSharpAttributeData? attributeData; 162protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 203MarshalAsAttributeDecoder<FieldWellKnownAttributeData, AttributeSyntax, CSharpAttributeData, AttributeLocation>.Decode(ref arguments, AttributeTargets.Field, MessageProvider.Instance); 264private void VerifyConstantValueMatches(ConstantValue attrValue, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 312internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData) 388internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\ImplicitNamedTypeSymbol.cs (2)
34public override ImmutableArray<CSharpAttributeData> GetAttributes() 37return ImmutableArray<CSharpAttributeData>.Empty;
Symbols\Source\SourceAssemblySymbol.cs (46)
66private CustomAttributesBag<CSharpAttributeData> _lazySourceAttributesBag; 71private CustomAttributesBag<CSharpAttributeData> _lazyNetModuleAttributesBag; 1146private bool IsKnownAssemblyAttribute(CSharpAttributeData attribute) 1189private HashSet<CSharpAttributeData> GetUniqueSourceAssemblyAttributes() 1191ImmutableArray<CSharpAttributeData> appliedSourceAttributes = this.GetSourceAttributesBag().Attributes; 1193HashSet<CSharpAttributeData> uniqueAttributes = null; 1197CSharpAttributeData attribute = appliedSourceAttributes[i]; 1210private static bool AddUniqueAssemblyAttribute(CSharpAttributeData attribute, ref HashSet<CSharpAttributeData> uniqueAttributes) 1216uniqueAttributes = new HashSet<CSharpAttributeData>(comparer: CommonAttributeDataComparer.Instance); 1222private bool ValidateAttributeUsageForNetModuleAttribute(CSharpAttributeData attribute, string netModuleName, BindingDiagnosticBag diagnostics, ref HashSet<CSharpAttributeData> uniqueAttributes) 1281private ImmutableArray<CSharpAttributeData> GetNetModuleAttributes(out ImmutableArray<string> netModuleNames) 1283ArrayBuilder<CSharpAttributeData> moduleAssemblyAttributesBuilder = null; 1290foreach (var attributeData in peModuleSymbol.GetAssemblyAttributes()) 1295moduleAssemblyAttributesBuilder = ArrayBuilder<CSharpAttributeData>.GetInstance(); 1306return ImmutableArray<CSharpAttributeData>.Empty; 1314ImmutableArray<CSharpAttributeData> attributesFromNetModules, 1326HashSet<CSharpAttributeData> uniqueAttributes = GetUniqueSourceAssemblyAttributes(); 1328var arguments = new DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation>(); 1340CSharpAttributeData attribute = attributesFromNetModules[i]; 1363private void LoadAndValidateNetModuleAttributes(ref CustomAttributesBag<CSharpAttributeData> lazyNetModuleAttributesBag) 1367Interlocked.CompareExchange(ref lazyNetModuleAttributesBag, CustomAttributesBag<CSharpAttributeData>.Empty, null); 1374ImmutableArray<CSharpAttributeData> attributesFromNetModules = GetNetModuleAttributes(out netModuleNames); 1432CustomAttributesBag<CSharpAttributeData> netModuleAttributesBag; 1436netModuleAttributesBag = new CustomAttributesBag<CSharpAttributeData>(); 1441if (netModuleAttributesBag.IsEmpty) netModuleAttributesBag = CustomAttributesBag<CSharpAttributeData>.Empty; 1445netModuleAttributesBag = CustomAttributesBag<CSharpAttributeData>.Empty; 1471ImmutableArray<CSharpAttributeData> attributesFromNetModules = GetNetModuleAttributes(out netModuleNames); 1484WellKnownAttributeData limitedDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> attributesFromNetModules, 1493HashSet<CSharpAttributeData> uniqueAttributes = null; 1500CSharpAttributeData attribute = attributesFromNetModules[i]; 1512void limitedDecodeWellKnownAttribute(CSharpAttributeData attribute, QuickAttributes attributeMatches, ref CommonAssemblyWellKnownAttributeData result) 1535private CustomAttributesBag<CSharpAttributeData> GetNetModuleAttributesBag() 1582private CustomAttributesBag<CSharpAttributeData> GetSourceAttributesBag() 1596public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 1663CustomAttributesBag<CSharpAttributeData>? attributesBag = _lazySourceAttributesBag; 1711CustomAttributesBag<CSharpAttributeData> attributesBag = _lazySourceAttributesBag; 1780private static IEnumerable<Cci.SecurityAttribute> GetSecurityAttributes(CustomAttributesBag<CSharpAttributeData> attributesBag) 1790foreach (var securityAttribute in securityData.GetSecurityAttributes<CSharpAttributeData>(attributesBag.Attributes)) 1939internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 2202private void DecodeTypeForwardedToAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 2270CSharpAttributeData attrData, 2358protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 2363private void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, int index, bool isFromNetModule) 2594private static void ValidateIntegralAttributeNonNegativeArguments(CSharpAttributeData attribute, AttributeSyntax nodeOpt, BindingDiagnosticBag diagnostics)
Symbols\Source\SourceClonedParameterSymbol.cs (1)
113public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Source\SourceComplexParameterSymbol.cs (25)
37private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 573internal sealed override CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 607public ImmutableArray<(CSharpAttributeData, BoundAttribute)> BindParameterAttributes() 618if (CSharpAttributeData.IsTargetEarlyAttribute(attributeType, attributeSyntax, AttributeDescription.OptionalAttribute)) 635internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 637if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.DefaultParameterValueAttribute)) 641else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.DecimalConstantAttribute)) 645else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.DateTimeConstantAttribute)) 649else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.UnscopedRefAttribute)) 658if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CallerLineNumberAttribute)) 662else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CallerFilePathAttribute)) 666else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CallerMemberNameAttribute)) 670else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CallerArgumentExpressionAttribute)) 699private (CSharpAttributeData?, BoundAttribute?) EarlyDecodeAttributeForDefaultParameterValue(AttributeDescription description, ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 728protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 778MarshalAsAttributeDecoder<ParameterWellKnownAttributeData, AttributeSyntax, CSharpAttributeData, AttributeLocation>.Decode(ref arguments, AttributeTargets.Parameter, MessageProvider.Instance); 880private static bool? DecodeMaybeNullWhenOrNotNullWhenOrDoesNotReturnIfAttribute(CSharpAttributeData attribute) 888private void DecodeDefaultParameterValueAttribute(AttributeDescription description, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 930private ConstantValue DecodeDefaultParameterValueAttribute(AttributeDescription description, CSharpAttributeData attribute, AttributeSyntax node, bool diagnose, BindingDiagnosticBag diagnosticsOpt) 949private ConstantValue DecodeDefaultParameterValueAttribute(CSharpAttributeData attribute, AttributeSyntax node, bool diagnose, BindingDiagnosticBag diagnosticsOpt) 1154private void ValidateCallerArgumentExpressionAttribute(AttributeSyntax node, CSharpAttributeData attribute, BindingDiagnosticBag diagnostics) 1237private void DecodeInterpolatedStringHandlerArgumentAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, BindingDiagnosticBag diagnostics, int attributeIndex) 1320(int Ordinal, ParameterSymbol? Parameter)? decodeName(TypedConstant constant, ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1377static void setInterpolatedStringHandlerAttributeError(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1384internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
Symbols\Source\SourceConstructorSymbolBase.cs (2)
239internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 243if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.SetsRequiredMembersAttribute))
Symbols\Source\SourceEventFieldSymbol.cs (1)
59internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceEventSymbol.cs (8)
34private CustomAttributesBag<CSharpAttributeData>? _lazyCustomAttributesBag; 204private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 258public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 298internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 300CSharpAttributeData? attributeData; 341protected sealed override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 361CSharpAttributeData.DecodeSkipLocalsInitAttribute<CommonEventWellKnownAttributeData>(DeclaringCompilation, ref arguments); 369internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData>? attributes)
Symbols\Source\SourceFieldSymbol.cs (1)
114protected sealed override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
Symbols\Source\SourceFixedFieldSymbol.cs (2)
41internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 207internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceMemberContainerSymbol.cs (2)
1437foreach (var attr in symbol.GetAttributes()) 5903internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceMemberFieldSymbol.cs (2)
113internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 141internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
Symbols\Source\SourceMethodSymbol.cs (2)
103internal sealed override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 109internal static void AddSynthesizedAttributes(MethodSymbol target, PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceMethodSymbolWithAttributes.cs (32)
30private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 31private CustomAttributesBag<CSharpAttributeData> _lazyReturnTypeCustomAttributesBag; 248private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 265private CustomAttributesBag<CSharpAttributeData> GetReturnTypeAttributesBag() 276private CustomAttributesBag<CSharpAttributeData> GetAttributesBag(ref CustomAttributesBag<CSharpAttributeData> lazyCustomAttributesBag, bool forReturnType) 318public override ImmutableArray<CSharpAttributeData> GetAttributes() 327public override ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes() 333internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 341if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.ConditionalAttribute)) 356else if (EarlyDecodeDeprecatedOrExperimentalOrObsoleteAttribute(ref arguments, out CSharpAttributeData? attributeData, out BoundAttribute? boundAttribute, out ObsoleteAttributeData? obsoleteData)) 365else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.UnmanagedCallersOnlyAttribute)) 373else if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.OverloadResolutionPriorityAttribute)) 403public ImmutableArray<(CSharpAttributeData, BoundAttribute)> BindMethodAttributes() 511protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 526private void DecodeWellKnownAttributeAppliedToMethod(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 540AttributeData.DecodeMethodImplAttribute<MethodWellKnownAttributeData, AttributeSyntax, CSharpAttributeData, AttributeLocation>(ref arguments, MessageProvider.Instance); 591CSharpAttributeData.DecodeSkipLocalsInitAttribute<MethodWellKnownAttributeData>(DeclaringCompilation, ref arguments); 600CSharpAttributeData.DecodeMemberNotNullAttribute<MethodWellKnownAttributeData>(ContainingType, ref arguments); 605CSharpAttributeData.DecodeMemberNotNullWhenAttribute<MethodWellKnownAttributeData>(ContainingType, ref arguments); 688ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, 715private void ValidateConditionalAttribute(CSharpAttributeData attribute, AttributeSyntax node, BindingDiagnosticBag diagnostics) 779private void DecodeWellKnownAttributeAppliedToReturnValue(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 790MarshalAsAttributeDecoder<ReturnTypeWellKnownAttributeData, AttributeSyntax, CSharpAttributeData, AttributeLocation>.Decode(ref arguments, AttributeTargets.ReturnValue, MessageProvider.Instance); 818private void DecodeDllImportAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 943private void DecodeModuleInitializerAttribute(DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 992private void DecodeInterceptsLocationAttribute(DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1010private void DecodeInterceptsLocationChecksumBased(DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, int version, string? data) 1165DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, 1378private void DecodeUnmanagedCallersOnlyAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1434static UnmanagedCallersOnlyAttributeData DecodeUnmanagedCallersOnlyAttributeData(SourceMethodSymbol @this, CSharpAttributeData attribute, Location location, BindingDiagnosticBag diagnostics) 1464internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
Symbols\Source\SourceModuleSymbol.cs (6)
43private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 514private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 537public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 559protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 585CSharpAttributeData.DecodeSkipLocalsInitAttribute<ModuleWellKnownAttributeData>(DeclaringCompilation, ref arguments); 632internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceNamedTypeSymbol.cs (20)
30private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 839private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 861public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 901internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 904CSharpAttributeData? attributeData; 907if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.ComImportAttribute)) 922if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CodeAnalysisEmbeddedAttribute)) 937if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.ConditionalAttribute)) 964if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.AttributeUsageAttribute)) 996if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.InterpolatedStringHandlerAttribute)) 1011if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.InlineArrayAttribute)) 1029if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.CollectionBuilderAttribute)) 1094protected sealed override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1137AttributeData.DecodeStructLayoutAttribute<TypeWellKnownAttributeData, AttributeSyntax, CSharpAttributeData, AttributeLocation>( 1182CSharpAttributeData.DecodeSkipLocalsInitAttribute<TypeWellKnownAttributeData>(DeclaringCompilation, ref arguments); 1299private AttributeUsageInfo DecodeAttributeUsageAttribute(CSharpAttributeData attribute, AttributeSyntax node, bool diagnose, BindingDiagnosticBag diagnosticsOpt = null) 1336private void DecodeCoClassAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1389private void ValidateConditionalAttribute(CSharpAttributeData attribute, AttributeSyntax node, BindingDiagnosticBag diagnostics) 1582internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData) 1681internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourceParameterSymbol.cs (2)
191internal abstract CustomAttributesBag<CSharpAttributeData> GetAttributesBag(); 197public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Source\SourceParameterSymbolBase.cs (2)
69internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 75internal static void AddSynthesizedAttributes(ParameterSymbol parameter, PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourcePropertyAccessorSymbol.cs (2)
796internal sealed override void AddSynthesizedReturnTypeAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 802internal void AddSynthesizedReturnTypeFlowAnalysisAttributes(ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Source\SourcePropertySymbolBase.cs (15)
70private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 472CustomAttributesBag<CSharpAttributeData>? temp = null; 1298private CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 1343public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 1382internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 1437internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 1439CSharpAttributeData? attributeData; 1453if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.IndexerNameAttribute)) 1473else if ((IsIndexer || this.GetIsNewExtensionMember()) && CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.OverloadResolutionPriorityAttribute)) 1517protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 1543CSharpAttributeData.DecodeSkipLocalsInitAttribute<PropertyWellKnownAttributeData>(DeclaringCompilation, ref arguments); 1581CSharpAttributeData.DecodeMemberNotNullAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments); 1586CSharpAttributeData.DecodeMemberNotNullWhenAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments); 1700internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData) 1712private void ValidateIndexerNameAttribute(CSharpAttributeData attribute, AttributeSyntax node, BindingDiagnosticBag diagnostics)
Symbols\Source\SourceSimpleParameterSymbol.cs (2)
154internal override CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 157return CustomAttributesBag<CSharpAttributeData>.Empty;
Symbols\Source\SourceTypeParameterSymbol.cs (6)
31private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag; 166public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 177internal virtual CustomAttributesBag<CSharpAttributeData> GetAttributesBag() 194CustomAttributesBag<CSharpAttributeData> attributesBag = typeParameter.GetAttributesBag(); 385internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 426protected sealed override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
Symbols\SubstitutedEventSymbol.cs (1)
54public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\SubstitutedFieldSymbol.cs (1)
77public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\SubstitutedMethodSymbol.cs (2)
206public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 211public override ImmutableArray<CSharpAttributeData> GetReturnTypeAttributes()
Symbols\SubstitutedNamedTypeSymbol.cs (2)
209public sealed override ImmutableArray<CSharpAttributeData> GetAttributes() 472internal override IEnumerable<CSharpAttributeData> GetCustomAttributesToEmit(PEModuleBuilder moduleBuilder)
Symbols\SubstitutedPropertySymbol.cs (1)
63public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\Symbol.cs (7)
874internal virtual void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 881internal static void AddSynthesizedAttribute(ref ArrayBuilder<CSharpAttributeData> attributes, CSharpAttributeData attribute) 887attributes = new ArrayBuilder<CSharpAttributeData>(1); 1525internal bool ReportExplicitUseOfReservedAttributes(in DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, ReservedAttributes reserved) 1605bool reportExplicitUseOfReservedAttribute(CSharpAttributeData attribute, in DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments, in AttributeDescription attributeDescription)
Symbols\Symbol_Attributes.cs (30)
27public virtual ImmutableArray<CSharpAttributeData> GetAttributes() 34return ImmutableArray<CSharpAttributeData>.Empty; 141internal virtual (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 148out CSharpAttributeData? attributeData, 156if (CSharpAttributeData.IsTargetEarlyAttribute(type, syntax, AttributeDescription.ObsoleteAttribute)) 160else if (CSharpAttributeData.IsTargetEarlyAttribute(type, syntax, AttributeDescription.DeprecatedAttribute)) 164else if (CSharpAttributeData.IsTargetEarlyAttribute(type, syntax, AttributeDescription.WindowsExperimentalAttribute)) 168else if (CSharpAttributeData.IsTargetEarlyAttribute(type, syntax, AttributeDescription.ExperimentalAttribute)) 215protected void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 237protected virtual void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 259internal virtual void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData) 300ref CustomAttributesBag<CSharpAttributeData>? lazyCustomAttributesBag, 317ImmutableArray<CSharpAttributeData> boundAttributes; 328Interlocked.CompareExchange(ref lazyCustomAttributesBag, new CustomAttributesBag<CSharpAttributeData>(), null); 354var attributeDataArray = new CSharpAttributeData[totalAttributesCount]; 392boundAttributes = ImmutableArray<CSharpAttributeData>.Empty; 395Interlocked.CompareExchange(ref lazyCustomAttributesBag, CustomAttributesBag<CSharpAttributeData>.WithEmptyData(), null); 434if (lazyCustomAttributesBag.IsEmpty) lazyCustomAttributesBag = CustomAttributesBag<CSharpAttributeData>.Empty; 441void removeObsoleteDiagnosticsForForwardedTypes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> attributesToBind, ref BindingDiagnosticBag diagnostics) 473CSharpAttributeData boundAttribute = boundAttributes[i]; 539protected ImmutableArray<(CSharpAttributeData, BoundAttribute)> BindAttributes(OneOrMany<SyntaxList<AttributeListSyntax>> attributeDeclarations, Binder? rootBinder) 541var boundAttributeArrayBuilder = ArrayBuilder<(CSharpAttributeData, BoundAttribute)>.GetInstance(); 561private void RecordPresenceOfBadAttributes(ImmutableArray<CSharpAttributeData> boundAttributes) 563foreach (var attribute in boundAttributes) 769CSharpAttributeData?[] attributeDataArray, 797(CSharpAttributeData? earlyAttributeDataOpt, BoundAttribute? boundAttributeOpt) = this.EarlyDecodeWellKnownAttribute(ref arguments); 839ImmutableArray<CSharpAttributeData> boundAttributes, 851var arguments = new DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation>(); 858CSharpAttributeData boundAttribute = boundAttributes[i]; 886CSharpAttributeData attribute,
Symbols\Synthesized\ReadOnlyListType\SynthesizedReadOnlyListTypeSymbol.cs (1)
928internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\Records\SynthesizedPrimaryConstructor.cs (3)
141internal override (CSharpAttributeData?, BoundAttribute?) EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments) 150protected override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 158internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
Symbols\Synthesized\Records\SynthesizedPrimaryConstructorParameterBackingFieldSymbol.cs (2)
70internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 72foreach (CSharpAttributeData attr in ParameterSymbol.GetAttributes())
Symbols\Synthesized\Records\SynthesizedRecordCopyCtor.cs (1)
75internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\Records\SynthesizedRecordEqualityContractProperty.cs (1)
92internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedAccessorValueParameterSymbol.cs (2)
80internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 86internal void AddSynthesizedFlowAnalysisAttributes(ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedBackingFieldSymbol.cs (3)
42internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 235protected sealed override void DecodeWellKnownAttributeImpl(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments) 261internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
Symbols\Synthesized\SynthesizedContainer.cs (1)
52internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedEmbeddedAttributeSymbol.cs (1)
183internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedEntryPointSymbol.cs (1)
381internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedEnumValueFieldSymbol.cs (1)
38internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedFieldSymbolBase.cs (1)
46internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedHotReloadExceptionSymbol.cs (1)
74internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedInlineArrayTypeSymbol.cs (1)
196internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedInstanceConstructor.cs (1)
322internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Synthesized\SynthesizedParameterSymbol.cs (3)
148internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 376public override ImmutableArray<CSharpAttributeData> GetAttributes() 378return _baseParameterForAttributes?.GetAttributes() ?? ImmutableArray<CSharpAttributeData>.Empty;
Symbols\Synthesized\SynthesizedSubstitutedTypeParameterSymbol.cs (4)
35internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes) 41foreach (CSharpAttributeData attr in definition.GetAttributes()) 58public override ImmutableArray<CSharpAttributeData> GetAttributes() 65return ImmutableArray<CSharpAttributeData>.Empty;
Symbols\Tuples\TupleFieldSymbol.cs (2)
134public override ImmutableArray<CSharpAttributeData> GetAttributes() 325public override ImmutableArray<CSharpAttributeData> GetAttributes()
Symbols\TypeSymbol.cs (1)
1980foreach (var attributeData in implementingSymbol.GetAttributes())
Symbols\Wrapped\WrappedParameterSymbol.cs (2)
69public override ImmutableArray<CSharpAttributeData> GetAttributes() 74internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<CSharpAttributeData> attributes)
Symbols\Wrapped\WrappedTypeParameterSymbol.cs (1)
178public override ImmutableArray<CSharpAttributeData> GetAttributes()