-
Notifications
You must be signed in to change notification settings - Fork 508
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
SA1100 autofix should replace base with 'this' #763
Comments
Our code fix should do exactly that. It might be a visual studio code fix that is doing that. StyleCopAnalyzers/StyleCop.Analyzers/StyleCop.Analyzers/ReadabilityRules/SA1100CodeFixProvider.cs Lines 57 to 65 in a8fa0ec
|
You are seeing a code fix for IDE0002 (a built-in diagnostic). Unfortunately, we cannot just disable this one like IDE0003 (#532) right now because it applies to other situations where it is helpful. I'm going to assume this is caused by one of the following. Please reopen it if you believe this is incorrect.
|
Yes, it appears you're correct. |
SA1100 tells me to not use
base
unless a local implementation exists. Its auto-fixer simply removes thebase.
prefix, which then produces an SA1101 violation (to prefix local calls withthis.
).Can the SA1100 auto-fixer be fixed to replace
base.
withthis.
so that fixing it does not produce a new violation of another one of SA11xx's own rules?The text was updated successfully, but these errors were encountered: