patch 8.1.0779: argument for message functions is inconsistent
Problem: Argument for message functions is inconsistent.
Solution: Make first argument to msg() "char *".
diff --git a/src/getchar.c b/src/getchar.c
index a51af9d..c0cfd92 100644
--- a/src/getchar.c
+++ b/src/getchar.c
@@ -1942,7 +1942,7 @@
}
/*
- * Get a character:
+ * Get a byte:
* 1. from the stuffbuffer
* This is used for abbreviated commands like "D" -> "d$".
* Also used to redo a command for ".".
@@ -3728,9 +3728,9 @@
)
{
if (abbrev)
- MSG(_("No abbreviation found"));
+ msg(_("No abbreviation found"));
else
- MSG(_("No mapping found"));
+ msg(_("No mapping found"));
}
goto theend; /* listing finished */
}
@@ -4047,7 +4047,7 @@
mapchars = map_mode_to_chars(mp->m_mode);
if (mapchars != NULL)
{
- msg_puts(mapchars);
+ msg_puts((char *)mapchars);
len = (int)STRLEN(mapchars);
vim_free(mapchars);
}
@@ -4064,9 +4064,9 @@
} while (len < 12);
if (mp->m_noremap == REMAP_NONE)
- msg_puts_attr((char_u *)"*", HL_ATTR(HLF_8));
+ msg_puts_attr("*", HL_ATTR(HLF_8));
else if (mp->m_noremap == REMAP_SCRIPT)
- msg_puts_attr((char_u *)"&", HL_ATTR(HLF_8));
+ msg_puts_attr("&", HL_ATTR(HLF_8));
else
msg_putchar(' ');
@@ -4078,7 +4078,7 @@
/* Use FALSE below if we only want things like <Up> to show up as such on
* the rhs, and not M-x etc, TRUE gets both -- webb */
if (*mp->m_str == NUL)
- msg_puts_attr((char_u *)"<Nop>", HL_ATTR(HLF_8));
+ msg_puts_attr("<Nop>", HL_ATTR(HLF_8));
else
{
/* Remove escaping of CSI, because "m_str" is in a format to be used