1
Fork 0

bypass auto_da_alloc for metadata files

This commit is contained in:
The8472 2021-02-13 00:54:17 +01:00
parent 3f5aee2d52
commit 6a679ffc81
2 changed files with 19 additions and 1 deletions

View file

@ -983,7 +983,7 @@ fn encode_and_write_metadata(
.unwrap_or_else(|err| tcx.sess.fatal(&format!("couldn't create a temp dir: {}", err)));
let metadata_tmpdir = MaybeTempDir::new(metadata_tmpdir, tcx.sess.opts.cg.save_temps);
let metadata_filename = emit_metadata(tcx.sess, &metadata, &metadata_tmpdir);
if let Err(e) = fs::rename(&metadata_filename, &out_filename) {
if let Err(e) = util::non_durable_rename(&metadata_filename, &out_filename) {
tcx.sess.fatal(&format!("failed to write {}: {}", out_filename.display(), e));
}
if tcx.sess.opts.json_artifact_notifications {