bc: simplify bc_lex_whitespace()
function old new delta bc_lex_whitespace 52 41 -11 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
bbcecc4118
commit
89198a9e5d
@ -2790,9 +2790,13 @@ static void bc_lex_lineComment(BcLex *l)
|
|||||||
|
|
||||||
static void bc_lex_whitespace(BcLex *l)
|
static void bc_lex_whitespace(BcLex *l)
|
||||||
{
|
{
|
||||||
char c;
|
|
||||||
l->t.t = BC_LEX_WHITESPACE;
|
l->t.t = BC_LEX_WHITESPACE;
|
||||||
for (c = l->buf[l->i]; c != '\n' && isspace(c); c = l->buf[++l->i]);
|
for (;;) {
|
||||||
|
char c = l->buf[l->i];
|
||||||
|
if (c == '\n' || !isspace(c))
|
||||||
|
break;
|
||||||
|
l->i++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static BC_STATUS zbc_lex_number(BcLex *l, char start)
|
static BC_STATUS zbc_lex_number(BcLex *l, char start)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user