Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge master to release/6.0.1xx-preview1 #4525

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,28 @@ dotnet_code_quality.CA1720.api_surface = public
# CA1715: Identifiers should have correct prefix
dotnet_code_quality.CA1715.exclude_single_letter_type_parameters = true

# CA1002: Do not expose generic lists
dotnet_diagnostic.CA1002.severity = suggestion

# CA1024: Use properties where appropriate
dotnet_diagnostic.CA1024.severity = suggestion

# CA1033: Interface methods should be callable by child types
dotnet_diagnostic.CA1033.severity = suggestion

# CA1307: Specify StringComparison for clarity
dotnet_diagnostic.CA1307.severity = suggestion

# CA1711: Identifiers should not have incorrect suffix
dotnet_diagnostic.CA1711.severity = suggestion

# CA1309: Use ordinal string comparison
dotnet_diagnostic.CA1309.severity = suggestion

# CA1725: Parameter names should match base declaration
# TODO: Enable this rule as warning and fix violations.
dotnet_diagnostic.CA1725.severity = suggestion

### Configuration for PublicAPI analyzers executed on this repo ###
[*.{cs,vb}]

Expand Down
6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ assignees: ''

_OR_

**NuGet Package**: [Microsoft.CodeAnalysis.FxCopAnalyzers](https://www.nuget.org/packages/Microsoft.CodeAnalysis.FxCopAnalyzers)
**NuGet Package**: [Microsoft.CodeAnalysis.NetAnalyzers](https://www.nuget.org/packages/Microsoft.CodeAnalysis.NetAnalyzers)

**Version**: v3.3.1 (Latest)
**Version**: 5.0.1 (Latest)

<!--
NOTE: FxCopAnalyzers package has been deprecated in favor of 'Microsoft.CodeAnalysis.NetAnalyzers', that ships with the .NET SDK.
NOTE: `Microsoft.CodeAnalysis.FxCopAnalyzers` package has been deprecated in favor of 'Microsoft.CodeAnalysis.NetAnalyzers', that ships with the .NET SDK.
Please refer to https://docs.microsoft.com/visualstudio/code-quality/migrate-from-fxcop-analyzers-to-net-analyzers to migrate to .NET analyzers.
-->

Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ You do not need to manually install this NuGet package to your project if you ar

### Microsoft.CodeAnalysis.FxCopAnalyzers

**NOTE:** Starting version `3.3.2`, `Microsoft.CodeAnalysis.FxCopAnalyzers` has been **deprecated** in favor of `Microsoft.CodeAnalysis.NetAnalyzers`. Documentation to migrate from FxCopAnalyzers to NetAnalyzers is available [here](https://docs.microsoft.com/visualstudio/code-quality/migrate-from-fxcop-analyzers-to-net-analyzers).

*Latest stable version:* [![NuGet](https://img.shields.io/nuget/v/Microsoft.CodeAnalysis.FxCopAnalyzers.svg)](https://www.nuget.org/packages/Microsoft.CodeAnalysis.FxCopAnalyzers)

*Latest pre-release version:* [here](https://dev.azure.com/dnceng/public/_packaging?_a=package&feed=dotnet5&view=overview&package=Microsoft.CodeAnalysis.FxCopAnalyzers&protocolType=NuGet)
Expand Down Expand Up @@ -154,7 +156,7 @@ See [VERSIONING.md](.//VERSIONING.md) for the versioning scheme for all analyzer

## Recommended version of Analyzer Packages

Recommended Analyzer Package Version: **Version 5.0.0**, for example [Microsoft.CodeAnalysis.NetAnalyzers 5.0.0](https://www.nuget.org/packages/Microsoft.CodeAnalysis.NetAnalyzers/5.0.0)
Recommended Analyzer Package Version: [![NuGet](https://img.shields.io/nuget/v/Microsoft.CodeAnalysis.NetAnalyzers.svg)](https://www.nuget.org/packages/Microsoft.CodeAnalysis.NetAnalyzers)

Required Visual Studio Version: **Visual Studio 2019 16.8 RTW or later**

Expand Down
7 changes: 7 additions & 0 deletions RoslynAnalyzers.sln
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.CodeAnalysis.CSha
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.CodeAnalysis.CSharp.PerformanceSensitiveAnalyzers.CodeFixes", "src\PerformanceSensitiveAnalyzers\CSharp\CodeFixes\Microsoft.CodeAnalysis.CSharp.PerformanceSensitiveAnalyzers.CodeFixes.csproj", "{046419A7-C60D-40FF-AD7E-2BAE461B7CE5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GenerateAnalyzerNuspec", "src\Tools\GenerateAnalyzerNuspec\GenerateAnalyzerNuspec.csproj", "{81E21880-3F26-42DC-9423-9DACB8933597}"
EndProject
Global
GlobalSection(SharedMSBuildProjectFiles) = preSolution
src\Utilities\Workspaces\Workspaces.Utilities.projitems*{046419a7-c60d-40ff-ad7e-2bae461b7ce5}*SharedItemsImports = 5
Expand Down Expand Up @@ -423,6 +425,10 @@ Global
{046419A7-C60D-40FF-AD7E-2BAE461B7CE5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{046419A7-C60D-40FF-AD7E-2BAE461B7CE5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{046419A7-C60D-40FF-AD7E-2BAE461B7CE5}.Release|Any CPU.Build.0 = Release|Any CPU
{81E21880-3F26-42DC-9423-9DACB8933597}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{81E21880-3F26-42DC-9423-9DACB8933597}.Debug|Any CPU.Build.0 = Debug|Any CPU
{81E21880-3F26-42DC-9423-9DACB8933597}.Release|Any CPU.ActiveCfg = Release|Any CPU
{81E21880-3F26-42DC-9423-9DACB8933597}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -494,6 +500,7 @@ Global
{4C362C30-C4B1-4C4B-A545-DBF67C7E9153} = {1F4F7A9B-FD3B-495F-86D0-89A7DEA2128C}
{8197A037-FF9E-4660-8C6D-2F722FEA0C10} = {34430BD4-4D66-4FE6-8076-51B87B4FBCD4}
{046419A7-C60D-40FF-AD7E-2BAE461B7CE5} = {34430BD4-4D66-4FE6-8076-51B87B4FBCD4}
{81E21880-3F26-42DC-9423-9DACB8933597} = {DB2DD702-8301-4FC6-B8C0-029C7DCC2931}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {FC44ACA9-AEA3-4EE6-881C-2E08ED281B5F}
Expand Down
2 changes: 2 additions & 0 deletions VERSIONING.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Released versions of analyzer packages, with the last GitHub Commit Tag and SHA
Sr. No. | Release |
--------|-----------------|
1 | [5.0.0](https://github.com/dotnet/roslyn-analyzers/releases/tag/5.0.0) |
2 | [5.0.1](https://github.com/dotnet/roslyn-analyzers/releases/tag/5.0.1) |

### Other analyzers

Expand Down Expand Up @@ -62,3 +63,4 @@ Sr. No. | Release Version | Commit Tag | Commit SHA
36 | 3.3.0-beta2.final (pre-release) | v3.3.0-beta2.final | [303d517](https://github.com/dotnet/roslyn-analyzers/commit/303d517d74aaaade61c2e46c9d8965c23758ee7d) | Microsoft.CodeAnalysis.FxCopAnalyzers, Microsoft.CodeAnalysis.VersionCheckAnalyzer, Microsoft.CodeQuality.Analyzers, Microsoft.NetCore.Analyzers, Microsoft.NetFramework.Analyzers, Roslyn.Diagnostics.Analyzers, Microsoft.CodeAnalysis.PublicApiAnalyzers, Microsoft.CodeAnalysis.BannedApiAnalyzers
37 | 3.3.0 | v3.3.0 | [0a95f9e](https://github.com/dotnet/roslyn-analyzers/commit/0a95f9e9a53519ee3cd59b9cf96be6326ef9955b) | Microsoft.CodeAnalysis.Analyzers, Microsoft.CodeAnalysis.AnalyzerUtilities, Microsoft.CodeAnalysis.FxCopAnalyzers, Microsoft.CodeAnalysis.Metrics, Microsoft.CodeAnalysis.VersionCheckAnalyzer, Microsoft.CodeQuality.Analyzers, Microsoft.NetCore.Analyzers, Microsoft.NetFramework.Analyzers, Roslyn.Diagnostics.Analyzers, Microsoft.CodeAnalysis.PublicApiAnalyzers, Microsoft.CodeAnalysis.BannedApiAnalyzers
38 | 3.3.1 | v3.3.1 | [49efc9e](https://github.com/dotnet/roslyn-analyzers/commit/49efc9eea7aaa303190beb5b3ea554604fb5ce9d) | Microsoft.CodeAnalysis.Analyzers, Microsoft.CodeAnalysis.AnalyzerUtilities, Microsoft.CodeAnalysis.FxCopAnalyzers, Microsoft.CodeAnalysis.VersionCheckAnalyzer, Microsoft.CodeQuality.Analyzers, Microsoft.NetCore.Analyzers, Microsoft.NetFramework.Analyzers, Roslyn.Diagnostics.Analyzers, Microsoft.CodeAnalysis.PublicApiAnalyzers, Microsoft.CodeAnalysis.BannedApiAnalyzers
39 | 3.3.2 | v3.3.2 | [4e0e1e8](https://github.com/dotnet/roslyn-analyzers/commit/4e0e1e855864587991a39e1e974dc53af094f4db) | Microsoft.CodeAnalysis.Analyzers, Microsoft.CodeAnalysis.AnalyzerUtilities, Microsoft.CodeAnalysis.FxCopAnalyzers, Microsoft.CodeAnalysis.VersionCheckAnalyzer, Microsoft.CodeQuality.Analyzers, Microsoft.NetCore.Analyzers, Microsoft.NetFramework.Analyzers, Roslyn.Diagnostics.Analyzers, Microsoft.CodeAnalysis.PublicApiAnalyzers, Microsoft.CodeAnalysis.BannedApiAnalyzers
54 changes: 6 additions & 48 deletions docs/Analyzer Configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -257,9 +257,7 @@ Default Value: `false`

Example: `dotnet_code_quality.try_determine_additional_string_formatting_methods_automatically = true`

### Excluded symbol names

Option Name: `excluded_symbol_names`
### Excluded symbols

Configurable Rules:
[CA1001](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1001),
Expand Down Expand Up @@ -305,6 +303,10 @@ Configurable Rules:
[CA5389](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5389),
[CA5390](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5390)

#### Excluded symbol names

Option Name: `excluded_symbol_names`

Option Values: Names of symbols (separated by '|') that are excluded for analysis.
Allowed symbol name formats:

Expand Down Expand Up @@ -332,54 +334,10 @@ Examples:

Additionally, all the dataflow analysis based rules can be configured with a single entry `dotnet_code_quality.dataflow.excluded_symbol_names = ...`

### Excluded type names with derived types
#### Excluded type names with derived types

Option Name: `excluded_type_names_with_derived_types`

Configurable Rules:
[CA1001](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1001),
[CA1062](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1062),
[CA1303](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1303),
[CA1304](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1304),
[CA1508](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1508),
[CA2000](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000),
[CA2100](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2100),
[CA2301](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2301),
[CA2302](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2302),
[CA2311](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2311),
[CA2312](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2312),
[CA2321](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2321),
[CA2322](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2322),
[CA2327](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2327),
[CA2328](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2328),
[CA2329](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2329),
[CA2330](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2330),
[CA3001](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3001),
[CA3002](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3002),
[CA3003](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3003),
[CA3004](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3004),
[CA3005](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3005),
[CA3006](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3006),
[CA3007](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3007),
[CA3008](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3008),
[CA3009](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3009),
[CA3010](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3010),
[CA3011](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3011),
[CA3012](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca3012),
[CA5361](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5361),
[CA5376](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5376),
[CA5377](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5377),
[CA5378](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5378),
[CA5380](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5380),
[CA5381](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5381),
[CA5382](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5382),
[CA5383](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5383),
[CA5384](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5384),
[CA5387](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5387),
[CA5388](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5388),
[CA5389](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5389),
[CA5390](https://docs.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca5390)

Option Values: Names of types (separated by '|'), such that the type and all its derived types are excluded for analysis.
Allowed symbol name formats:

Expand Down
2 changes: 2 additions & 0 deletions eng/Analyzers_ShippingRules.ruleset
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
<Rules AnalyzerId="Microsoft.ApiDesignGuidelines.Analyzers" RuleNamespace="Microsoft.ApiDesignGuidelines.Analyzers">
<!-- ValidateArgumentsOfPublicMethods - only useful for libraries with supported public API surface, we don't have any -->
<Rule Id="CA1062" Action="None" />
<!-- CA1014: Mark assemblies with CLSCompliant -->
<Rule Id="CA1014" Action="None" />
</Rules>

<Rules AnalyzerId="System.Runtime.Analyzers" RuleNamespace="System.Runtime.Analyzers">
Expand Down
4 changes: 2 additions & 2 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<ProductDependencies>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="6.0.0-beta.20573.2">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="6.0.0-beta.20601.2">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>35bddd4fbfab8da3518fb920250d7c9e0c3138ff</Sha>
<Sha>6d8efa00a7dd2d15e07df673a83cecb8a0a3031f</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
4 changes: 2 additions & 2 deletions eng/Versions.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<VersionPrefix>3.3.2</VersionPrefix>
<VersionPrefix>3.3.3</VersionPrefix>
<PreReleaseVersionLabel>beta1</PreReleaseVersionLabel>
<NetAnalyzersVersionPrefix>6.0.0</NetAnalyzersVersionPrefix>
<NetAnalyzersPreReleaseVersionLabel>preview1</NetAnalyzersPreReleaseVersionLabel>
Expand Down Expand Up @@ -29,8 +29,8 @@
<MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion>3.7.0</MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion>
<MicrosoftCodeAnalysisVersionForTests>3.8.0-4.final</MicrosoftCodeAnalysisVersionForTests>
<DogfoodAnalyzersVersion>3.3.1</DogfoodAnalyzersVersion>
<DogfoodNetAnalyzersVersion>5.0.1</DogfoodNetAnalyzersVersion>
<MicrosoftCodeAnalysisBannedApiAnalyzersVersion>$(DogfoodAnalyzersVersion)</MicrosoftCodeAnalysisBannedApiAnalyzersVersion>
<MicrosoftCodeAnalysisFXCopAnalyzersVersion>$(DogfoodAnalyzersVersion)</MicrosoftCodeAnalysisFXCopAnalyzersVersion>
<MicrosoftCodeAnalysisAnalyzersVersion>$(DogfoodAnalyzersVersion)</MicrosoftCodeAnalysisAnalyzersVersion>
<MicrosoftCodeAnalysisPublicApiAnalyzersVersion>$(DogfoodAnalyzersVersion)</MicrosoftCodeAnalysisPublicApiAnalyzersVersion>
<RoslynDiagnosticsAnalyzersVersion>$(DogfoodAnalyzersVersion)</RoslynDiagnosticsAnalyzersVersion>
Expand Down
14 changes: 9 additions & 5 deletions eng/common/tools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ function with_retries {
return 0
fi

timeout=$((2**$retries-1))
timeout=$((3**$retries-1))
echo "Failed to execute '$@'. Waiting $timeout seconds before next attempt ($retries out of $maxRetries)." 1>&2
sleep $timeout
done
Expand All @@ -271,10 +271,14 @@ function GetDotNetInstallScript {

# Use curl if available, otherwise use wget
if command -v curl > /dev/null; then
with_retries curl "$install_script_url" -sSL --retry 10 --create-dirs -o "$install_script" || {
local exit_code=$?
Write-PipelineTelemetryError -category 'InitializeToolset' "Failed to acquire dotnet install script (exit code '$exit_code')."
ExitWithExitCode $exit_code
# first, try directly, if this fails we will retry with verbose logging
curl "$install_script_url" -sSL --retry 10 --create-dirs -o "$install_script" || {
echo "curl failed; will now retry with verbose logging."
with_retries curl "$install_script_url" -sSL --verbose --retry 10 --create-dirs -o "$install_script" || {
local exit_code=$?
Write-PipelineTelemetryError -category 'InitializeToolset' "Failed to acquire dotnet install script (exit code '$exit_code')."
ExitWithExitCode $exit_code
}
}
else
with_retries wget -v -O "$install_script" "$install_script_url" || {
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@
"rollForward": "patch"
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "6.0.0-beta.20573.2"
"Microsoft.DotNet.Arcade.Sdk": "6.0.0-beta.20601.2"
}
}
8 changes: 7 additions & 1 deletion src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,14 @@
</ItemGroup>

<!-- Code analyzers -->
<PropertyGroup>
<!-- Enable all the latest CA rules from 'Microsoft.CodeAnalysis.NetAnalyzers' as build warnings by default. Specific rules are disabled or downgraded in repo's editorconfig. -->
<AnalysisLevel>latest</AnalysisLevel>
<AnalysisMode>AllEnabledByDefault</AnalysisMode>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="$(MicrosoftCodeAnalysisFXCopAnalyzersVersion)" />
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="$(DogfoodNetAnalyzersVersion)" />
<PackageReference Include="Microsoft.CodeAnalysis.Analyzers" Version="$(MicrosoftCodeAnalysisAnalyzersVersion)" />
<PackageReference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" Version="$(MicrosoftCodeAnalysisPublicApiAnalyzersVersion)" />
<PackageReference Include="Roslyn.Diagnostics.Analyzers" Version="$(RoslynDiagnosticsAnalyzersVersion)" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,9 @@ private void AnalyzeInvocation(SyntaxNodeAnalysisContext context)
{
symbol = semanticModel.GetSymbolInfo(argument, context.CancellationToken).Symbol;
if (symbol != null &&
#pragma warning disable CA1508 // Avoid dead conditional code - https://github.com/dotnet/roslyn-analyzers/issues/4519
symbol.Kind == SymbolKind.Field &&
#pragma warning restore CA1508 // Avoid dead conditional code
_symbolKind.Equals(symbol.ContainingType) &&
!s_supportedSymbolKinds.Contains(symbol.Name))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ protected abstract class ReportDiagnosticCompilationAnalyzer : SyntaxNodeWithinA

private ImmutableDictionary<INamedTypeSymbol, ImmutableArray<IFieldSymbol>> _supportedDescriptorFieldsMap;

public ReportDiagnosticCompilationAnalyzer(ImmutableHashSet<INamedTypeSymbol> contextTypes, INamedTypeSymbol diagnosticType, INamedTypeSymbol diagnosticDescriptorType, INamedTypeSymbol diagnosticAnalyzer, INamedTypeSymbol diagnosticAnalyzerAttribute)
protected ReportDiagnosticCompilationAnalyzer(ImmutableHashSet<INamedTypeSymbol> contextTypes, INamedTypeSymbol diagnosticType, INamedTypeSymbol diagnosticDescriptorType, INamedTypeSymbol diagnosticAnalyzer, INamedTypeSymbol diagnosticAnalyzerAttribute)
: base(diagnosticAnalyzer, diagnosticAnalyzerAttribute)
{
_contextTypes = contextTypes;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
{
"tool": {
"name": "Microsoft.CodeAnalysis.Analyzers",
"version": "3.3.2",
"version": "3.3.3",
"language": "en-US"
},
"rules": {
Expand Down Expand Up @@ -605,7 +605,7 @@
{
"tool": {
"name": "Microsoft.CodeAnalysis.CSharp.Analyzers",
"version": "3.3.2",
"version": "3.3.3",
"language": "en-US"
},
"rules": {
Expand Down Expand Up @@ -786,7 +786,7 @@
{
"tool": {
"name": "Microsoft.CodeAnalysis.VisualBasic.Analyzers",
"version": "3.3.2",
"version": "3.3.3",
"language": "en-US"
},
"rules": {
Expand Down
Loading