Opt-in to .NET 5 SDK's extra static analysis, update Analyzer packages
the extra CSxxxx rules should be available for Framework too if using the new SDK, I haven't tried
This commit is contained in:
parent
52a559908e
commit
17ff66c61b
|
@ -1,5 +1,6 @@
|
|||
<Project>
|
||||
<PropertyGroup>
|
||||
<AnalysisLevel>5</AnalysisLevel>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<LangVersion>8.0</LangVersion>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
|
|
|
@ -122,6 +122,9 @@
|
|||
<!-- Do not prefix enum values with type name -->
|
||||
<Rule Id="CA1712" Action="Hidden" />
|
||||
|
||||
<!-- Events should not have 'Before' or 'After' prefix -->
|
||||
<Rule Id="CA1713" Action="Hidden" />
|
||||
|
||||
<!-- Flags enums should have plural names -->
|
||||
<Rule Id="CA1714" Action="Hidden" />
|
||||
|
||||
|
@ -149,6 +152,9 @@
|
|||
<!-- Use literals where appropriate -->
|
||||
<Rule Id="CA1802" Action="Hidden" />
|
||||
|
||||
<!-- Do not initialize unnecessarily -->
|
||||
<Rule Id="CA1805" Action="Hidden" />
|
||||
|
||||
<!-- Do not ignore method results -->
|
||||
<Rule Id="CA1806" Action="Hidden" />
|
||||
|
||||
|
@ -191,6 +197,9 @@
|
|||
<!-- Do not lock on objects with weak identity -->
|
||||
<Rule Id="CA2002" Action="Hidden" />
|
||||
|
||||
<!-- Do not use stackalloc in loops -->
|
||||
<Rule Id="CA2014" Action="Hidden" />
|
||||
|
||||
<!-- Review SQL queries for security vulnerabilities -->
|
||||
<Rule Id="CA2100" Action="Hidden" />
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<PackageReference Include="System.Memory" Version="4.5.4" />
|
||||
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="4.7.0" PrivateAssets="all" />
|
||||
<PackageReference Include="Menees.Analyzers" Version="2.0.4" Condition=" '$(MachineRunAnalyzersDuringBuild)' != '' " />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="3.0.0" Condition=" '$(MachineRunAnalyzersDuringBuild)' != '' " />
|
||||
<PackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.164" Condition=" '$(MachineRunAnalyzersDuringBuild)' != '' " />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="3.3.0" Condition=" '$(MachineRunAnalyzersDuringBuild)' != '' " />
|
||||
<PackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.205" Condition=" '$(MachineRunAnalyzersDuringBuild)' != '' " />
|
||||
<ProjectReference Include="$(ProjectDir)../BizHawk.Version/BizHawk.Version.csproj" /><!-- generates VersionInfo.gen.cs -->
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
|
Loading…
Reference in New Issue