summaryrefslogtreecommitdiff
path: root/src/ex_cmds.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-05-27 20:23:44 +0000
committerBram Moolenaar <Bram@vim.org>2005-05-27 20:23:44 +0000
commit0e6830e0098ba8c1a95c3b4ef9939666e8b9aba7 (patch)
treec37ceca643305657f02e970d6925fe6f3f5923ec /src/ex_cmds.c
parent21de6660e1be5900a9ca1991aeda7a115f03105f (diff)
downloadvim-0e6830e0098ba8c1a95c3b4ef9939666e8b9aba7.zip
updated for version 7.0076
Diffstat (limited to 'src/ex_cmds.c')
-rw-r--r--src/ex_cmds.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index 20bba1c8b..a8083b32e 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -327,7 +327,14 @@ ex_sort(eap)
sort_ic = TRUE;
else if (*p == 'u')
unique = TRUE;
- else if (!ASCII_ISALPHA(*p))
+ else if (*p == '"') /* comment start */
+ break;
+ else if (check_nextcmd(p) != NULL)
+ {
+ eap->nextcmd = check_nextcmd(p);
+ break;
+ }
+ else if (!ASCII_ISALPHA(*p) && regmatch.regprog == NULL)
{
s = skip_regexp(p + 1, *p, TRUE, NULL);
if (*s != *p)
@@ -339,7 +346,7 @@ ex_sort(eap)
regmatch.regprog = vim_regcomp(p + 1, RE_MAGIC);
if (regmatch.regprog == NULL)
goto theend;
- p = s + 1;
+ p = s; /* continue after the regexp */
regmatch.rm_ic = p_ic;
}
else