Closed notgull closed 2 years ago
Thanks for the PR!
These can be written very simply using async-await, so I think they do not match the policy of futures-lite.
These can be written very simply using async-await, so I think they do not match the policy of futures-lite.
Fair enough. I'll close this PR.
Feels like a relatively trivial to implement, yet relatively important thing to leave out. This adds two methods to the
FutureExt
trait:map
andchain
.map
waits for the future to finish and then applies a closure to the result, whilechain
waits for one future to finish and then uses a closure to generate another future that is then polled.