summaryrefslogtreecommitdiffstats
path: root/src/evalfunc.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2021-12-25 19:29:21 +0000
committerBram Moolenaar <Bram@vim.org>2021-12-25 19:29:21 +0000
commit223d0a6bc8dc68039ceb6660de9576fafe178d73 (patch)
tree0f9028c48b6ba36d5a093ac91bbe99ccc080a075 /src/evalfunc.c
parent5cd647935d0834b3064aa36384b8f6730fadadd6 (diff)
patch 8.2.3894: Vim9: no proper type check for first argument of call()v8.2.3894
Problem: Vim9: no proper type check for first argument of call(). Solution: Add specific type check.
Diffstat (limited to 'src/evalfunc.c')
-rw-r--r--src/evalfunc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/evalfunc.c b/src/evalfunc.c
index 8f52053938..e4fa35b4ef 100644
--- a/src/evalfunc.c
+++ b/src/evalfunc.c
@@ -2858,7 +2858,8 @@ f_call(typval_T *argvars, typval_T *rettv)
dict_T *selfdict = NULL;
if (in_vim9script()
- && (check_for_list_arg(argvars, 1) == FAIL
+ && (check_for_string_or_func_arg(argvars, 0) == FAIL
+ || check_for_list_arg(argvars, 1) == FAIL
|| check_for_opt_dict_arg(argvars, 2) == FAIL))
return;