Patch 9.0.1040

5 views
Skip to first unread message

Bram Moolenaar

unread,
Dec 9, 2022, 7:42:05 AM12/9/22
to vim...@googlegroups.com

Patch 9.0.1040 (after 9.0.1039)
Problem: Test for <Cmd> mapping with CmdlineChanged fails.
Solution: Put back the check for the cmdline length not changing.
Files: src/ex_getln.c


*** ../vim-9.0.1039/src/ex_getln.c 2022-12-09 12:21:46.473444271 +0000
--- src/ex_getln.c 2022-12-09 12:38:46.535484568 +0000
***************
*** 1785,1797 ****

if (c == K_COMMAND || c == K_SCRIPT_COMMAND)
{
int cc_count = aucmd_cmdline_changed_count;

if (do_cmdkey_command(c, DOCMD_NOWAIT) == OK)
{
! // Do not trigger CmdlineChanged below if the <Cmd> mapping
! // already did that.
! if (cc_count != aucmd_cmdline_changed_count)
trigger_cmdlinechanged = FALSE;
goto cmdline_changed;
}
--- 1785,1800 ----

if (c == K_COMMAND || c == K_SCRIPT_COMMAND)
{
+ int clen = ccline.cmdlen;
int cc_count = aucmd_cmdline_changed_count;

if (do_cmdkey_command(c, DOCMD_NOWAIT) == OK)
{
! // Do not trigger CmdlineChanged below if:
! // - the length of the command line didn't change
! // - the <Cmd> mapping already triggered the event
! if (clen == ccline.cmdlen
! || cc_count != aucmd_cmdline_changed_count)
trigger_cmdlinechanged = FALSE;
goto cmdline_changed;
}
*** ../vim-9.0.1039/src/version.c 2022-12-09 12:21:46.473444271 +0000
--- src/version.c 2022-12-09 12:41:12.362910734 +0000
***************
*** 697,698 ****
--- 697,700 ----
{ /* Add new patch number below this line */
+ /**/
+ 1040,
/**/

--
We're knights of the Round Table
Our shows are formidable
But many times
We're given rhymes
That are quite unsingable
We're opera mad in Camelot
We sing from the diaphragm a lot.
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Reply all
Reply to author
Forward
0 new messages