Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/lower.rs')
| -rw-r--r-- | crates/hir-ty/src/lower.rs | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/crates/hir-ty/src/lower.rs b/crates/hir-ty/src/lower.rs index 42f7290962..6f7ca4829d 100644 --- a/crates/hir-ty/src/lower.rs +++ b/crates/hir-ty/src/lower.rs @@ -42,8 +42,8 @@ use rustc_ast_ir::Mutability; use rustc_hash::FxHashSet; use rustc_pattern_analysis::Captures; use rustc_type_ir::{ - AliasTyKind, ConstKind, DebruijnIndex, ExistentialPredicate, ExistentialProjection, - ExistentialTraitRef, FnSig, OutlivesPredicate, + AliasTyKind, BoundVarIndexKind, ConstKind, DebruijnIndex, ExistentialPredicate, + ExistentialProjection, ExistentialTraitRef, FnSig, OutlivesPredicate, TyKind::{self}, TypeVisitableExt, inherent::{GenericArg as _, GenericArgs as _, IntoKind as _, Region as _, SliceLike, Ty as _}, @@ -858,11 +858,13 @@ impl<'db, 'a> TyLoweringContext<'db, 'a> { if let Some(bounds) = bounds { let region = match lifetime { Some(it) => match it.kind() { - rustc_type_ir::RegionKind::ReBound(db, var) => Region::new_bound( - self.interner, - db.shifted_out_to_binder(DebruijnIndex::from_u32(2)), - var, - ), + rustc_type_ir::RegionKind::ReBound(BoundVarIndexKind::Bound(db), var) => { + Region::new_bound( + self.interner, + db.shifted_out_to_binder(DebruijnIndex::from_u32(2)), + var, + ) + } _ => it, }, None => Region::new_static(self.interner), |