Rollup merge of #129718 - lolbinarycat:remove_dir-docs, r=Noratrieb
add guarantee about remove_dir and remove_file error kinds approved in ACP https://github.com/rust-lang/libs-team/issues/433
This commit is contained in:
commit
f2290c23fc
@ -1991,6 +1991,11 @@ fn as_inner(&self) -> &fs_imp::DirEntry {
|
||||
/// * The file doesn't exist.
|
||||
/// * The user lacks permissions to remove the file.
|
||||
///
|
||||
/// This function will only ever return an error of kind `NotFound` if the given
|
||||
/// path does not exist. Note that the inverse is not true,
|
||||
/// ie. if a path does not exist, its removal may fail for a number of reasons,
|
||||
/// such as insufficient permissions.
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
/// ```no_run
|
||||
@ -2448,6 +2453,11 @@ pub fn create_dir_all<P: AsRef<Path>>(path: P) -> io::Result<()> {
|
||||
/// * The user lacks permissions to remove the directory at the provided `path`.
|
||||
/// * The directory isn't empty.
|
||||
///
|
||||
/// This function will only ever return an error of kind `NotFound` if the given
|
||||
/// path does not exist. Note that the inverse is not true,
|
||||
/// ie. if a path does not exist, its removal may fail for a number of reasons,
|
||||
/// such as insufficient permissions.
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
/// ```no_run
|
||||
|
Loading…
Reference in New Issue
Block a user