Skip to content

Commit 66268e8

Browse files
committed
Add a hint what BufRead functions do on EOF
1 parent 6713736 commit 66268e8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/libstd/io/mod.rs

+4
Original file line numberDiff line numberDiff line change
@@ -1410,6 +1410,8 @@ pub trait BufRead: Read {
14101410
///
14111411
/// If successful, this function will return the total number of bytes read.
14121412
///
1413+
/// An empty buffer returned indicates that the stream has reached EOF.
1414+
///
14131415
/// # Errors
14141416
///
14151417
/// This function will ignore all instances of [`ErrorKind::Interrupted`] and
@@ -1470,6 +1472,8 @@ pub trait BufRead: Read {
14701472
///
14711473
/// If successful, this function will return the total number of bytes read.
14721474
///
1475+
/// An empty buffer returned indicates that the stream has reached EOF.
1476+
///
14731477
/// # Errors
14741478
///
14751479
/// This function has the same error semantics as [`read_until`] and will

0 commit comments

Comments
 (0)