// Copyright (c) Microsoft. All rights reserved. #pragma warning disable SA1623 // Property summary documentation should match accessors namespace System.Runtime.CompilerServices; /// /// Indicates that compiler support for a particular feature is required for the location where this attribute is applied. /// [AttributeUsage(AttributeTargets.All, AllowMultiple = true, Inherited = false)] internal sealed class CompilerFeatureRequiredAttribute : Attribute { public CompilerFeatureRequiredAttribute(string featureName) { this.FeatureName = featureName; } /// /// The name of the compiler feature. /// public string FeatureName { get; } /// /// If true, the compiler can choose to allow access to the location where this attribute is applied if it does not understand . /// public bool IsOptional { get; init; } /// /// The used for the ref structs C# feature. /// public const string RefStructs = nameof(RefStructs); /// /// The used for the required members C# feature. /// public const string RequiredMembers = nameof(RequiredMembers); }