diff options
| author | Michael Goulet <michael@errs.io> | 2023-12-08 21:46:08 +0000 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2023-12-08 21:46:39 +0000 |
| commit | d5dcd85376925f5f3d5fdbdcc9467165fe2c0b18 (patch) | |
| tree | 641addd2dba0ae0555062a7ee14a7b9cf58a36fd | |
| parent | 8361a7288e42d303890a63092fe5fd276819c79d (diff) | |
| download | rust-d5dcd85376925f5f3d5fdbdcc9467165fe2c0b18.tar.gz rust-d5dcd85376925f5f3d5fdbdcc9467165fe2c0b18.zip | |
More nits
| -rw-r--r-- | compiler/rustc_ast_lowering/src/lib.rs | 3 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/error_reporting/suggestions.rs | 5 |
2 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_ast_lowering/src/lib.rs b/compiler/rustc_ast_lowering/src/lib.rs index 753650f7324..0c71165deed 100644 --- a/compiler/rustc_ast_lowering/src/lib.rs +++ b/compiler/rustc_ast_lowering/src/lib.rs @@ -177,7 +177,8 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> { } else { [sym::gen_future].into() }, - // FIXME(gen_blocks): how does `closure_track_caller` + // FIXME(gen_blocks): how does `closure_track_caller`/`async_fn_track_caller` + // interact with `gen`/`async gen` blocks allow_async_iterator: [sym::gen_future, sym::async_iterator].into(), generics_def_id_map: Default::default(), host_param_id: None, 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" |
