Suppress e.g., CA1861 for certain project types #38633
Labels
in-pr
This issue will be closed (fixed) by an active pull request.
📌 seQUESTered
Identifies that an issue has been imported into Quest.
This issue has been moved from a ticket on Developer Community.
After the upgrade to .NET 8 / VS 2022 17.8 a new message pops up: CA1861 Prefer 'static readonly' fields over constant array arguments if the called method is called repeatedly and is not mutating the passed array.
This is a useful diagnostic to have for production code, but it pops up a lot in my unit tests that verify whether some code produces the required list of things. I now have a choice to disable it completely, add an .editorconfig to all my unit test projects, or live with tons of blue squiggles in test code. I'll do the first, but that is obviously not why you introduced this analytics. But I can't see a way to disable the issue in a single .editorconfig file for all projects in the directory tree that satisfy a condition. Please provide such an optio
(this may be more of a suggestion, but for me all those new messages are a problem)
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
Associated WorkItem - 250216
The text was updated successfully, but these errors were encountered: