-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[cxx-interop] Make sure interop does not trigger TBD validation errors #64841
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 |
@swift-ci please test |
9406511
to
43161fd
Compare
@swift-ci please smoke test |
@swift-ci please test |
I think that's fine, but we should be mindful that it's not necessarily a fix, rather a workaround. We do have additional issues tracking this here: |
@@ -410,6 +411,14 @@ void ArgsToFrontendOptionsConverter::computeTBDOptions() { | |||
Diags.diagnose(SourceLoc(), diag::error_unsupported_option_argument, | |||
A->getOption().getPrefixedName(), value); | |||
} | |||
} else if (Args.hasArg(OPT_enable_experimental_cxx_interop) || | |||
Args.hasArg(OPT_cxx_interoperability_mode)) { | |||
// TBD validation currently emits erroneous diagnostics when C++ interop is |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would argue that the diagnostics are not erroneous, but rather that IRGen is incorrectly applying linkage and/or visibility to the symbols. I think we need to clarify in the comment that this is specifically a workaround for correct diagnostics, and that it also must be a FIXME
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, that makes sense, I updated the comment.
43161fd
to
50910da
Compare
This disables TBD validation when C++ interop is enabled, unless an explicit `-validate-tbd-against-ir=` flag was passed. rdar://83405989 / #56458
50910da
to
8f58eaf
Compare
@swift-ci please smoke test |
rdar://83405989 / #56458