mirror of
https://github.com/neovim/neovim.git
synced 2025-10-15 14:26:07 +00:00
vim-patch:8.2.2182: Vim9: value of 'magic' is still relevant
Problem: Vim9: value of 'magic' is still relevant.
Solution: Always behave like 'magic' is on in Vim9 script (closes vim/vim#7509)
f4e2099e39
EX_NONWHITE_OK is N/A: only applies to Vim9 script.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
This commit is contained in:
@@ -1336,7 +1336,7 @@ static void ins_compl_dictionaries(char_u *dict_start, char_u *pat, int flags, i
|
||||
xfree(pat_esc);
|
||||
xfree(ptr);
|
||||
} else {
|
||||
regmatch.regprog = vim_regcomp((char *)pat, p_magic ? RE_MAGIC : 0);
|
||||
regmatch.regprog = vim_regcomp((char *)pat, magic_isset() ? RE_MAGIC : 0);
|
||||
if (regmatch.regprog == NULL) {
|
||||
goto theend;
|
||||
}
|
||||
@@ -4430,7 +4430,7 @@ static unsigned quote_meta(char_u *dest, char_u *src, int len)
|
||||
}
|
||||
FALLTHROUGH;
|
||||
case '~':
|
||||
if (!p_magic) { // quote these only if magic is set
|
||||
if (!magic_isset()) { // quote these only if magic is set
|
||||
break;
|
||||
}
|
||||
FALLTHROUGH;
|
||||
|
Reference in New Issue
Block a user