Skip to content

Commit 61265b4

Browse files
committed
patch 8.2.2114: Vim9: unreachable code in assignment
Problem: Vim9: unreachable code in assignment. Solution: Remove impossible condition and code.
1 parent 1b3e072 commit 61265b4

2 files changed

Lines changed: 2 additions & 10 deletions

File tree

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,6 +750,8 @@ static char *(features[]) =
750750

751751
static int included_patches[] =
752752
{ /* Add new patch number below this line */
753+
/**/
754+
2114,
753755
/**/
754756
2113,
755757
/**/

src/vim9compile.c

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5483,16 +5483,6 @@ compile_assignment(char_u *arg, exarg_T *eap, cmdidx_T cmdidx, cctx_T *cctx)
54835483
}
54845484
}
54855485
}
5486-
else if (name[1] == ':' && name[2] != NUL)
5487-
{
5488-
semsg(_(e_cannot_use_namespaced_variable), name);
5489-
goto theend;
5490-
}
5491-
else if (!is_decl)
5492-
{
5493-
semsg(_(e_unknown_variable_str), name);
5494-
goto theend;
5495-
}
54965486
else if (check_defined(var_start, varlen, cctx) == FAIL)
54975487
goto theend;
54985488
}

0 commit comments

Comments
 (0)