aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/buffer.c
diff options
context:
space:
mode:
authorFelipe Oliveira Carvalho <felipekde@gmail.com>2015-04-25 13:34:30 -0300
committerFelipe Oliveira Carvalho <felipekde@gmail.com>2015-04-25 13:37:44 -0300
commit0bce4dc54427d05ab320a88f6269a9c1b05ea899 (patch)
tree4a3aff2749eb0b70b7947ecfc7cd56d56ad4e29d /src/nvim/buffer.c
parentd350d12a00518aa0d9e3a1d49c6815c3398d882f (diff)
parentc96b933acc4d9ec7382d451055e44c85959772b9 (diff)
downloadrneovim-0bce4dc54427d05ab320a88f6269a9c1b05ea899.tar.gz
rneovim-0bce4dc54427d05ab320a88f6269a9c1b05ea899.tar.bz2
rneovim-0bce4dc54427d05ab320a88f6269a9c1b05ea899.zip
Merge #2486: Replacements for vim_iswhite, VIM_ISDIGIT, vim_isdigit, vim_isxdigit, and vim_isspace
Reviewed-by: Michael Reed <m.reed@mykolab.com>
Diffstat (limited to 'src/nvim/buffer.c')
-rw-r--r--src/nvim/buffer.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c
index 4585278714..1465b13c00 100644
--- a/src/nvim/buffer.c
+++ b/src/nvim/buffer.c
@@ -752,7 +752,7 @@ do_bufdel (
arg = skipwhite(arg);
if (*arg == NUL)
break;
- if (!VIM_ISDIGIT(*arg)) {
+ if (!ascii_isdigit(*arg)) {
p = skiptowhite_esc(arg);
bnr = buflist_findpat(arg, p, command == DOBUF_WIPE,
FALSE, FALSE);
@@ -3012,7 +3012,7 @@ build_stl_str_hl (
s++;
l = -1;
}
- if (VIM_ISDIGIT(*s)) {
+ if (ascii_isdigit(*s)) {
minwid = getdigits_int(&s);
if (minwid < 0) /* overflow */
minwid = 0;
@@ -3048,7 +3048,7 @@ build_stl_str_hl (
}
if (*s == '.') {
s++;
- if (VIM_ISDIGIT(*s)) {
+ if (ascii_isdigit(*s)) {
maxwid = getdigits_int(&s);
if (maxwid <= 0) /* overflow */
maxwid = 50;
@@ -3321,7 +3321,7 @@ build_stl_str_hl (
if (minwid > 0) {
for (; l < minwid && p + 1 < out + outlen; l++) {
/* Don't put a "-" in front of a digit. */
- if (l + 1 == minwid && fillchar == '-' && VIM_ISDIGIT(*t))
+ if (l + 1 == minwid && fillchar == '-' && ascii_isdigit(*t))
*p++ = ' ';
else
*p++ = fillchar;
@@ -3334,7 +3334,7 @@ build_stl_str_hl (
/* Change a space by fillchar, unless fillchar is '-' and a
* digit follows. */
if (fillable && p[-1] == ' '
- && (!VIM_ISDIGIT(*t) || fillchar != '-'))
+ && (!ascii_isdigit(*t) || fillchar != '-'))
p[-1] = fillchar;
}
for (; l < minwid && p + 1 < out + outlen; l++)
@@ -4075,7 +4075,7 @@ chk_modeline (
prev = -1;
for (s = ml_get(lnum); *s != NUL; ++s) {
- if (prev == -1 || vim_isspace(prev)) {
+ if (prev == -1 || ascii_isspace(prev)) {
if ((prev != -1 && STRNCMP(s, "ex:", (size_t)3) == 0)
|| STRNCMP(s, "vi:", (size_t)3) == 0)
break;