Skip to content

Commit

Permalink
Lower the severity until bugs fixed (dotnet#6456)
Browse files Browse the repository at this point in the history
  • Loading branch information
buyaa-n authored Jan 26, 2023
1 parent 9b5d130 commit 87457b2
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/NetAnalyzers/Core/AnalyzerReleases.Unshipped.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ CA1856 | Performance | Error | ConstantExpectedAnalyzer, [Documentation](https:/
CA1857 | Performance | Warning | ConstantExpectedAnalyzer, [Documentation](https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1857)
CA1858 | Performance | Info | UseStartsWithInsteadOfIndexOfComparisonWithZero, [Documentation](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1858)
CA1859 | Performance | Info | UseConcreteTypeAnalyzer, [Documentation](https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1859)
CA2021 | Reliability | Warning | DoNotCallEnumerableCastOrOfTypeWithIncompatibleTypesAnalyzer, [Documentation](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2021)
CA2021 | Reliability | Info | DoNotCallEnumerableCastOrOfTypeWithIncompatibleTypesAnalyzer, [Documentation](https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2021)

### Removed Rules

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public sealed class DoNotCallEnumerableCastOrOfTypeWithIncompatibleTypesAnalyzer
s_localizableTitle,
s_localizableCastMessage,
DiagnosticCategory.Reliability,
RuleLevel.BuildWarning,
RuleLevel.IdeSuggestion,
s_localizableDescription,
isPortedFxCopRule: false,
isDataflowRule: false);
Expand All @@ -39,7 +39,7 @@ public sealed class DoNotCallEnumerableCastOrOfTypeWithIncompatibleTypesAnalyzer
s_localizableTitle,
s_localizableOfTypeMessage,
DiagnosticCategory.Reliability,
RuleLevel.BuildWarning,
RuleLevel.IdeSuggestion,
s_localizableDescription,
isPortedFxCopRule: false,
isDataflowRule: false);
Expand Down
2 changes: 1 addition & 1 deletion src/NetAnalyzers/Microsoft.CodeAnalysis.NetAnalyzers.md
Original file line number Diff line number Diff line change
Expand Up @@ -1874,7 +1874,7 @@ Widening and user defined conversions are not supported with generic types.
|-|-|
|Category|Reliability|
|Enabled|True|
|Severity|Warning|
|Severity|Info|
|CodeFix|False|
---

Expand Down
2 changes: 1 addition & 1 deletion src/NetAnalyzers/Microsoft.CodeAnalysis.NetAnalyzers.sarif
Original file line number Diff line number Diff line change
Expand Up @@ -3362,7 +3362,7 @@
"id": "CA2021",
"shortDescription": "Do not call Enumerable.Cast<T> or Enumerable.OfType<T> with incompatible types",
"fullDescription": "Enumerable.Cast<T> and Enumerable.OfType<T> require compatible types to function expectedly. \u000aThe generic cast (IL 'unbox.any') used by the sequence returned by Enumerable.Cast<T> will throw InvalidCastException at runtime on elements of the types specified. \u000aThe generic type check (C# 'is' operator/IL 'isinst') used by Enumerable.OfType<T> will never succeed with elements of types specified, resulting in an empty sequence. \u000aWidening and user defined conversions are not supported with generic types.",
"defaultLevel": "warning",
"defaultLevel": "note",
"helpUri": "https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2021",
"properties": {
"category": "Reliability",
Expand Down
2 changes: 0 additions & 2 deletions src/NetAnalyzers/RulesMissingDocumentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

Rule ID | Missing Help Link | Title |
--------|-------------------|-------|
CA1311 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1311> | Specify a culture or use an invariant version |
CA1421 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1421> | This method uses runtime marshalling even when the 'DisableRuntimeMarshallingAttribute' is applied |
CA1510 | <https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1510> | Use ArgumentNullException throw helper |
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 |
Expand Down

0 comments on commit 87457b2

Please sign in to comment.