--- a/Scanner.st Fri Jan 12 20:00:56 2007 +0100
+++ b/Scanner.st Fri Jan 12 21:24:32 2007 +0100
@@ -2410,13 +2410,17 @@
fixedPointNumerator := 0.
fixedPointScale := 0.
- factor := 1.0 asLongFloat / radix.
+ factor := 1.0 / radix.
nextChar := source peekOrNil.
[(nextChar notNil and:[nextChar isDigitRadix:radix])] whileTrue:[
fixedPointNumerator := (fixedPointNumerator * 10) + nextChar digitValue.
fixedPointScale := fixedPointScale + 1.
value := value + (nextChar digitValue * factor).
factor := factor / radix.
+ factor < 0.00001 ifTrue:[
+ factor := factor asLongFloat.
+ value := value asLongFloat.
+ ].
nextChar := source nextPeek
].
^ (Array with:value with:fixedPointNumerator with:fixedPointScale)
@@ -3178,7 +3182,7 @@
!Scanner class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libcomp/Scanner.st,v 1.229 2006-12-07 17:13:26 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libcomp/Scanner.st,v 1.230 2007-01-12 20:24:32 cg Exp $'
! !
Scanner initialize!