diff --git a/library/std/src/fs.rs b/library/std/src/fs.rs index 2767675ff92..b1630f8f549 100644 --- a/library/std/src/fs.rs +++ b/library/std/src/fs.rs @@ -1921,7 +1921,7 @@ pub fn create_dir_all>(path: P) -> io::Result<()> { DirBuilder::new().recursive(true).create(path.as_ref()) } -/// Removes an existing, empty directory. +/// Removes an empty directory. /// /// # Platform-specific behavior /// @@ -1936,6 +1936,8 @@ pub fn create_dir_all>(path: P) -> io::Result<()> { /// This function will return an error in the following situations, but is not /// limited to just these cases: /// +/// * `path` doesn't exist. +/// * `path` isn't a directory. /// * The user lacks permissions to remove the directory at the provided `path`. /// * The directory isn't empty. ///