patch 8.2.0200: Vim9 script commands not sufficiently tested
Problem: Vim9 script commands not sufficiently tested.
Solution: Add more tests. Fix storing global variable. Make script
variables work.
diff --git a/src/misc1.c b/src/misc1.c
index 85ab727..bb7137d 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -1854,6 +1854,22 @@
/*
+ * Set environment variable "name" and take care of side effects.
+ */
+ void
+vim_setenv_ext(char_u *name, char_u *val)
+{
+ vim_setenv(name, val);
+ if (STRICMP(name, "HOME") == 0)
+ init_homedir();
+ else if (didset_vim && STRICMP(name, "VIM") == 0)
+ didset_vim = FALSE;
+ else if (didset_vimruntime
+ && STRICMP(name, "VIMRUNTIME") == 0)
+ didset_vimruntime = FALSE;
+}
+
+/*
* Our portable version of setenv.
*/
void