Skip to content

[ParseableInterface] Honor "exported module names" #23474

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
Mar 22, 2019

Conversation

jrose-apple
Copy link
Contributor

@jrose-apple jrose-apple commented Mar 21, 2019

Clang's "exported module name" is a pretty obscure feature (and one we wish we didn't need), but sometimes API is initially exposed through one module in order to build another one, and we want the canonical presented name to be something else. Push this concept into Swift's AST properly, then use that name when printing a parseable interface, just like we do with serialization.

rdar://problem/49114811

std::string -> StringRef of long-lived backing storage.

No functionality change.
It's a pretty obscure feature (and one we wish we didn't need), but
sometimes API is initially exposed through one module in order to
build another one, and we want the canonical presented name to be
something else. Push this concept into Swift's AST properly so that
other parts of the compiler stop having to know that this is a
Clang-specific special case.

No functionality change in this commit; will be used in the next
commit.
@jrose-apple
Copy link
Contributor Author

@swift-ci Please test

(as described in the previous commit)

When printing an interface that has to be stable, we need to use the
module name that identifies where declarations should be searched for,
just like we do with serialization.

rdar://problem/49114811
@jrose-apple
Copy link
Contributor Author

@swift-ci Please test

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - 6e236e07cd18726580908278b132b9e6fdd6d085

Copy link
Contributor

@harlanhaskins harlanhaskins left a comment

Choose a reason for hiding this comment

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

Thanks for fixing this, and good catch!

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 6e236e07cd18726580908278b132b9e6fdd6d085

@jrose-apple jrose-apple merged commit d8df1bf into swiftlang:master Mar 22, 2019
@jrose-apple jrose-apple deleted the export-au-prince branch March 22, 2019 03:12
jrose-apple added a commit to jrose-apple/swift that referenced this pull request Mar 22, 2019
[ParseableInterface] Honor "exported module names"

(cherry picked from commit d8df1bf)
jrose-apple added a commit to jrose-apple/swift that referenced this pull request Mar 22, 2019
[ParseableInterface] Honor "exported module names"

(cherry picked from commit d8df1bf)
@compnerd
Copy link
Member

This caused a regression on the Windows tests!

@jrose-apple
Copy link
Contributor Author

:-( What was it? Did I do something too shell-y again?

jrose-apple added a commit that referenced this pull request Mar 22, 2019
[ParseableInterface] Honor "exported module names"

(cherry picked from commit d8df1bf)
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.

4 participants