comparison src/testdir/test_registers.vim @ 27418:6ecfb8d99353 v8.2.4237

patch 8.2.4237: record buffer wrong if character in Select mode was not typed Commit: https://github.com/vim/vim/commit/fbf4f1ca159028382eaeb3bfc31bb6bb96dbb67a Author: zeertzjq <zeertzjq@outlook.com> Date: Fri Jan 28 12:50:43 2022 +0000 patch 8.2.4237: record buffer wrong if character in Select mode was not typed Problem: Record buffer wrong if character in Select mode was not typed. Solution: Only delete the tail from the record buffer if the character was typed. (closes #9650)
author Bram Moolenaar <Bram@vim.org>
date Fri, 28 Jan 2022 14:00:04 +0100
parents 5d6774c0df4f
children 390dfc3e409b
comparison
equal deleted inserted replaced
27417:98239fdd09c5 27418:6ecfb8d99353
743 new 743 new
744 call setline(1, 'text') 744 call setline(1, 'text')
745 sil norm q00 745 sil norm q00
746 sil norm q 746 sil norm q
747 call assert_equal('0ext', getline(1)) 747 call assert_equal('0ext', getline(1))
748
749 %delete
750 let @r = ''
751 call setline(1, ['abc', 'abc', 'abc'])
752 smap <F2> <Right><Right>,
753 call feedkeys("qrgh\<F2>Dk\<Esc>q", 'xt')
754 call assert_equal("gh\<F2>Dk\<Esc>", @r)
755 norm j0@rj0@@
756 call assert_equal([',Dk', ',Dk', ',Dk'], getline(1, 3))
757 sunmap <F2>
758
748 bwipe! 759 bwipe!
749 endfunc 760 endfunc
750 761
751 " Make sure that y_append is correctly reset 762 " Make sure that y_append is correctly reset
752 " and the previous register is working as expected 763 " and the previous register is working as expected