From: Colin P. A. <co...@co...> - 2007-08-18 05:50:45
|
It seems that truncated_to_integer_64 is not enough in itself, and (in ISE 6.0) isn't sufficiently accurate anyway. My problem is converting 1e100 to an integer. The debugger displays this as something like 1.000000000000000006e100 (I have not counted the the exact number of zeros). Calling truncated_to_integer_64 on this produces -9223372036854775808. The alternative (which I have adopted) is to convert to MA_DECIMAL first, using make_from_string ({DOUBLE}.out), works, but gives an inaccurate value (because of the 6). I guess this is acceptable, as doubles are inherently inaccurate. -- Colin Adams Preston Lancashire |