1
0
forked from aniani/vim

patch 8.2.3650: Vim9: for loop variable can be a list member

Problem:    Vim9: for loop variable can be a list member.
Solution:   Check for valid variable name. (closes #9179)
This commit is contained in:
Bram Moolenaar
2021-11-22 20:10:18 +00:00
parent 7a53f29c03
commit 3b3755fe19
7 changed files with 38 additions and 9 deletions

View File

@@ -1102,7 +1102,7 @@ dict_extend(dict_T *d1, dict_T *d2, char_u *action, char *func_name)
&& HI2DI(hi2)->di_tv.v_type == VAR_FUNC
&& var_wrong_func_name(hi2->hi_key, di1 == NULL))
break;
if (!valid_varname(hi2->hi_key, TRUE))
if (!valid_varname(hi2->hi_key, -1, TRUE))
break;
}