mirror of
https://github.com/Myriad-Dreamin/tinymist.git
synced 2025-11-23 12:46:43 +00:00
dev: cache expression information correctly (#736)
* dev: cache expression information correctly * rev
This commit is contained in:
parent
2c38695b6f
commit
1d49e110e2
18 changed files with 430 additions and 187 deletions
|
|
@ -310,7 +310,7 @@ fn format_ty(ty: Option<&Ty>, doc_ty: Option<&mut ShowTypeRepr>) -> TypeRepr {
|
|||
|
||||
pub(crate) fn variable_docs(ctx: &mut AnalysisContext, pos: &LinkedNode) -> Option<VarDocs> {
|
||||
let source = ctx.source_by_id(pos.span().id()?).ok()?;
|
||||
let type_info = ctx.type_check(&source)?;
|
||||
let type_info = ctx.type_check(&source);
|
||||
let ty = type_info.type_of_span(pos.span())?;
|
||||
|
||||
// todo multiple sources
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue