Ozaki Kiichi wrote:
> Since 7.4.1989, filter()/map() cause SEGV when 2nd argument is number.
>
> [repro steps]
>
> vim -Nu NONE
>
> :call filter([0], 0)
>
> [cause]
>
> https://github.com/vim/vim/blob/245a7cb/src/eval.c#L12054
> https://github.com/vim/vim/blob/245a7cb/src/eval.c#L12073
>
> It needs type-checking (or value-convertion) before calling 'skipwhite()'.
>
> [patch]
>
> Calling 'get_tv_string_buf_chk()' to convert the value of 'expr' to string.
>
> https://gist.github.com/ichizok/edca7401330a988501993e170d1388e8
Thanks!
--
"The amigos also appear to be guilty of not citing the work of others who had
gone before them. Even worse, they have a chapter about modeling time and
space without making a single reference to Star Trek!"
(Scott Ambler, reviewing the UML User Guide)
/// 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].
For more options, visit https://groups.google.com/d/optout.