1
0
forked from aniani/vim

patch 8.2.2143: Vim9: dead code in compiling :unlet

Problem:    Vim9: dead code in compiling :unlet.
Solution:   Don't check for "!" a second time.
This commit is contained in:
Bram Moolenaar 2020-12-13 21:26:56 +01:00
parent fffdf4754f
commit ec792290eb
2 changed files with 3 additions and 7 deletions

View File

@ -750,6 +750,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
2143,
/**/
2142,
/**/

View File

@ -5993,7 +5993,7 @@ compile_assignment(char_u *arg, exarg_T *eap, cmdidx_T cmdidx, cctx_T *cctx)
// for "[var, var] = expr" drop the "expr" value
if (var_count > 0 && !semicolon)
{
if (generate_instr_drop(cctx, ISN_DROP, 1) == NULL)
if (generate_instr_drop(cctx, ISN_DROP, 1) == NULL)
goto theend;
}
@ -6074,12 +6074,6 @@ compile_unletlock(char_u *arg, exarg_T *eap, cctx_T *cctx)
return NULL;
}
if (*p == '!')
{
p = skipwhite(p + 1);
eap->forceit = TRUE;
}
ex_unletlock(eap, p, 0, GLV_NO_AUTOLOAD, compile_unlet, cctx);
return eap->nextcmd == NULL ? (char_u *)"" : eap->nextcmd;
}