patch 8.2.3626: "au! event" cannot be followed by another command
Problem: "au!" and "au! event" cannot be followed by another command as
documented.
Solution: When a bar is found set nextcmd.
diff --git a/src/autocmd.c b/src/autocmd.c
index 14cd4af..ac21196 100644
--- a/src/autocmd.c
+++ b/src/autocmd.c
@@ -845,6 +845,7 @@
if (*arg == '|')
{
+ eap->nextcmd = arg + 1;
arg = (char_u *)"";
group = AUGROUP_ALL; // no argument, use all groups
}
@@ -869,6 +870,7 @@
pat = skipwhite(pat);
if (*pat == '|')
{
+ eap->nextcmd = pat + 1;
pat = (char_u *)"";
cmd = (char_u *)"";
}
diff --git a/src/testdir/test_autocmd.vim b/src/testdir/test_autocmd.vim
index 045320e..4bdb8dc 100644
--- a/src/testdir/test_autocmd.vim
+++ b/src/testdir/test_autocmd.vim
Binary files differ
diff --git a/src/version.c b/src/version.c
index 8e84cbb..c54307e 100644
--- a/src/version.c
+++ b/src/version.c
@@ -758,6 +758,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 3626,
+/**/
3625,
/**/
3624,