patch 8.2.4163: no error for omitting function name after autoload prefix
Problem: No error for omitting function name after autoload prefix.
Solution: Check for missing function name. (issue #9577)
diff --git a/src/userfunc.c b/src/userfunc.c
index 014ec55..680017c 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -3693,7 +3693,8 @@
// Note that TFN_ flags use the same values as GLV_ flags.
end = get_lval(start, NULL, &lv, FALSE, skip, flags | GLV_READ_ONLY,
lead > 2 ? 0 : FNE_CHECK_START);
- if (end == start)
+ if (end == start
+ || (end != NULL && end[-1] == AUTOLOAD_CHAR && *end == '('))
{
if (!skip)
emsg(_(e_function_name_required));