Mercurial > vim
diff src/vim9compile.c @ 23505:bb29b09902d5 v8.2.2295
patch 8.2.2295: incsearch does not detect empty pattern properly
Commit: https://github.com/vim/vim/commit/d93a7fc1a98a58f8101ee780d4735079ad99ae35
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Jan 4 12:42:13 2021 +0100
patch 8.2.2295: incsearch does not detect empty pattern properly
Problem: Incsearch does not detect empty pattern properly.
Solution: Return magic state when skipping over a pattern. (Christian
Brabandt, closes #7612, closes #6420)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 04 Jan 2021 12:45:05 +0100 |
parents | 2247a2ce3630 |
children | 872239543313 |
line wrap: on
line diff
--- a/src/vim9compile.c +++ b/src/vim9compile.c @@ -7048,7 +7048,7 @@ compile_catch(char_u *arg, cctx_T *cctx // Push v:exception, push {expr} and MATCH generate_instr_type(cctx, ISN_PUSHEXC, &t_string); - end = skip_regexp_ex(p + 1, *p, TRUE, &tofree, &dropped); + end = skip_regexp_ex(p + 1, *p, TRUE, &tofree, &dropped, NULL); if (*end != *p) { semsg(_(e_separator_mismatch_str), p); @@ -7372,7 +7372,7 @@ compile_exec(char_u *line, exarg_T *eap, { int delim = *eap->arg; - p = skip_regexp_ex(eap->arg + 1, delim, TRUE, NULL, NULL); + p = skip_regexp_ex(eap->arg + 1, delim, TRUE, NULL, NULL, NULL); if (*p == delim) { eap->arg = p + 1;