-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
CA1823 incorrectly flags const used as a fixed buffer length #37593
Comments
@jinujoseph @vatsalyaagrawal Can we port this issue to Roslyn repo? The issue does not seem specific to this analyzer. Seems like there is no Even |
Yeah, and the Rename support doesn't fix the reference, IDE0051 flags it as unused, Go to Definition on the reference fails, etc. |
QuiclInfo doesn't work either. So this is likely a deeper SemanticModel issue, not just an IOp issue. |
@CyrusNajmabadi is correct - this is a deeper issue in the compiler layer. Moved to Area-Compilers. |
The underlying semantic model issue is likely #29224 |
FYI, there's an instance of this warning in PR dotnet/runtime#105403 |
Analyzer package
Microsoft.CodeAnalysis.FxCopAnalyzers
Package Version
v2.9.4
Diagnostic ID
CA1823
Repro steps
Expected behavior
No warnings.
Actual behavior
The CA1823 analyzer flags the SomeLength const as being unused:
even though obviously it is being used.
The text was updated successfully, but these errors were encountered: