vim:aucmd: Fix missing w:cword_timer_id error msg
This commit is contained in:
@@ -78,7 +78,11 @@ endfunction
|
|||||||
|
|
||||||
function! _HighlightCurrentWord(timer_id)
|
function! _HighlightCurrentWord(timer_id)
|
||||||
" TODO: there is probably some kind of race condition here
|
" TODO: there is probably some kind of race condition here
|
||||||
unlet w:cword_timer_id
|
" NOTE: w:cword_timer_id can be unset when switching from a window that is
|
||||||
|
" currently in visual mode as then the ModeChanged event is triggered.
|
||||||
|
if exists('w:cword_timer_id')
|
||||||
|
unlet w:cword_timer_id
|
||||||
|
endif
|
||||||
|
|
||||||
let l:cword = expand('<cword>')
|
let l:cword = expand('<cword>')
|
||||||
if exists('w:old_cword') && w:old_cword == l:cword
|
if exists('w:old_cword') && w:old_cword == l:cword
|
||||||
|
|||||||
Reference in New Issue
Block a user