RE: [flexcoders] In actionscript, converting from string to number loses precision

2006-03-09 Thread Gordon Smith
com Subject: RE: [flexcoders] In actionscript, converting from string to number loses precision   This actually exists in Flash 8 as well.  And I don't think it's a case of trace( ) not calling parseFloat, I get the same thing when I output it to a textfield. And it gets better:

RE: [flexcoders] In actionscript, converting from string to number loses precision

2006-03-09 Thread Boon Chew
This actually exists in Flash 8 as well.  And I don't think it's a case of trace( ) not calling parseFloat, I get the same thing when I output it to a textfield.And it gets better:stop();var s:String = "952.85";var i:Number = parseFloat(s);// txtResultX are dynamic textbox on stagetxtResult1 = M

RE: [flexcoders] In actionscript, converting from string to number loses precision

2006-03-08 Thread Gordon Smith
This is a bug. Can you please file it?   Apparently when the AS3 compiler compiles trace(i - 952.86), it doesn't convert the 952.86 to the exact same Number that the player does when it executes parseFloat() on "952.86". They should produce identical Numbers, and the different should be