INIT(= N_("E1190: %d arguments too few"));
EXTERN char e_call_to_function_that_failed_to_compile_str[]
INIT(= N_("E1191: Call to function that failed to compile: %s"));
+EXTERN char e_empty_function_name[]
+ INIT(= N_("E1192: Empty function name"));
s = partial_name(pt);
}
else
+ {
s = functv.vval.v_string;
+ if (s == NULL || *s == NUL)
+ {
+ emsg(_(e_empty_function_name));
+ goto theend;
+ }
+ }
}
else
s = (char_u *)"";
funcexe.basetv = basetv;
ret = get_func_tv(s, -1, rettv, arg, evalarg, &funcexe);
+theend:
// Clear the funcref afterwards, so that deleting it while
// evaluating the arguments is possible (see test55).
if (evaluate)
call assert_fails("call call('Mylen', [], 0)", 'E715:')
call assert_fails('call foo', 'E107:')
- " This once caused a crash.
+ " These once caused a crash.
call call(test_null_function(), [])
call call(test_null_partial(), [])
+ call assert_fails('call test_null_function()()', 'E1192:')
+ call assert_fails('call test_null_partial()()', 'E117:')
endfunc
func Test_char2nr()
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 2977,
/**/
2976,
/**/