Skip to content

Commit

Permalink
Merge pull request #91 from eoger/silent-probe
Browse files Browse the repository at this point in the history
Redirect probe compile errors to /dev/null
  • Loading branch information
dtolnay authored May 13, 2020
2 parents 290d3d2 + 5ed5f56 commit afc3079
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion build.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::env;
use std::fs;
use std::path::Path;
use std::process::{Command, ExitStatus};
use std::process::{Command, ExitStatus, Stdio};

// This code exercises the surface area that we expect of the std Backtrace
// type. If the current toolchain is able to compile it, we go ahead and use
Expand Down Expand Up @@ -50,6 +50,7 @@ fn compile_probe() -> Option<ExitStatus> {
let probefile = Path::new(&out_dir).join("probe.rs");
fs::write(&probefile, PROBE).ok()?;
Command::new(rustc)
.stderr(Stdio::null())
.arg("--edition=2018")
.arg("--crate-name=anyhow_build")
.arg("--crate-type=lib")
Expand Down

0 comments on commit afc3079

Please sign in to comment.