diff options
author | Tom Praschan <13141438+tom-anders@users.noreply.github.com> | 2024-06-24 16:54:56 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-24 07:54:56 -0700 |
commit | 5581a95534e44b8714e715c925c9de2d95ae1c21 (patch) | |
tree | 0aa6443467f9f103ff95b591c3296d4e1b394276 /runtime/lua/vim/lsp/protocol.lua | |
parent | b0e59909075a582fbcf12b4c8a3ec1bff12c4eea (diff) | |
download | rneovim-5581a95534e44b8714e715c925c9de2d95ae1c21.tar.gz rneovim-5581a95534e44b8714e715c925c9de2d95ae1c21.tar.bz2 rneovim-5581a95534e44b8714e715c925c9de2d95ae1c21.zip |
feat(lsp): vim.lsp.buf.format() supports textDocument/rangesFormatting #27323
While this relies on a proposed LSP 3.18 feature, it's fully backwards
compatible, so IMO there's no harm in adding this already.
Looks like some servers already support for this e.g.
- gopls: https://go-review.googlesource.com/c/tools/+/510235
- clangd: https://github.com/llvm/llvm-project/pull/80180
Fixes #27293
Diffstat (limited to 'runtime/lua/vim/lsp/protocol.lua')
-rw-r--r-- | runtime/lua/vim/lsp/protocol.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/runtime/lua/vim/lsp/protocol.lua b/runtime/lua/vim/lsp/protocol.lua index eb18043843..656921644d 100644 --- a/runtime/lua/vim/lsp/protocol.lua +++ b/runtime/lua/vim/lsp/protocol.lua @@ -425,6 +425,7 @@ function protocol.make_client_capabilities() }, rangeFormatting = { dynamicRegistration = true, + rangesSupport = true, }, completion = { dynamicRegistration = false, |