We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 918f393 commit cc4670fCopy full SHA for cc4670f
src/tools/miri/cargo-miri/src/main.rs
@@ -80,7 +80,11 @@ fn main() {
80
match first.as_str() {
81
"miri" => phase_cargo_miri(args),
82
"runner" => phase_runner(args, RunnerPhase::Cargo),
83
- arg if arg == env::var("RUSTC").unwrap() => {
+ arg if arg == env::var("RUSTC").unwrap_or_else(|_| {
84
+ show_error!(
85
+ "`cargo-miri` called without RUSTC set; please only invoke this binary through `cargo miri`"
86
+ )
87
+ }) => {
88
// If the first arg is equal to the RUSTC env variable (which should be set at this
89
// point), then we need to behave as rustc. This is the somewhat counter-intuitive
90
// behavior of having both RUSTC and RUSTC_WRAPPER set
0 commit comments