Mantis - Squeak
Viewing Issue Advanced Details
6779 Kernel minor always 11-22-07 21:21 04-18-10 22:05
nicolas cellier  
andreas  
normal  
closed 3.10  
fixed  
none    
none trunk  
0006779: ScaledDecimal readFrom: '5.3' would not answer a ScaledDecimal

It inherits this method from Number and Answer a Float...
Adding a posteriori asScaledDecimal conversion
- is not easy (How many digits?)
- is not good, passing through a Float will introduce roundOff errors

It is better hacking SqNumberParser
 ScaledDecimal-readFrom-M6779-nice-Patch.1.cs [^] (2,473 bytes) 11-22-07 21:35
 ScaledDecimal-readFrom-M6779-nice-Test.1.cs [^] (795 bytes) 11-22-07 21:36
 ScaledDecimal-readFrom-M6779-nice-Patch.2.cs [^] (2,626 bytes) 08-29-08 20:27

Notes
(0011563)
Keith_Hodges   
12-17-07 17:03   
"fix begin"
Installer mantis bug: 6779 fix:'ScaledDecimal-readFrom-M6779-nice-Patch.1.cs'.
"fix test"
Installer mantis bug: 6779 fix:'ScaledDecimal-readFrom-M6779-nice-Test.1.cs'.
"fix end"

(0012542)
nicolas cellier   
08-29-08 20:11   
"fix begin"
Installer mantis ensureFix: 7169.
Installer mantis bug: 6779 fix:'ScaledDecimal-readFrom-M6779-nice-Patch.2.cs'.
"fix test"
Installer mantis bug: 6779 fix:'ScaledDecimal-readFrom-M6779-nice-Test.1.cs'.
"fix end"

(0012544)
nicolas cellier   
08-29-08 20:30   
Patch number 1 is bugged as every SqNumberParser method for reading ScaledDecimal:

self assert: (ScaledDecimal readFrom: '0.50') = (1/2)

Patch number 2 correct this

See also 0007169

(0013279)
nicolas cellier   
08-24-09 20:17   
Fixed in http://source.squeak.org/trunk/Kernel-nice.202.mcz [^]