mirror of
https://github.com/neovim/neovim.git
synced 2025-09-18 09:18:19 +00:00
menu: use char* for set_context_in_menu_cmd() param
All calls to set_context_in_menu_cmd() cast "cmd" arg to char_u. get_menu_cmd_nodes() doesn't require "cmd" to be unsigned char. Use "char" type for "cmd" function param to reduce type casts.
This commit is contained in:
@@ -3518,7 +3518,7 @@ const char * set_one_cmd_context(
|
||||
// EX_XFILE: file names are handled above.
|
||||
if (!(ea.argt & EX_XFILE)) {
|
||||
if (context == EXPAND_MENUS) {
|
||||
return (const char *)set_context_in_menu_cmd(xp, (char_u *)cmd,
|
||||
return (const char *)set_context_in_menu_cmd(xp, cmd,
|
||||
(char_u *)arg, forceit);
|
||||
} else if (context == EXPAND_COMMANDS) {
|
||||
return arg;
|
||||
@@ -3598,7 +3598,7 @@ const char * set_one_cmd_context(
|
||||
case CMD_tmenu: case CMD_tunmenu:
|
||||
case CMD_popup: case CMD_emenu:
|
||||
return (const char *)set_context_in_menu_cmd(
|
||||
xp, (char_u *)cmd, (char_u *)arg, forceit);
|
||||
xp, cmd, (char_u *)arg, forceit);
|
||||
|
||||
case CMD_colorscheme:
|
||||
xp->xp_context = EXPAND_COLORS;
|
||||
|
Reference in New Issue
Block a user