mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.2.2332: Vim9: missing :endif not reported when using :windo
Problem: Vim9: missing :endif not reported when using :windo. Solution: Pass a getline function to do_cmdline(). (closes #7650)
This commit is contained in:
@@ -1382,9 +1382,18 @@ call_def_function(
|
||||
// execute Ex command line
|
||||
case ISN_EXEC:
|
||||
{
|
||||
source_cookie_T cookie;
|
||||
|
||||
SOURCING_LNUM = iptr->isn_lnum;
|
||||
do_cmdline_cmd(iptr->isn_arg.string);
|
||||
if (did_emsg)
|
||||
// Pass getsourceline to get an error for a missing ":end"
|
||||
// command.
|
||||
CLEAR_FIELD(cookie);
|
||||
cookie.sourcing_lnum = iptr->isn_lnum - 1;
|
||||
if (do_cmdline(iptr->isn_arg.string,
|
||||
getsourceline, &cookie,
|
||||
DOCMD_VERBOSE|DOCMD_NOWAIT|DOCMD_KEYTYPED)
|
||||
== FAIL
|
||||
|| did_emsg)
|
||||
goto on_error;
|
||||
}
|
||||
break;
|
||||
|
Reference in New Issue
Block a user