diff options
author | pommicket <pommicket@gmail.com> | 2023-09-09 21:19:26 -0400 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2023-09-09 21:19:26 -0400 |
commit | 16fbe87451b0ca3e8fa35fd04e0afbfab368ea65 (patch) | |
tree | dcd4c1e37b4a89173e23047f644df94a9ca92399 /lsp.c | |
parent | 0dcfd5a4f1fd865c24c01b17b214e1f72e4c06fe (diff) |
fix handling of TextEdit[]
i hate microsoft so much
Diffstat (limited to 'lsp.c')
-rw-r--r-- | lsp.c | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -159,9 +159,15 @@ void lsp_response_free(LSPResponse *r) { case LSP_REQUEST_WORKSPACE_SYMBOLS: arr_free(r->data.workspace_symbols.symbols); break; - case LSP_REQUEST_RENAME: + case LSP_REQUEST_RENAME: { + LSPResponseRename *rename = &r->data.rename; + arr_foreach_ptr(rename->changes, LSPWorkspaceChange, c) { + if (c->type == LSP_CHANGE_EDITS) { + arr_free(c->data.edit.edits); + } + } arr_free(r->data.rename.changes); - break; + } break; case LSP_REQUEST_HIGHLIGHT: arr_free(r->data.highlight.highlights); break; |