[2263] XML dump of DOUBLE rounds values

Thorsten Hohage thohage at objectmanufactur.com
Mon Mar 26 17:15:39 CDT 2007


On 2007-03-26, at 23:58, Ruslan Zasukhin wrote:

> And we get
>     buff = "10149.2" on MAC, XCODE
>     buff = "10149.3" on WIN, MS Visual

AFAIR there was some moment in time, many years ago, where there was  
many issue in the FPU of a Pentium and incompatibility with AMD so  
there was many, many DOUBLE errors even in EXCEL.

And what I kept from this time, there is allways a difference in  
"rounding"between different plattforms.


> RESUME:
>
>     there is no technical way convert any possible DOUBLE VALUE
>     into string accurately.

After the date object being not really "empty" earlier this day,  
there is only one resume: Everything should be a string? (ok, THIS  
was not serious!)


> This is why I again want to point. If you need EXACT storage of  
> numbers,
> DO NOT use DOUBLE/FLOAT type.

Yes and the most important problem is not retrieving "correct" value,  
but comparing two values, because on a computer using rounding/ 
truncation you've got uncountable (right translation?) different  
"zeros"!


regards

Thorsten Hohage
--
objectmanufactur.com - Hamburg,Germany




More information about the Valentina mailing list