summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornaohiro ono <obcat@icloud.com>2021-08-28 15:56:06 +0200
committerBram Moolenaar <Bram@vim.org>2021-08-28 15:56:06 +0200
commit9aecf79c45da5593e4d8c0de1b2d212edc4765ce (patch)
treec847bf698ddd1d2c442594e96a7f8d298e110c69
parentc8103b4c2547ce2044469bcd49e3d55907bd33d1 (diff)
downloadvim-git-9aecf79c45da5593e4d8c0de1b2d212edc4765ce.tar.gz
patch 8.2.3383: Vim9: completion for :disassemble adds parenthesisv8.2.3383
Problem: Vim9: completion for :disassemble adds parenthesis. Solution: Don't add parenthesis. (Naohiro Ono, closes #8802)
-rw-r--r--src/testdir/test_cmdline.vim4
-rw-r--r--src/userfunc.c3
-rw-r--r--src/version.c2
3 files changed, 7 insertions, 2 deletions
diff --git a/src/testdir/test_cmdline.vim b/src/testdir/test_cmdline.vim
index 0a71b1118..341a0f113 100644
--- a/src/testdir/test_cmdline.vim
+++ b/src/testdir/test_cmdline.vim
@@ -841,9 +841,11 @@ func Test_cmdline_complete_various()
call assert_equal("\"disas debug Test_cmdline_complete_various", @:)
call feedkeys(":disas profile Test_cmdline_complete_var\<C-A>\<C-B>\"\<CR>", 'xt')
call assert_equal("\"disas profile Test_cmdline_complete_various", @:)
+ call feedkeys(":disas Test_cmdline_complete_var\<C-A>\<C-B>\"\<CR>", 'xt')
+ call assert_equal("\"disas Test_cmdline_complete_various", @:)
call feedkeys(":disas s:WeirdF\<C-A>\<C-B>\"\<CR>", 'xt')
- call assert_match('"disas <SNR>\d\+_WeirdFunc()', @:)
+ call assert_match('"disas <SNR>\d\+_WeirdFunc', @:)
" completion for the :match command
call feedkeys(":match Search /pat/\<C-A>\<C-B>\"\<CR>", 'xt')
diff --git a/src/userfunc.c b/src/userfunc.c
index 86a2bec4e..4a2b05e0c 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -4625,7 +4625,8 @@ get_user_func_name(expand_T *xp, int idx)
return fp->uf_name; // prevents overflow
cat_func_name(IObuff, fp);
- if (xp->xp_context != EXPAND_USER_FUNC)
+ if (xp->xp_context != EXPAND_USER_FUNC
+ && xp->xp_context != EXPAND_DISASSEMBLE)
{
STRCAT(IObuff, "(");
if (!has_varargs(fp) && fp->uf_args.ga_len == 0)
diff --git a/src/version.c b/src/version.c
index 77935e5e6..a9c5b4cdf 100644
--- a/src/version.c
+++ b/src/version.c
@@ -756,6 +756,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 3383,
+/**/
3382,
/**/
3381,