Treat BlockExpr as a potential module origin

This commit is contained in:
Jonas Schievink 2021-01-20 20:05:48 +01:00
parent 7d5ed18c42
commit 82146737ac
8 changed files with 44 additions and 7 deletions

View file

@ -321,6 +321,7 @@ fn hover_for_definition(db: &RootDatabase, def: Definition) -> Option<Markup> {
match it.definition_source(db).value {
ModuleSource::Module(it) => it.short_label(),
ModuleSource::SourceFile(it) => it.short_label(),
ModuleSource::BlockExpr(it) => it.short_label(),
},
mod_path,
),