From: simonmar Date: Wed, 27 Feb 2002 10:29:12 +0000 (+0000) Subject: [project @ 2002-02-27 10:26:13 by simonmar] X-Git-Tag: Approx_11550_changesets_converted~2347 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=90cdb78726795320190f5dac8e82c4f0a068014a;hp=2a966c8ed5b083a6b33f61dc002ff5a62e79b2f8;p=ghc-hetmet.git [project @ 2002-02-27 10:26:13 by simonmar] Expand on the behaviour of fromIntegral a bit. --- diff --git a/ghc/docs/users_guide/vs_haskell.sgml b/ghc/docs/users_guide/vs_haskell.sgml index 5ad9f98..87c6b9c 100644 --- a/ghc/docs/users_guide/vs_haskell.sgml +++ b/ghc/docs/users_guide/vs_haskell.sgml @@ -220,6 +220,15 @@ main = print (array (1,1) [(1,2), (1,3)]) arithmetic). This behaviour was chosen so that for example writing 0xffffffff :: Int preserves the bit-pattern in the resulting Int. + + The fromIntegral function also + preserves bit-patterns when converting between the sized + integral types (Int8, + Int16, Int32, + Int64 and the unsigned + Word variants), see and . +