Skip to content

Fail nicely when copying artefacts fails #22150

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 12, 2015
Merged

Conversation

nagisa
Copy link
Member

@nagisa nagisa commented Feb 10, 2015

Fixes #22124

@rust-highfive
Copy link
Contributor

r? @brson

(rust_highfive has picked a reviewer for you, use r? to override)

let output_path = &crate_output.path(output_type);
if let Err(e) = fs::copy(input_path, output_path) {
sess.err(&format!("could not copy {:?} to {:?}: {}",
input_path, output_path, e.description()));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this may wish to rather just print e itself rather than just the description (as it has more information)

@nagisa
Copy link
Member Author

nagisa commented Feb 10, 2015

@alexcrichton updated

@@ -22,6 +22,7 @@ use syntax::codemap;
use syntax::diagnostic;
use syntax::diagnostic::{Emitter, Handler, Level, mk_handler};

use std::error::Error;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that this may be an unused import now.

@alexcrichton
Copy link
Member

@bors: r+ a941fdb rollup

Thanks!

@alexcrichton alexcrichton assigned alexcrichton and unassigned brson Feb 11, 2015
alexcrichton added a commit to alexcrichton/rust that referenced this pull request Feb 11, 2015
@bors bors merged commit a941fdb into rust-lang:master Feb 12, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ICE when copying artifacts fails
5 participants