We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e341644 commit b82f9e6Copy full SHA for b82f9e6
src/lib.rs
@@ -18,10 +18,12 @@
18
//! use async_std::io::{self, BufReader, prelude::*};
19
//! use duplexify::Duplex;
20
//!
21
+//! // Create a reader and writer, and merge them into a single "duplex".
22
//! let stdin = BufReader::new(io::stdin());
23
//! let stdout = io::stdout();
24
//! let mut stdio = Duplex::new(stdin, stdout);
25
26
+//! // We can now read + write from and to the duplex.
27
//! let mut line = String::new();
28
//! stdio.read_line(&mut line).await?;
29
//! stdio.write_all(&line.as_bytes()).await?;
0 commit comments