]> git.lizzy.rs Git - rust.git/commitdiff
Add track_caller to `builder_helper::output`
authorJoshua Nelson <jyn514@gmail.com>
Wed, 3 Feb 2021 16:22:35 +0000 (11:22 -0500)
committerJoshua Nelson <jyn514@gmail.com>
Thu, 20 May 2021 02:55:59 +0000 (22:55 -0400)
If something goes wrong here, showing `fn output` is unhelpful. Show
where the command is being run instead.

src/build_helper/lib.rs

index 80f804174ed082e20527f8206cd6aef5bbf5eb19..b1ec072f3f8aae7da31f1d171b770bf097948197 100644 (file)
@@ -130,6 +130,7 @@ pub fn make(host: &str) -> PathBuf {
     }
 }
 
+#[track_caller]
 pub fn output(cmd: &mut Command) -> String {
     let output = match cmd.stderr(Stdio::inherit()).output() {
         Ok(status) => status,