fn into_future(self) -> StreamFuture<Self>
    where
        Self: Sized + Unpin,
    {
        assert_future::<(Option<Self::Item>, Self), _>(StreamFuture::new(self))
    }
Converts this stream into a future of `(next_item, tail_of_stream)`.
If the stream terminates, then the next item is [`None`].

The returned future can be used to compose streams and futures together
by placing everything into the "world of futures".

Note that because `into_future` moves the stream, the [`Stream`] type
must be [`Unpin`]. If you want to use `into_future` with a
[`!Unpin`](Unpin) stream, you'll first have to pin the stream. This can
be done by boxing the stream using [`Box::pin`] or
pinning it to the stack using the `pin_mut!` macro from the `pin_utils`
crate.

# Examples

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

let stream = stream::iter(1..=3);

let (item, stream) = stream.into_future().await;
assert_eq!(Some(1), item);

let (item, stream) = stream.into_future().await;
assert_eq!(Some(2), item);
# });
```
futures-util/src/stream/stream/mod.rs