Integer = infinite precision integer? How?

Does anyone have an explanation how Haskell implement this? Or a pointer to a article describing this? -- View this message in context: http://www.nabble.com/Integer-%3D-infinite-precision-integer--How--tp1827387... Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.

On Thu, Jul 03, 2008 at 11:49:44PM -0700, leledumbo wrote:
Does anyone have an explanation how Haskell implement this? Or a pointer to a article describing this? --
AFAIK it's implemented via GMP library: http://gmplib.org/
View this message in context: http://www.nabble.com/Integer-%3D-infinite-precision-integer--How--tp1827387... Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
-- pierre

On Fri, 04 Jul 2008 02:49:44 -0400, leledumbo
Does anyone have an explanation how Haskell implement this? Or a pointer to a article describing this?
GMP is presently used in GHC (at least according to http://hackage.haskell.org/trac/ghc/wiki/ReplacingGMPNotes). Regards, Brad Larsen

On Thu, 3 Jul 2008, leledumbo wrote:
Does anyone have an explanation how Haskell implement this? Or a pointer to a article describing this?
Just a nitpick: Integers can have an arbitrary but only a finite number of digits. In contrast to that reals have infinitely many digits after the decimal point. There are Cantor's proofs that the set of natural numbers and the set of rational numbers have the same cardinality, whereas the set of reals has larger cardinality. Students often fail to understand that, if they are not aware that integers can only have finitely many digits.
participants (4)
-
Brad Larsen
-
Henning Thielemann
-
leledumbo
-
pierre