diff --git a/.config/vim/vimrc.d/80-autocommands.vim b/.config/vim/vimrc.d/80-autocommands.vim index 67b7ff3..bfe538a 100644 --- a/.config/vim/vimrc.d/80-autocommands.vim +++ b/.config/vim/vimrc.d/80-autocommands.vim @@ -94,6 +94,11 @@ function! HighlightVisualSel() let l:old_regtype = getregtype('"') silent! norm ygv + if @" == "" + " Abort when visual mode stated on an empty line + return + endif + let w:visual_match_ids = [] " Add match to all windows containing the current buffer