aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/lsp/buf.lua
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/lua/vim/lsp/buf.lua')
-rw-r--r--runtime/lua/vim/lsp/buf.lua15
1 files changed, 8 insertions, 7 deletions
diff --git a/runtime/lua/vim/lsp/buf.lua b/runtime/lua/vim/lsp/buf.lua
index bac66b671d..8ae0e0cde3 100644
--- a/runtime/lua/vim/lsp/buf.lua
+++ b/runtime/lua/vim/lsp/buf.lua
@@ -13,10 +13,11 @@ local M = {}
---@param params (table|nil) Parameters to send to the server
---@param handler (function|nil) See |lsp-handler|. Follows |lsp-handler-resolution|
--
----@returns 2-tuple:
---- - Map of client-id:request-id pairs for all successful requests.
---- - Function which can be used to cancel all the requests. You could instead
---- iterate all clients and call their `cancel_request()` methods.
+---@return table<integer, integer> client_request_ids Map of client-id:request-id pairs
+---for all successful requests.
+---@return function _cancel_all_requests Function which can be used to
+---cancel all the requests. You could instead
+---iterate all clients and call their `cancel_request()` methods.
---
---@see |vim.lsp.buf_request()|
local function request(method, params, handler)
@@ -30,7 +31,7 @@ end
--- Checks whether the language servers attached to the current buffer are
--- ready.
---
----@returns `true` if server responds.
+---@return boolean if server responds.
---@deprecated
function M.server_ready()
vim.deprecate('vim.lsp.buf.server_ready', nil, '0.10.0')
@@ -108,7 +109,7 @@ end
--- Retrieves the completion items at the current cursor position. Can only be
--- called in Insert mode.
---
----@param context (context support not yet implemented) Additional information
+---@param context table (context support not yet implemented) Additional information
--- about the context in which a completion was triggered (how it was triggered,
--- and by which trigger character, if applicable)
---
@@ -549,7 +550,7 @@ end
--- call, the user is prompted to enter a string on the command line. An empty
--- string means no filtering is done.
---
----@param query (string, optional)
+---@param query string|nil optional
---@param options table|nil additional options
--- - on_list: (function) handler for list results. See |lsp-on-list-handler|
function M.workspace_symbol(query, options)