diff options
| author | Jubilee <46493976+workingjubilee@users.noreply.github.com> | 2023-12-09 00:48:11 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-09 00:48:11 -0800 |
| commit | 402cfb17f76e54392b2e12ebfe89bf5bbae08228 (patch) | |
| tree | 541fac9fc79fa89c230cc536686904d0a69c1de3 /compiler/rustc_trait_selection/src | |
| parent | ad9114125dac32747570c8ba37abaab557030003 (diff) | |
| parent | 384a49edd0cddba275e6be73acbb9a7c37ec03b2 (diff) | |
| download | rust-402cfb17f76e54392b2e12ebfe89bf5bbae08228.tar.gz rust-402cfb17f76e54392b2e12ebfe89bf5bbae08228.zip | |
Rollup merge of #118762 - compiler-errors:gen-nits, r=eholk
Some more minor `async gen`-related nits Tiny tweaks found after `async gen` pr landed r? eholk
Diffstat (limited to 'compiler/rustc_trait_selection/src')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs b/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs index 7bf37cf7980..95ffd07e397 100644 --- a/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs +++ b/compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs @@ -3144,10 +3144,9 @@ impl<'tcx> TypeErrCtxtExt<'tcx> for TypeErrCtxt<'_, 'tcx> { let what = match self.tcx.coroutine_kind(coroutine_def_id) { None | Some(hir::CoroutineKind::Coroutine) - | Some(hir::CoroutineKind::Gen(_)) - // FIXME(gen_blocks): This could be yield or await... - | Some(hir::CoroutineKind::AsyncGen(_)) => "yield", + | Some(hir::CoroutineKind::Gen(_)) => "yield", Some(hir::CoroutineKind::Async(..)) => "await", + Some(hir::CoroutineKind::AsyncGen(_)) => "yield`/`await", }; err.note(format!( "all values live across `{what}` must have a statically known size" |
