Skip to content

Commit d97ae45

Browse files
committed
Auto merge of #8206 - alexcrichton:no-probe-beta, r=Eh2406
[beta] Do not probe for `-Cembed-bitcode` This flag didn't make it to the beta branch of rustc, so remove the probe here in Cargo. This is intended to be a very small patch to remove the probe, since the real support is updated on master and will replace this eventually anyway.
2 parents ebda506 + 96d5b73 commit d97ae45

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed

src/cargo/core/compiler/build_context/target_info.rs

+1-6
Original file line numberDiff line numberDiff line change
@@ -105,12 +105,7 @@ impl TargetInfo {
105105
.args(&rustflags)
106106
.env_remove("RUSTC_LOG");
107107

108-
let mut embed_bitcode_test = process.clone();
109-
embed_bitcode_test.arg("-Cembed-bitcode");
110-
let supports_embed_bitcode = match kind {
111-
CompileKind::Host => Some(rustc.cached_output(&embed_bitcode_test).is_ok()),
112-
_ => None,
113-
};
108+
let supports_embed_bitcode = Some(false);
114109

115110
if let CompileKind::Target(target) = kind {
116111
process.arg("--target").arg(target.rustc_target());

src/cargo/sources/git/utils.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ use serde::Serialize;
1111
use std::env;
1212
use std::fmt;
1313
use std::fs::File;
14-
use std::mem;
1514
use std::path::{Path, PathBuf};
1615
use std::process::Command;
1716
use url::Url;
@@ -838,7 +837,7 @@ fn maybe_gc_repo(repo: &mut git2::Repository) -> CargoResult<()> {
838837
);
839838
if out.status.success() {
840839
let new = git2::Repository::open(repo.path())?;
841-
mem::replace(repo, new);
840+
*repo = new;
842841
return Ok(());
843842
}
844843
}

0 commit comments

Comments
 (0)