Drop Stream
A stream that wraps another stream with a closure that is called once it is dropped. Very useful for libraries that use streams for data transfer and you need to connect when the opposite site drops the connection, thus dropping the stream.
This crate only depends on futures-core and thus is a minimal dependency, suitable for any type of project utilising futures.
Example
use Stream;
use DropStream;
let test_stream = repeat;
Acknowledgement
I thank Aadam Zocolo for letting me take over the crate name "drop-stream" on crates.io and replace his 0.1 version.