math.parser: okay time for sleep, maybe this works, sorry git history.

db4
John Benediktsson 2015-07-14 22:48:08 -07:00
parent 86639b9df0
commit f6f596f40f
2 changed files with 4 additions and 4 deletions

View File

@ -363,7 +363,7 @@ unit-test
! #1229, float parsing bug, and a regression
{ -0.5 } [ "-.5" dec> ] unit-test
{ "0" } [ "0" hex> ] unit-test
{ 0 } [ "0" hex> ] unit-test
{ t } [ most-positive-fixnum number>string string>number fixnum? ] unit-test
{ t } [ most-negative-fixnum number>string string>number fixnum? ] unit-test

View File

@ -288,19 +288,19 @@ DEFER: @neg-digit
{ f [ 4drop 0 ] }
[ swap call ]
} case
] curry require-next-digit ; inline
] curry next-digit ; inline
: @neg-first-digit-no-radix ( i number-parse n char -- n/f )
{
{ CHAR: . [ ->required-mantissa ] }
{ CHAR: 0 [ [ @neg-digit ] with-no-radix ] }
{ CHAR: 0 [ [ @neg-digit-or-punc ] with-no-radix ] }
[ @neg-digit ]
} case ; inline
: @pos-first-digit-no-radix ( i number-parse n char -- n/f )
{
{ CHAR: . [ ->required-mantissa ] }
{ CHAR: 0 [ [ @pos-digit ] with-no-radix ] }
{ CHAR: 0 [ [ @pos-digit-or-punc ] with-no-radix ] }
[ @pos-digit ]
} case ; inline