-
Notifications
You must be signed in to change notification settings - Fork 636
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
Poll<T, E> = Result<Async<T>, E> vs Async<Result<T,E>> #141
Comments
In one word: Note, this could* possibly be changed in the future depending on what the final form of the *I'm not a dev; I'm just speculating. |
Thanks for the report @Matthias247! This actually was indeed what we used to do, but after the discussion on #108 we decided to settle on what we've got today. @Stebalien hit the nail on the head with the primary rationale being to support the use of |
Closing due to previous discussion on this topic. |
I do think this design decision should be reconsidered once the |
With futures 0.3 removing the error type from the base There are also some |
That's also a great step forward! I'm glad to see that, and a bit ashamed I didn't see that. Looking forward to the 0.3 rewrite then. |
Hi,
why was the type of poll to be chosen to be
Result<Async<T>,E>
instead ofAsync<Result<T,E>>
.Imho the latter signature matches better to the typical definition of a future, which is it's either
It also matches better the fact that the thing is a boxed (in the sense of 'monadic', not) version of the actual Result of the call.
The text was updated successfully, but these errors were encountered: