File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -28,8 +28,10 @@ pub trait Read: ErrorType {
2828 /// If bytes are available to read:
2929 /// - A non-zero amount of bytes is read to the beginning of `buf`, and the amount is returned immediately,
3030 /// *without waiting for more bytes to become available*;
31- /// - It is not guaranteed that *all* available bytes are returned, it is possible for the implementation to
32- /// read an amount of bytes less than `buf.len()` while there are more bytes immediately available.
31+ ///
32+ /// Note that once some bytes are available to read, it is *not* guaranteed that all available bytes are returned.
33+ /// It is possible for the implementation to read an amount of bytes less than `buf.len()` while there are more
34+ /// bytes immediately available.
3335 ///
3436 /// This waiting behavior is important for the cases where `Read` represents the "read" leg of a pipe-like
3537 /// protocol (a socket, a pipe, a serial line etc.). The semantics is that the caller - by passing a non-empty
Original file line number Diff line number Diff line change @@ -309,8 +309,10 @@ pub trait Read: ErrorType {
309309 /// If bytes are available to read:
310310 /// - A non-zero amount of bytes is read to the beginning of `buf`, and the amount is returned immediately,
311311 /// *without blocking and waiting for more bytes to become available*;
312- /// - It is not guaranteed that *all* available bytes are returned, it is possible for the implementation to
313- /// read an amount of bytes less than `buf.len()` while there are more bytes immediately available.
312+ ///
313+ /// Note that once some bytes are available to read, it is *not* guaranteed that all available bytes are returned.
314+ /// It is possible for the implementation to read an amount of bytes less than `buf.len()` while there are more
315+ /// bytes immediately available.
314316 ///
315317 /// This blocking behavior is important for the cases where `Read` represents the "read" leg of a pipe-like
316318 /// protocol (a socket, a pipe, a serial line etc.). The semantics is that the caller - by passing a non-empty
You can’t perform that action at this time.
0 commit comments