Skip to content

Commit

Permalink
Add a comment.
Browse files Browse the repository at this point in the history
  • Loading branch information
sunfishcode committed Oct 12, 2023
1 parent 556ed8a commit 7eb9187
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ fn can_compile<T: AsRef<str>>(test: T) -> bool {
let rustc = var("RUSTC").unwrap();
let target = var("TARGET").unwrap();

// Use `RUSTC_WRAPPER` if it's set, unless it's set to an empty string,
// as documented [here].
// [here]: https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-reads
let wrapper = var("RUSTC_WRAPPER")
.ok()
.and_then(|w| if w.is_empty() { None } else { Some(w) });
Expand Down

0 comments on commit 7eb9187

Please sign in to comment.