Skip to content

Commit

Permalink
Merge pull request #6345 from Youssef1313/patch-26
Browse files Browse the repository at this point in the history
Fix analyzer description
  • Loading branch information
mavasani authored Dec 13, 2022
2 parents ed54cef + bb32f58 commit 141bdd5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
3 changes: 0 additions & 3 deletions src/NetAnalyzers/RulesMissingDocumentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,5 @@ CA1510 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-
CA1511 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1511> | Use ArgumentException throw helper |
CA1512 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1512> | Use ArgumentOutOfRangeException throw helper |
CA1513 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1513> | Use ObjectDisposedException throw helper |
CA1852 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1852> | Seal internal types |
CA1853 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1853> | Unnecessary call to 'Dictionary.ContainsKey(key)' |
CA1855 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1855> | Prefer 'Clear' over 'Fill' |
CA1856 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1856> | Incorrect usage of ConstantExpected attribute |
CA1857 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1857> | A constant is expected for the parameter |
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public partial class DeclarePublicApiAnalyzer
category: "ApiDesign",
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: false,
description: CreateLocalizableResourceString(nameof(DeclarePublicApiDescription)),
description: CreateLocalizableResourceString(nameof(DeclareInternalApiDescription)),
helpLinkUri: "https://github.com/dotnet/roslyn-analyzers/blob/main/src/PublicApiAnalyzers/PublicApiAnalyzers.Help.md",
customTags: WellKnownDiagnosticTagsExtensions.Telemetry);

Expand Down Expand Up @@ -270,7 +270,7 @@ public partial class DeclarePublicApiAnalyzer
category: "ApiDesign",
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: false,
description: CreateLocalizableResourceString(nameof(ShouldAnnotatePublicApiFilesDescription)),
description: CreateLocalizableResourceString(nameof(ShouldAnnotateInternalApiFilesDescription)),
helpLinkUri: "https://github.com/dotnet/roslyn-analyzers/blob/main/src/InternalApiAnalyzers/InternalApiAnalyzers.Help.md",
customTags: WellKnownDiagnosticTagsExtensions.Telemetry);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ Symbol '{0}' is marked as removed but it isn't deleted in source code

## [RS0051](https://github.com/dotnet/roslyn-analyzers/blob/main/src/PublicApiAnalyzers/PublicApiAnalyzers.Help.md): Add internal types and members to the declared API

All public types and members should be declared in PublicAPI.txt. This draws attention to API changes in the code reviews and source control history, and helps prevent breaking changes.
All internal types and members should be declared in InternalAPI.txt. This draws attention to API changes in the code reviews and source control history, and helps prevent breaking changes.

|Item|Value|
|-|-|
Expand Down Expand Up @@ -206,7 +206,7 @@ All internal types and members should be declared with nullability annotations i

## [RS0056](https://github.com/dotnet/roslyn-analyzers/blob/main/src/InternalApiAnalyzers/InternalApiAnalyzers.Help.md): Enable tracking of nullability of reference types in the declared API

PublicAPI.txt files should have `#nullable enable` to track nullability information, or this diagnostic should be suppressed. With nullability enabled, PublicAPI.txt records which types are nullable (suffix `?` on type) or non-nullable (suffix `!`). It also tracks any API that is still using an oblivious reference type (prefix `~` on line).
InternalAPI.txt files should have `#nullable enable` to track nullability information, or this diagnostic should be suppressed. With nullability enabled, InternalAPI.txt records which types are nullable (suffix `?` on type) or non-nullable (suffix `!`). It also tracks any API that is still using an oblivious reference type (prefix `~` on line).

|Item|Value|
|-|-|
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@
"RS0051": {
"id": "RS0051",
"shortDescription": "Add internal types and members to the declared API",
"fullDescription": "All public types and members should be declared in PublicAPI.txt. This draws attention to API changes in the code reviews and source control history, and helps prevent breaking changes.",
"fullDescription": "All internal types and members should be declared in InternalAPI.txt. This draws attention to API changes in the code reviews and source control history, and helps prevent breaking changes.",
"defaultLevel": "warning",
"helpUri": "https://github.com/dotnet/roslyn-analyzers/blob/main/src/PublicApiAnalyzers/PublicApiAnalyzers.Help.md",
"properties": {
Expand Down Expand Up @@ -343,7 +343,7 @@
"RS0056": {
"id": "RS0056",
"shortDescription": "Enable tracking of nullability of reference types in the declared API",
"fullDescription": "PublicAPI.txt files should have `#nullable enable` to track nullability information, or this diagnostic should be suppressed. With nullability enabled, PublicAPI.txt records which types are nullable (suffix `?` on type) or non-nullable (suffix `!`). It also tracks any API that is still using an oblivious reference type (prefix `~` on line).",
"fullDescription": "InternalAPI.txt files should have `#nullable enable` to track nullability information, or this diagnostic should be suppressed. With nullability enabled, InternalAPI.txt records which types are nullable (suffix `?` on type) or non-nullable (suffix `!`). It also tracks any API that is still using an oblivious reference type (prefix `~` on line).",
"defaultLevel": "warning",
"helpUri": "https://github.com/dotnet/roslyn-analyzers/blob/main/src/InternalApiAnalyzers/InternalApiAnalyzers.Help.md",
"properties": {
Expand Down

0 comments on commit 141bdd5

Please sign in to comment.