Previously, this would change the test output when RUSTUP_HOME was set: ``` ---- [ui] ui/issues/issue-49851/compiler-builtins-error.rs stdout ---- diff of stderr: 1 error[E0463]: can't find crate for `core` 2 | 3 = note: the `thumbv7em-none-eabihf` target may not be installed + = help: consider downloading the target with `rustup target add thumbv7em-none-eabihf` 4 5 error: aborting due to previous error 6 ``` Originally, I fixed it by explicitly unsetting RUSTUP_HOME in compiletest. Then I realized that almost no one has RUSTUP_HOME set, since rustup doesn't set it itself; although it does set RUST_RECURSION_COUNT whenever it launches a proxy. Then it was pointed out that this runtime check doesn't really make sense and it's fine to make it unconditional.
11 lines
438 B
Rust
11 lines
438 B
Rust
// compile-flags: --target x86_64-unknown-uefi
|
|
// needs-llvm-components: x86
|
|
// rustc-env:CARGO=/usr/bin/cargo
|
|
#![no_core]
|
|
extern crate core;
|
|
//~^ ERROR can't find crate for `core`
|
|
//~| NOTE can't find crate
|
|
//~| NOTE target may not be installed
|
|
//~| HELP consider building the standard library from source with `cargo build -Zbuild-std`
|
|
//~| HELP consider downloading the target with `rustup target add x86_64-unknown-uefi`
|
|
fn main() {}
|