diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-11-10 17:33:29 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-11-10 17:33:29 +0100 |
commit | ded5f1bed7ff2d138b3ee0f9610d17290b62692d (patch) | |
tree | 54727bd70279df4fadc4b8f4701577ac33282ef5 /src/option.c | |
parent | 1bbb61948342b5cf6e363629f145c65eb455c388 (diff) | |
download | vim-git-ded5f1bed7ff2d138b3ee0f9610d17290b62692d.tar.gz |
patch 8.1.0515: reloading a script gives errors for existing functionsv8.1.0515
Problem: Reloading a script gives errors for existing functions.
Solution: Allow redefining a function once when reloading a script.
Diffstat (limited to 'src/option.c')
-rw-r--r-- | src/option.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/option.c b/src/option.c index 3c54ab642..a4a9c9711 100644 --- a/src/option.c +++ b/src/option.c @@ -415,7 +415,7 @@ struct vimoption char_u *def_val[2]; // default values for variable (vi and vim) #ifdef FEAT_EVAL sctx_T script_ctx; // script context where the option was last set -# define SCTX_INIT , {0, 0} +# define SCTX_INIT , {0, 0, 0} #else # define SCTX_INIT #endif @@ -5959,6 +5959,7 @@ set_string_option_direct( else { script_ctx.sc_sid = set_sid; + script_ctx.sc_seq = 0; script_ctx.sc_lnum = 0; } set_option_sctx_idx(idx, opt_flags, script_ctx); |