We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 98c1e3d commit 1fb0033Copy full SHA for 1fb0033
library/std/src/io/mod.rs
@@ -556,6 +556,10 @@ where
556
/// therefore, using something that implements [`BufRead`], such as
557
/// [`BufReader`], will be more efficient.
558
///
559
+/// Repeated calls to the reader use the same cursor, so for example
560
+/// calling `read_to_end` twice on a [`File`] will only return the file's
561
+/// contents once. It's recommended to first call `rewind()` in that case.
562
+///
563
/// # Examples
564
565
/// [`File`]s implement `Read`:
0 commit comments