@@ -21,7 +21,7 @@ use io::{self, DEFAULT_BUF_SIZE, Error, ErrorKind, SeekFrom};
2121use ptr;
2222use iter;
2323
24- /// Wraps a `Read` and buffers input from it
24+ /// Wraps a `Read` and buffers input from it.
2525///
2626/// It can be excessively inefficient to work directly with a `Read` instance.
2727/// For example, every call to `read` on `TcpStream` results in a system call.
@@ -54,13 +54,13 @@ pub struct BufReader<R> {
5454}
5555
5656impl < R : Read > BufReader < R > {
57- /// Creates a new `BufReader` with a default buffer capacity
57+ /// Creates a new `BufReader` with a default buffer capacity.
5858 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
5959 pub fn new ( inner : R ) -> BufReader < R > {
6060 BufReader :: with_capacity ( DEFAULT_BUF_SIZE , inner)
6161 }
6262
63- /// Creates a new `BufReader` with the specified buffer capacity
63+ /// Creates a new `BufReader` with the specified buffer capacity.
6464 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
6565 pub fn with_capacity ( cap : usize , inner : R ) -> BufReader < R > {
6666 let mut buf = Vec :: with_capacity ( cap) ;
@@ -183,7 +183,7 @@ impl<R: Seek> Seek for BufReader<R> {
183183 }
184184}
185185
186- /// Wraps a Writer and buffers output to it
186+ /// Wraps a Writer and buffers output to it.
187187///
188188/// It can be excessively inefficient to work directly with a `Write`. For
189189/// example, every call to `write` on `TcpStream` results in a system call. A
@@ -205,13 +205,13 @@ pub struct BufWriter<W: Write> {
205205pub struct IntoInnerError < W > ( W , Error ) ;
206206
207207impl < W : Write > BufWriter < W > {
208- /// Creates a new `BufWriter` with a default buffer capacity
208+ /// Creates a new `BufWriter` with a default buffer capacity.
209209 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
210210 pub fn new ( inner : W ) -> BufWriter < W > {
211211 BufWriter :: with_capacity ( DEFAULT_BUF_SIZE , inner)
212212 }
213213
214- /// Creates a new `BufWriter` with the specified buffer capacity
214+ /// Creates a new `BufWriter` with the specified buffer capacity.
215215 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
216216 pub fn with_capacity ( cap : usize , inner : W ) -> BufWriter < W > {
217217 BufWriter {
@@ -253,11 +253,11 @@ impl<W: Write> BufWriter<W> {
253253 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
254254 pub fn get_ref ( & self ) -> & W { self . inner . as_ref ( ) . unwrap ( ) }
255255
256- /// Gets a mutable reference to the underlying write .
256+ /// Gets a mutable reference to the underlying writer .
257257 ///
258258 /// # Warning
259259 ///
260- /// It is inadvisable to directly read from the underlying writer.
260+ /// It is inadvisable to directly write to the underlying writer.
261261 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
262262 pub fn get_mut ( & mut self ) -> & mut W { self . inner . as_mut ( ) . unwrap ( ) }
263263
0 commit comments