diff options
author | Josh Rahm <joshuarahm@gmail.com> | 2025-02-05 23:09:29 +0000 |
---|---|---|
committer | Josh Rahm <joshuarahm@gmail.com> | 2025-02-05 23:09:29 +0000 |
commit | d5f194ce780c95821a855aca3c19426576d28ae0 (patch) | |
tree | d45f461b19f9118ad2bb1f440a7a08973ad18832 /src/nvim/mbyte.c | |
parent | c5d770d311841ea5230426cc4c868e8db27300a8 (diff) | |
parent | 44740e561fc93afe3ebecfd3618bda2d2abeafb0 (diff) | |
download | rneovim-rahm.tar.gz rneovim-rahm.tar.bz2 rneovim-rahm.zip |
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); } |