diff options
Diffstat (limited to 'src/nvim/mbyte.c')
-rw-r--r-- | src/nvim/mbyte.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/mbyte.c b/src/nvim/mbyte.c index 65f718f925..ffd4472b8a 100644 --- a/src/nvim/mbyte.c +++ b/src/nvim/mbyte.c @@ -26,6 +26,7 @@ #include <ctype.h> #include <errno.h> #include <iconv.h> +#include <limits.h> #include <locale.h> #include <stdbool.h> #include <stddef.h> @@ -51,7 +52,6 @@ #include "nvim/gettext_defs.h" #include "nvim/globals.h" #include "nvim/grid.h" -#include "nvim/grid_defs.h" #include "nvim/iconv_defs.h" #include "nvim/keycodes.h" #include "nvim/macros_defs.h" @@ -1119,7 +1119,7 @@ int utf_char2bytes(const int c, char *const buf) /// stateful algorithm to determine grapheme clusters. Still available /// to support some legacy code which hasn't been refactored yet. /// -/// To check if a char would combine with a preceeding space, use +/// To check if a char would combine with a preceding space, use /// utf_iscomposing_first() instead. /// /// Based on code from Markus Kuhn. @@ -1400,11 +1400,11 @@ int utf_fold(int a) int mb_toupper(int a) { // If 'casemap' contains "keepascii" use ASCII style toupper(). - if (a < 128 && (cmp_flags & CMP_KEEPASCII)) { + if (a < 128 && (cmp_flags & kOptCmpFlagKeepascii)) { return TOUPPER_ASC(a); } - if (!(cmp_flags & CMP_INTERNAL)) { + if (!(cmp_flags & kOptCmpFlagInternal)) { return (int)towupper((wint_t)a); } @@ -1426,11 +1426,11 @@ bool mb_islower(int a) int mb_tolower(int a) { // If 'casemap' contains "keepascii" use ASCII style tolower(). - if (a < 128 && (cmp_flags & CMP_KEEPASCII)) { + if (a < 128 && (cmp_flags & kOptCmpFlagKeepascii)) { return TOLOWER_ASC(a); } - if (!(cmp_flags & CMP_INTERNAL)) { + if (!(cmp_flags & kOptCmpFlagInternal)) { return (int)towlower((wint_t)a); } |