Skip to content

[ASTPrinter] Use TypeLoc printing for extended types. #38014

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

varungandhi-apple
Copy link
Contributor

When the -module-interface-preserve-types-as-written flag is used,
the extended type should be printed similar to other types. The
checking for that flag happens in TypeLoc printing, not Type printing.
So we change extended type printing to use a TypeLoc instead.

Fixes rdar://79563937.

@varungandhi-apple
Copy link
Contributor Author

@swift-ci smoke test

@varungandhi-apple varungandhi-apple force-pushed the vg-interface-respect-flag branch from 69c4d91 to 3bb2945 Compare June 21, 2021 22:18
@varungandhi-apple
Copy link
Contributor Author

@swift-ci smoke test

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.

Thanks!

Copy link
Contributor

@beccadax beccadax left a comment

Choose a reason for hiding this comment

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

I see one situation that I'm not sure has been fully thought out (possibly due to pre-existing holes in the design), but otherwise I think this looks good!

When the -module-interface-preserve-types-as-written flag is used,
the extended type should be printed similar to other types. The
checking for that flag happens in TypeLoc printing, not Type printing.
So we change extended type printing to use a TypeLoc instead.

Fixes rdar://79563937.
@varungandhi-apple varungandhi-apple force-pushed the vg-interface-respect-flag branch from 3bb2945 to 284fcb5 Compare June 21, 2021 23:19
@varungandhi-apple
Copy link
Contributor Author

@swift-ci smoke test

@varungandhi-apple varungandhi-apple merged commit 8ccc176 into swiftlang:main Jun 22, 2021
@varungandhi-apple varungandhi-apple deleted the vg-interface-respect-flag branch June 22, 2021 16:17
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