mirror of
https://github.com/neovim/neovim.git
synced 2026-08-27 01:21:48 +00:00
vim-patch:8.2.1571: Vim9: count() third argument cannot be "true"
Problem: Vim9: count() third argument cannot be "true".
Solution: use tv_get_bool_chk(). (closes vim/vim#6818)
119f557230
Co-authored-by: Bram Moolenaar <Bram@vim.org>
This commit is contained in:
@@ -540,7 +540,7 @@ void f_count(typval_T *argvars, typval_T *rettv, EvalFuncData fptr)
|
||||
bool error = false;
|
||||
|
||||
if (argvars[2].v_type != VAR_UNKNOWN) {
|
||||
ic = (int)tv_get_number_chk(&argvars[2], &error);
|
||||
ic = (int)tv_get_bool_chk(&argvars[2], &error);
|
||||
}
|
||||
|
||||
if (!error && argvars[0].v_type == VAR_STRING) {
|
||||
|
||||
Reference in New Issue
Block a user