summaryrefslogtreecommitdiffstats
path: root/src/userfunc.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2021-07-08 20:57:24 +0200
committerBram Moolenaar <Bram@vim.org>2021-07-08 20:57:24 +0200
commitf055d4502365f24de6c0f210a06e2c146a75dc4d (patch)
tree507f31a2d9b5a7ff03b410f1be7066ca97fdb0d9 /src/userfunc.c
parentf32f099761e5ae0603149b305a0086e4f4627d81 (diff)
patch 8.2.3128: Vim9: uninitialzed list does not get type checkedv8.2.3128
Problem: Vim9: uninitialzed list does not get type checked. Solution: Set the type when initializing the variable. (closes #8529)
Diffstat (limited to 'src/userfunc.c')
-rw-r--r--src/userfunc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/userfunc.c b/src/userfunc.c
index 4234681cd7..4ab7cc18bc 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -1512,7 +1512,7 @@ deref_func_name(
{
if (type != NULL && ht == get_script_local_ht())
{
- svar_T *sv = find_typval_in_script(&v->di_tv);
+ svar_T *sv = find_typval_in_script(&v->di_tv, TRUE);
if (sv != NULL)
*type = sv->sv_type;