A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/neovim/neovim/commit/8066abcd65a672010e7159bcb9601f6eb5481e81 below:

forward offset_encoding in rename handler (#17079) · neovim/neovim@8066abc · GitHub

File tree Expand file treeCollapse file tree 2 files changed

+5

-3

lines changed

Filter options

Expand file treeCollapse file tree 2 files changed

+5

-3

lines changed Original file line number Diff line number Diff line change

@@ -225,9 +225,10 @@ M['textDocument/documentSymbol'] = response_to_list(util.symbols_to_items, 'docu

225 225

M['workspace/symbol'] = response_to_list(util.symbols_to_items, 'symbols')

226 226 227 227

--see: https://microsoft.github.io/language-server-protocol/specifications/specification-current/#textDocument_rename

228 -

M['textDocument/rename'] = function(_, result, _)

228 +

M['textDocument/rename'] = function(_, result, ctx, _)

229 229

if not result then return end

230 -

util.apply_workspace_edit(result)

230 +

local client = vim.lsp.get_client_by_id(ctx.client_id)

231 +

util.apply_workspace_edit(result, client.offset_encoding)

231 232

end

232 233 233 234

--see: https://microsoft.github.io/language-server-protocol/specifications/specification-current/#textDocument_rangeFormatting

Original file line number Diff line number Diff line change

@@ -737,7 +737,8 @@ end

737 737 738 738

--- Applies a `WorkspaceEdit`.

739 739

---

740 -

---@param workspace_edit (table) `WorkspaceEdit`

740 +

---@param workspace_edit table `WorkspaceEdit`

741 +

---@param offset_encoding string utf-8|utf-16|utf-32 (required)

741 742

--see https://microsoft.github.io/language-server-protocol/specifications/specification-current/#workspace_applyEdit

742 743

function M.apply_workspace_edit(workspace_edit, offset_encoding)

743 744

if offset_encoding == nil then

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4