summaryrefslogtreecommitdiff
path: root/src/regexp.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2013-06-02 15:01:57 +0200
committerBram Moolenaar <Bram@vim.org>2013-06-02 15:01:57 +0200
commit5de820b916c38d95f6af7f4315f827764d587497 (patch)
treee6207902f7cffbb6e1a259db098ced83ac394e0a /src/regexp.c
parentefb23f26e8da3edb9fe8c980f7a0f27906f98bf2 (diff)
downloadvim-git-5de820b916c38d95f6af7f4315f827764d587497.tar.gz
updated for version 7.3.1091v7.3.1091
Problem: New regexp engine: no error when using \z1 or \z( where it does not work. Solution: Give an error message.
Diffstat (limited to 'src/regexp.c')
-rw-r--r--src/regexp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/regexp.c b/src/regexp.c
index 3eaf74dd9..2804f8062 100644
--- a/src/regexp.c
+++ b/src/regexp.c
@@ -361,6 +361,8 @@ static char_u e_missingbracket[] = N_("E769: Missing ] after %s[");
static char_u e_unmatchedpp[] = N_("E53: Unmatched %s%%(");
static char_u e_unmatchedp[] = N_("E54: Unmatched %s(");
static char_u e_unmatchedpar[] = N_("E55: Unmatched %s)");
+static char_u e_z_not_allowed[] = N_("E66: \\z( not allowed here");
+static char_u e_z1_not_allowed[] = N_("E67: \\z1 et al. not allowed here");
#define NOT_MULTI 0
#define MULTI_ONE 1
@@ -2120,7 +2122,7 @@ regatom(flagp)
{
#ifdef FEAT_SYN_HL
case '(': if (reg_do_extmatch != REX_SET)
- EMSG_RET_NULL(_("E66: \\z( not allowed here"));
+ EMSG_RET_NULL(_(e_z_not_allowed));
if (one_exactly)
EMSG_ONE_RET_NULL;
ret = reg(REG_ZPAREN, &flags);
@@ -2139,7 +2141,7 @@ regatom(flagp)
case '7':
case '8':
case '9': if (reg_do_extmatch != REX_USE)
- EMSG_RET_NULL(_("E67: \\z1 et al. not allowed here"));
+ EMSG_RET_NULL(_(e_z1_not_allowed));
ret = regnode(ZREF + c - '0');
re_has_z = REX_USE;
break;