Skip to content

[AST] Remove getSemanticAttrs #81942

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

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Jun 3, 2025

After #69578, the only users of getSemanticAttrs after that PR are the AST printer and SemaAnnotator, all other calls were switched to getExpandedAttrs. This caused the SemanticDeclAttrsRequest to only get evaluated during indexing, which ends up doing semantic analysis in the pass that writes out the index data. Neither the AST printer nor indexing should report data that is unavailable during compilation and so both of these should use getExpandedAttrs.

After swiftlang#69578, the only users of `getSemanticAttrs` after that PR are the AST printer and `SemaAnnotator`, all other calls were switched to `getExpandedAttrs`. This caused the `SemanticDeclAttrsRequest` to only get evaluated during indexing, which ends up doing semantic analysis in the pass that writes out the index data. Neither the AST printer nor indexing should report data that is unavailable during compilation and so both of these should use `getExpandedAttrs`.
@ahoppen
Copy link
Member Author

ahoppen commented Jun 3, 2025

@swift-ci Please smoke test

@ahoppen ahoppen marked this pull request as draft June 3, 2025 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant