We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Read::bytes
1 parent 69ad06f commit 1c12a4eCopy full SHA for 1c12a4e
library/std/src/io/mod.rs
@@ -969,7 +969,10 @@ pub trait Read {
969
///
970
/// The default implementation calls `read` for each byte,
971
/// which can be very inefficient for data that's not in memory,
972
- /// such as [`File`]. Consider using a [`BufReader`] in such cases.
+ /// such as [`File`]. Consider using a [`BufReader`] in such cases. Even
973
+ /// then, going through the [`BufReader`] for every byte will still be
974
+ /// relatively slow. If speed is important, consider instead reading the
975
+ /// input in larger chunks.
976
977
/// # Examples
978
0 commit comments