1
Fork 0

Remove extra call to upvar_tys

Fixes #78720
This commit is contained in:
Aman Arora 2020-11-04 03:07:40 -05:00 committed by Roxane
parent 349b3b324d
commit 5da2bf197d
3 changed files with 74 additions and 10 deletions

View file

@ -722,11 +722,6 @@ where
// Skip lifetime parameters of the enclosing item(s)
substs.as_closure().tupled_upvars_ty().visit_with(self);
for upvar_ty in substs.as_closure().upvar_tys() {
upvar_ty.visit_with(self);
}
substs.as_closure().sig_as_fn_ptr_ty().visit_with(self);
}
@ -735,11 +730,6 @@ where
// Also skip the witness type, because that has no free regions.
substs.as_generator().tupled_upvars_ty().visit_with(self);
for upvar_ty in substs.as_generator().upvar_tys() {
upvar_ty.visit_with(self);
}
substs.as_generator().return_ty().visit_with(self);
substs.as_generator().yield_ty().visit_with(self);
substs.as_generator().resume_ty().visit_with(self);