diff options
author | Bram Moolenaar <Bram@vim.org> | 2004-06-20 12:51:53 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2004-06-20 12:51:53 +0000 |
commit | 69a7cb473ceae109b61fae9aa04ee0c29afba5d9 (patch) | |
tree | 04bd3292cc6c2317842d7a46ae3ab11e9956ed99 /src/ex_docmd.c | |
parent | ed20346f0b81d1d89c22c9616abe8e47b4c17f08 (diff) | |
download | vim-69a7cb473ceae109b61fae9aa04ee0c29afba5d9.zip |
updated for version 7.0002
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r-- | src/ex_docmd.c | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c index c4b9012ca..af8d3fc7c 100644 --- a/src/ex_docmd.c +++ b/src/ex_docmd.c @@ -2319,8 +2319,8 @@ do_one_cmd(cmdlinep, sourcing, } } /* no arguments allowed */ - if (!ni && !(ea.argt & EXTRA) && *ea.arg != NUL && - vim_strchr((char_u *)"|\"", *ea.arg) == NULL) + if (!ni && !(ea.argt & EXTRA) && *ea.arg != NUL + && vim_strchr((char_u *)"|\"", *ea.arg) == NULL) { errormsg = (char_u *)_(e_trailing); goto doend; @@ -3885,6 +3885,17 @@ expand_filename(eap, cmdlinep, errormsgp) has_wildcards = mch_has_wildcard(eap->arg); for (p = eap->arg; *p; ) { +#ifdef FEAT_EVAL + /* Skip over `=expr`, wildcards in it are not expanded. */ + if (p[0] == '`' && p[1] == '=') + { + p += 2; + (void)skip_expr(&p); + if (*p == '`') + ++p; + continue; + } +#endif /* * Quick check if this cannot be the start of a special string. * Also removes backslash before '%', '#' and '<'. @@ -4157,6 +4168,18 @@ separate_nextcmd(eap) if (*p == NUL) /* stop at NUL after CTRL-V */ break; } + +#ifdef FEAT_EVAL + /* Skip over `=expr` when wildcards are expanded. */ + else if (p[0] == '`' && p[1] == '=') + { + p += 2; + (void)skip_expr(&p); + if (*p == '`') + ++p; + } +#endif + /* Check for '"': start of comment or '|': next command */ /* :@" and :*" do not start a comment! * :redir @" doesn't either. */ |