0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

patch 8.2.2435: setline() gives an error for some types

Problem:    setline() gives an error for some types.
Solution:   Allow any type, convert each item to a string.
This commit is contained in:
Bram Moolenaar
2021-01-31 13:08:38 +01:00
parent f2b26bcf8f
commit 3445320839
9 changed files with 96 additions and 20 deletions

View File

@@ -879,7 +879,7 @@ do_2string(typval_T *tv, int is_2string_any)
return FAIL;
}
}
str = typval_tostring(tv);
str = typval_tostring(tv, TRUE);
clear_tv(tv);
tv->v_type = VAR_STRING;
tv->vval.v_string = str;