.netfxcopanalyzersoftware-quality

What is the advantage to use the Microsoft.CodeAnalysis.FxCopAnalyzers nuget over the default Managed Binary Analysis ruleset?


I currently use the Managed Binary Analysis and it looks like the nuget adds the same rules (maybe less).

I also use this SonarQube plugin: https://github.com/SonarQubeCommunity/sonar-fxcop.

What is the nuget for exactly?


Solution

  • I know this question is very old, but I recently had the same question and would like to provide my findings.

    The .NET Compiler Platform ("Roslyn") analyzers offer the following advantages over the legacy FxCop static analysis of managed assemblies:

    The Roslyn analyzers are available either directly in the .NET SDK or as the NuGet package Microsoft.CodeAnalysis.NetAnalyzers

    Source and more information:
    Overview of source code analysis
    Enable or install first-party .NET analyzers