Silence harmless warnings discovered via run_tests.sh.

This commit is contained in:
Jason Evans 2017-02-01 10:03:04 -08:00
parent 54d2d697b2
commit ed19a48928

View File

@ -67,7 +67,10 @@ token_error(token_t *token)
token->col); token->col);
break; break;
} }
write(STDERR_FILENO, &token->parser->buf[token->pos], token->len); {
UNUSED ssize_t err = write(STDERR_FILENO,
&token->parser->buf[token->pos], token->len);
}
malloc_printf("\n"); malloc_printf("\n");
} }
@ -135,7 +138,9 @@ parser_tokenize(parser_t *parser)
STATE_EXP_DIGITS, STATE_EXP_DIGITS,
STATE_ACCEPT STATE_ACCEPT
} state = STATE_START; } state = STATE_START;
size_t token_pos, token_line, token_col; size_t token_pos JEMALLOC_CC_SILENCE_INIT(0);
size_t token_line JEMALLOC_CC_SILENCE_INIT(1);
size_t token_col JEMALLOC_CC_SILENCE_INIT(0);
assert_zu_le(parser->pos, parser->len, assert_zu_le(parser->pos, parser->len,
"Position is past end of buffer"); "Position is past end of buffer");