Patch 8.2.2189
Problem:    Cannot repeat a command that uses the small delete register.
Solution:   Store the register name instead of the contents. (Christian
            Brabandt, closes #7527)
Files:      src/ops.c, src/register.c, src/testdir/test_registers.vim


*** ../vim-8.2.2188/src/ops.c   2020-12-22 12:20:04.541293877 +0100
--- src/ops.c   2020-12-22 17:58:50.975227356 +0100
***************
*** 9,15 ****
  
  /*
   * ops.c: implementation of various operators: op_shift, op_delete, op_tilde,
!  *      op_change, op_yank, do_put, do_join
   */
  
  #include "vim.h"
--- 9,15 ----
  
  /*
   * ops.c: implementation of various operators: op_shift, op_delete, op_tilde,
!  *      op_change, op_yank, do_join
   */
  
  #include "vim.h"
*** ../vim-8.2.2188/src/register.c      2020-11-26 20:33:56.856583887 +0100
--- src/register.c      2020-12-22 17:58:50.975227356 +0100
***************
*** 809,815 ****
        {
            for (i = 0; i < y_current->y_size; ++i)
            {
!               stuffescaped(y_current->y_array[i], literally);
                // Insert a newline between lines and after last line if
                // y_type is MLINE.
                if (y_current->y_type == MLINE || i < y_current->y_size - 1)
--- 809,822 ----
        {
            for (i = 0; i < y_current->y_size; ++i)
            {
!               if (regname == '-')
!               {
!                   AppendCharToRedobuff(Ctrl_R);
!                   AppendCharToRedobuff(regname);
!                   do_put(regname, NULL, BACKWARD, 1L, PUT_CURSEND);
!               }
!               else
!                   stuffescaped(y_current->y_array[i], literally);
                // Insert a newline between lines and after last line if
                // y_type is MLINE.
                if (y_current->y_type == MLINE || i < y_current->y_size - 1)
*** ../vim-8.2.2188/src/testdir/test_registers.vim      2020-10-04 
16:16:50.919838655 +0200
--- src/testdir/test_registers.vim      2020-12-22 17:58:50.975227356 +0100
***************
*** 698,701 ****
--- 698,712 ----
    bwipe!
  endfunc
  
+ func Test_insert_small_delete()
+   new
+   call setline(1, ['foo foobar bar'])
+   call cursor(1,1)
+   exe ":norm! ciw'\<C-R>-'"
+   call assert_equal(getline(1), "'foo' foobar bar")
+   exe ":norm! w.w."
+   call assert_equal(getline(1), "'foo' 'foobar' 'bar'")
+   bwipe!
+ endfunc
+ 
  " vim: shiftwidth=2 sts=2 expandtab
*** ../vim-8.2.2188/src/version.c       2020-12-22 17:35:50.043978116 +0100
--- src/version.c       2020-12-22 17:57:21.999626326 +0100
***************
*** 752,753 ****
--- 752,755 ----
  {   /* Add new patch number below this line */
+ /**/
+     2189,
  /**/

-- 
Often you're less important than your furniture.  If you think about it, you
can get fired but your furniture stays behind, gainfully employed at the
company that didn't need _you_ anymore.
                                (Scott Adams - The Dilbert principle)

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202012221700.0BMH07Rt2612921%40masaka.moolenaar.net.

Raspunde prin e-mail lui