summaryrefslogtreecommitdiff
path: root/lsp.c
diff options
context:
space:
mode:
authorpommicket <pommicket@gmail.com>2022-12-27 23:15:27 -0500
committerpommicket <pommicket@gmail.com>2022-12-27 23:15:27 -0500
commit47adb1651d35dcc545850916c4a16b747901dba5 (patch)
treef329f973016d15f17b0437202c26f4ca93a0b7be /lsp.c
parente112a90ff73f7f407ed2251f905565713c237bc1 (diff)
more signature help
Diffstat (limited to 'lsp.c')
-rw-r--r--lsp.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/lsp.c b/lsp.c
index 9ec7ad7..bd6348a 100644
--- a/lsp.c
+++ b/lsp.c
@@ -1,5 +1,5 @@
// print server-to-client communication
-#define LSP_SHOW_S2C 0
+#define LSP_SHOW_S2C 1
// print client-to-server communication
#define LSP_SHOW_C2S 0
@@ -42,6 +42,7 @@ static void lsp_request_free(LSPRequest *r) {
case LSP_REQUEST_SHUTDOWN:
case LSP_REQUEST_EXIT:
case LSP_REQUEST_COMPLETION:
+ case LSP_REQUEST_SIGNATURE_HELP:
case LSP_REQUEST_DID_CLOSE:
case LSP_REQUEST_WORKSPACE_FOLDERS:
break;
@@ -74,6 +75,9 @@ static void lsp_response_free(LSPResponse *r) {
case LSP_REQUEST_COMPLETION:
arr_free(r->data.completion.items);
break;
+ case LSP_REQUEST_SIGNATURE_HELP:
+ arr_free(r->data.signature_help.signatures);
+ break;
default:
break;
}
@@ -130,6 +134,8 @@ static bool lsp_supports_request(LSP *lsp, const LSPRequest *request) {
return true;
case LSP_REQUEST_COMPLETION:
return cap->completion_support;
+ case LSP_REQUEST_SIGNATURE_HELP:
+ return cap->signature_help_support;
case LSP_REQUEST_DID_CHANGE_WORKSPACE_FOLDERS:
return cap->workspace_folders_support;
}