*: Partial string handling refactoring

Main points:

- Replace `char_u` with `char` in some cases.
- Remove `str[len] = NUL` hack in some cases when `str` may be considered
  `const`.
This commit is contained in:
ZyX
2016-07-29 21:41:45 +03:00
parent 2a50ff7e2f
commit efa2682e3b
32 changed files with 1289 additions and 1037 deletions

View File

@@ -755,10 +755,11 @@ static void show_menus_recursive(vimmenu_T *menu, int modes, int depth)
else
msg_putchar(' ');
MSG_PUTS(" ");
if (*menu->strings[bit] == NUL)
msg_puts_attr((char_u *)"<Nop>", hl_attr(HLF_8));
else
if (*menu->strings[bit] == NUL) {
msg_puts_attr("<Nop>", hl_attr(HLF_8));
} else {
msg_outtrans_special(menu->strings[bit], FALSE);
}
}
} else {
if (menu == NULL) {