don't take TyCtxt by reference

This commit is contained in:
Bastian Kauschke
2020-09-18 20:49:25 +02:00
parent 2c69266c06
commit 925cd26162
6 changed files with 35 additions and 37 deletions

View File

@@ -623,7 +623,7 @@ impl<'tcx> TyCtxt<'tcx> {
/// Replaces any late-bound regions bound in `value` with
/// free variants attached to `all_outlive_scope`.
pub fn liberate_late_bound_regions<T>(
&self,
self,
all_outlive_scope: DefId,
value: &ty::Binder<T>,
) -> T
@@ -644,7 +644,7 @@ impl<'tcx> TyCtxt<'tcx> {
/// variables and equate `value` with something else, those
/// variables will also be equated.
pub fn collect_constrained_late_bound_regions<T>(
&self,
self,
value: &Binder<T>,
) -> FxHashSet<ty::BoundRegion>
where
@@ -655,7 +655,7 @@ impl<'tcx> TyCtxt<'tcx> {
/// Returns a set of all late-bound regions that appear in `value` anywhere.
pub fn collect_referenced_late_bound_regions<T>(
&self,
self,
value: &Binder<T>,
) -> FxHashSet<ty::BoundRegion>
where
@@ -665,7 +665,7 @@ impl<'tcx> TyCtxt<'tcx> {
}
fn collect_late_bound_regions<T>(
&self,
self,
value: &Binder<T>,
just_constraint: bool,
) -> FxHashSet<ty::BoundRegion>