pub(super) fn copy_to_new_file(from: &mut dyn Read, dest: &Path) -> Result<()>Expand description
Writes all of from to a new file at dest. The file is created exclusively, so one that appeared since
any earlier check is never replaced; a write that fails part-way leaves nothing behind.