Merge pull request #50 from oberien/read

doc(read): Add number of bytes read to doc
This commit is contained in:
Alex Crichton
2016-10-04 07:50:44 -07:00
committed by GitHub
+2 -2
View File
@@ -13,8 +13,8 @@ enum State<R, T> {
/// Tries to read some bytes directly into the given `buf` in asynchronous /// Tries to read some bytes directly into the given `buf` in asynchronous
/// manner, returning a future type. /// manner, returning a future type.
/// ///
/// The returned future will resolve to both the I/O stream as well as the /// The returned future will resolve to both the I/O stream and the buffer
/// buffer once the read operation is completed. /// as well as the number of bytes read once the read operation is completed.
pub fn read<R, T>(rd: R, buf: T) -> Read<R, T> pub fn read<R, T>(rd: R, buf: T) -> Read<R, T>
where R: ::std::io::Read, where R: ::std::io::Read,
T: AsMut<[u8]> T: AsMut<[u8]>