-*builtin.txt* For Vim version 9.1. Last change: 2025 Apr 21
+*builtin.txt* For Vim version 9.1. Last change: 2025 Apr 23
VIM REFERENCE MANUAL by Bram Moolenaar
Return type: |Number|
-cmdcomplete_info([{what}]) *cmdcomplete_info()*
+cmdcomplete_info() *cmdcomplete_info()*
Returns a |Dictionary| with information about cmdline
completion. See |cmdline-completion|.
The items are:
// Save cmdline before expansion
if (ccline->cmdbuff != NULL)
+ {
+ vim_free(cmdline_orig);
cmdline_orig = vim_strnsave(ccline->cmdbuff, ccline->cmdlen);
+ }
if (xp->xp_numfiles == -1)
{
}
// Trigger CmdlineLeavePre autocommand
- if (ccline.cmdfirstc != NUL && (c == '\n' || c == '\r' || c == K_KENTER
- || c == ESC || c == Ctrl_C))
+ if (c == '\n' || c == '\r' || c == K_KENTER || c == ESC || c == Ctrl_C)
trigger_cmd_autocmd(cmdline_type, EVENT_CMDLINELEAVEPRE);
// The wildmenu is cleared if the pressed key is not used for
call assert_equal('', g:log)
call feedkeys(":echo hello", "tx")
call assert_equal('CmdlineLeavePre', g:log)
+ let g:count = 0
+ autocmd CmdlineLeavePre * let g:count += 1
+ call feedkeys(":let c = input('? ')\<cr>B\<cr>", "tx")
+ call assert_equal(2, g:count)
+ unlet! g:count
+ unlet! g:log
bw!
endfunc
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1331,
/**/
1330,
/**/