mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 8.2.1480: Vim9: skip expression in search() gives error
Problem: Vim9: skip expression in search() gives error. Solution: use tv_get_bool() eval_expr_to_bool(). (closes #6729)
This commit is contained in:
11
src/typval.c
11
src/typval.c
@@ -270,6 +270,17 @@ tv_get_bool(typval_T *varp)
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
* Get the boolean value of "varp". This is like tv_get_number_chk(),
|
||||
* but in Vim9 script accepts Number and Bool.
|
||||
*/
|
||||
varnumber_T
|
||||
tv_get_bool_chk(typval_T *varp, int *denote)
|
||||
{
|
||||
return tv_get_bool_or_number_chk(varp, denote, TRUE);
|
||||
|
||||
}
|
||||
|
||||
#ifdef FEAT_FLOAT
|
||||
float_T
|
||||
tv_get_float(typval_T *varp)
|
||||
|
Reference in New Issue
Block a user