1
0
forked from aniani/vim

patch 9.0.0397: :defer not tested with exceptions and ":qa!"

Problem:    :defer not tested with exceptions and ":qa!".
Solution:   Test :defer works when exceptions are thrown and when ":qa!" is
            used.  Invoke the deferred calls on exit.
This commit is contained in:
Bram Moolenaar
2022-09-06 18:31:14 +01:00
parent 2834ebdee4
commit 58779858fb
9 changed files with 123 additions and 19 deletions

View File

@@ -1753,7 +1753,11 @@ struct funccall_S
linenr_T breakpoint; // next line with breakpoint or zero
int dbg_tick; // debug_tick when breakpoint was set
int level; // top nesting level of executed function
garray_T fc_defer; // functions to be called on return
ectx_T *fc_ectx; // execution context for :def function, NULL
// otherwise
#ifdef FEAT_PROFILE
proftime_T prof_child; // time spent in a child
#endif