futures-rs
futures-rs copied to clipboard
Zero-cost asynchronous programming in Rust
Currently, `std::panic::resume_unwind` is called if I await a `RemoteHandle` with a canceled `Remote` future: https://github.com/rust-lang/futures-rs/blob/96c2fc4668f8bfb428352e8a1558972961bd31a1/futures-util/src/future/future/remote_handle.rs#L65-L66 But says that > panics in Rust are not always implemented via unwinding, but they...
I recently had a pretty nasty logic bug in my code, involving the `select!` macro. This is unusual, because in Rust I'm expecting that APIs are hard to use incorrectly,...
We needed a clean way to do things like `buffered(n)` but with limited number of futures being drived at the same time, particularly useful is `try_bufferred_x(n, 1)`, where those futures...
This is related to #2470 but has some complexity because it's Streams, not Futures. It also touches on the same area as #2237 but has more reasoning. For `StreamExt`, we...
This is a preliminary attempt at a massively unsafe manual self-borrowing future to allow working with borrowing `futures` combinators without relying on `async`/`await`. I'm uncomfortable about the number of different...
`select!` is probably my favorite API in the whole Rust async story. That is because it enables use-cases that are not possible in normal threaded code: We can wait on...
I noticed that the implication for [future::Fuse](https://github.com/rust-lang/futures-rs/blob/master/futures-util/src/future/future/fuse.rs) will drop the wrapped future when it completes, but [stream::Fuse](https://github.com/rust-lang/futures-rs/blob/master/futures-util/src/stream/stream/fuse.rs) keeps around the stream after it's completed. Would it make sense to make...
## Recent work Recently I posted a PR (#2507) to implement an abortable feature to futures_util::io::copy_buf(), which provides an abort handle for the copy operation, and enables to stop copying...
Reading https://github.com/rust-lang/futures-rs/blob/3601bb76708ea4bcc14c3491237abc33b685ba0b/futures-core/src/stream.rs#L174-L182 I’m wondering: what’s those limitations? Trying something like b7f417d738d89071fe4d2ec880a908d67e19c12c seems to work without problems.
With completion based IO, we need a way to deregister interest in the IO when it is cancelled. Setting aside buffer management issues (which have been discussed at length elsewhere),...