I think the expected behavior is the IEEE 754 round-to-nearest rule, which I *think* says that if two equally good choices exist, the one closer to positive infinity will be taken.

One classic workaround is to take absolute value, round, then restore the sign...


______________________________________
"... Three things see no end: A loop with exit code done wrong,
A semaphore untested, And the change that comes along. ..."
-- "Threes" Rev 1.1 - Duane Elms / Leslie Fish (http://www.ovff.org/pegasus/songs/threes-rev-11.html)

Reply via email to