Skip to content

Commit 3e3408d

Browse files
committed
Comment on when ReadDir is Err
Fixes #23426
1 parent 08dd30d commit 3e3408d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: src/libstd/fs/mod.rs

+5
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,11 @@ pub struct Metadata(fs_imp::FileAttr);
7373
/// will yield instances of `io::Result<DirEntry>`. Through a `DirEntry`
7474
/// information like the entry's path and possibly other metadata can be
7575
/// learned.
76+
///
77+
/// # Failure
78+
///
79+
/// This `io::Result` will be an `Err` if there's some sort of intermittent
80+
/// IO error during iteration.
7681
#[stable(feature = "rust1", since = "1.0.0")]
7782
pub struct ReadDir(fs_imp::ReadDir);
7883

0 commit comments

Comments
 (0)