mirror of
https://github.com/vim/vim.git
synced 2025-07-25 10:54:51 -04:00
updated for version 7.3.1104
Problem: New regexp engine does not handle "~". Solution: Add support for "~".
This commit is contained in:
parent
f6de032afe
commit
f18fb7af75
@ -829,9 +829,26 @@ nfa_regatom()
|
|||||||
EMSGN(_(e_misplaced), no_Magic(c));
|
EMSGN(_(e_misplaced), no_Magic(c));
|
||||||
return FAIL;
|
return FAIL;
|
||||||
|
|
||||||
case Magic('~'): /* previous substitute pattern */
|
case Magic('~'):
|
||||||
/* TODO: Not supported yet */
|
{
|
||||||
return FAIL;
|
char_u *lp;
|
||||||
|
|
||||||
|
/* Previous substitute pattern.
|
||||||
|
* Generated as "\%(pattern\)". */
|
||||||
|
if (reg_prev_sub == NULL)
|
||||||
|
{
|
||||||
|
EMSG(_(e_nopresub));
|
||||||
|
return FAIL;
|
||||||
|
}
|
||||||
|
for (lp = reg_prev_sub; *lp != NUL; mb_cptr_adv(lp))
|
||||||
|
{
|
||||||
|
EMIT(PTR2CHAR(lp));
|
||||||
|
if (lp != reg_prev_sub)
|
||||||
|
EMIT(NFA_CONCAT);
|
||||||
|
}
|
||||||
|
EMIT(NFA_NOPEN);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
case Magic('1'):
|
case Magic('1'):
|
||||||
case Magic('2'):
|
case Magic('2'):
|
||||||
|
Binary file not shown.
@ -27,3 +27,6 @@ xx foobar xA xx
|
|||||||
xx an A xx
|
xx an A xx
|
||||||
XX 9;
|
XX 9;
|
||||||
YY 77;
|
YY 77;
|
||||||
|
xyz
|
||||||
|
bcd
|
||||||
|
BB
|
||||||
|
@ -728,6 +728,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 */
|
||||||
|
/**/
|
||||||
|
1104,
|
||||||
/**/
|
/**/
|
||||||
1103,
|
1103,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user