Skip to content

Commit

Permalink
def: only use native tagstack when the t action is supported
Browse files Browse the repository at this point in the history
The action to support replacing the current stack from the current
position was only added in 8.0.0077, so check for that before trying to
use `settagstack`.

ref:
vim/vim@271fa08
  • Loading branch information
bhcleek committed May 31, 2023
1 parent d98d671 commit 8946b6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion autoload/go/def.vim
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ function! go#def#jump_to_declaration(out, mode, bin_name) abort
" also align the line to middle of the view
normal! zz

if exists('*settagstack')
if exists('*settagstack') && has('patch-8.2.0077')
" Jump was successful, write previous location to tag stack.
let l:winid = win_getid()
let l:stack = gettagstack(l:winid)
Expand Down

0 comments on commit 8946b6d

Please sign in to comment.