diff options
| author | 许杰友 Jieyou Xu (Joe) <jieyouxu@outlook.com> | 2024-07-19 09:49:32 +0000 |
|---|---|---|
| committer | 许杰友 Jieyou Xu (Joe) <jieyouxu@outlook.com> | 2024-07-19 14:04:58 +0000 |
| commit | f5488f0c4b12aa56744da0cb212df7b7152ea580 (patch) | |
| tree | 8014f47109e4fa05a8e9c6afa0a0f23b98d9c8e9 | |
| parent | cf5edfe3f92e7b40f984c3e6336f441869901eec (diff) | |
| download | rust-f5488f0c4b12aa56744da0cb212df7b7152ea580.tar.gz rust-f5488f0c4b12aa56744da0cb212df7b7152ea580.zip | |
compiletest/rmake: rename `cmd` to `rustc`
| -rw-r--r-- | src/tools/compiletest/src/runtest.rs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 79c63710070..ba7bac18c9d 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -3609,8 +3609,9 @@ impl<'test> TestCx<'test> { // FIXME(jieyouxu): explain what the hecc we are doing here. // FIXME(jieyouxu): audit these env vars. some of them only makes sense for make, not rustc! - let mut cmd = Command::new(&self.config.rustc_path); - cmd.arg("-o") + let mut rustc = Command::new(&self.config.rustc_path); + rustc + .arg("-o") .arg(&recipe_bin) .arg(format!("-Ldependency={}", &support_lib_path.parent().unwrap().to_string_lossy())) .arg(format!("-Ldependency={}", &support_lib_deps.to_string_lossy())) @@ -3631,7 +3632,7 @@ impl<'test> TestCx<'test> { // In test code we want to be very pedantic about values being silently discarded that are // annotated with `#[must_use]`. - cmd.arg("-Dunused_must_use"); + rustc.arg("-Dunused_must_use"); // FIXME(jieyouxu): explain this! if std::env::var_os("COMPILETEST_FORCE_STAGE0").is_some() { @@ -3640,10 +3641,10 @@ impl<'test> TestCx<'test> { debug!(?stage0_sysroot); debug!(exists = stage0_sysroot.exists()); - cmd.arg("--sysroot").arg(&stage0_sysroot); + rustc.arg("--sysroot").arg(&stage0_sysroot); } - let res = self.run_command_to_procres(&mut cmd); + let res = self.run_command_to_procres(&mut rustc); if !res.status.success() { self.fatal_proc_rec("run-make test failed: could not build `rmake.rs` recipe", &res); } |
