Skip to content
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

SA1316: Inactionable diagnostic in method overrides #3781

Open
AArnott opened this issue Jan 21, 2024 · 2 comments · May be fixed by #3782
Open

SA1316: Inactionable diagnostic in method overrides #3781

AArnott opened this issue Jan 21, 2024 · 2 comments · May be fixed by #3782

Comments

@AArnott
Copy link
Contributor

AArnott commented Jan 21, 2024

When a virtual method declared in a reference assembly returns a tuple with named values that are not PascalCase, overriding them in a compilation that includes stylecop analyzers warns that I must change them to pascal case. Yet doing so produces CS8139.

SA1316 should not activate on method overrides.

StyleCop.Analyzers version: 1.2.0.556

@bjornhellander
Copy link
Contributor

Seems correct to ignore tuples which are part of an override's signature. SA1414 does the same.
I can have a go at this.

bjornhellander added a commit to bjornhellander/StyleCopAnalyzers that referenced this issue Jan 21, 2024
@bjornhellander
Copy link
Contributor

Noting that this also applies to classes implementing interfaces which do not follow SA1316.

bjornhellander added a commit to bjornhellander/StyleCopAnalyzers that referenced this issue Mar 23, 2024
…r's signature, if that member is an override or implements an interface

DotNetAnalyzers#3781
bjornhellander added a commit to bjornhellander/StyleCopAnalyzers that referenced this issue Mar 23, 2024
…r's signature, if that member is an override or implements an interface

DotNetAnalyzers#3781
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants