[Haskell-cafe] Why 'round' does not just round numbers ?
Jules Bean
jules at jellybean.co.uk
Mon Oct 27 10:59:31 EDT 2008
> 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.
The authority here is the report which says
"round x returns the nearest integer to x, the even integer if x is
equidistant between two integers."
However I agree the haddock ought to mirror the report.
Jules
More information about the Haskell-Cafe
mailing list