summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2021-02-14 13:30:01 +0100
committerBram Moolenaar <Bram@vim.org>2021-02-14 13:30:01 +0100
commit9979fcd72ed671ec2c98800587c3a6996adb27d4 (patch)
tree172d029c28db47a2e735634249d950235a3748db /src
parent03dfde2b5f81f06639ec8697cdd32ad50d8509fd (diff)
downloadvim-git-9979fcd72ed671ec2c98800587c3a6996adb27d4.tar.gz
patch 8.2.2513: Vim9: missing part of :vim9cmd changev8.2.2513
Problem: Vim9: missing part of :vim9cmd change. Solution: Use command modifier in in_vim9script().
Diffstat (limited to 'src')
-rw-r--r--src/version.c2
-rw-r--r--src/vim9script.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/src/version.c b/src/version.c
index dabc2af70..20bc9a225 100644
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 2513,
+/**/
2512,
/**/
2511,
diff --git a/src/vim9script.c b/src/vim9script.c
index fea478592..d40104cb7 100644
--- a/src/vim9script.c
+++ b/src/vim9script.c
@@ -23,7 +23,8 @@ in_vim9script(void)
// Do not go up the stack, a ":function" inside vim9script uses legacy
// syntax. "sc_version" is also set when compiling a ":def" function in
// legacy script.
- return current_sctx.sc_version == SCRIPT_VERSION_VIM9;
+ return current_sctx.sc_version == SCRIPT_VERSION_VIM9
+ || (cmdmod.cmod_flags & CMOD_VIM9CMD);
}
/*