small doc fixes
We don't need this &mut, and vec could use []s
This commit is contained in:
parent
930f87774d
commit
44abe92d66
@ -280,10 +280,10 @@ impl<'a> Seek for BufWriter<'a> {
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::BufReader;
|
||||
///
|
||||
/// let mut buf = [0, 1, 2, 3];
|
||||
/// let mut r = BufReader::new(&mut buf);
|
||||
/// let buf = [0, 1, 2, 3];
|
||||
/// let mut r = BufReader::new(&buf);
|
||||
///
|
||||
/// assert_eq!(r.read_to_end().unwrap(), vec!(0, 1, 2, 3));
|
||||
/// assert_eq!(r.read_to_end().unwrap(), vec![0, 1, 2, 3]);
|
||||
/// ```
|
||||
pub struct BufReader<'a> {
|
||||
buf: &'a [u8],
|
||||
|
Loading…
x
Reference in New Issue
Block a user