Replace vim_iswhite with ascii_iswhite() defined in ascii.h

This commit is contained in:
Felipe Oliveira Carvalho
2015-04-22 19:12:26 -03:00
parent d350d12a00
commit 93bf201119
33 changed files with 198 additions and 192 deletions

View File

@@ -2461,7 +2461,7 @@ do_set (
afterchar = arg[len];
/* skip white space, allow ":set ai ?" */
while (vim_iswhite(arg[len]))
while (ascii_iswhite(arg[len]))
++len;
adding = FALSE;
@@ -2549,7 +2549,7 @@ do_set (
}
}
if (vim_strchr((char_u *)"?!&<", nextchar) != NULL
&& arg[1] != NUL && !vim_iswhite(arg[1])) {
&& arg[1] != NUL && !ascii_iswhite(arg[1])) {
errmsg = e_trailing;
goto skip;
}
@@ -2590,7 +2590,7 @@ do_set (
goto skip;
}
if (nextchar != '?'
&& nextchar != NUL && !vim_iswhite(afterchar))
&& nextchar != NUL && !ascii_iswhite(afterchar))
errmsg = e_trailing;
} else {
if (flags & P_BOOL) { /* boolean */
@@ -2623,7 +2623,7 @@ do_set (
* ":set invopt": invert
* ":set opt" or ":set noopt": set or reset
*/
if (nextchar != NUL && !vim_iswhite(afterchar)) {
if (nextchar != NUL && !ascii_iswhite(afterchar)) {
errmsg = e_trailing;
goto skip;
}
@@ -2670,7 +2670,7 @@ do_set (
|| (long *)varp == &p_wcm)
&& (*arg == '<'
|| *arg == '^'
|| ((!arg[1] || vim_iswhite(arg[1]))
|| ((!arg[1] || ascii_iswhite(arg[1]))
&& !VIM_ISDIGIT(*arg)))) {
value = string_to_key(arg);
if (value == 0 && (long *)varp != &p_wcm) {
@@ -2688,7 +2688,7 @@ do_set (
i += 2;
while (VIM_ISDIGIT(arg[i]))
++i;
if (arg[i] != NUL && !vim_iswhite(arg[i])) {
if (arg[i] != NUL && !ascii_iswhite(arg[i])) {
errmsg = e_invarg;
goto skip;
}
@@ -2848,7 +2848,7 @@ do_set (
* do remove it for "\\\\machine\\path".
* The reverse is found in ExpandOldSetting().
*/
while (*arg && !vim_iswhite(*arg)) {
while (*arg && !ascii_iswhite(*arg)) {
if (*arg == '\\' && arg[1] != NUL
#ifdef BACKSLASH_IN_FILENAME
&& !((flags & P_EXPAND)
@@ -3004,7 +3004,7 @@ skip:
* - skip one "=val" argument (for hidden options ":set gfn =xx")
*/
for (i = 0; i < 2; ++i) {
while (*arg != NUL && !vim_iswhite(*arg))
while (*arg != NUL && !ascii_iswhite(*arg))
if (*arg++ == '\\' && *arg != NUL)
++arg;
arg = skipwhite(arg);