diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-11-05 15:51:26 +0800 |
---|---|---|
committer | zeertzjq <zeertzjq@outlook.com> | 2022-11-05 16:09:21 +0800 |
commit | 78e69412acb481c7ad56e68c541f5c5383992d5b (patch) | |
tree | bc96dfa6fca4e26ea661eb3f7326ff660a9b012d /src/nvim/regexp.c | |
parent | 45a3e7f6694c66c3577a47c7ff1fb8bfcc2ab7be (diff) | |
download | rneovim-78e69412acb481c7ad56e68c541f5c5383992d5b.tar.gz rneovim-78e69412acb481c7ad56e68c541f5c5383992d5b.tar.bz2 rneovim-78e69412acb481c7ad56e68c541f5c5383992d5b.zip |
vim-patch:8.2.4688: new regexp engine does not give an error for "\%v"
Problem: New regexp engine does not give an error for "\%v".
Solution: Check for a value argument. (issue vim/vim#10079)
https://github.com/vim/vim/commit/91ff3d4f52a55a7c37a52aaad524cd9dd12efae4
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'src/nvim/regexp.c')
-rw-r--r-- | src/nvim/regexp.c | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/src/nvim/regexp.c b/src/nvim/regexp.c index 68ffc70457..3e8724c1ef 100644 --- a/src/nvim/regexp.c +++ b/src/nvim/regexp.c @@ -97,20 +97,22 @@ static int toggle_Magic(int x) #define MAX_LIMIT (32767L << 16L) -static char_u e_missingbracket[] = N_("E769: Missing ] after %s["); -static char_u e_reverse_range[] = N_("E944: Reverse range in character class"); -static char_u e_large_class[] = N_("E945: Range too large in character class"); -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 - \\z9 not allowed here"); -static char_u e_missing_sb[] = N_("E69: Missing ] after %s%%["); -static char_u e_empty_sb[] = N_("E70: Empty %s%%[]"); -static char_u e_recursive[] = N_("E956: Cannot use pattern recursively"); -static char_u e_regexp_number_after_dot_pos_search[] +static char e_missingbracket[] = N_("E769: Missing ] after %s["); +static char e_reverse_range[] = N_("E944: Reverse range in character class"); +static char e_large_class[] = N_("E945: Range too large in character class"); +static char e_unmatchedpp[] = N_("E53: Unmatched %s%%("); +static char e_unmatchedp[] = N_("E54: Unmatched %s("); +static char e_unmatchedpar[] = N_("E55: Unmatched %s)"); +static char e_z_not_allowed[] = N_("E66: \\z( not allowed here"); +static char e_z1_not_allowed[] = N_("E67: \\z1 - \\z9 not allowed here"); +static char e_missing_sb[] = N_("E69: Missing ] after %s%%["); +static char e_empty_sb[] = N_("E70: Empty %s%%[]"); +static char e_recursive[] = N_("E956: Cannot use pattern recursively"); +static char e_regexp_number_after_dot_pos_search_chr[] = N_("E1204: No Number allowed after .: '\\%%%c'"); -static char_u e_substitute_nesting_too_deep[] = N_("E1290: substitute nesting too deep"); +static char e_nfa_regexp_missing_value_in_chr[] + = N_("E1273: (NFA regexp) missing value in '\\%%%c'"); +static char e_substitute_nesting_too_deep[] = N_("E1290: substitute nesting too deep"); #define NOT_MULTI 0 #define MULTI_ONE 1 |