aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/message.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2021-11-16 20:27:59 +0100
committerGitHub <noreply@github.com>2021-11-16 20:27:59 +0100
commiteba317d7a907a76e6e265c0fe0b97a87f17cf943 (patch)
tree21edca825d0de28a4024c969e26ecfe75f6dc298 /src/nvim/message.c
parent99211b008c10561560e84eabfaa22e1577ac179a (diff)
downloadrneovim-eba317d7a907a76e6e265c0fe0b97a87f17cf943.tar.gz
rneovim-eba317d7a907a76e6e265c0fe0b97a87f17cf943.tar.bz2
rneovim-eba317d7a907a76e6e265c0fe0b97a87f17cf943.zip
refactor: reduce number of explicit char casts (#16077)
* refactor: reduce number of explicit char casts
Diffstat (limited to 'src/nvim/message.c')
-rw-r--r--src/nvim/message.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/message.c b/src/nvim/message.c
index 7b6337bea2..8223e6c188 100644
--- a/src/nvim/message.c
+++ b/src/nvim/message.c
@@ -329,7 +329,7 @@ bool msg_attr_keep(const char *s, int attr, bool keep, bool multiline)
if (keep && retval && vim_strsize((char_u *)s) < (int)(Rows - cmdline_row - 1)
* Columns + sc_col) {
- set_keep_msg((char_u *)s, 0);
+ set_keep_msg((char *)s, 0);
}
xfree(buf);
@@ -732,7 +732,7 @@ static bool emsg_multiline(const char *s, bool multiline)
/// @return true if wait_return not called
bool emsg(const char *s)
{
- return emsg_multiline((const char *)s, false);
+ return emsg_multiline(s, false);
}
void emsg_invreg(int name)
@@ -1288,11 +1288,11 @@ static void hit_return_msg(void)
/*
* Set "keep_msg" to "s". Free the old value and check for NULL pointer.
*/
-void set_keep_msg(char_u *s, int attr)
+void set_keep_msg(char *s, int attr)
{
xfree(keep_msg);
if (s != NULL && msg_silent == 0) {
- keep_msg = vim_strsave(s);
+ keep_msg = vim_strsave((char_u *)s);
} else {
keep_msg = NULL;
}
@@ -3342,7 +3342,7 @@ void give_warning(char_u *message, bool hl) FUNC_ATTR_NONNULL_ARG(1)
}
if (msg_attr((const char *)message, keep_msg_attr) && msg_scrolled == 0) {
- set_keep_msg(message, keep_msg_attr);
+ set_keep_msg((char *)message, keep_msg_attr);
}
msg_didout = false; // Overwrite this message.
msg_nowait = true; // Don't wait for this message.