-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
pattern vs. prefer naming #28285
Comments
that name was simply a mistake (due to a copy/paste error). It was always supposed to be be 'prefer_X_over_Y' as that is what we use elsewhere. The 'pattern' part was copied from another config key errantly. |
Yes, it's a good fix, but 'pattern' is still recognized in VS, but 'prefer' is not. Is a future version of VS needed for 'prefer' to be recognized? |
You'll need 17.1 to pick this up. Thanks! |
@MisinformedDNA Why did you close this issue? The documentation was not updated for the new rule name. |
This was fixed by #30059. |
The documentation says the rule name is
csharp_style_pattern_local_over_anonymous_function
and that's what works for me in VS 2022 17.0.4, but the Roslyn code base changed the name tocsharp_style_prefer_local_over_anonymous_function
. When is the latter used over the former?@CyrusNajmabadi
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
The text was updated successfully, but these errors were encountered: