0
0
mirror of https://github.com/vim/vim.git synced 2025-09-29 04:34:16 -04:00

patch 8.2.4503: Vim9: there is no point in supporting :Print and :mode

Problem:    Vim9: there is no point in supporting :Print and :mode.
Solution:   Do not recognize :Print and :mode as commands. (closes #9870)
This commit is contained in:
Bram Moolenaar
2022-03-04 17:10:19 +00:00
parent d979d64fa2
commit 6aca4d3c2b
3 changed files with 21 additions and 10 deletions

View File

@@ -3752,6 +3752,10 @@ find_ex_command(
break;
}
// :Print and :mode are not supported in Vim9 script
if (vim9 && (eap->cmdidx == CMD_mode || eap->cmdidx == CMD_Print))
eap->cmdidx = CMD_SIZE;
// Do not recognize ":*" as the star command unless '*' is in
// 'cpoptions'.
if (eap->cmdidx == CMD_star && vim_strchr(p_cpo, CPO_STAR) == NULL)