diff options
Diffstat (limited to 'src/nvim/spell.c')
-rw-r--r-- | src/nvim/spell.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/nvim/spell.c b/src/nvim/spell.c index 8cfe1c8c9a..90a2d69703 100644 --- a/src/nvim/spell.c +++ b/src/nvim/spell.c @@ -5155,7 +5155,7 @@ static unsigned get_affitem(int flagtype, char_u **pp) int res; if (flagtype == AFT_NUM) { - if (!VIM_ISDIGIT(**pp)) { + if (!ascii_isdigit(**pp)) { ++*pp; // always advance, avoid getting stuck return 0; } @@ -5410,7 +5410,7 @@ static int spell_read_dic(spellinfo_T *spin, char_u *fname, afffile_T *affile) // Read and ignore the first line: word count. (void)vim_fgets(line, MAXLINELEN, fd); - if (!vim_isdigit(*skipwhite(line))) + if (!ascii_isdigit(*skipwhite(line))) EMSG2(_("E760: No word count in %s"), fname); // Read all the lines in the file one by one. @@ -6019,7 +6019,7 @@ static int spell_read_wordfile(spellinfo_T *spin, char_u *fname) flags |= WF_BANNED; else if (*p == '?') // Rare word. flags |= WF_RARE; - else if (VIM_ISDIGIT(*p)) { // region number(s) + else if (ascii_isdigit(*p)) { // region number(s) if ((flags & WF_REGION) == 0) // first one regionmask = 0; flags |= WF_REGION; @@ -6351,20 +6351,20 @@ int spell_check_msm(void) long incr = 0; long added = 0; - if (!VIM_ISDIGIT(*p)) + if (!ascii_isdigit(*p)) return FAIL; // block count = (value * 1024) / SBLOCKSIZE (but avoid overflow) start = (getdigits_long(&p) * 10) / (SBLOCKSIZE / 102); if (*p != ',') return FAIL; ++p; - if (!VIM_ISDIGIT(*p)) + if (!ascii_isdigit(*p)) return FAIL; incr = (getdigits_long(&p) * 102) / (SBLOCKSIZE / 10); if (*p != ',') return FAIL; ++p; - if (!VIM_ISDIGIT(*p)) + if (!ascii_isdigit(*p)) return FAIL; added = getdigits_long(&p) * 1024; if (*p != NUL) @@ -8350,10 +8350,10 @@ int spell_check_sps(void) copy_option_part(&p, buf, MAXPATHL, ","); f = 0; - if (VIM_ISDIGIT(*buf)) { + if (ascii_isdigit(*buf)) { s = buf; sps_limit = getdigits_int(&s); - if (*s != NUL && !VIM_ISDIGIT(*s)) + if (*s != NUL && !ascii_isdigit(*s)) f = -1; } else if (STRCMP(buf, "best") == 0) f = SPS_BEST; @@ -11822,7 +11822,7 @@ static void spell_soundfold_sal(slang_T *slang, char_u *inword, char_u *res) } if (*s == '<') s++; - if (VIM_ISDIGIT(*s)) { + if (ascii_isdigit(*s)) { // determine priority pri = *s - '0'; s++; @@ -11883,7 +11883,7 @@ static void spell_soundfold_sal(slang_T *slang, char_u *inword, char_u *res) } if (*s == '<') s++; - if (VIM_ISDIGIT(*s)) { + if (ascii_isdigit(*s)) { p0 = *s - '0'; s++; } @@ -12076,7 +12076,7 @@ static void spell_soundfold_wsal(slang_T *slang, char_u *inword, char_u *res) } if (*s == '<') s++; - if (VIM_ISDIGIT(*s)) { + if (ascii_isdigit(*s)) { // determine priority pri = *s - '0'; s++; @@ -12141,7 +12141,7 @@ static void spell_soundfold_wsal(slang_T *slang, char_u *inword, char_u *res) } if (*s == '<') s++; - if (VIM_ISDIGIT(*s)) { + if (ascii_isdigit(*s)) { p0 = *s - '0'; s++; } |