fn compat(self) -> Compat01As03<Self>
        where
            Self: Sized,
        {
            Compat01As03::new(self)
        }
Converts a tokio-io [`AsyncWrite`](tokio_io::AsyncWrite) into a futures-io 0.3
[`AsyncWrite`](futures_io::AsyncWrite).

```
# if cfg!(miri) { return; } // https://github.com/rust-lang/futures-rs/issues/2514
# futures::executor::block_on(async {
use futures::io::AsyncWriteExt;
use futures_util::compat::AsyncWrite01CompatExt;

let input = b"Hello World!";
let mut cursor = std::io::Cursor::new(Vec::with_capacity(12));

let mut writer = (&mut cursor).compat();
writer.write_all(input).await.unwrap();

assert_eq!(cursor.into_inner(), input);
# });
```
futures-util/src/compat/compat01as03.rs