use Source more

This commit is contained in:
Aleksey Kladov 2019-06-11 03:17:29 +03:00
parent 91c120ccea
commit 2a1fe26b6d
7 changed files with 39 additions and 64 deletions

View file

@ -77,8 +77,8 @@ pub(crate) fn documentation_query(
FieldSource::Pos(..) => return None,
},
DocDef::Struct(it) => docs_from_ast(&*it.source(db).ast),
DocDef::Enum(it) => docs_from_ast(&*it.source(db).1),
DocDef::EnumVariant(it) => docs_from_ast(&*it.source(db).1),
DocDef::Enum(it) => docs_from_ast(&*it.source(db).ast),
DocDef::EnumVariant(it) => docs_from_ast(&*it.source(db).ast),
DocDef::Static(it) => docs_from_ast(&*it.source(db).1),
DocDef::Const(it) => docs_from_ast(&*it.source(db).1),
DocDef::Function(it) => docs_from_ast(&*it.source(db).1),