diff src/ex_docmd.c @ 21893:f19ac9b8b011 v8.2.1496

patch 8.2.1496: Vim9: cannot use " #" in a mapping Commit: https://github.com/vim/vim/commit/b8a9296cedb9fae35572041ef5cfa894f3ad9fbb Author: Bram Moolenaar <Bram@vim.org> Date: Thu Aug 20 18:02:47 2020 +0200 patch 8.2.1496: Vim9: cannot use " #" in a mapping Problem: Vim9: cannot use " #" in a mapping. Solution: Do not remove a comment with the EX_NOTRLCOM flag. (closes https://github.com/vim/vim/issues/6746)
author Bram Moolenaar <Bram@vim.org>
date Thu, 20 Aug 2020 18:15:03 +0200
parents 72525eabfe61
children b931df03adcc
line wrap: on
line diff
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -4604,6 +4604,7 @@ separate_nextcmd(exarg_T *eap)
 #ifdef FEAT_EVAL
 		|| (*p == '#'
 		    && in_vim9script()
+		    && !(eap->argt & EX_NOTRLCOM)
 		    && p[1] != '{'
 		    && p > eap->cmd && VIM_ISWHITE(p[-1]))
 #endif