Skip to content

[Distributed] Generic reqs must be forwarded to accessor from enclosing actor #70785

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

ktoso
Copy link
Contributor

@ktoso ktoso commented Jan 9, 2024

The distributed func accessor does not need to carry forward generic parameters EXCEPT the Decoder and the self type. We adjust the implementation to pass those and correct handling of those parameters. This will now no longer produce crashes when distributed funcs are used in nested generic types in debug builds. This does not affect stable releases because those assertions are disabled there, and don't actually happen to cause issues here. But we should do the right thing in any case.

Resolves rdar://115497090
Resolves #68517

…ng actor

If we don't do this, the generic parameter has no requirements at all,
which a) is incorrect to begin with, it should have the exact same
signature as the method it is the accessor for, and b) it would trip up
verification which is enabled on linux in snapshot builds -- causing
crashes.

Resolves rdar://115497090
@ktoso
Copy link
Contributor Author

ktoso commented Jan 9, 2024

This PR replaces the #68859 where github got confused about branch state it seems

@ktoso ktoso changed the title [Distributed] Generic reqs must be forwarded to accessor from enclosi… [Distributed] Generic reqs must be forwarded to accessor from enclosing actor Jan 9, 2024
@ktoso ktoso marked this pull request as draft January 11, 2024 08:36
@ktoso ktoso closed this Jan 11, 2024
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.

Swift 5.9 compiler crash on Linux when compile a generic distributed actor with type constraints
1 participant