[Haskell-cafe] How to convert number types.
Brandon S. Allbery KF8NH
allbery at ece.cmu.edu
Mon Dec 31 13:04:52 EST 2007
On Dec 31, 2007, at 12:50 , L.Guo wrote:
> And what is the difference between fromIntegral and fromInteger ?
Integer is a specific single type: unlimited-precision integers.
Integral is a typeclass which includes, among others: Integer, Int
(integers represented in machine words, so either 32 or 64 bits), the
various Word* types defined in Data.Word (various fixed word sizes
such as Word8, as distinct from the hardware-preferred one
represented by Int), and the compatibility types defined in
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university KF8NH
More information about the Haskell-Cafe