mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-04 01:42:54 +03:00
1999ed798e
Add a `File::create_new` constructor We have `File::create` for creating a file or opening an existing file, but the secure way to guarantee creating a new file requires a longhand invocation via `OpenOptions`. Add `File::create_new` to handle this case, to make it easier for people to do secure file creation.