summaryrefslogtreecommitdiffstats
path: root/src/cmdexpand.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-12-21 19:59:08 +0100
committerBram Moolenaar <Bram@vim.org>2020-12-21 19:59:08 +0100
commitf4e2099e39ed4d71aed0f9a9579455aed5ec6cc2 (patch)
tree40a384257e29f443c46bbaa19fb88a8eb5441b05 /src/cmdexpand.c
parenta3d10a508c404a32485adc86284725e0bdc5b602 (diff)
patch 8.2.2182: Vim9: value of 'magic' is still relevantv8.2.2182
Problem: Vim9: value of 'magic' is still relevant. Solution: Always behave like 'magic' is on in Vim9 script (closes #7509)
Diffstat (limited to 'src/cmdexpand.c')
-rw-r--r--src/cmdexpand.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cmdexpand.c b/src/cmdexpand.c
index 11cb0e3245..4ebb693341 100644
--- a/src/cmdexpand.c
+++ b/src/cmdexpand.c
@@ -1391,7 +1391,7 @@ set_one_cmd_context(
if (*arg != NUL)
{
xp->xp_context = EXPAND_NOTHING;
- arg = skip_regexp(arg + 1, *arg, p_magic);
+ arg = skip_regexp(arg + 1, *arg, magic_isset());
}
}
return find_nextcmd(arg);
@@ -1429,7 +1429,7 @@ set_one_cmd_context(
{
// skip "from" part
++arg;
- arg = skip_regexp(arg, delim, p_magic);
+ arg = skip_regexp(arg, delim, magic_isset());
}
// skip "to" part
while (arg[0] != NUL && arg[0] != delim)
@@ -2077,7 +2077,7 @@ ExpandFromContext(
pat = tofree;
}
- regmatch.regprog = vim_regcomp(pat, p_magic ? RE_MAGIC : 0);
+ regmatch.regprog = vim_regcomp(pat, magic_isset() ? RE_MAGIC : 0);
if (regmatch.regprog == NULL)
return FAIL;