aboutsummaryrefslogtreecommitdiff
path: root/crates/project_model/src/cargo_workspace.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/project_model/src/cargo_workspace.rs')
-rw-r--r--crates/project_model/src/cargo_workspace.rs12
1 files changed, 4 insertions, 8 deletions
diff --git a/crates/project_model/src/cargo_workspace.rs b/crates/project_model/src/cargo_workspace.rs
index f1ad00d36..b18699b77 100644
--- a/crates/project_model/src/cargo_workspace.rs
+++ b/crates/project_model/src/cargo_workspace.rs
@@ -375,14 +375,10 @@ fn rustc_discover_host_triple(cargo_toml: &AbsPath) -> Option<String> {
375 375
376fn cargo_config_build_target(cargo_toml: &AbsPath) -> Option<String> { 376fn cargo_config_build_target(cargo_toml: &AbsPath) -> Option<String> {
377 let mut cargo_config = Command::new(toolchain::cargo()); 377 let mut cargo_config = Command::new(toolchain::cargo());
378 cargo_config.current_dir(cargo_toml.parent().unwrap()).args(&[ 378 cargo_config
379 "+nightly", 379 .current_dir(cargo_toml.parent().unwrap())
380 "-Z", 380 .args(&["-Z", "unstable-options", "config", "get", "build.target"])
381 "unstable-options", 381 .env("RUSTC_BOOTSTRAP", "1");
382 "config",
383 "get",
384 "build.target",
385 ]);
386 // if successful we receive `build.target = "target-triple"` 382 // if successful we receive `build.target = "target-triple"`
387 log::debug!("Discovering cargo config target by {:?}", cargo_config); 383 log::debug!("Discovering cargo config target by {:?}", cargo_config);
388 match utf8_stdout(cargo_config) { 384 match utf8_stdout(cargo_config) {