diff options
author | Tristan Knight <admin@snappeh.com> | 2024-10-26 15:38:25 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-26 07:38:25 -0700 |
commit | 25b53b593ef6f229fbec5b3dc205a7539579d13a (patch) | |
tree | 8c13b6b78e22437b8fd22ac8b639ecc65417fff3 /runtime/lua/vim/lsp.lua | |
parent | b922b7d6d7889cce863540df7b0da7d512f8a2a1 (diff) | |
download | rneovim-25b53b593ef6f229fbec5b3dc205a7539579d13a.tar.gz rneovim-25b53b593ef6f229fbec5b3dc205a7539579d13a.tar.bz2 rneovim-25b53b593ef6f229fbec5b3dc205a7539579d13a.zip |
refactor(lsp): drop str_byteindex/str_utfindex wrappers #30915
* deprecate old signatures
* move to new str_byteindex/str_utfindex signature
* use single-underscore name (double-underscore is reserved for Lua itself)
Diffstat (limited to 'runtime/lua/vim/lsp.lua')
-rw-r--r-- | runtime/lua/vim/lsp.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/lua/vim/lsp.lua b/runtime/lua/vim/lsp.lua index 4f13ad5721..125238a8e9 100644 --- a/runtime/lua/vim/lsp.lua +++ b/runtime/lua/vim/lsp.lua @@ -1049,7 +1049,7 @@ function lsp.formatexpr(opts) if client.supports_method(ms.textDocument_rangeFormatting) then local params = util.make_formatting_params() local end_line = vim.fn.getline(end_lnum) --[[@as string]] - local end_col = util._str_utfindex_enc(end_line, nil, client.offset_encoding) + local end_col = vim.str_utfindex(end_line, client.offset_encoding) --- @cast params +lsp.DocumentRangeFormattingParams params.range = { start = { |