On Wed, Apr 24, 2013 at 6:35 PM, Bram Moolenaar <[email protected]> wrote:
>
> Patch 7.3.918
> Problem:    Repeating an Ex command after using a Visual motion does not work.
> Solution:   Check for an Ex command being used. (David Bürgin)
> Files:      src/normal.c
>
>
> *** ../vim-7.3.917/src/normal.c 2013-04-05 17:43:10.000000000 +0200
> --- src/normal.c        2013-04-24 18:12:43.000000000 +0200
> ***************
> *** 1504,1514 ****
>         }
>   #endif
>
> !       /* only redo yank when 'y' flag is in 'cpoptions' */
> !       /* never redo "zf" (define fold) */
>         if ((vim_strchr(p_cpo, CPO_YANK) != NULL || oap->op_type != OP_YANK)
>   #ifdef FEAT_VISUAL
> !               && (!VIsual_active || oap->motion_force)
>   #endif
>                 && cap->cmdchar != 'D'
>   #ifdef FEAT_FOLDING
> --- 1504,1517 ----
>         }
>   #endif
>
> !       /* Only redo yank when 'y' flag is in 'cpoptions'. */
> !       /* Never redo "zf" (define fold). */
>         if ((vim_strchr(p_cpo, CPO_YANK) != NULL || oap->op_type != OP_YANK)
>   #ifdef FEAT_VISUAL
> !               && ((!VIsual_active || oap->motion_force)
> !                   /* Also redo Operator-pending Visual mode mappings */
> !                   || (VIsual_active && cap->cmdchar == ':'
> !                                                && oap->op_type != OP_COLON))
>   #endif
>                 && cap->cmdchar != 'D'
>   #ifdef FEAT_FOLDING
> ***************
> *** 1797,1803 ****
>                     prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar,
>                                         get_op_char(oap->op_type),
>                                         get_extra_op_char(oap->op_type));
> !               else
>                     prep_redo(oap->regname, 0L, NUL, 'v',
>                                         get_op_char(oap->op_type),
>                                         get_extra_op_char(oap->op_type),
> --- 1800,1806 ----
>                     prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar,
>                                         get_op_char(oap->op_type),
>                                         get_extra_op_char(oap->op_type));
> !               else if (cap->cmdchar != ':')
>                     prep_redo(oap->regname, 0L, NUL, 'v',
>                                         get_op_char(oap->op_type),
>                                         get_extra_op_char(oap->op_type),
> *** ../vim-7.3.917/src/version.c        2013-04-24 17:34:15.000000000 +0200
> --- src/version.c       2013-04-24 18:34:03.000000000 +0200
> ***************
> *** 730,731 ****
> --- 730,733 ----
>   {   /* Add new patch number below this line */
> + /**/
> +     918,
>   /**/
>

Thank you for including this.

I had meant to write a test for this but put it off for too long. Here
is a test which works after applying this patch.

-- 
-- 
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].
For more options, visit https://groups.google.com/groups/opt_out.


Raspunde prin e-mail lui