0
0
mirror of https://github.com/vim/vim.git synced 2025-10-04 05:25:06 -04:00

patch 8.2.2650: Vim9: command modifiers not handled in nested function

Problem:    Vim9: command modifiers not handled in nested function.
Solution:   Keep function-local info in a structure and save it on the stack.
This commit is contained in:
Bram Moolenaar
2021-03-24 22:00:56 +01:00
parent 1ff89deeaa
commit 2fecb53115
4 changed files with 127 additions and 45 deletions

View File

@@ -402,12 +402,14 @@ struct dfunc_S {
// - ec_dfunc_idx: function index
// - ec_iidx: instruction index
// - ec_outer: stack used for closures
// - funclocal: function-local data
// - ec_frame_idx: previous frame index
#define STACK_FRAME_FUNC_OFF 0
#define STACK_FRAME_IIDX_OFF 1
#define STACK_FRAME_OUTER_OFF 2
#define STACK_FRAME_IDX_OFF 3
#define STACK_FRAME_SIZE 4
#define STACK_FRAME_FUNCLOCAL_OFF 3
#define STACK_FRAME_IDX_OFF 4
#define STACK_FRAME_SIZE 5
#ifdef DEFINE_VIM9_GLOBALS