forked from aniani/vim
patch 8.2.5123: using invalid index when looking for spell suggestions
Problem: Using invalid index when looking for spell suggestions. Solution: Do not decrement the index when it is zero.
This commit is contained in:
@@ -70,6 +70,16 @@ func Test_z_equal_on_invalid_utf8_word()
|
||||
bwipe!
|
||||
endfunc
|
||||
|
||||
func Test_z_equal_on_single_character()
|
||||
" this was decrementing the index below zero
|
||||
new
|
||||
norm a0\<5C>
|
||||
norm zW
|
||||
norm z=
|
||||
|
||||
bwipe!
|
||||
endfunc
|
||||
|
||||
" Test spellbadword() with argument
|
||||
func Test_spellbadword()
|
||||
set spell
|
||||
|
||||
Reference in New Issue
Block a user