Problem: Test failures with legacy Vim script.
Solution: Actually check for Vim9 script.
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1311,
/**/
1310,
/**/
int
not_in_vim9(exarg_T *eap)
{
- switch (eap->cmdidx)
- {
- case CMD_insert:
- case CMD_append:
- case CMD_change:
- case CMD_xit:
- semsg(_("E1100: Missing :let: %s"), eap->cmd);
- return FAIL;
- default: break;
- }
+ if (in_vim9script())
+ switch (eap->cmdidx)
+ {
+ case CMD_insert:
+ case CMD_append:
+ case CMD_change:
+ case CMD_xit:
+ semsg(_("E1100: Missing :let: %s"), eap->cmd);
+ return FAIL;
+ default: break;
+ }
return OK;
}