aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/usercmd.c
diff options
context:
space:
mode:
authorii14 <59243201+ii14@users.noreply.github.com>2023-04-07 19:40:57 +0200
committerGitHub <noreply@github.com>2023-04-07 19:40:57 +0200
commit9408f2dcf7cade2631688300e9b58eed6bc5219a (patch)
tree152b8b6135f50619b1fb2a69719d71a180ea0792 /src/nvim/usercmd.c
parent1d2a29f75ba7d094c8e7444c9b249a4a7211c93c (diff)
downloadrneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.tar.gz
rneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.tar.bz2
rneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.zip
refactor: remove redundant const char * casts
Diffstat (limited to 'src/nvim/usercmd.c')
-rw-r--r--src/nvim/usercmd.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/usercmd.c b/src/nvim/usercmd.c
index 8c2f8533d8..4cd58bb91b 100644
--- a/src/nvim/usercmd.c
+++ b/src/nvim/usercmd.c
@@ -234,7 +234,7 @@ const char *set_context_in_user_cmd(expand_T *xp, const char *arg_in)
// Check for attributes
while (*arg == '-') {
arg++; // Skip "-".
- p = (const char *)skiptowhite(arg);
+ p = skiptowhite(arg);
if (*p == NUL) {
// Cursor is still in the attribute.
p = strchr(arg, '=');
@@ -262,11 +262,11 @@ const char *set_context_in_user_cmd(expand_T *xp, const char *arg_in)
}
return NULL;
}
- arg = (const char *)skipwhite(p);
+ arg = skipwhite(p);
}
// After the attributes comes the new command name.
- p = (const char *)skiptowhite(arg);
+ p = skiptowhite(arg);
if (*p == NUL) {
xp->xp_context = EXPAND_USER_COMMANDS;
xp->xp_pattern = (char *)arg;
@@ -274,7 +274,7 @@ const char *set_context_in_user_cmd(expand_T *xp, const char *arg_in)
}
// And finally comes a normal command.
- return (const char *)skipwhite(p);
+ return skipwhite(p);
}
/// Set the completion context for the argument of a user defined command.
@@ -292,7 +292,7 @@ const char *set_context_in_user_cmdarg(const char *cmd FUNC_ATTR_UNUSED, const c
}
if (context == EXPAND_MENUS) {
- return (const char *)set_context_in_menu_cmd(xp, cmd, (char *)arg, forceit);
+ return set_context_in_menu_cmd(xp, cmd, (char *)arg, forceit);
}
if (context == EXPAND_COMMANDS) {
return arg;