Re: [perl #31859] [TODO] Plain ole Hash
Bernhard Schmalhofer via RT wrote: I assume that the Hash PMC should also be used by PIR code in 'runtime/parrot/library'. In that case returning PMCNULL is not nice, as the returned PMC can't even be queried for it's type. So for now a None PMC is returned for non-existent keys. However this is not consistent with e.q. FixedPMCArray, which does return PMCNULL. ResizablePMCArray is even more inconsistent and seems to return an Undef PMC. Yep, we've to unify aggregates behavior. Thanks, applied. leo
Re: [perl #31859] [TODO] Plain ole Hash
Bernhard Schmalhofer via RT wrote: The attached patch makes the Hash PMC use basic PMCs by default. Native integers, numbers and strings are now stored as Integer, Float and String PMCs. For keys without values, the Undef PMC is returned, as it is laid out in pdd17. As already mentioned: the Hash PMC is mainly used inside Parrot to manage internals. For a non-existent key NULL should be returned. WRT type mappings: we need a more general scheme for mappings of basic types to Perl, python, whatever. TODO: - Go skiing in the Austrian Alps!! He, he. Have fun! CU, Bernhard Servus, leo
[perl #31859] [TODO] Plain ole Hash
# New Ticket Created by Will Coleda # Please include the string: [perl #31859] # in the subject line of all future correspondence about this issue. # http://rt.perl.org:80/rt3/Ticket/Display.html?id=31859 > Original Message Subject: Re: Plain ole Hash Date: Mon, 04 Oct 2004 15:24:03 -0400 From: Dan Sugalski <[EMAIL PROTECTED]> To: William Coleda <[EMAIL PROTECTED]>, Perl 6 Internals <[EMAIL PROTECTED]> References: <[EMAIL PROTECTED]> At 9:56 AM -0400 10/2/04, William Coleda wrote: >Are there any plans to make a Hash (as oppposed to a PerlHash, or an >OrderedHash (which is really a PerlHash) ? D'oh! Knew there was something that was getting forgotten. Yes, there should be plans. If someone wants to throw a basic Hash.pmc list-way we'll get it in. -- Dan --it's like this--- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk