Skip to content

Commit d99e01f

Browse files
committed
resolve: Remove item_attrs_untracked
1 parent f28f77f commit d99e01f

File tree

2 files changed

+1
-12
lines changed

2 files changed

+1
-12
lines changed

compiler/rustc_metadata/src/rmeta/decoder/cstore_impl.rs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -576,14 +576,6 @@ impl CStore {
576576
self.get_crate_data(cnum).num_def_ids()
577577
}
578578

579-
pub fn item_attrs_untracked<'a>(
580-
&'a self,
581-
def_id: DefId,
582-
sess: &'a Session,
583-
) -> impl Iterator<Item = ast::Attribute> + 'a {
584-
self.get_crate_data(def_id.krate).get_item_attrs(def_id.index, sess)
585-
}
586-
587579
pub fn get_proc_macro_quoted_span_untracked(
588580
&self,
589581
cnum: CrateNum,

compiler/rustc_resolve/src/lib.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1906,10 +1906,7 @@ impl<'a, 'tcx> Resolver<'a, 'tcx> {
19061906
return v.clone();
19071907
}
19081908

1909-
let attr = self
1910-
.cstore()
1911-
.item_attrs_untracked(def_id, self.tcx.sess)
1912-
.find(|a| a.has_name(sym::rustc_legacy_const_generics))?;
1909+
let attr = self.tcx.get_attr(def_id, sym::rustc_legacy_const_generics)?;
19131910
let mut ret = Vec::new();
19141911
for meta in attr.meta_item_list()? {
19151912
match meta.lit()?.kind {

0 commit comments

Comments
 (0)