Yes, technically adding trait impl to the existing type doesn't requires the RFC process and get insta-stabilized. But I think what I want to do is not very obvious and maybe too opinionated so I wanted to collect more thoughts before sending the PR.
IMO Option<T: Future>
should impl Future<Output = Option<T::Output>>
. I guess most people wouldn't disagree with it. The possibly-opinionated part is, that I think Option<impl Future>
should be fused - polling it should keep returning Ready(None)
after the first Ready
result. Implementation would be fairly trivial thanks to the Pin::set()
function.
Does it seems too opinionated for the stdlib? Or am I overthinking it? Please let me know how do you think about it.