about summary refs log tree commit diff
path: root/src/test/ui/issues
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2021-07-24 09:51:57 -0700
committerGitHub <noreply@github.com>2021-07-24 09:51:57 -0700
commitbfa0358d2a7d0f0989b3a4374df9077fece170f9 (patch)
tree555a5f7f48ee9878addb457d29e7118773f54498 /src/test/ui/issues
parente4d8f0e3493d65f8d8d4121dd868402a1365d951 (diff)
parent17f7536fb220fc53cd0af2de46528070cfab012c (diff)
downloadrust-bfa0358d2a7d0f0989b3a4374df9077fece170f9.tar.gz
rust-bfa0358d2a7d0f0989b3a4374df9077fece170f9.zip
Rollup merge of #87359 - jyn514:bless-rustup, r=estebank
Remove detection of rustup and cargo in 'missing extern crate' diagnostics

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. It does set RUST_RECURSION_COUNT
whenever it launches a proxy, though - use that instead.

r? ```@estebank``` cc ```@petrochenkov``` ```@kinnison```
Diffstat (limited to 'src/test/ui/issues')
-rw-r--r--src/test/ui/issues/issue-37131.stderr2
-rw-r--r--src/test/ui/issues/issue-49851/compiler-builtins-error.stderr2
2 files changed, 4 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-37131.stderr b/src/test/ui/issues/issue-37131.stderr
index 660a6935f36..b45574f0c49 100644
--- a/src/test/ui/issues/issue-37131.stderr
+++ b/src/test/ui/issues/issue-37131.stderr
@@ -1,6 +1,8 @@
 error[E0463]: can't find crate for `std`
    |
    = note: the `thumbv6m-none-eabi` target may not be installed
+   = help: consider downloading the target with `rustup target add thumbv6m-none-eabi`
+   = help: consider building the standard library from source with `cargo build -Zbuild-std`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/issues/issue-49851/compiler-builtins-error.stderr b/src/test/ui/issues/issue-49851/compiler-builtins-error.stderr
index 7e23e0fd747..d963c07ea91 100644
--- a/src/test/ui/issues/issue-49851/compiler-builtins-error.stderr
+++ b/src/test/ui/issues/issue-49851/compiler-builtins-error.stderr
@@ -1,6 +1,8 @@
 error[E0463]: can't find crate for `core`
    |
    = note: the `thumbv7em-none-eabihf` target may not be installed
+   = help: consider downloading the target with `rustup target add thumbv7em-none-eabihf`
+   = help: consider building the standard library from source with `cargo build -Zbuild-std`
 
 error: aborting due to previous error