mirror of
https://github.com/vim/vim.git
synced 2025-09-26 04:04:07 -04:00
updated for version 7.4.110
Problem: "gUgn" cannot be repeeated. (Dimitar Dimitrov) Solution: Don't put "gn" in a different order in the redo buffer. Restore 'wrapscan' when the pattern isn't found. (Christian Wellenbrock)
This commit is contained in:
12
src/normal.c
12
src/normal.c
@@ -962,11 +962,8 @@ getcount:
|
|||||||
#ifdef FEAT_CMDL_INFO
|
#ifdef FEAT_CMDL_INFO
|
||||||
need_flushbuf |= add_to_showcmd(ca.nchar);
|
need_flushbuf |= add_to_showcmd(ca.nchar);
|
||||||
#endif
|
#endif
|
||||||
/* For "gn" from redo, need to get one more char to determine the
|
|
||||||
* operator */
|
|
||||||
if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`'
|
if (ca.nchar == 'r' || ca.nchar == '\'' || ca.nchar == '`'
|
||||||
|| ca.nchar == Ctrl_BSL
|
|| ca.nchar == Ctrl_BSL)
|
||||||
|| ((ca.nchar == 'n' || ca.nchar == 'N') && !stuff_empty()))
|
|
||||||
{
|
{
|
||||||
cp = &ca.extra_char; /* need to get a third character */
|
cp = &ca.extra_char; /* need to get a third character */
|
||||||
if (ca.nchar != 'r')
|
if (ca.nchar != 'r')
|
||||||
@@ -1797,10 +1794,9 @@ do_pending_operator(cap, old_col, gui_yank)
|
|||||||
* otherwise it might be the second char of the operator. */
|
* otherwise it might be the second char of the operator. */
|
||||||
if (cap->cmdchar == 'g' && (cap->nchar == 'n'
|
if (cap->cmdchar == 'g' && (cap->nchar == 'n'
|
||||||
|| cap->nchar == 'N'))
|
|| cap->nchar == 'N'))
|
||||||
/* "gn" and "gN" are a bit different */
|
prep_redo(oap->regname, cap->count0,
|
||||||
prep_redo(oap->regname, 0L, NUL, cap->cmdchar, cap->nchar,
|
get_op_char(oap->op_type), get_extra_op_char(oap->op_type),
|
||||||
get_op_char(oap->op_type),
|
oap->motion_force, cap->cmdchar, cap->nchar);
|
||||||
get_extra_op_char(oap->op_type));
|
|
||||||
else if (cap->cmdchar != ':')
|
else if (cap->cmdchar != ':')
|
||||||
prep_redo(oap->regname, 0L, NUL, 'v',
|
prep_redo(oap->regname, 0L, NUL, 'v',
|
||||||
get_op_char(oap->op_type),
|
get_op_char(oap->op_type),
|
||||||
|
@@ -4544,7 +4544,10 @@ current_search(count, forward)
|
|||||||
/* Is the pattern is zero-width? */
|
/* Is the pattern is zero-width? */
|
||||||
one_char = is_one_char(spats[last_idx].pat);
|
one_char = is_one_char(spats[last_idx].pat);
|
||||||
if (one_char == -1)
|
if (one_char == -1)
|
||||||
return FAIL; /* invalid pattern */
|
{
|
||||||
|
p_ws = old_p_ws;
|
||||||
|
return FAIL; /* pattern not found */
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The trick is to first search backwards and then search forward again,
|
* The trick is to first search backwards and then search forward again,
|
||||||
|
@@ -738,6 +738,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
110,
|
||||||
/**/
|
/**/
|
||||||
109,
|
109,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user