Skip to content

Commit

Permalink
style: format code with dotnet-format
Browse files Browse the repository at this point in the history
This commit fixes the style issues introduced in f4ff5cf according to the output
from dotnet-format.

Details: None
  • Loading branch information
deepsource-autofix[bot] authored Nov 23, 2023
1 parent f4ff5cf commit fd2e819
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ namespace System.Diagnostics.CodeAnalysis;
[System.AttributeUsage(AttributeTargets.Constructor, AllowMultiple = false, Inherited = false)]
internal sealed class SetsRequiredMembersAttribute(params string[] members) : Attribute
{
public string[] Members { get; } = members;

public SetsRequiredMembersAttribute()
: this(null as string[]) { }

public SetsRequiredMembersAttribute(string members)
: this(new[] { members }) { }
public string[] Members { get; } = members;

public SetsRequiredMembersAttribute()
: this(null as string[]) { }

public SetsRequiredMembersAttribute(string members)
: this(new[] { members }) { }
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,28 +8,28 @@ internal sealed class CompilerFeatureRequiredAttribute(string? featureName, bool
: Attribute
{
public CompilerFeatureRequiredAttribute(string? featureName)
: this(featureName, false) { }

public CompilerFeatureRequiredAttribute()
: this(null) { }

/// <summary>
/// The <see cref="FeatureName"/> used for the ref structs C# feature.
/// </summary>
public const string RefStructs = nameof(RefStructs);

/// <summary>
/// The <see cref="FeatureName"/> used for the required members C# feature.
/// </summary>
public const string RequiredMembers = nameof(RequiredMembers);

/// <summary>
/// The name of the compiler feature.
/// </summary>
public string FeatureName { get; } = featureName;

/// <summary>
/// If <see langword="true" />, the compiler can choose to allow access to the location where this attribute is applied if it does not understand <see cref="FeatureName"/>.
/// </summary>
public bool IsOptional { get; init; } = isOptional;
: this(featureName, false) { }

public CompilerFeatureRequiredAttribute()
: this(null) { }

/// <summary>
/// The <see cref="FeatureName"/> used for the ref structs C# feature.
/// </summary>
public const string RefStructs = nameof(RefStructs);

/// <summary>
/// The <see cref="FeatureName"/> used for the required members C# feature.
/// </summary>
public const string RequiredMembers = nameof(RequiredMembers);

/// <summary>
/// The name of the compiler feature.
/// </summary>
public string FeatureName { get; } = featureName;

/// <summary>
/// If <see langword="true" />, the compiler can choose to allow access to the location where this attribute is applied if it does not understand <see cref="FeatureName"/>.
/// </summary>
public bool IsOptional { get; init; } = isOptional;
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,6 @@ namespace System.Runtime.CompilerServices
#else
internal
#endif
static class IsExternalInit { }
static class IsExternalInit
{ }
}

0 comments on commit fd2e819

Please sign in to comment.