diff options
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r-- | src/ex_docmd.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c index d74ef9026..6d2923ccb 100644 --- a/src/ex_docmd.c +++ b/src/ex_docmd.c @@ -2910,7 +2910,14 @@ parse_command_modifiers( int c = 0; if (!checkforcmd_noparen(&p, "filter", 4) - || *p == NUL || ends_excmd(*p)) + || *p == NUL + || (ends_excmd(*p) +#ifdef FEAT_EVAL + // in ":filter #pat# cmd" # does not + // start a comment + && (!in_vim9script() || VIM_ISWHITE(p[1])) +#endif + )) break; if (*p == '!') { |