Make LowerPolyBounds take an IntoIterator
This commit is contained in:
parent
bfab34af4c
commit
b922ae07b3
2 changed files with 5 additions and 5 deletions
|
@ -267,7 +267,7 @@ fn gather_explicit_predicates_of(tcx: TyCtxt<'_>, def_id: LocalDefId) -> ty::Gen
|
||||||
let mut bounds = Bounds::default();
|
let mut bounds = Bounds::default();
|
||||||
icx.lowerer().lower_poly_bounds(
|
icx.lowerer().lower_poly_bounds(
|
||||||
ty,
|
ty,
|
||||||
bound_pred.bounds.iter(),
|
bound_pred.bounds,
|
||||||
&mut bounds,
|
&mut bounds,
|
||||||
bound_vars,
|
bound_vars,
|
||||||
PredicateFilter::All,
|
PredicateFilter::All,
|
||||||
|
@ -836,7 +836,7 @@ impl<'tcx> ItemCtxt<'tcx> {
|
||||||
let bound_vars = self.tcx.late_bound_vars(predicate.hir_id);
|
let bound_vars = self.tcx.late_bound_vars(predicate.hir_id);
|
||||||
self.lowerer().lower_poly_bounds(
|
self.lowerer().lower_poly_bounds(
|
||||||
bound_ty,
|
bound_ty,
|
||||||
predicate.bounds.iter(),
|
predicate.bounds,
|
||||||
&mut bounds,
|
&mut bounds,
|
||||||
bound_vars,
|
bound_vars,
|
||||||
filter,
|
filter,
|
||||||
|
|
|
@ -142,7 +142,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
|
||||||
/// There is an implied binder around `param_ty` and `hir_bounds`.
|
/// There is an implied binder around `param_ty` and `hir_bounds`.
|
||||||
/// See `lower_poly_trait_ref` for more details.
|
/// See `lower_poly_trait_ref` for more details.
|
||||||
#[instrument(level = "debug", skip(self, hir_bounds, bounds))]
|
#[instrument(level = "debug", skip(self, hir_bounds, bounds))]
|
||||||
pub(crate) fn lower_poly_bounds<'hir, I: Iterator<Item = &'hir hir::GenericBound<'tcx>>>(
|
pub(crate) fn lower_poly_bounds<'hir, I: IntoIterator<Item = &'hir hir::GenericBound<'tcx>>>(
|
||||||
&self,
|
&self,
|
||||||
param_ty: Ty<'tcx>,
|
param_ty: Ty<'tcx>,
|
||||||
hir_bounds: I,
|
hir_bounds: I,
|
||||||
|
@ -231,7 +231,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
|
||||||
|
|
||||||
self.lower_poly_bounds(
|
self.lower_poly_bounds(
|
||||||
param_ty,
|
param_ty,
|
||||||
hir_bounds.iter(),
|
hir_bounds,
|
||||||
&mut bounds,
|
&mut bounds,
|
||||||
ty::List::empty(),
|
ty::List::empty(),
|
||||||
predicate_filter,
|
predicate_filter,
|
||||||
|
@ -446,7 +446,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
|
||||||
Ty::new_alias(tcx, ty::Projection, projection_ty.skip_binder());
|
Ty::new_alias(tcx, ty::Projection, projection_ty.skip_binder());
|
||||||
self.lower_poly_bounds(
|
self.lower_poly_bounds(
|
||||||
param_ty,
|
param_ty,
|
||||||
hir_bounds.iter(),
|
hir_bounds,
|
||||||
bounds,
|
bounds,
|
||||||
projection_ty.bound_vars(),
|
projection_ty.bound_vars(),
|
||||||
predicate_filter,
|
predicate_filter,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue