mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-23 21:23:20 +00:00
Rollup merge of #83108 - jyn514:remove-unused, r=estebank
Remove unused `opt_local_def_id_to_hir_id` function Found while investigating #82933 - all LocalDefIds are expected to have HirIds, there's no point in pretending otherwise.
This commit is contained in:
commit
f1061d1dff
@ -342,11 +342,6 @@ impl Definitions {
|
||||
self.def_id_to_hir_id[id].unwrap()
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn opt_local_def_id_to_hir_id(&self, id: LocalDefId) -> Option<hir::HirId> {
|
||||
self.def_id_to_hir_id[id]
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn opt_hir_id_to_local_def_id(&self, hir_id: hir::HirId) -> Option<LocalDefId> {
|
||||
self.hir_id_to_def_id.get(&hir_id).copied()
|
||||
|
@ -180,11 +180,6 @@ impl<'hir> Map<'hir> {
|
||||
self.tcx.definitions.local_def_id_to_hir_id(def_id)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn opt_local_def_id_to_hir_id(&self, def_id: LocalDefId) -> Option<HirId> {
|
||||
self.tcx.definitions.opt_local_def_id_to_hir_id(def_id)
|
||||
}
|
||||
|
||||
pub fn iter_local_def_id(&self) -> impl Iterator<Item = LocalDefId> + '_ {
|
||||
self.tcx.definitions.iter_local_def_id()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user