@@ -67,7 +67,7 @@ struct NeedsDropTypes<'tcx, F> {
6767 tcx : TyCtxt < ' tcx > ,
6868 param_env : ty:: ParamEnv < ' tcx > ,
6969 // Whether to reveal coroutine witnesses, this is set
70- // to `false` unless we compute `needs_drop` for a generator witness.
70+ // to `false` unless we compute `needs_drop` for a coroutine witness.
7171 reveal_coroutine_witnesses : bool ,
7272 query_ty : Ty < ' tcx > ,
7373 seen_tys : FxHashSet < Ty < ' tcx > > ,
@@ -138,11 +138,11 @@ where
138138 // computed on MIR, while this very method is used to build MIR.
139139 // To avoid cycles, we consider that coroutines always require drop.
140140 //
141- // HACK: Because we erase regions contained in the generator witness, we
141+ // HACK: Because we erase regions contained in the coroutine witness, we
142142 // have to conservatively assume that every region captured by the
143- // generator has to be live when dropped. This results in a lot of
143+ // coroutine has to be live when dropped. This results in a lot of
144144 // undesirable borrowck errors. During borrowck, we call `needs_drop`
145- // for the generator witness and check whether any of the contained types
145+ // for the coroutine witness and check whether any of the contained types
146146 // need to be dropped, and only require the captured types to be live
147147 // if they do.
148148 ty:: Coroutine ( _, args, _) => {
0 commit comments