Patch 8.2.1604
Problem: Vim9: cannot use "true" with getcompletion().
Solution: use tv_get_bool_chk(). (closes #6875)
Files: src/cmdexpand.c, src/testdir/test_vim9_func.vim
*** ../vim-8.2.1603/src/cmdexpand.c 2020-09-04 15:37:27.861546325 +0200
--- src/cmdexpand.c 2020-09-05 18:02:18.057037418 +0200
***************
*** 2885,2891 ****
type = tv_get_string(&argvars[1]);
if (argvars[2].v_type != VAR_UNKNOWN)
! filtered = tv_get_number_chk(&argvars[2], NULL);
if (p_wic)
options |= WILD_ICASE;
--- 2885,2891 ----
type = tv_get_string(&argvars[1]);
if (argvars[2].v_type != VAR_UNKNOWN)
! filtered = tv_get_bool_chk(&argvars[2], NULL);
if (p_wic)
options |= WILD_ICASE;
*** ../vim-8.2.1603/src/testdir/test_vim9_func.vim 2020-09-05
17:51:19.626561774 +0200
--- src/testdir/test_vim9_func.vim 2020-09-05 18:04:59.772704143 +0200
***************
*** 1509,1514 ****
--- 1509,1521 ----
assert_equal(0, getchar(true))
enddef
+ def Test_getcompletion()
+ set wildignore=*.vim,*~
+ let l = getcompletion('run', 'file', true)
+ assert_equal([], l)
+ set wildignore&
+ enddef
+
def Fibonacci(n: number): number
if n < 2
return n
*** ../vim-8.2.1603/src/version.c 2020-09-05 17:51:19.626561774 +0200
--- src/version.c 2020-09-05 18:01:20.113150602 +0200
***************
*** 756,757 ****
--- 756,759 ----
{ /* Add new patch number below this line */
+ /**/
+ 1604,
/**/
--
ARTHUR: I command you as King of the Britons to stand aside!
BLACK KNIGHT: I move for no man.
The Quest for the Holy Grail (Monty Python)
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/202009051631.085GVxeF649564%40masaka.moolenaar.net.