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

Use more specific checks for skipping work for unused usings #74807

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

sharwell
Copy link
Member

This change ensures AnalyzeSemanticModel only performs analysis when unused imports are being reported. Previously, this method would run when the only enabled diagnostic was 'EnableGenerateDocumentationFile', even though that diagnostic is unrelated to the work performed in AnalyzeSemanticModel.

Discovered during investigation of #74761.

This change ensures AnalyzeSemanticModel only performs analysis when
unused imports are being reported. Previously, this method would run
when the only enabled diagnostic was 'EnableGenerateDocumentationFile',
even though that diagnostic is unrelated to the work performed in
AnalyzeSemanticModel.

Discovered during investigation of dotnet#74761.
@CyrusNajmabadi
Copy link
Member

This seems fine to me. But my preference is still that we take this and shutoff the other analyzer. Code style on generated code doesn't make sense to me. And i cannot reconcile that we have this particular style analyzer on, while not having any other analyzers on (especially ones that related to unnecessary code) :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Analyzers untriaged Issues and PRs which have not yet been triaged by a lead VSCode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants