fix missing export for the return value

split-by-pattern
k-nasa 5 years ago
parent 61eb52cb36
commit 43f4f393af

@ -105,8 +105,8 @@
//!
//! ```no_run
//! use async_std::fs::File;
//! use async_std::io::BufWriter;
//! use async_std::io::prelude::*;
//! use async_std::io::BufWriter;
//!
//! # fn main() -> std::io::Result<()> { async_std::task::block_on(async {
//! #
@ -116,8 +116,8 @@
//!
//! // write a byte to the buffer
//! writer.write(&[42]).await?;
//!
//! } // the buffer is flushed once writer goes out of scope
//! //
//! #
//! # Ok(()) }) }
//! ```
@ -281,7 +281,7 @@ cfg_std! {
pub use copy::copy;
pub use cursor::Cursor;
pub use empty::{empty, Empty};
pub use read::Read;
pub use read::*;
pub use repeat::{repeat, Repeat};
pub use seek::Seek;
pub use sink::{sink, Sink};

@ -17,6 +17,10 @@ use std::mem;
use crate::io::IoSliceMut;
pub use take::Take;
pub use bytes::Bytes;
pub use chain::Chain;
extension_trait! {
use std::pin::Pin;
use std::ops::{Deref, DerefMut};
@ -301,11 +305,11 @@ extension_trait! {
# Ok(()) }) }
```
"#]
fn take(self, limit: u64) -> take::Take<Self>
fn take(self, limit: u64) -> Take<Self>
where
Self: Sized,
{
take::Take { inner: self, limit }
Take { inner: self, limit }
}
#[doc = r#"
@ -377,8 +381,8 @@ extension_trait! {
# Ok(()) }) }
```
"#]
fn bytes(self) -> bytes::Bytes<Self> where Self: Sized {
bytes::Bytes { inner: self }
fn bytes(self) -> Bytes<Self> where Self: Sized {
Bytes { inner: self }
}
#[doc = r#"
@ -413,8 +417,8 @@ extension_trait! {
# Ok(()) }) }
```
"#]
fn chain<R: Read>(self, next: R) -> chain::Chain<Self, R> where Self: Sized {
chain::Chain { first: self, second: next, done_first: false }
fn chain<R: Read>(self, next: R) -> Chain<Self, R> where Self: Sized {
Chain { first: self, second: next, done_first: false }
}
}

Loading…
Cancel
Save