fn flatten_stream(self) -> FlattenStream<Self>
    where
        Self::Output: Stream,
        Self: Sized,
    {
        assert_stream::<<Self::Output as Stream>::Item, _>(FlattenStream::new(self))
    }
Flatten the execution of this future when the successful result of this
future is a stream.

This can be useful when stream initialization is deferred, and it is
convenient to work with that stream as if stream was available at the
call site.

Note that this function consumes this future and returns a wrapped
version of it.

# Examples

```
# futures::executor::block_on(async {
use futures::future::FutureExt;
use futures::stream::{self, StreamExt};

let stream_items = vec![17, 18, 19];
let future_of_a_stream = async { stream::iter(stream_items) };

let stream = future_of_a_stream.flatten_stream();
let list: Vec<_> = stream.collect().await;
assert_eq!(list, vec![17, 18, 19]);
# });
```
futures-util/src/future/future/mod.rs