diff src/vim9execute.c @ 23788:d12ef361d9de v8.2.2435

patch 8.2.2435: setline() gives an error for some types Commit: https://github.com/vim/vim/commit/3445320839a38b3b0c253513b125da8298ec27d6 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jan 31 13:08:38 2021 +0100 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.
author Bram Moolenaar <Bram@vim.org>
date Sun, 31 Jan 2021 13:15:04 +0100
parents 7caffd835aa1
children 23d6ead591c1
line wrap: on
line diff
--- a/src/vim9execute.c
+++ b/src/vim9execute.c
@@ -879,7 +879,7 @@ do_2string(typval_T *tv, int is_2string_
 				return FAIL;
 	    }
 	}
-	str = typval_tostring(tv);
+	str = typval_tostring(tv, TRUE);
 	clear_tv(tv);
 	tv->v_type = VAR_STRING;
 	tv->vval.v_string = str;