Merge pull request #21393 from folke/highlight_show

feat(lsp): add function to get semantic tokens at cursor
feat: `vim.inspect_pos()`, `vim.show_pos()` and `:Inspect[!]`
This commit is contained in:
Christian Clason
2022-12-17 13:43:46 +01:00
committed by GitHub
13 changed files with 437 additions and 6 deletions

View File

@@ -240,7 +240,7 @@ function M.get_captures_at_pos(bufnr, row, col)
if M.is_in_node_range(node, row, col) then
local c = q._query.captures[capture] -- name of the capture in the query
if c ~= nil then
table.insert(matches, { capture = c, metadata = metadata })
table.insert(matches, { capture = c, metadata = metadata, lang = tree:lang() })
end
end
end