mirror of
https://github.com/vim/vim.git
synced 2025-09-24 03:44:06 -04:00
patch 8.2.0706: Vim9: using assert_fails() causes function to finish
Problem: Vim9: using assert_fails() causes function to finish. Solution: Check did_emsg instead of called_emsg.
This commit is contained in:
@@ -458,7 +458,7 @@ call_bfunc(int func_idx, int argcount, ectx_T *ectx)
|
||||
{
|
||||
typval_T argvars[MAX_FUNC_ARGS];
|
||||
int idx;
|
||||
int called_emsg_before = called_emsg;
|
||||
int did_emsg_before = did_emsg;
|
||||
|
||||
if (call_prepare(argcount, argvars, ectx) == FAIL)
|
||||
return FAIL;
|
||||
@@ -470,7 +470,7 @@ call_bfunc(int func_idx, int argcount, ectx_T *ectx)
|
||||
for (idx = 0; idx < argcount; ++idx)
|
||||
clear_tv(&argvars[idx]);
|
||||
|
||||
if (called_emsg != called_emsg_before)
|
||||
if (did_emsg != did_emsg_before)
|
||||
return FAIL;
|
||||
return OK;
|
||||
}
|
||||
|
Reference in New Issue
Block a user