diff --git a/compiler/rustc_error_codes/src/error_codes/E0373.md b/compiler/rustc_error_codes/src/error_codes/E0373.md index effa597aad918..d4d26007aa50e 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0373.md +++ b/compiler/rustc_error_codes/src/error_codes/E0373.md @@ -70,4 +70,4 @@ fn spawn(future: F) { Similarly to closures, `async` blocks are not executed immediately and may capture closed-over data by reference. For more information, see -https://rust-lang.github.io/async-book/03_async_await/01_chapter.html. +. diff --git a/compiler/rustc_error_codes/src/error_codes/E0378.md b/compiler/rustc_error_codes/src/error_codes/E0378.md index c6fe997f3dcfc..7d939b99b04eb 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0378.md +++ b/compiler/rustc_error_codes/src/error_codes/E0378.md @@ -20,7 +20,7 @@ where The `DispatchFromDyn` trait currently can only be implemented for builtin pointer types and structs that are newtype wrappers around them -— that is, the struct must have only one field (except for`PhantomData`), +— that is, the struct must have only one field (except for `PhantomData`), and that field must itself implement `DispatchFromDyn`. ``` diff --git a/compiler/rustc_errors/src/lib.rs b/compiler/rustc_errors/src/lib.rs index 2086d4030f905..2a850d9303c71 100644 --- a/compiler/rustc_errors/src/lib.rs +++ b/compiler/rustc_errors/src/lib.rs @@ -15,6 +15,7 @@ #![feature(box_patterns)] #![feature(error_reporter)] #![feature(extract_if)] +#![feature(if_let_guard)] #![feature(let_chains)] #![feature(negative_impls)] #![feature(never_type)] diff --git a/compiler/rustc_errors/src/markdown/parse.rs b/compiler/rustc_errors/src/markdown/parse.rs index 67e4963fddf7f..69e7120e7149b 100644 --- a/compiler/rustc_errors/src/markdown/parse.rs +++ b/compiler/rustc_errors/src/markdown/parse.rs @@ -10,15 +10,15 @@ const CBK: &[u8] = b"```"; const CIL: &[u8] = b"`"; const CMT_E: &[u8] = b"-->"; const CMT_S: &[u8] = b" $DIR/closure-no-fn-3.rs:6:33 + | +LL | let baz: fn() -> u8 = (|| { b }) as fn() -> u8; + | ^ `b` captured here error: aborting due to 1 previous error