Skip to content

AST: Cut down on DescriptiveDeclKind usage in diagnostics #80524

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

Merged

Conversation

AnthonyLatsis
Copy link
Collaborator

@AnthonyLatsis AnthonyLatsis commented Apr 4, 2025

Use format specifiers instead and trust the engine to call getDescriptiveKind() and do its thing. The remaining few diagnostics that accept DescriptiveDeclKind will require more work.

Includes #80473 to avoid conflicts.

@AnthonyLatsis
Copy link
Collaborator Author

@swift-ci please smoke test macOS

@AnthonyLatsis AnthonyLatsis force-pushed the diag-descriptive-decl-kind branch from 4814f91 to cfa4074 Compare April 5, 2025 05:43
@AnthonyLatsis AnthonyLatsis requested a review from artemcm as a code owner April 5, 2025 05:43
@AnthonyLatsis
Copy link
Collaborator Author

@swift-ci please smoke test macOS

Copy link
Contributor

@xedin xedin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great refactoring, thank you!

@AnthonyLatsis
Copy link
Collaborator Author

@xedin Thank you for finding time to review this! The PR builds on #80473. Should I take it as an approval of that one too?

@xedin
Copy link
Contributor

xedin commented Apr 5, 2025

Yes, while splitting @execution into multiple attributes I ran into out inability to use TypeAttribute which is pretty restrictive.

@AnthonyLatsis AnthonyLatsis force-pushed the diag-descriptive-decl-kind branch from cfa4074 to 5c190b9 Compare April 5, 2025 11:33
@AnthonyLatsis
Copy link
Collaborator Author

@swift-ci please smoke test

@AnthonyLatsis AnthonyLatsis enabled auto-merge April 5, 2025 11:34
@AnthonyLatsis AnthonyLatsis merged commit ddd9914 into swiftlang:main Apr 5, 2025
3 checks passed
@AnthonyLatsis AnthonyLatsis deleted the diag-descriptive-decl-kind branch April 6, 2025 03:07
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.

3 participants