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

Signatures of Recipient::do_send() and Addr::do_send() are not consistent #440

Open
hoodie opened this issue Oct 18, 2020 · 0 comments
Open

Comments

@hoodie
Copy link
Contributor

hoodie commented Oct 18, 2020

Expected Behavior

Recipient::do_send() should not return a Result, same as Addr::do_send() does.

Current Behavior

Currently Recipient::do_send() is identical in behavior with Recipient::try_send(), this seems to be an oversight.

Possible Solution

Consume the Result inside the method body, same as Addr::do_send() does:
https://github.com/actix/actix/blob/master/src/address/mod.rs#L99

Context

This is a breaking API change, but a consistency improvement, users of Recipient::do_send() presumably already throw away the Result.

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 a pull request may close this issue.

1 participant