Skip to content

Commit b4a6f89

Browse files
committed
Explain how to create a Stdin or Stdout
1 parent 3dbfa74 commit b4a6f89

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/libstd/io/stdio.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ impl Write for StderrRaw {
9595
///
9696
/// This handle implements the `Read` trait, but beware that concurrent reads
9797
/// of `Stdin` must be executed with care.
98+
///
99+
/// Created by the function `io::stdin()`.
98100
#[stable(feature = "rust1", since = "1.0.0")]
99101
pub struct Stdin {
100102
inner: Arc<Mutex<BufReader<StdinRaw>>>,
@@ -206,6 +208,8 @@ const OUT_MAX: usize = ::usize::MAX;
206208
/// Each handle shares a global buffer of data to be written to the standard
207209
/// output stream. Access is also synchronized via a lock and explicit control
208210
/// over locking is available via the `lock` method.
211+
///
212+
/// Created by the function `io::stdout()`.
209213
#[stable(feature = "rust1", since = "1.0.0")]
210214
pub struct Stdout {
211215
// FIXME: this should be LineWriter or BufWriter depending on the state of

0 commit comments

Comments
 (0)