feat: Add Default trait

write-by-ref
k-nasa 5 years ago
parent 33d2191cec
commit 6253e97717

@ -14,7 +14,7 @@ use crate::task::blocking;
///
/// [`os::unix::fs::DirBuilderExt`]: ../os/unix/fs/trait.DirBuilderExt.html
/// [`std::fs::DirBuilder`]: https://doc.rust-lang.org/std/fs/struct.DirBuilder.html
#[derive(Debug)]
#[derive(Debug, Default)]
pub struct DirBuilder {
/// Set to `true` if non-existent parent directories should be created.
recursive: bool,

@ -290,6 +290,12 @@ impl OpenOptions {
}
}
impl Default for OpenOptions {
fn default() -> Self {
Self::new()
}
}
cfg_if! {
if #[cfg(feature = "docs")] {
use crate::os::unix::fs::OpenOptionsExt;

Loading…
Cancel
Save