diff options
author | Stephen Toub <stoub@microsoft.com> | 2022-03-30 13:55:28 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-30 13:55:28 +0300 |
commit | b2e494c6ba2d3290e18c42559ced61b6cf1eebd0 (patch) | |
tree | 74815c66ce62c6bee65c598675e717bb1ef2ef0c /eng/CodeAnalysis.src.globalconfig | |
parent | 38fe46837aae576b8d1fdaa3177ddb3c24fa6018 (diff) |
Enable recently added analyzers (and fix some violations) (#67292)
Diffstat (limited to 'eng/CodeAnalysis.src.globalconfig')
-rw-r--r-- | eng/CodeAnalysis.src.globalconfig | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/eng/CodeAnalysis.src.globalconfig b/eng/CodeAnalysis.src.globalconfig index fc4c46fe765..e1a620e8a7f 100644 --- a/eng/CodeAnalysis.src.globalconfig +++ b/eng/CodeAnalysis.src.globalconfig @@ -205,6 +205,12 @@ dotnet_diagnostic.CA1418.severity = warning # CA1419: Provide a parameterless constructor that is as visible as the containing type for concrete types derived from 'System.Runtime.InteropServices.SafeHandle' dotnet_diagnostic.CA1419.severity = warning +# CA1420: Property, type, or attribute requires runtime marshalling +dotnet_diagnostic.CA1420.severity = warning + +# CA1421: This method uses runtime marshalling even when the 'DisableRuntimeMarshallingAttribute' is applied +dotnet_diagnostic.CA1421.severity = suggestion + # CA1501: Avoid excessive inheritance dotnet_diagnostic.CA1501.severity = none @@ -393,6 +399,9 @@ dotnet_diagnostic.CA1849.severity = suggestion # CA1850: Prefer static 'HashData' method over 'ComputeHash' dotnet_diagnostic.CA1850.severity = warning +# CA1851: Possible multiple enumerations of 'IEnumerable' collection +dotnet_diagnostic.CA1851.severity = suggestion + # CA2000: Dispose objects before losing scope dotnet_diagnostic.CA2000.severity = none @@ -432,6 +441,9 @@ dotnet_diagnostic.CA2017.severity = warning # CA2018: 'Buffer.BlockCopy' expects the number of bytes to be copied for the 'count' argument dotnet_diagnostic.CA2018.severity = warning +# CA2019: Improper 'ThreadStatic' field initialization +dotnet_diagnostic.CA2019.severity = warning + # CA2100: Review SQL queries for security vulnerabilities dotnet_diagnostic.CA2100.severity = none @@ -565,6 +577,9 @@ dotnet_diagnostic.CA2257.severity = warning # CA2258: Providing a 'DynamicInterfaceCastableImplementation' interface in Visual Basic is unsupported dotnet_diagnostic.CA2258.severity = warning +# CA2259: 'ThreadStatic' only affects static fields +dotnet_diagnostic.CA2259.severity = warning + # CA2300: Do not use insecure deserializer BinaryFormatter dotnet_diagnostic.CA2300.severity = none |