minor, update ragel generated hb-number-parser.hh

This commit is contained in:
Ebrahim Byagowi 2020-04-21 14:42:17 +04:30
parent 6d5e8e5ee4
commit 1cd14b40e7
1 changed files with 11 additions and 11 deletions

View File

@ -31,7 +31,7 @@
#include "hb.hh" #include "hb.hh"
#line 37 "hb-number-parser.hh" #line 35 "hb-number-parser.hh"
static const unsigned char _double_parser_trans_keys[] = { static const unsigned char _double_parser_trans_keys[] = {
0u, 0u, 43u, 57u, 46u, 57u, 48u, 57u, 43u, 57u, 48u, 57u, 48u, 101u, 48u, 57u, 0u, 0u, 43u, 57u, 46u, 57u, 48u, 57u, 43u, 57u, 48u, 57u, 48u, 101u, 48u, 57u,
46u, 101u, 0 46u, 101u, 0
@ -91,7 +91,7 @@ static const int double_parser_error = 0;
static const int double_parser_en_main = 1; static const int double_parser_en_main = 1;
#line 70 "hb-number-parser.rl" #line 68 "hb-number-parser.rl"
/* Works only for n < 512 */ /* Works only for n < 512 */
@ -136,12 +136,12 @@ strtod_rl (const char *buf, char **end_ptr)
int cs; int cs;
#line 142 "hb-number-parser.hh" #line 140 "hb-number-parser.hh"
{ {
cs = double_parser_start; cs = double_parser_start;
} }
#line 147 "hb-number-parser.hh" #line 145 "hb-number-parser.hh"
{ {
int _slen; int _slen;
int _trans; int _trans;
@ -167,21 +167,21 @@ _resume:
switch ( _double_parser_trans_actions[_trans] ) { switch ( _double_parser_trans_actions[_trans] ) {
case 1: case 1:
#line 39 "hb-number-parser.rl" #line 37 "hb-number-parser.rl"
{ neg = true; } { neg = true; }
break; break;
case 4: case 4:
#line 40 "hb-number-parser.rl" #line 38 "hb-number-parser.rl"
{ exp_neg = true; } { exp_neg = true; }
break; break;
case 2: case 2:
#line 42 "hb-number-parser.rl" #line 40 "hb-number-parser.rl"
{ {
value = value * 10. + ((*p) - '0'); value = value * 10. + ((*p) - '0');
} }
break; break;
case 3: case 3:
#line 45 "hb-number-parser.rl" #line 43 "hb-number-parser.rl"
{ {
if (likely (frac <= MAX_FRACT / 10)) if (likely (frac <= MAX_FRACT / 10))
{ {
@ -191,7 +191,7 @@ _resume:
} }
break; break;
case 5: case 5:
#line 52 "hb-number-parser.rl" #line 50 "hb-number-parser.rl"
{ {
if (likely (exp * 10 + ((*p) - '0') <= MAX_EXP)) if (likely (exp * 10 + ((*p) - '0') <= MAX_EXP))
exp = exp * 10 + ((*p) - '0'); exp = exp * 10 + ((*p) - '0');
@ -199,7 +199,7 @@ _resume:
exp_overflow = true; exp_overflow = true;
} }
break; break;
#line 205 "hb-number-parser.hh" #line 203 "hb-number-parser.hh"
} }
_again: _again:
@ -211,7 +211,7 @@ _again:
_out: {} _out: {}
} }
#line 116 "hb-number-parser.rl" #line 114 "hb-number-parser.rl"
*end_ptr = (char *) p; *end_ptr = (char *) p;