
27 Oct
2008
27 Oct
'08
9:50 a.m.
[1] The Haskell 98 Report: Predefined Types and Classes http://haskell.org/onlinereport/basic.html
This behaviour is not what I expect after reading the description at http://haskell.org/ghc/docs/latest/html/libraries/base/ Prelude.html#v:round . Given that this behaviour has caused a bit of confusion I think a change to the documention might be in order.
Given that the documentation says "round x returns the nearest integer to x", I think pretty much any behavior can be expected -- there's no single integer nearest to 2.5. The documentation certainly needs updated though. Bob