[MLton-user] IEEEReal rounding not working
seanmcl at gmail.com
Thu Jul 26 12:26:54 PDT 2007
Yes, I also came to this conclusion
val mtenth_lo = (down();(Option.valOf ` Real.fromString "1.0") / (
Option.valOf ` Real.fromString "10.0"))
val mtenth_hi = (up();(Option.valOf ` R.fromString "1.0") / (Option.valOf`
These do the correct thing.
I'm not sure what the correct behavior should be. I'd hate to lose
optimizations, as I switched
from O'Caml because the floating point computations were so much faster in
But it would be nice to have a document somewhere specifying exactly how
are treated in expressions. For instance, I can imagine an optimization
Real.fromString at compile time for a string constant, which would kill the
> BTW, would you expect the following output:
Yes, that looks right.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the MLton-user