diff --git a/src/future/future/mod.rs b/src/future/future/mod.rs index 05d099b0..d6c4d7e0 100644 --- a/src/future/future/mod.rs +++ b/src/future/future/mod.rs @@ -20,6 +20,8 @@ cfg_unstable_default! { use crate::future::timeout::TimeoutFuture; } +pub use core::future::Future as Future; + extension_trait! { pub trait Future {} diff --git a/src/io/buf_read/mod.rs b/src/io/buf_read/mod.rs index 1314dc9f..82917156 100644 --- a/src/io/buf_read/mod.rs +++ b/src/io/buf_read/mod.rs @@ -15,6 +15,8 @@ use std::pin::Pin; use crate::io; use crate::task::{Context, Poll}; +pub use futures_io::AsyncBufRead as BufRead; + extension_trait! { pub trait BufRead {} diff --git a/src/io/read/mod.rs b/src/io/read/mod.rs index 9b5b9644..b8855886 100644 --- a/src/io/read/mod.rs +++ b/src/io/read/mod.rs @@ -21,6 +21,8 @@ pub use bytes::Bytes; pub use chain::Chain; pub use take::Take; +pub use futures_io::AsyncRead as Read; + extension_trait! { pub trait Read {} diff --git a/src/io/seek/mod.rs b/src/io/seek/mod.rs index 33ba25e3..cafbfe62 100644 --- a/src/io/seek/mod.rs +++ b/src/io/seek/mod.rs @@ -4,6 +4,8 @@ use seek::SeekFuture; use crate::io::SeekFrom; +pub use futures_io::AsyncSeek as Seek; + extension_trait! { pub trait Seek {} diff --git a/src/io/write/mod.rs b/src/io/write/mod.rs index 3463d282..6e9a574f 100644 --- a/src/io/write/mod.rs +++ b/src/io/write/mod.rs @@ -12,6 +12,8 @@ use write_vectored::WriteVectoredFuture; use crate::io::{self, IoSlice}; +pub use futures_io::AsyncWrite as Write; + extension_trait! { pub trait Write {} diff --git a/src/stream/stream/mod.rs b/src/stream/stream/mod.rs index 279a8369..48fdbb22 100644 --- a/src/stream/stream/mod.rs +++ b/src/stream/stream/mod.rs @@ -143,6 +143,8 @@ cfg_unstable! { mod unzip; } +pub use futures_core::stream::Stream as Stream; + extension_trait! { pub trait Stream {} diff --git a/src/utils.rs b/src/utils.rs index 51b2fb0c..d662e17f 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -257,9 +257,6 @@ macro_rules! extension_trait { $($body_ext:tt)* } ) => { - // Re-export the base trait from the futures crate. - pub use $base as $name; - // The extension trait that adds methods to any type implementing the base trait. #[doc = $doc_ext] pub trait $ext: $name {