Skip to content

Commit 70e8476

Browse files
committed
fix StdinLock doc test
1 parent a5a00d7 commit 70e8476

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/io/stdin.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,14 +151,14 @@ impl Stdin {
151151
/// # fn main() -> std::io::Result<()> { async_std::task::block_on(async {
152152
/// #
153153
/// use async_std::io;
154-
/// use std::io::Read;
154+
/// use crate::async_std::prelude::*;
155155
///
156156
/// let mut buffer = String::new();
157157
///
158158
/// let stdin = io::stdin();
159159
/// let mut handle = stdin.lock().await;
160160
///
161-
/// handle.read_to_string(&mut buffer)?;
161+
/// handle.read_to_string(&mut buffer).await?;
162162
/// #
163163
/// # Ok(()) }) }
164164
/// ```

0 commit comments

Comments
 (0)