1
0
forked from aniani/vim

patch 8.2.3152: Vim9: accessing "s:" results in an error

Problem:    Vim9: accessing "s:" results in an error.
Solution:   Do not try to lookup a script variable for "s:". (closes #8549)
This commit is contained in:
Bram Moolenaar
2021-07-11 20:59:00 +02:00
parent ffcfddc759
commit 11005b078d
3 changed files with 11 additions and 1 deletions

View File

@@ -2660,7 +2660,8 @@ eval_variable(
}
else if (rettv != NULL)
{
if (ht != NULL && ht == get_script_local_ht())
if (ht != NULL && ht == get_script_local_ht()
&& tv != &SCRIPT_SV(current_sctx.sc_sid)->sv_var.di_tv)
{
svar_T *sv = find_typval_in_script(tv);