diff options
author | Sean Dewar <seandewar@users.noreply.github.com> | 2021-05-21 15:12:35 +0100 |
---|---|---|
committer | Sean Dewar <seandewar@users.noreply.github.com> | 2021-08-12 22:31:18 +0100 |
commit | 4042ae5a2bc4bbca608ebb196a3d54a78d6c100c (patch) | |
tree | 6da940b00ff0f62ef3a2ebdeb730726e0f69755b /src/nvim/normal.c | |
parent | 60dd76c7e29e75dee641f93483eb6e5c2afb28e4 (diff) | |
download | rneovim-4042ae5a2bc4bbca608ebb196a3d54a78d6c100c.tar.gz rneovim-4042ae5a2bc4bbca608ebb196a3d54a78d6c100c.tar.bz2 rneovim-4042ae5a2bc4bbca608ebb196a3d54a78d6c100c.zip |
vim-patch:8.1.1800: function call functions have too many arguments
Problem: Function call functions have too many arguments.
Solution: Pass values in a funcexe_T struct.
https://github.com/vim/vim/commit/c6538bcc1cdd1fb83732f22fdc69bd9bb66f968a
Use FUNCEXE_INIT to initialize funcexe_T instances.
call_callback() and other Vim listener related stuff is N/A.
Diffstat (limited to 'src/nvim/normal.c')
-rw-r--r-- | src/nvim/normal.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/normal.c b/src/nvim/normal.c index 2a530db934..e42ec92a4c 100644 --- a/src/nvim/normal.c +++ b/src/nvim/normal.c @@ -2531,12 +2531,12 @@ do_mouse ( } }; typval_T rettv; - int doesrange; - (void)call_func((char_u *)tab_page_click_defs[mouse_col].func, - -1, - &rettv, ARRAY_SIZE(argv), argv, NULL, - curwin->w_cursor.lnum, curwin->w_cursor.lnum, - &doesrange, true, NULL, NULL); + funcexe_T funcexe = FUNCEXE_INIT; + funcexe.firstline = curwin->w_cursor.lnum; + funcexe.lastline = curwin->w_cursor.lnum; + funcexe.evaluate = true; + (void)call_func((char_u *)tab_page_click_defs[mouse_col].func, -1, + &rettv, ARRAY_SIZE(argv), argv, &funcexe); tv_clear(&rettv); break; } |