mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 21:35:20 +00:00
chore: Prefer tracing span shorthand macros
This commit is contained in:
parent
5f3de7863a
commit
27182bb96b
82 changed files with 240 additions and 275 deletions
|
@ -334,7 +334,7 @@ fn parse_macro_expansion(
|
|||
db: &dyn ExpandDatabase,
|
||||
macro_file: MacroFileId,
|
||||
) -> ExpandResult<(Parse<SyntaxNode>, Arc<ExpansionSpanMap>)> {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "parse_macro_expansion").entered();
|
||||
let _p = tracing::info_span!("parse_macro_expansion").entered();
|
||||
let loc = db.lookup_intern_macro_call(macro_file.macro_call_id);
|
||||
let edition = loc.def.edition;
|
||||
let expand_to = loc.expand_to();
|
||||
|
@ -588,7 +588,7 @@ fn macro_expand(
|
|||
macro_call_id: MacroCallId,
|
||||
loc: MacroCallLoc,
|
||||
) -> ExpandResult<(CowArc<tt::Subtree>, MatchedArmIndex)> {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "macro_expand").entered();
|
||||
let _p = tracing::info_span!("macro_expand").entered();
|
||||
|
||||
let (ExpandResult { value: (tt, matched_arm), err }, span) = match loc.def.kind {
|
||||
MacroDefKind::ProcMacro(..) => {
|
||||
|
|
|
@ -809,7 +809,7 @@ impl ExpansionInfo {
|
|||
}
|
||||
|
||||
pub fn new(db: &dyn ExpandDatabase, macro_file: MacroFileId) -> ExpansionInfo {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "ExpansionInfo::new").entered();
|
||||
let _p = tracing::info_span!("ExpansionInfo::new").entered();
|
||||
let loc = db.lookup_intern_macro_call(macro_file.macro_call_id);
|
||||
|
||||
let arg_tt = loc.kind.arg(db);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue