diff src/match.c @ 21459:a422bd80b434 v8.2.1280

patch 8.2.1280: Ex command error cannot contain an argument Commit: https://github.com/vim/vim/commit/8930caaa1a283092aca81fdbc3fcf15c7eadb197 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jul 23 16:37:03 2020 +0200 patch 8.2.1280: Ex command error cannot contain an argument Problem: Ex command error cannot contain an argument. Solution: Add ex_errmsg() and translate earlier. Use e_trailing_arg where possible.
author Bram Moolenaar <Bram@vim.org>
date Thu, 23 Jul 2020 16:45:03 +0200
parents b1fac55cf8a3
children 0deb6f96a5a3
line wrap: on
line diff
--- a/src/match.c
+++ b/src/match.c
@@ -1329,7 +1329,7 @@ ex_match(exarg_T *eap)
 	    if (*end != NUL && !ends_excmd2(end, skipwhite(end + 1)))
 	    {
 		vim_free(g);
-		eap->errmsg = e_trailing;
+		eap->errmsg = ex_errmsg(e_trailing_arg, end);
 		return;
 	    }
 	    if (*end != *p)