summaryrefslogtreecommitdiff
path: root/src/ex_docmd.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-12-26 15:39:31 +0100
committerBram Moolenaar <Bram@vim.org>2020-12-26 15:39:31 +0100
commit2b32700dabf392566d8e9fef76e0d587a891ee3e (patch)
tree3f83eabd005ede0c2dc4fd171b8a9cbb3fb412f6 /src/ex_docmd.c
parentb0ac4ea5e1c5f0ff4e951978c32ccfffe46916f8 (diff)
downloadvim-git-2b32700dabf392566d8e9fef76e0d587a891ee3e.tar.gz
patch 8.2.2222: Vim9: cannot keep script variables when reloadingv8.2.2222
Problem: Vim9: cannot keep script variables when reloading. Solution: Add the "noclear" argument to :vim9script.
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r--src/ex_docmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 69e3f12e6..156f0df16 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -2594,7 +2594,7 @@ do_one_cmd(
// Set flag that any command was executed, used by ex_vim9script().
if (getline_equal(ea.getline, ea.cookie, getsourceline)
&& current_sctx.sc_sid > 0)
- SCRIPT_ITEM(current_sctx.sc_sid)->sn_had_command = TRUE;
+ SCRIPT_ITEM(current_sctx.sc_sid)->sn_state = SN_STATE_HAD_COMMAND;
/*
* If the command just executed called do_cmdline(), any throw or ":return"