To: vim_dev@googlegroups.com Subject: Patch 8.2.2415 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.2415 Problem: No way to check for the cmdwin feature, cmdline_hist is now always enabled. Solution: Add has('cmdwin') support. Skip arglist test on Windows temporarily. Files: runtime/doc/cmdline.txt, src/evalfunc.c, src/testdir/test_autocmd.vim, src/testdir/test_arglist.vim, src/testdir/test_cmdline.vim, src/testdir/test_ins_complete.vim, src/testdir/test_normal.vim, src/testdir/test_tabpage.vim, src/testdir/test_termcodes.vim, src/testdir/test_window_cmd.vim *** ../vim-8.2.2414/runtime/doc/cmdline.txt 2020-07-26 15:36:12.959172993 +0200 --- runtime/doc/cmdline.txt 2021-01-26 22:26:27.905473276 +0100 *************** *** 1077,1083 **** In the command-line window the command line can be edited just like editing text in any window. It is a special kind of window, because you cannot leave it in a normal way. ! {not available when compiled without the |+cmdline_hist| feature} OPEN *c_CTRL-F* *q:* *q/* *q?* --- 1096,1102 ---- In the command-line window the command line can be edited just like editing text in any window. It is a special kind of window, because you cannot leave it in a normal way. ! {not available when compiled without the |+cmdwin| feature} OPEN *c_CTRL-F* *q:* *q/* *q?* *** ../vim-8.2.2414/src/evalfunc.c 2021-01-22 22:31:06.676005413 +0100 --- src/evalfunc.c 2021-01-26 22:24:25.061841721 +0100 *************** *** 4651,4656 **** --- 4651,4663 ---- }, {"cmdline_compl", 1}, {"cmdline_hist", 1}, + {"cmdwin", + #ifdef FEAT_CMDWIN + 1 + #else + 0 + #endif + }, {"comments", 1}, {"conceal", #ifdef FEAT_CONCEAL *** ../vim-8.2.2414/src/testdir/test_autocmd.vim 2021-01-16 13:11:39.102733790 +0100 --- src/testdir/test_autocmd.vim 2021-01-26 22:26:06.009538196 +0100 *************** *** 2397,2406 **** func Test_autocmd_CmdWinEnter() CheckRunVimInTerminal ! " There is not cmdwin switch, so ! " test for cmdline_hist ! " (both are available with small builds) ! CheckFeature cmdline_hist let lines =<< trim END let b:dummy_var = 'This is a dummy' autocmd CmdWinEnter * quit --- 2397,2404 ---- func Test_autocmd_CmdWinEnter() CheckRunVimInTerminal ! CheckFeature cmdwin ! let lines =<< trim END let b:dummy_var = 'This is a dummy' autocmd CmdWinEnter * quit *** ../vim-8.2.2414/src/testdir/test_arglist.vim 2021-01-26 21:35:05.048158026 +0100 --- src/testdir/test_arglist.vim 2021-01-26 22:40:17.583159089 +0100 *************** *** 527,532 **** --- 527,533 ---- " Test for quitting Vim with unedited files in the argument list func Test_quit_with_arglist() CheckRunVimInTerminal + let buf = RunVimInTerminal('', {'rows': 6}) call term_sendkeys(buf, ":set nomore\n") call term_sendkeys(buf, ":args a b c\n") *************** *** 561,569 **** " Test for ":all" not working when in the cmdline window func Test_all_not_allowed_from_cmdwin() au BufEnter * all next x ! call assert_fails(":norm 7q?x\", 'E11:') au! BufEnter endfunc --- 562,574 ---- " Test for ":all" not working when in the cmdline window func Test_all_not_allowed_from_cmdwin() + CheckFeature cmdwin + " TODO: why does this hang on Windows? + CheckNotMSWindows + au BufEnter * all next x ! call assert_fails(":norm 7q?print\", 'E11:') au! BufEnter endfunc *** ../vim-8.2.2414/src/testdir/test_cmdline.vim 2021-01-13 19:48:41.628312470 +0100 --- src/testdir/test_cmdline.vim 2021-01-26 22:31:01.940683415 +0100 *************** *** 129,135 **** endfunc func Test_map_completion() - CheckFeature cmdline_compl call feedkeys(":map \\"\", 'xt') call assert_equal('"map ', getreg(':')) call feedkeys(":map