"be consistent" | |
PerlMonks |
Re: Using SV as key in hashby Fletch (Bishop) |
on Jul 17, 2006 at 01:41 UTC ( [id://561629]=note: print w/replies, xml ) | Need Help?? |
Gratuitous handwaving here since it's been ages since I mucked with XS, but . . . I want to say that the keys to an HV are always stringified and kept as char*, not as SV*s. A good starting place might be to look at what Tie::RefHash does and then implement something similar in your XS (possibly something like keeping your own internal mapping of char* to original SV*).
In Section
Seekers of Perl Wisdom
|
|