lower attr spans and inline some functions to hopefully mitigate perf regressions

This commit is contained in:
Jana Dönszelmann 2025-02-24 14:07:34 +01:00
parent 2f0652745d
commit 4daa35ce33
No known key found for this signature in database
5 changed files with 52 additions and 13 deletions

View file

@ -142,7 +142,12 @@ impl<'a, 'ra, 'tcx> visit::Visitor<'a> for DefCollector<'a, 'ra, 'tcx> {
self.resolver.tcx.features(),
Vec::new(),
);
let attrs = parser.parse_attribute_list(&i.attrs, i.span, OmitDoc::Skip);
let attrs = parser.parse_attribute_list(
&i.attrs,
i.span,
OmitDoc::Skip,
std::convert::identity,
);
let macro_data =
self.resolver.compile_macro(def, i.ident, &attrs, i.span, i.id, edition);