patch 8.1.1957: more code can be moved to evalvars.c

Problem:    More code can be moved to evalvars.c.
Solution:   Move code to where it fits better. (Yegappan Lakshmanan,
            closes #4883)
diff --git a/src/viminfo.c b/src/viminfo.c
index 608c5cc..276e1b3 100644
--- a/src/viminfo.c
+++ b/src/viminfo.c
@@ -1277,6 +1277,7 @@
     static void
 write_viminfo_varlist(FILE *fp)
 {
+    hashtab_T	*gvht = get_globvar_ht();
     hashitem_T	*hi;
     dictitem_T	*this_var;
     int		todo;
@@ -1290,8 +1291,8 @@
 
     fputs(_("\n# global variables:\n"), fp);
 
-    todo = (int)globvarht.ht_used;
-    for (hi = globvarht.ht_array; todo > 0; ++hi)
+    todo = (int)gvht->ht_used;
+    for (hi = gvht->ht_array; todo > 0; ++hi)
     {
 	if (!HASHITEM_EMPTY(hi))
 	{