fix(lsp): call hierarchy results processing (#2728)

(cherry picked from commit 5a747a9587)
This commit is contained in:
AI
2023-10-11 08:15:42 +02:00
committed by Simon Hauser
parent 2eb23ffa34
commit 296668f632
+6 -8
View File
@@ -69,14 +69,12 @@ local function call_hierarchy(opts, method, title, direction, item)
local locations = {}
for _, ch_call in pairs(result) do
local ch_item = ch_call[direction]
for _, range in pairs(ch_call.fromRanges) do
table.insert(locations, {
filename = vim.uri_to_fname(ch_item.uri),
text = ch_item.name,
lnum = range.start.line + 1,
col = range.start.character + 1,
})
end
table.insert(locations, {
filename = vim.uri_to_fname(ch_item.uri),
text = ch_item.name,
lnum = ch_item.range.start.line + 1,
col = ch_item.range.start.character + 1,
})
end
pickers