patch 8.2.4030: a script local funcref is not found from a mapping
Problem: A script local funcref is not found from a mapping.
Solution: When looking for a function, also find a script-local funcref.
(closes #9485)
diff --git a/src/userfunc.c b/src/userfunc.c
index 7446d6e..6821569 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -1589,7 +1589,7 @@
cc = name[*lenp];
name[*lenp] = NUL;
- v = find_var(name, &ht, no_autoload);
+ v = find_var_also_in_script(name, &ht, no_autoload);
name[*lenp] = cc;
if (v != NULL)
{