vim-patch:8.1.0619: :echomsg and :echoerr do not handle List and Dict

Problem:    :echomsg and :echoerr do not handle List and Dict like :echo does.
            (Daniel Hahler)
Solution:   Be more tolerant about the expression result type.
461a7fcfce

Add lua functional tests for :echo,:echon,:echomsg,:echoerr
because nvim did not port "test_" functions from Vim
that modify internal state.

Testing :echoerr via try/catch is sufficient.
This commit is contained in:
Jan Edmund Lazo
2020-02-02 15:55:15 -05:00
parent 1656367b90
commit 3c12ee333a
5 changed files with 178 additions and 54 deletions

View File

@@ -9558,7 +9558,7 @@ static void f_stridx(typval_T *argvars, typval_T *rettv, FunPtr fptr)
/*
* "string()" function
*/
static void f_string(typval_T *argvars, typval_T *rettv, FunPtr fptr)
void f_string(typval_T *argvars, typval_T *rettv, FunPtr fptr)
{
rettv->v_type = VAR_STRING;
rettv->vval.v_string = (char_u *)encode_tv2string(&argvars[0], NULL);