We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4e6531d commit e9cc383Copy full SHA for e9cc383
runtime/lua/vim/lsp/util.lua
@@ -421,7 +421,13 @@ function M.jump_to_location(location)
421
local bufnr = vim.uri_to_bufnr(location.uri)
422
-- Save position in jumplist
423
vim.cmd "normal! m'"
424
- -- TODO(ashkan) use tagfunc here to update tagstack.
+
425
+ -- Push a new item into tagstack
426
+ local items = {}
427
+ table.insert(items, {tagname=vim.fn.expand("<cword>"), from=vim.fn.getpos('.')})
428
+ vim.fn.settagstack(vim.fn.bufnr('%'), {items=items}, 't')
429
430
+ --- Jump to new location
431
api.nvim_set_current_buf(bufnr)
432
local row = location.range.start.line
433
local col = location.range.start.character
0 commit comments