codegen_llvm_back: improve allocations

This commit is contained in:
ljedrz
2018-10-06 11:45:11 +02:00
parent a563ceb3b9
commit 2043d30c2e
4 changed files with 23 additions and 21 deletions

View File

@@ -72,12 +72,12 @@ pub(crate) fn link_binary(sess: &Session,
bug!("invalid output type `{:?}` for target os `{}`",
crate_type, sess.opts.target_triple);
}
let mut out_files = link_binary_output(sess,
codegen_results,
crate_type,
outputs,
crate_name);
out_filenames.append(&mut out_files);
let out_files = link_binary_output(sess,
codegen_results,
crate_type,
outputs,
crate_name);
out_filenames.extend(out_files);
}
// Remove the temporary object file and metadata if we aren't saving temps