Apparent Bug: Number>>printShowingDecimalPlaces::

cogitare at ixpres.com cogitare at ixpres.com
Fri May 23 22:33:27 UTC 2003


Float number longer than 9 digits printed incorrectly
by Number>>printShowingDecimalPlaces:
(Version Squeak3.5-5180 on Windows XP)

	"THE BUG IN CONCISE FORM:"
	Transcript show: (1234.567 printShowingDecimalPlaces: 2).
	    "--> 1234.57 "
	Transcript show: (12345.678 printShowingDecimalPlaces: 2).
	    "--> 12345.68 "
	Transcript show: (123456.789 printShowingDecimalPlaces: 2).
		"--> 123456.79 "
	Transcript show: (1234567.891 printShowingDecimalPlaces: 2). 
		"--> 1.23 (oops)"
		
	"The problem appears to be in Number>>printShowingDecimalPlaces:'
	 and involves its usage of the 'Object>>asString' method
	 which does as its makers intended and creates a string
	 in exponential notation format (1.23456789e6). 
	 Unfortunately, 'Number>>printShowingDecimalPlaces:' is
	 expecting a decimal format string (1234567.89)"

* * * 

No fix available now...or even soon...

(Still mind-boggled and basically
clueless.)




More information about the Squeak-dev mailing list