diff options
| author | Michael Goulet <michael@errs.io> | 2024-05-26 20:03:47 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-05-26 20:04:05 -0400 |
| commit | bbcdb4fd3e4df3554e6d406a2f2e9e47114521f6 (patch) | |
| tree | 4c6258665a4b80409bea6c8582e0a8fad6cee202 /compiler/rustc_ty_utils/src | |
| parent | bdbbb6c6a718d4d196131aa16bafb60e850311d9 (diff) | |
| download | rust-bbcdb4fd3e4df3554e6d406a2f2e9e47114521f6.tar.gz rust-bbcdb4fd3e4df3554e6d406a2f2e9e47114521f6.zip | |
Give EarlyBinder a tcx parameter
We are gonna need it to uplift EarlyBinder
Diffstat (limited to 'compiler/rustc_ty_utils/src')
| -rw-r--r-- | compiler/rustc_ty_utils/src/consts.rs | 6 | ||||
| -rw-r--r-- | compiler/rustc_ty_utils/src/ty.rs | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/compiler/rustc_ty_utils/src/consts.rs b/compiler/rustc_ty_utils/src/consts.rs index 67ffb8a58b5..58447f6d6a3 100644 --- a/compiler/rustc_ty_utils/src/consts.rs +++ b/compiler/rustc_ty_utils/src/consts.rs @@ -398,10 +398,10 @@ impl<'a, 'tcx> visit::Visitor<'a, 'tcx> for IsThirPolymorphic<'a, 'tcx> { } /// Builds an abstract const, do not use this directly, but use `AbstractConst::new` instead. -fn thir_abstract_const( - tcx: TyCtxt<'_>, +fn thir_abstract_const<'tcx>( + tcx: TyCtxt<'tcx>, def: LocalDefId, -) -> Result<Option<ty::EarlyBinder<ty::Const<'_>>>, ErrorGuaranteed> { +) -> Result<Option<ty::EarlyBinder<'tcx, ty::Const<'tcx>>>, ErrorGuaranteed> { if !tcx.features().generic_const_exprs { return Ok(None); } diff --git a/compiler/rustc_ty_utils/src/ty.rs b/compiler/rustc_ty_utils/src/ty.rs index 617e8a54365..38950c97c9d 100644 --- a/compiler/rustc_ty_utils/src/ty.rs +++ b/compiler/rustc_ty_utils/src/ty.rs @@ -77,7 +77,7 @@ fn defaultness(tcx: TyCtxt<'_>, def_id: LocalDefId) -> hir::Defaultness { fn adt_sized_constraint<'tcx>( tcx: TyCtxt<'tcx>, def_id: DefId, -) -> Option<ty::EarlyBinder<Ty<'tcx>>> { +) -> Option<ty::EarlyBinder<'tcx, Ty<'tcx>>> { if let Some(def_id) = def_id.as_local() { if let ty::Representability::Infinite(_) = tcx.representability(def_id) { return None; @@ -253,7 +253,7 @@ fn param_env_reveal_all_normalized(tcx: TyCtxt<'_>, def_id: DefId) -> ty::ParamE fn self_ty_of_trait_impl_enabling_order_dep_trait_object_hack( tcx: TyCtxt<'_>, def_id: DefId, -) -> Option<EarlyBinder<Ty<'_>>> { +) -> Option<EarlyBinder<'_, Ty<'_>>> { let impl_ = tcx.impl_trait_header(def_id).unwrap_or_else(|| bug!("called on inherent impl {def_id:?}")); |
