-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Add support for textual imports to -emit-objc-header #60971
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
Conversation
@swift-ci Please smoke test |
573646d
to
0047ecf
Compare
@swift-ci Please smoke test |
0047ecf
to
a55adfe
Compare
@swift-ci Please smoke test |
a55adfe
to
78efbab
Compare
@swift-ci Please smoke test |
78efbab
to
010a042
Compare
@swift-ci Please smoke test |
Can this be on by default in the |
That makes sense to me. I've got some more changes coming, going to redraft. |
Perfect, cheers! This is going to help with C++ interop too, as it would allow us to reinclude C++ headers imported into Swift that we need in the generated C++ header. |
010a042
to
5fbec4c
Compare
@swift-ci Please smoke test |
5fbec4c
to
f52ac0f
Compare
@swift-ci Please smoke test |
f52ac0f
to
c02df77
Compare
@swift-ci Please smoke test |
c02df77
to
a8cd7ed
Compare
@swift-ci Please smoke test |
@swift-ci please test source compatibility |
a8cd7ed
to
432da13
Compare
@swift-ci Please smoke test |
@swift-ci please test source compatibility |
@swift-ci Smoke test macOS Platform |
432da13
to
58cfc41
Compare
@swift-ci Please smoke test |
@swift-ci please test source compatibility |
@swift-ci please test |
@swift-ci please test macOS platform |
Seems to fail on macOS: PrintAsObjC/emit-clang-header-nonmodular-includes.swift |
Yeah, just saw earlier, will look into it. It only failed on iphonesimulator-x86_64 iirc, so I'm thinking maybe an SDK difference, but I'll update once I figure it out. Thanks! |
Currently headers produced with `-emit-objc-header` / `-emit-objc-header-path` produce headers that include modular imports. If the consumer wishes to operate without modules enabled, these headers cannot be used. This patch introduces a new flag (`-emit-clang-header-nonmodular-includes`) that when enabled attempts to argument each modular import included in such a header with a set of equivalent textual imports.
58cfc41
to
89a01dd
Compare
@swift-ci please test |
@swift-ci please test source compatibility |
swiftlang#60971 has landed, so we can remove the temporary workarounds.
Currently headers produced with
-emit-objc-header
/-emit-objc-header-path
produce headers that include modular imports. If the consumer wishes to operate without modules enabled, these headers cannot be used. This patch introduces a new flag (-emit-objc-header-textually
) that when enabled attempts to translate each modular import included in such a header with a set of equivalent textual imports.