summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2022-02-18 13:56:38 +0000
committerBram Moolenaar <Bram@vim.org>2022-02-18 13:56:38 +0000
commitb8fb5bb68d45f3e52bb9ea201dc9e7dc6b6d2c6d (patch)
tree591192e20ba2e40b05f1243653312a6e993e3761
parent97b231541d4e82fbc85e51121448d95bd43c50ad (diff)
downloadvim-git-b8fb5bb68d45f3e52bb9ea201dc9e7dc6b6d2c6d.tar.gz
patch 8.2.4415: function argument name conflicts with C++ keywordv8.2.4415
Problem: Function argument name conflicts with C++ keyword. Solution: Rename the argument.
-rw-r--r--src/proto/usercmd.pro2
-rw-r--r--src/usercmd.c14
-rw-r--r--src/version.c2
3 files changed, 10 insertions, 8 deletions
diff --git a/src/proto/usercmd.pro b/src/proto/usercmd.pro
index 8eda5a30f..c3ac79cec 100644
--- a/src/proto/usercmd.pro
+++ b/src/proto/usercmd.pro
@@ -1,6 +1,6 @@
/* usercmd.c */
char_u *find_ucmd(exarg_T *eap, char_u *p, int *full, expand_T *xp, int *complp);
-char_u *set_context_in_user_cmdarg(char_u *cmd, char_u *arg, long argt, int compl, expand_T *xp, int forceit);
+char_u *set_context_in_user_cmdarg(char_u *cmd, char_u *arg, long argt, int context, expand_T *xp, int forceit);
char_u *set_context_in_user_cmd(expand_T *xp, char_u *arg_in);
char_u *expand_user_command_name(int idx);
char_u *get_user_commands(expand_T *xp, int idx);
diff --git a/src/usercmd.c b/src/usercmd.c
index 53285bdd2..d4a7a9c15 100644
--- a/src/usercmd.c
+++ b/src/usercmd.c
@@ -303,29 +303,29 @@ set_context_in_user_cmdarg(
char_u *cmd UNUSED,
char_u *arg,
long argt,
- int compl,
+ int context,
expand_T *xp,
int forceit)
{
char_u *p;
- if (compl == EXPAND_NOTHING)
+ if (context == EXPAND_NOTHING)
return NULL;
if (argt & EX_XFILE)
{
// EX_XFILE: file names are handled before this call
- xp->xp_context = compl;
+ xp->xp_context = context;
return NULL;
}
#ifdef FEAT_MENU
- if (compl == EXPAND_MENUS)
+ if (context == EXPAND_MENUS)
return set_context_in_menu_cmd(xp, cmd, arg, forceit);
#endif
- if (compl == EXPAND_COMMANDS)
+ if (context == EXPAND_COMMANDS)
return arg;
- if (compl == EXPAND_MAPPINGS)
+ if (context == EXPAND_MAPPINGS)
return set_context_in_map_cmd(xp, (char_u *)"map", arg, forceit, FALSE,
FALSE, CMD_map);
// Find start of last argument.
@@ -340,7 +340,7 @@ set_context_in_user_cmdarg(
MB_PTR_ADV(p);
}
xp->xp_pattern = arg;
- xp->xp_context = compl;
+ xp->xp_context = context;
return NULL;
}
diff --git a/src/version.c b/src/version.c
index 5039e9ec1..f313448c2 100644
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 4415,
+/**/
4414,
/**/
4413,