aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/fold.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/fold.c')
-rw-r--r--src/nvim/fold.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/nvim/fold.c b/src/nvim/fold.c
index 8e6c2a598e..654cdf82a8 100644
--- a/src/nvim/fold.c
+++ b/src/nvim/fold.c
@@ -1651,7 +1651,7 @@ static void foldDelMarker(linenr_T lnum, char_u *marker, size_t markerlen)
}
/* Found the marker, include a digit if it's there. */
size_t len = markerlen;
- if (VIM_ISDIGIT(p[len]))
+ if (ascii_isdigit(p[len]))
++len;
if (*cms != NUL) {
/* Also delete 'commentstring' if it matches. */
@@ -1787,7 +1787,7 @@ void foldtext_cleanup(char_u *str)
/* Ignore leading and trailing white space in 'commentstring'. */
char_u *cms_start = skipwhite(curbuf->b_p_cms);
size_t cms_slen = STRLEN(cms_start);
- while (cms_slen > 0 && vim_iswhite(cms_start[cms_slen - 1]))
+ while (cms_slen > 0 && ascii_iswhite(cms_start[cms_slen - 1]))
--cms_slen;
/* locate "%s" in 'commentstring', use the part before and after it. */
@@ -1798,7 +1798,7 @@ void foldtext_cleanup(char_u *str)
cms_slen = (size_t)(cms_end - cms_start);
/* exclude white space before "%s" */
- while (cms_slen > 0 && vim_iswhite(cms_start[cms_slen - 1]))
+ while (cms_slen > 0 && ascii_iswhite(cms_start[cms_slen - 1]))
--cms_slen;
/* skip "%s" and white space after it */
@@ -1815,12 +1815,12 @@ void foldtext_cleanup(char_u *str)
else if (STRNCMP(s, foldendmarker, foldendmarkerlen) == 0)
len = foldendmarkerlen;
if (len > 0) {
- if (VIM_ISDIGIT(s[len]))
+ if (ascii_isdigit(s[len]))
++len;
/* May remove 'commentstring' start. Useful when it's a double
* quote and we already removed a double quote. */
- for (p = s; p > str && vim_iswhite(p[-1]); --p)
+ for (p = s; p > str && ascii_iswhite(p[-1]); --p)
;
if (p >= str + cms_slen
&& STRNCMP(p - cms_slen, cms_start, cms_slen) == 0) {
@@ -1838,7 +1838,7 @@ void foldtext_cleanup(char_u *str)
}
}
if (len != 0) {
- while (vim_iswhite(s[len]))
+ while (ascii_iswhite(s[len]))
++len;
STRMOVE(s, s + len);
} else {
@@ -2799,7 +2799,7 @@ static void foldlevelMarker(fline_T *flp)
&& STRNCMP(s + 1, startmarker, foldstartmarkerlen - 1) == 0) {
/* found startmarker: set flp->lvl */
s += foldstartmarkerlen;
- if (VIM_ISDIGIT(*s)) {
+ if (ascii_isdigit(*s)) {
n = atoi((char *)s);
if (n > 0) {
flp->lvl = n;
@@ -2818,7 +2818,7 @@ static void foldlevelMarker(fline_T *flp)
foldendmarkerlen - 1) == 0) {
/* found endmarker: set flp->lvl_next */
s += foldendmarkerlen;
- if (VIM_ISDIGIT(*s)) {
+ if (ascii_isdigit(*s)) {
n = atoi((char *)s);
if (n > 0) {
flp->lvl = n;