Fix BufRead::{read_until, read_line} documentation.
This commit is contained in:
parent
7660bdf70a
commit
1e8f692461
1 changed files with 3 additions and 7 deletions
|
@ -1264,15 +1264,13 @@ pub trait BufRead: Read {
|
|||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
fn consume(&mut self, amt: usize);
|
||||
|
||||
/// Read all bytes into `buf` until the delimiter `byte` is reached.
|
||||
/// Read all bytes into `buf` until the delimiter `byte` or EOF is reached.
|
||||
///
|
||||
/// This function will read bytes from the underlying stream until the
|
||||
/// delimiter or EOF is found. Once found, all bytes up to, and including,
|
||||
/// the delimiter (if found) will be appended to `buf`.
|
||||
///
|
||||
/// If this reader is currently at EOF then this function will not modify
|
||||
/// `buf` and will return `Ok(n)` where `n` is the number of bytes which
|
||||
/// were read.
|
||||
/// If successful, this function will return the total number of bytes read.
|
||||
///
|
||||
/// # Errors
|
||||
///
|
||||
|
@ -1315,9 +1313,7 @@ pub trait BufRead: Read {
|
|||
/// up to, and including, the delimiter (if found) will be appended to
|
||||
/// `buf`.
|
||||
///
|
||||
/// If this reader is currently at EOF then this function will not modify
|
||||
/// `buf` and will return `Ok(n)` where `n` is the number of bytes which
|
||||
/// were read.
|
||||
/// If successful, this function will return the total number of bytes read.
|
||||
///
|
||||
/// # Errors
|
||||
///
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue