@@ -345,7 +345,7 @@ impl<'tcx> ClosureSubsts<'tcx> {
345345 self ,
346346 def_id : DefId ,
347347 tcx : TyCtxt < ' _ > ,
348- ) -> impl Iterator < Item = Ty < ' tcx > > + ExactSizeIterator + ' tcx {
348+ ) -> impl Iterator < Item = Ty < ' tcx > > + ' tcx {
349349 let SplitClosureSubsts { upvar_kinds, .. } = self . split ( def_id, tcx) ;
350350 upvar_kinds. iter ( ) . map ( |t| {
351351 if let GenericArgKind :: Type ( ty) = t. unpack ( ) {
@@ -433,7 +433,7 @@ impl<'tcx> GeneratorSubsts<'tcx> {
433433 self ,
434434 def_id : DefId ,
435435 tcx : TyCtxt < ' _ > ,
436- ) -> impl Iterator < Item = Ty < ' tcx > > + ExactSizeIterator + ' tcx {
436+ ) -> impl Iterator < Item = Ty < ' tcx > > + ' tcx {
437437 let SplitGeneratorSubsts { upvar_kinds, .. } = self . split ( def_id, tcx) ;
438438 upvar_kinds. iter ( ) . map ( |t| {
439439 if let GenericArgKind :: Type ( ty) = t. unpack ( ) {
@@ -551,7 +551,7 @@ impl<'tcx> GeneratorSubsts<'tcx> {
551551 self ,
552552 def_id : DefId ,
553553 tcx : TyCtxt < ' tcx > ,
554- ) -> impl Iterator < Item = impl Iterator < Item = Ty < ' tcx > > + ExactSizeIterator + Captures < ' tcx > > {
554+ ) -> impl Iterator < Item = impl Iterator < Item = Ty < ' tcx > > + Captures < ' tcx > > {
555555 let layout = tcx. generator_layout ( def_id) ;
556556 layout. variant_fields . iter ( ) . map ( move |variant| {
557557 variant. iter ( ) . map ( move |field| {
@@ -563,9 +563,7 @@ impl<'tcx> GeneratorSubsts<'tcx> {
563563 /// This is the types of the fields of a generator which are not stored in a
564564 /// variant.
565565 #[ inline]
566- pub fn prefix_tys ( self , def_id : DefId , tcx : TyCtxt < ' tcx > )
567- -> impl Iterator < Item = Ty < ' tcx > > + ExactSizeIterator
568- {
566+ pub fn prefix_tys ( self , def_id : DefId , tcx : TyCtxt < ' tcx > ) -> impl Iterator < Item = Ty < ' tcx > > {
569567 self . upvar_tys ( def_id, tcx)
570568 }
571569}
@@ -582,7 +580,7 @@ impl<'tcx> UpvarSubsts<'tcx> {
582580 self ,
583581 def_id : DefId ,
584582 tcx : TyCtxt < ' tcx > ,
585- ) -> impl Iterator < Item = Ty < ' tcx > > + ExactSizeIterator + ' tcx {
583+ ) -> impl Iterator < Item = Ty < ' tcx > > + ' tcx {
586584 let upvar_kinds = match self {
587585 UpvarSubsts :: Closure ( substs) => substs. as_closure ( ) . split ( def_id, tcx) . upvar_kinds ,
588586 UpvarSubsts :: Generator ( substs) => substs. as_generator ( ) . split ( def_id, tcx) . upvar_kinds ,
0 commit comments