Skip to content
Myr

fix bug in integer parsing

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Sean Barrett · committed by Sean Barrett · parent 3f73dfd · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:stb_c_lexer.h+1 added-1 removed
632 unmodified lines
633 if (p+1 != lexer->eof) {634 if (p[1] == 'x' || p[1] == 'X') {635 char *q = p+2;636 #ifdef STB__CLEX_use_stdlib637 lexer->int_number = strtol((char *) p, (char **) q, 16);637 lexer->int_number = strtol((char *) p, (char **) &q, 16);638 #else639 stb__clex_int n=0;640 while (q != lexer->eof) {641 if (*q >= '0' && *q <= '9')
174 unmodified lines