diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-10-17 19:29:51 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-10-17 19:29:51 +0200 |
commit | 403dc31f5a03b5858f62e72c3407ffaf827b3005 (patch) | |
tree | fd71a65d97628331a9bc55d491ca49bf37e0c3f9 /src/popupwin.c | |
parent | 218450ad5ea1f9f033b06754a29502d86100ff65 (diff) |
patch 8.2.1858: Vim9: filter functions return number instead of boolv8.2.1858
Problem: Vim9: filter functions return number instead of bool.
Solution: Return v:true instead of one. (closes #7144)
Diffstat (limited to 'src/popupwin.c')
-rw-r--r-- | src/popupwin.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/popupwin.c b/src/popupwin.c index 777e7d84b1..2868a9da39 100644 --- a/src/popupwin.c +++ b/src/popupwin.c @@ -2375,7 +2375,8 @@ f_popup_filter_menu(typval_T *argvars, typval_T *rettv) c = TO_SPECIAL(key[1], key[2]); // consume all keys until done - rettv->vval.v_number = 1; + rettv->v_type = VAR_BOOL; + rettv->vval.v_number = VVAL_TRUE; res.v_type = VAR_NUMBER; old_lnum = wp->w_cursor.lnum; @@ -2429,7 +2430,8 @@ f_popup_filter_yesno(typval_T *argvars, typval_T *rettv) c = TO_SPECIAL(key[1], key[2]); // consume all keys until done - rettv->vval.v_number = 1; + rettv->v_type = VAR_BOOL; + rettv->vval.v_number = VVAL_TRUE; if (c == 'y' || c == 'Y') res.vval.v_number = 1; |