-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[cxx-interop] Enabling C++ interop leads to linking errors with URL.bookmark() #66501
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
Comments
@plotfi could you check this one out? |
Good news, @hyp I have gotten the xcode project to repro. Just gotta extract the clang invocations and see if they repro on the latest main toolchain. |
Made a little bit of progress, minimized the test case: /// ContentView.swift
import Foundation
public struct ContentView {
public init() {
let url = URL(string: "https://foo.bar")!
print(url)
try? url.bookmarkData()
}
}
Alter the swift-frontend like to the following and it links:
|
Here are the symbol diffs (from nm dump) bad.symbols.txt Difference is:
Meaning:
|
Difference appears to be a missing dot '.' in NSURL.BookmarkCreationOptions, I may have fixed this in #66619 |
I tested things out with a swiftc built from top of tree, the issue appears to be fixed already.
|
Thanks! |
Let's leave it open for now until we have an Xcode beta out with the fix but this appears to be fixed. |
Agreed, I want to close once we are sure an upcoming Xcode build fixes this. |
As reported here: https://forums.swift.org/t/undefined-symbol-when-using-c-interop-and-url-bookmark/65444
The text was updated successfully, but these errors were encountered: