diff --git a/library/core/src/num/mod.rs b/library/core/src/num/mod.rs
index f45b73b053364..8b93cd39d5df3 100644
--- a/library/core/src/num/mod.rs
+++ b/library/core/src/num/mod.rs
@@ -999,7 +999,7 @@ macro_rules! impl_helper_for {
}
impl_helper_for! { i8 i16 i32 i64 i128 isize u8 u16 u32 u64 u128 usize }
-/// Determins if a string of text of that length of that radix could be guaranteed to be
+/// Determines if a string of text of that length of that radix could be guaranteed to be
/// stored in the given type T.
/// Note that if the radix is known to the compiler, it is just the check of digits.len that
/// is done at runtime.
diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs
index 7b496e6c66933..59102ad9f50b8 100644
--- a/src/bootstrap/lib.rs
+++ b/src/bootstrap/lib.rs
@@ -1176,7 +1176,17 @@ impl Build {
/// Path to the python interpreter to use
fn python(&self) -> &Path {
- self.config.python.as_ref().unwrap()
+ if self.config.build.ends_with("apple-darwin") {
+ // Force /usr/bin/python3 on macOS for LLDB tests because we're loading the
+ // LLDB plugin's compiled module which only works with the system python
+ // (namely not Homebrew-installed python)
+ Path::new("/usr/bin/python3")
+ } else {
+ self.config
+ .python
+ .as_ref()
+ .expect("python is required for running LLDB or rustdoc tests")
+ }
}
/// Temporary directory that extended error information is emitted to.
diff --git a/src/bootstrap/sanity.rs b/src/bootstrap/sanity.rs
index 8c2899c1ac01e..c96e6f9a3678f 100644
--- a/src/bootstrap/sanity.rs
+++ b/src/bootstrap/sanity.rs
@@ -103,7 +103,9 @@ pub fn check(build: &mut Build) {
.take()
.map(|p| cmd_finder.must_have(p))
.or_else(|| env::var_os("BOOTSTRAP_PYTHON").map(PathBuf::from)) // set by bootstrap.py
- .or_else(|| Some(cmd_finder.must_have("python")));
+ .or_else(|| cmd_finder.maybe_have("python"))
+ .or_else(|| cmd_finder.maybe_have("python3"))
+ .or_else(|| cmd_finder.maybe_have("python2"));
build.config.nodejs = build
.config
diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
index b88684791bc6d..f60766bde726e 100644
--- a/src/bootstrap/test.rs
+++ b/src/bootstrap/test.rs
@@ -1402,14 +1402,7 @@ note: if you're sure you want to do this, please open an issue as to why. In the
cmd.arg("--docck-python").arg(builder.python());
- if builder.config.build.ends_with("apple-darwin") {
- // Force /usr/bin/python3 on macOS for LLDB tests because we're loading the
- // LLDB plugin's compiled module which only works with the system python
- // (namely not Homebrew-installed python)
- cmd.arg("--lldb-python").arg("/usr/bin/python3");
- } else {
- cmd.arg("--lldb-python").arg(builder.python());
- }
+ cmd.arg("--lldb-python").arg(builder.python());
if let Some(ref gdb) = builder.config.gdb {
cmd.arg("--gdb").arg(gdb);
diff --git a/src/doc/unstable-book/src/compiler-flags/img/llvm-cov-show-01.png b/src/doc/rustc/src/images/llvm-cov-show-01.png
similarity index 100%
rename from src/doc/unstable-book/src/compiler-flags/img/llvm-cov-show-01.png
rename to src/doc/rustc/src/images/llvm-cov-show-01.png
diff --git a/src/doc/rustc/src/instrument-coverage.md b/src/doc/rustc/src/instrument-coverage.md
index b94989161ccfc..108b0ffe99b85 100644
--- a/src/doc/rustc/src/instrument-coverage.md
+++ b/src/doc/rustc/src/instrument-coverage.md
@@ -145,7 +145,7 @@ $ llvm-cov show -Xdemangler=rustfilt target/debug/examples/formatjson5 \
-name=add_quoted_string
```
-
+
diff --git a/src/test/ui/box/issue-82446.rs b/src/test/ui/box/issue-82446.rs
new file mode 100644
index 0000000000000..2960f7fbc2121
--- /dev/null
+++ b/src/test/ui/box/issue-82446.rs
@@ -0,0 +1,15 @@
+// https://github.com/rust-lang/rust/issues/82446
+// Spurious 'help: store this in the heap' regression test
+trait MyTrait {}
+
+struct Foo {
+ val: Box
+}
+
+fn make_it(val: &Box) {
+ Foo {
+ val //~ ERROR [E0308]
+ };
+}
+
+fn main() {}
diff --git a/src/test/ui/box/issue-82446.stderr b/src/test/ui/box/issue-82446.stderr
new file mode 100644
index 0000000000000..0374737957e48
--- /dev/null
+++ b/src/test/ui/box/issue-82446.stderr
@@ -0,0 +1,12 @@
+error[E0308]: mismatched types
+ --> $DIR/issue-82446.rs:11:9
+ |
+LL | val
+ | ^^^ expected struct `Box`, found reference
+ |
+ = note: expected struct `Box<(dyn MyTrait + 'static)>`
+ found reference `&Box<(dyn MyTrait + 'static)>`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0308`.