Skip to content

Commit 5495ce0

Browse files
committed
Use detailed and shorter fs error explaination
Includes suggestion from the8472 #79390 (comment) More detail error explanation in fs doc
1 parent 1c389ff commit 5495ce0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

library/std/src/fs.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1676,9 +1676,9 @@ pub fn rename<P: AsRef<Path>, Q: AsRef<Path>>(from: P, to: Q) -> io::Result<()>
16761676
/// This function will return an error in the following situations, but is not
16771677
/// limited to just these cases:
16781678
///
1679-
/// * The `from` path is not a file.
1680-
/// * The `from` file does not exist.
1681-
/// * The current process does not have the permission rights to access
1679+
/// * `from` is neither a regular file nor a symlink to a regular file.
1680+
/// * `from` does not exist.
1681+
/// * The current process does not have the permission rights to read
16821682
/// `from` or write `to`.
16831683
///
16841684
/// # Examples

0 commit comments

Comments
 (0)