On Sun, Apr 17, 2005 at 09:50:28AM +0200, Leopold Toetsch wrote:
: Larry Wall <[EMAIL PROTECTED]> wrote:
: > Is there a bitarray lookup by native int?
: 
: Yes. All array lookups support a native int index.

Good, good.  Speaking of bitarrays (uint1 in the Perl panoply of
types), is there any built-in support for arrays of tiny integers
like uint2 or uint4?  It'd be nice to have uint24 in there too.
These can all be emulated from an array of bytes like vec() does in
Perl 5, but we're making feeble attempts to treat the oddball types
as standard types in Perl 6.  'Course, I'm not writing the compiler
myself, so I'm only asking out of curiosity.  :-)

: > Yes, but there's still got to be some internal overhead in deciding
: > whether the run-time Int object is representing the integer in some
: > kind of extended bigint form.  (Or are you meaning Int as Parrot's
: > native integer there?)
: 
: A Parrot Integer PMC (32bit for a 32bit sytem), which has a different
: type number then a BigInt PMC.

For simplicity Perl is probably just going to make a two-way
distinction between int/Int, where the latter is assumed to have
BigInt properties as necessary.  We can probably use Parrot Integer
PMCs for boxing native ints when we need to do that, but that's
hopefully transparent to the user.

Thanks for all the info.  Nice to know we're pushing the state of the
art in spots.  We'll just keep on pushing it till it falls over.

Larry

Reply via email to