Skip to content

Introduce missing Sendable conformances for existential conversions #42606

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 2 commits into from
Apr 23, 2022

Conversation

DougGregor
Copy link
Member

@DougGregor DougGregor commented Apr 23, 2022

When performing conversions to an existential that involves Sendable,
introduce missing conformances as needed to allow the type-check to
succeed and then (later) they'll be diagnosed appropriately.

Fixes rdar://89992095.

When performing conversions to an existential that involves Sendable,
introducing missing conformances as needed to allow the type-check to
succeed and then (later) they'll be diagnosed appropriately.

Fixes rdar://89992095.

_ = sendable
_ = arrayOfSendable
}
Copy link
Contributor

Choose a reason for hiding this comment

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

nice :) what would happen if the test() function were inside an actor -- it'd be a synchronous function but we know i "adopted concurrency" I guess, so it should warn, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok, awesome 👍

@DougGregor
Copy link
Member Author

@swift-ci please smoke test

@DougGregor DougGregor merged commit 5f2b790 into swiftlang:main Apr 23, 2022
@DougGregor DougGregor deleted the existential-sendable-warnings branch April 23, 2022 15:05
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.

2 participants