aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/lsp/_changetracking.lua
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2024-11-14 11:53:20 +0000
committerLewis Russell <me@lewisr.dev>2024-11-20 08:51:45 +0000
commit454ae672aad172a299dcff7c33c5e61a3b631c90 (patch)
tree0a7116ed6967563ca724cc3169e4ec72f40b70c0 /runtime/lua/vim/lsp/_changetracking.lua
parentf55c842ec7eabd2e12749411babdcadba47438bc (diff)
downloadrneovim-454ae672aad172a299dcff7c33c5e61a3b631c90.tar.gz
rneovim-454ae672aad172a299dcff7c33c5e61a3b631c90.tar.bz2
rneovim-454ae672aad172a299dcff7c33c5e61a3b631c90.zip
feat(lsp): deprecate non-method client functions
Deprecated: - `client.request()` -> `client:request()` - `client.request_sync()` -> `client:request_sync()` - `client.notify()` -> `client:notify()` - `client.cancel_request()` -> `client:cancel_request()` - `client.stop()` -> `client:stop()` - `client.is_stopped()` `client:is_stopped()` - `client.supports_method()` -> `client:supports_method()` - `client.on_attach()` -> `client:on_attach()` Fixed docgen to link class fields to the full function doc.
Diffstat (limited to 'runtime/lua/vim/lsp/_changetracking.lua')
-rw-r--r--runtime/lua/vim/lsp/_changetracking.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/runtime/lua/vim/lsp/_changetracking.lua b/runtime/lua/vim/lsp/_changetracking.lua
index b2be53269f..8588502697 100644
--- a/runtime/lua/vim/lsp/_changetracking.lua
+++ b/runtime/lua/vim/lsp/_changetracking.lua
@@ -40,7 +40,7 @@ local M = {}
--- @class vim.lsp.CTGroupState
--- @field buffers table<integer,vim.lsp.CTBufferState>
--- @field debounce integer debounce duration in ms
---- @field clients table<integer, table> clients using this state. {client_id, client}
+--- @field clients table<integer, vim.lsp.Client> clients using this state. {client_id, client}
---@param group vim.lsp.CTGroup
---@return string
@@ -273,8 +273,8 @@ local function send_changes(bufnr, sync_kind, state, buf_state)
end
local uri = vim.uri_from_bufnr(bufnr)
for _, client in pairs(state.clients) do
- if not client.is_stopped() and vim.lsp.buf_is_attached(bufnr, client.id) then
- client.notify(protocol.Methods.textDocument_didChange, {
+ if not client:is_stopped() and vim.lsp.buf_is_attached(bufnr, client.id) then
+ client:notify(protocol.Methods.textDocument_didChange, {
textDocument = {
uri = uri,
version = util.buf_versions[bufnr],