-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Sema: Fix the insertion location for conformances attributes #82452
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 macOS |
@swift-ci please smoke test macOS |
"@" + globalActorIsolation.getString() + " "); | ||
// Take permanent ownership of the string. The diagnostic may outlive this | ||
// function call. | ||
auto globalActorTypeStr = ctx.AllocateCopy(globalActorType.getString()); |
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.
Not for this PR but I think the engine should take ownership of all the arguments, we already do that for diagnostic transactions and might as well do it for the diagnostics in general to avoid surprises.
@swift-ci please smoke test |
@swift-ci please smoke test Linux |
@swift-ci please smoke test macOS |
/// The `TypeRepr` of the inheritance clause entry from which this nominal was | ||
/// sourced, if any. For example, if this is a conformance to `Y` declared as | ||
/// `struct S: X, Y & Z {}`, this is the `TypeRepr` for `Y & Z`. | ||
TypeRepr *inheritedTypeRepr; |
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.
Thank you for adding this!
We were using
ProtocolNameLoc
for the insertion location, which is not necessarily the start location of theTypeRepr
associated with the conformance:Fixes rdar://132570262.