aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/spellfile.c
diff options
context:
space:
mode:
authorBjörn Linse <bjorn.linse@gmail.com>2021-11-14 13:34:59 +0100
committerBjörn Linse <bjorn.linse@gmail.com>2021-11-14 16:33:12 +0100
commit54ff21a15303e1c7dbfde4895c3444daad6df16a (patch)
treea2b5a7913e2ea8c20d3af1f9af89c2752bf8fdd4 /src/nvim/spellfile.c
parentede00b29d175625479060c5c52e256ec6fc445c1 (diff)
downloadrneovim-54ff21a15303e1c7dbfde4895c3444daad6df16a.tar.gz
rneovim-54ff21a15303e1c7dbfde4895c3444daad6df16a.tar.bz2
rneovim-54ff21a15303e1c7dbfde4895c3444daad6df16a.zip
refactor(macros): delete multibyte macros which just are aliases
Diffstat (limited to 'src/nvim/spellfile.c')
-rw-r--r--src/nvim/spellfile.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/spellfile.c b/src/nvim/spellfile.c
index 1227cd5adc..7e8c24b1bf 100644
--- a/src/nvim/spellfile.c
+++ b/src/nvim/spellfile.c
@@ -2508,15 +2508,15 @@ static afffile_T *spell_read_aff(spellinfo_T *spin, char_u *fname)
NUL) {
int c, c_up;
- c = PTR2CHAR(aff_entry->ae_chop);
+ c = utf_ptr2char(aff_entry->ae_chop);
c_up = SPELL_TOUPPER(c);
if (c_up != c
&& (aff_entry->ae_cond == NULL
- || PTR2CHAR(aff_entry->ae_cond) == c)) {
+ || utf_ptr2char(aff_entry->ae_cond) == c)) {
p = aff_entry->ae_add
+ STRLEN(aff_entry->ae_add);
MB_PTR_BACK(aff_entry->ae_add, p);
- if (PTR2CHAR(p) == c_up) {
+ if (utf_ptr2char(p) == c_up) {
upper = true;
aff_entry->ae_chop = NULL;
*p = NUL;
@@ -3501,7 +3501,7 @@ static int store_aff_word(spellinfo_T *spin, char_u *word, char_u *afflist, afff
if (ae->ae_chop != NULL) {
// Remove chop string.
p = newword + STRLEN(newword);
- i = (int)MB_CHARLEN(ae->ae_chop);
+ i = (int)mb_charlen(ae->ae_chop);
for (; i > 0; i--) {
MB_PTR_BACK(newword, p);
}