Temporarily make the test cfg a well known bootstrap cfg
This commit is contained in:
parent
e8a4792b3e
commit
c73d81ec33
2 changed files with 4 additions and 0 deletions
|
|
@ -624,6 +624,8 @@ impl Builder<'_> {
|
|||
// get warnings about it being unexpected.
|
||||
hostflags.arg("-Zunstable-options");
|
||||
hostflags.arg("--check-cfg=cfg(bootstrap)");
|
||||
// #[cfg(bootstrap)] as we are transition `test` to userspace cfg
|
||||
hostflags.arg("--check-cfg=cfg(test)");
|
||||
|
||||
// FIXME: It might be better to use the same value for both `RUSTFLAGS` and `RUSTDOCFLAGS`,
|
||||
// but this breaks CI. At the very least, stage0 `rustdoc` needs `--cfg bootstrap`. See
|
||||
|
|
|
|||
|
|
@ -77,6 +77,8 @@ const LLD_FILE_NAMES: &[&str] = &["ld.lld", "ld64.lld", "lld-link", "wasm-ld"];
|
|||
#[allow(clippy::type_complexity)] // It's fine for hard-coded list and type is explained above.
|
||||
const EXTRA_CHECK_CFGS: &[(Option<Mode>, &str, Option<&[&'static str]>)] = &[
|
||||
(None, "bootstrap", None),
|
||||
// #[cfg(bootstrap)] to be removed when Cargo is updated
|
||||
(None, "test", None),
|
||||
(Some(Mode::Rustc), "llvm_enzyme", None),
|
||||
(Some(Mode::Codegen), "llvm_enzyme", None),
|
||||
(Some(Mode::ToolRustc), "llvm_enzyme", None),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue