Mercurial > vim
diff src/testdir/test_virtualedit.vim @ 30295:da023a22d73e v9.0.0483
patch 9.0.0483: illegal memory access when replacing in virtualedit mode
Commit: https://github.com/vim/vim/commit/c249913edc35c0e666d783bfc21595cf9f7d9e0d
Author: Bram Moolenaar <Bram@vim.org>
Date: Fri Sep 16 22:16:59 2022 +0100
patch 9.0.0483: illegal memory access when replacing in virtualedit mode
Problem: Illegal memory access when replacing in virtualedit mode.
Solution: Check for replacing NUL after Tab.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Fri, 16 Sep 2022 23:30:04 +0200 |
parents | b11130c6e694 |
children | 2ce8e7c4acf4 |
line wrap: on
line diff
--- a/src/testdir/test_virtualedit.vim +++ b/src/testdir/test_virtualedit.vim @@ -572,4 +572,18 @@ func Test_virtualedit_mouse() set virtualedit& endfunc +" this was replacing the NUL at the end of the line +func Test_virtualedit_replace_after_tab() + new + s/\v/ 0 + set ve=all + let @" = '' + sil! norm vPvr0 + + call assert_equal("\t0", getline(1)) + set ve& + bwipe! +endfunc + + " vim: shiftwidth=2 sts=2 expandtab