diff options
author | pommicket <pommicket@gmail.com> | 2023-09-07 14:38:49 -0400 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2023-09-07 14:38:49 -0400 |
commit | 815d652b570f53c989f62d0c7db847d7d6dfd940 (patch) | |
tree | c977583cfcc5b682a8cee5546bcf3c837014df1b /lsp.c | |
parent | bb4b7774aabc2686f936935b02899b1aa0bf1f2b (diff) |
textDocument/publishDiagnostics parsing
Diffstat (limited to 'lsp.c')
-rw-r--r-- | lsp.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -119,6 +119,11 @@ void lsp_request_free(LSPRequest *r) { case LSP_REQUEST_DOCUMENT_LINK: case LSP_REQUEST_CONFIGURATION: case LSP_REQUEST_DID_OPEN: + break; + case LSP_REQUEST_PUBLISH_DIAGNOSTICS: { + LSPRequestPublishDiagnostics *pub = &r->data.publish_diagnostics; + arr_free(pub->diagnostics); + } break; case LSP_REQUEST_SHOW_MESSAGE: case LSP_REQUEST_LOG_MESSAGE: case LSP_REQUEST_RENAME: @@ -209,6 +214,7 @@ static bool lsp_supports_request(LSP *lsp, const LSPRequest *request) { case LSP_REQUEST_SHOW_MESSAGE: case LSP_REQUEST_LOG_MESSAGE: case LSP_REQUEST_WORKSPACE_FOLDERS: + case LSP_REQUEST_PUBLISH_DIAGNOSTICS: return false; case LSP_REQUEST_INITIALIZE: case LSP_REQUEST_INITIALIZED: @@ -268,6 +274,7 @@ static bool request_type_is_notification(LSPRequestType type) { case LSP_REQUEST_DID_CHANGE: case LSP_REQUEST_DID_CHANGE_WORKSPACE_FOLDERS: case LSP_REQUEST_CONFIGURATION: + case LSP_REQUEST_PUBLISH_DIAGNOSTICS: return true; case LSP_REQUEST_INITIALIZE: case LSP_REQUEST_SHUTDOWN: |