change fn_sig query to use EarlyBinder; remove bound_fn_sig query; add EarlyBinder to fn_sig in metadata

This commit is contained in:
Kyle Matsuda
2023-01-18 16:52:47 -07:00
parent e982971ff2
commit c2414dfaa4
80 changed files with 142 additions and 152 deletions

View File

@@ -643,10 +643,6 @@ impl<'tcx> TyCtxt<'tcx> {
ty::EarlyBinder(self.collect_return_position_impl_trait_in_trait_tys(def_id))
}
pub fn bound_fn_sig(self, def_id: DefId) -> ty::EarlyBinder<ty::PolyFnSig<'tcx>> {
ty::EarlyBinder(self.fn_sig(def_id))
}
pub fn bound_explicit_item_bounds(
self,
def_id: DefId,
@@ -1315,10 +1311,7 @@ pub fn is_doc_notable_trait(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
/// Determines whether an item is an intrinsic by Abi.
pub fn is_intrinsic(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
matches!(
tcx.bound_fn_sig(def_id).skip_binder().abi(),
Abi::RustIntrinsic | Abi::PlatformIntrinsic
)
matches!(tcx.fn_sig(def_id).skip_binder().abi(), Abi::RustIntrinsic | Abi::PlatformIntrinsic)
}
pub fn provide(providers: &mut ty::query::Providers) {