mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 17:30:04 +08:00
fix(highlight.vim): fix list index out of range
This commit is contained in:
parent
561da4ffbd
commit
0f336f386e
@ -309,7 +309,9 @@ function! s:highlight() abort
|
||||
for item in s:stack
|
||||
call add(s:highlight_id, s:CMP.matchaddpos('HiBlueBold', [ item ]))
|
||||
endfor
|
||||
if !empty(get(s:stack, s:index, []))
|
||||
let s:highlight_id_c = s:CMP.matchaddpos('HiPurpleBold', [s:stack[s:index]])
|
||||
endif
|
||||
endfunction
|
||||
" }}}
|
||||
|
||||
|
@ -7,7 +7,7 @@ Given (fixture):
|
||||
Hello
|
||||
Hello
|
||||
|
||||
Execute ( SpaceVim plugin: iedit ):
|
||||
Execute ( SpaceVim plugin: highlight.vim `SPC s h/H` ):
|
||||
let g:_spacevim_input_list = ['e', 'D', 'a', 'W', 'o', 'r', 'l', 'd', "\<Esc>", "\<Esc>"]
|
||||
call SpaceVim#plugins#highlight#start()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user