]> granicus.if.org Git - vim/commitdiff
patch 8.2.2143: Vim9: dead code in compiling :unlet v8.2.2143
authorBram Moolenaar <Bram@vim.org>
Sun, 13 Dec 2020 20:26:56 +0000 (21:26 +0100)
committerBram Moolenaar <Bram@vim.org>
Sun, 13 Dec 2020 20:26:56 +0000 (21:26 +0100)
Problem:    Vim9: dead code in compiling :unlet.
Solution:   Don't check for "!" a second time.

src/version.c
src/vim9compile.c

index be7e4f088778f5df188313f1f6bbc8a71a51d06f..be8c64a5e53b45773d802ab8e50a9dac9d2ca66c 100644 (file)
@@ -750,6 +750,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2143,
 /**/
     2142,
 /**/
index 3fae25e1152c6f58227a467e5d894f0998ddf374..86d3260d96f8f1ad6c2f0a7796be70326ed06f68 100644 (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;
 }