Skip to content
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

[Concurrency] Stage in new Async{Throwing}Stream.init(unfolding:) errors as warnings. #73310

Merged
merged 4 commits into from May 1, 2024

Conversation

hborla
Copy link
Member

@hborla hborla commented Apr 27, 2024

Marking the closure parameter to these inits as @Sendable changed the inferred isolation of closure arguments in actor-isolated contexts, which caused new effects checker errors when accessing isolated properties and methods without await. Mark these inits as @preconcurrency, and fix the effects checker to downgrade those errors to warnings when the context of the call is @preconcurrency.

Note that this PR builds on #73308

Resolves: rdar://127145741, rdar://126929825

…rrors

as warnings.

Marking the closure parameter to these inits as `@Sendable` changed the
inferred isolation of closure arguments in actor-isolated contexts, which
caused new effects checker errors when accessing isolated properties and
methods without `await`. Mark these `init`s as `@preconcurrency`, and fix
the effects checker to downgrade those errors to warnings when the context
of the call is `@preconcurrency`.
@hborla
Copy link
Member Author

hborla commented Apr 27, 2024

@swift-ci please smoke test

@hborla
Copy link
Member Author

hborla commented Apr 30, 2024

@swift-ci please smoke test

@hborla
Copy link
Member Author

hborla commented Apr 30, 2024

@swift-ci please smoke test

@hborla hborla merged commit 4368125 into apple:main May 1, 2024
3 checks passed
@hborla hborla deleted the async-stream-sendable-error branch May 1, 2024 16:15
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.

None yet

1 participant