Skip to content

🍒[6.1] Add a flag to dump the AST as JSON. #78955

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
merged 3 commits into from
Jan 28, 2025

Conversation

allevato
Copy link
Member

@allevato allevato requested a review from a team as a code owner January 27, 2025 20:34
@allevato
Copy link
Member Author

@swift-ci please smoke test

@allevato allevato requested a review from bnbarham January 27, 2025 20:54
@DougGregor
Copy link
Member

@swift-ci please test

@DougGregor
Copy link
Member

We need full (non-smoke) tests for the 6.1 branch, so I just kicked those off

Copy link
Member

@DougGregor DougGregor left a comment

Choose a reason for hiding this comment

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

I'm okay with us taking this, but it does look like the Windows issue is a legitimate bug?

@allevato
Copy link
Member Author

allevato commented Jan 28, 2025

I'm okay with us taking this, but it does look like the Windows issue is a legitimate bug?

That test uses @DebugDescription as a convenience since it's a macro that's defined in the standard library, but all it cares about is whether some expansion occurred. When I compare the JSON dump in the log to one that I generate locally, there are no macro-expanded decls at all. This makes sense after tracking down #71685, which wraps all the generated decls in #if !os(Windows). What doesn't make sense is why the same test didn't fail on main—I don't see any changes since the 6.1 branch cut that would re-enable the macro there.

@allevato
Copy link
Member Author

While I wait for my Windows build of the 6.1 branch to make progress, I'll work on updating the test to use its own macro instead of depending on one from stdlib. If that passes on all platforms, I can update main afterwards to use the same test going forward.

@allevato
Copy link
Member Author

@swift-ci please test

@allevato allevato enabled auto-merge January 28, 2025 21:22
@allevato allevato merged commit 8498861 into swiftlang:release/6.1 Jan 28, 2025
5 checks passed
@allevato allevato deleted the 6.1-json-ast branch January 28, 2025 21:52
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.

2 participants