Patch 8.2.3431

5 views
Skip to first unread message

Bram Moolenaar

unread,
Sep 12, 2021, 9:46:07 AM9/12/21
to vim...@googlegroups.com

Patch 8.2.3431
Problem: Completion for :disas sorts local functions first.
Solution: Sort local functions last, like with :delfunc. (Naohiro Ono,
closes #8860)
Files: src/cmdexpand.c, src/testdir/test_cmdline.vim


*** ../vim-8.2.3430/src/cmdexpand.c 2021-09-01 13:03:31.422768900 +0200
--- src/cmdexpand.c 2021-09-12 13:50:39.833604762 +0200
***************
*** 2262,2268 ****
{
if (xp->xp_context == EXPAND_EXPRESSION
|| xp->xp_context == EXPAND_FUNCTIONS
! || xp->xp_context == EXPAND_USER_FUNC)
// <SNR> functions should be sorted to the end.
qsort((void *)*file, (size_t)*num_file, sizeof(char_u *),
sort_func_compare);
--- 2262,2269 ----
{
if (xp->xp_context == EXPAND_EXPRESSION
|| xp->xp_context == EXPAND_FUNCTIONS
! || xp->xp_context == EXPAND_USER_FUNC
! || xp->xp_context == EXPAND_DISASSEMBLE)
// <SNR> functions should be sorted to the end.
qsort((void *)*file, (size_t)*num_file, sizeof(char_u *),
sort_func_compare);
*** ../vim-8.2.3430/src/testdir/test_cmdline.vim 2021-09-08 14:29:43.117509762 +0200
--- src/testdir/test_cmdline.vim 2021-09-12 13:50:39.837604753 +0200
***************
*** 854,859 ****
--- 854,864 ----
call feedkeys(":disas s:WeirdF\<C-A>\<C-B>\"\<CR>", 'xt')
call assert_match('"disas <SNR>\d\+_WeirdFunc', @:)

+ call feedkeys(":disas \<S-Tab>\<C-B>\"\<CR>", 'xt')
+ call assert_match('"disas <SNR>\d\+_', @:)
+ call feedkeys(":disas debug \<S-Tab>\<C-B>\"\<CR>", 'xt')
+ call assert_match('"disas debug <SNR>\d\+_', @:)
+
" completion for the :match command
call feedkeys(":match Search /pat/\<C-A>\<C-B>\"\<CR>", 'xt')
call assert_equal("\"match Search /pat/\<C-A>", @:)
*** ../vim-8.2.3430/src/version.c 2021-09-12 13:39:04.327467410 +0200
--- src/version.c 2021-09-12 13:52:20.925388698 +0200
***************
*** 757,758 ****
--- 757,760 ----
{ /* Add new patch number below this line */
+ /**/
+ 3431,
/**/

--
If they don't keep on exercising their lips, he thought, their brains
start working.
-- Douglas Adams, "The Hitchhiker's Guide to the Galaxy"

/// 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