Merge pull request #1197 from Techatrix/invalidate-analysis-cache
invalidate Analyser on didClose
This commit is contained in:
commit
2ff2593a86
@ -805,6 +805,9 @@ fn saveDocumentHandler(server: *Server, notification: types.DidSaveTextDocumentP
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn closeDocumentHandler(server: *Server, notification: types.DidCloseTextDocumentParams) error{}!void {
|
fn closeDocumentHandler(server: *Server, notification: types.DidCloseTextDocumentParams) error{}!void {
|
||||||
|
// cached type info may point to a closed handle
|
||||||
|
server.analyser.invalidate();
|
||||||
|
|
||||||
server.document_store.closeDocument(notification.textDocument.uri);
|
server.document_store.closeDocument(notification.textDocument.uri);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user