0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

patch 8.2.0199: Vim9 script commands not sufficiently tested

Problem:    Vim9 script commands not sufficiently tested.
Solution:   Add more tests.  Fix script-local function use.
This commit is contained in:
Bram Moolenaar
2020-02-02 17:22:27 +01:00
parent 43c60eda2a
commit 0f18b6d17b
4 changed files with 58 additions and 11 deletions

View File

@@ -1502,21 +1502,26 @@ failed:
ex_disassemble(exarg_T *eap)
{
#ifdef DISASSEMBLE
ufunc_T *ufunc = find_func(eap->arg, NULL);
char_u *fname;
ufunc_T *ufunc;
dfunc_T *dfunc;
isn_T *instr;
int current;
int line_idx = 0;
int prev_current = 0;
fname = trans_function_name(&eap->arg, FALSE,
TFN_INT | TFN_QUIET | TFN_NO_AUTOLOAD | TFN_NO_DEREF, NULL, NULL);
ufunc = find_func(fname, NULL);
vim_free(fname);
if (ufunc == NULL)
{
semsg("Cannot find function %s", eap->arg);
semsg("E1061: Cannot find function %s", eap->arg);
return;
}
if (ufunc->uf_dfunc_idx < 0)
{
semsg("Function %s is not compiled", eap->arg);
semsg("E1062: Function %s is not compiled", eap->arg);
return;
}
if (ufunc->uf_name_exp != NULL)