patch 9.0.1321: vimscript test fails where using {expr} syntax
Problem: vimscript test fails where using {expr} syntax.
Solution: Only return FCERR_FAILED in call_user_func() for Vim9 script.
diff --git a/src/userfunc.c b/src/userfunc.c
index d5dd369..c3b2a25 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -3060,7 +3060,11 @@
clear_tv(rettv);
rettv->v_type = VAR_NUMBER;
rettv->vval.v_number = -1;
- retval = FCERR_FAILED;
+
+ // In corner cases returning a "failed" value is not backwards
+ // compatible. Only do this for Vim9 script.
+ if (in_vim9script())
+ retval = FCERR_FAILED;
}
#ifdef FEAT_PROFILE
diff --git a/src/version.c b/src/version.c
index 20df490..41822fd 100644
--- a/src/version.c
+++ b/src/version.c
@@ -696,6 +696,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1321,
+/**/
1320,
/**/
1319,