mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 04:44:57 +00:00
chore: fix a few spans without .entered()
This commit is contained in:
parent
d07f0240fd
commit
5ba37f3f8e
6 changed files with 16 additions and 15 deletions
|
@ -118,7 +118,7 @@ pub(super) struct SourceToDefCtx<'a, 'b> {
|
|||
|
||||
impl SourceToDefCtx<'_, '_> {
|
||||
pub(super) fn file_to_def(&self, file: FileId) -> SmallVec<[ModuleId; 1]> {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "SourceBinder::file_to_module_def");
|
||||
let _p = tracing::span!(tracing::Level::INFO, "SourceBinder::file_to_module_def").entered();
|
||||
let mut mods = SmallVec::new();
|
||||
for &crate_id in self.db.relevant_crates(file).iter() {
|
||||
// FIXME: inner items
|
||||
|
@ -133,7 +133,7 @@ impl SourceToDefCtx<'_, '_> {
|
|||
}
|
||||
|
||||
pub(super) fn module_to_def(&mut self, src: InFile<ast::Module>) -> Option<ModuleId> {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "module_to_def");
|
||||
let _p = tracing::span!(tracing::Level::INFO, "module_to_def").entered();
|
||||
let parent_declaration = src
|
||||
.syntax()
|
||||
.ancestors_with_macros_skip_attr_item(self.db.upcast())
|
||||
|
@ -158,7 +158,7 @@ impl SourceToDefCtx<'_, '_> {
|
|||
}
|
||||
|
||||
pub(super) fn source_file_to_def(&self, src: InFile<ast::SourceFile>) -> Option<ModuleId> {
|
||||
let _p = tracing::span!(tracing::Level::INFO, "source_file_to_def");
|
||||
let _p = tracing::span!(tracing::Level::INFO, "source_file_to_def").entered();
|
||||
let file_id = src.file_id.original_file(self.db.upcast());
|
||||
self.file_to_def(file_id).first().copied()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue