Patrick R. Michaud wrote:
On Fri, Aug 13, 2010 at 11:08:30AM -0400, Aaron Sherman wrote:
On Thu, Aug 12, 2010 at 3:48 PM, Darren Duncan <dar...@darrenduncan.net>wrote:

What is the difference between Parrot bignums and gmp?  Could Parrot not
just use gmp to implement its bignums? --  Darren Duncan

Parrot does use GMP. What we're discussing is how appropriate those are for
Perl 6. My feeling is that the closer Perl 6 can get to using GMP directly,
the better. If we need to wrap Parrot BigInt in a Perl 6 class, that
wouldn't be terrible.

It ultimately needs to be wrapped into a Perl 6 Int -- there's not a
separate "big integer" type. Or, put another way, we need Rakudo's Int class to be smart enough to adapt to using a bigint representation (e.g., Parrot's BigInt PMC)
whenever the values are outside of a native int.

I think it would make sense for Parrot to provide the abstraction directly as to whether a bigint or a native int was being used, so Rakudo and other language implementations that just want to have a single all-purpose integer type can use it rather than having to have their own promotion or abstraction logic.

I seem to recall a discussion on this happening a year ago, although that might have been with respect to Perl 5.

-- Darren Duncan

Reply via email to