laziness, impatience, and hubris | |
PerlMonks |
Re: undef as a key in a hash.by Eimi Metamorphoumai (Deacon) |
on Sep 25, 2007 at 18:40 UTC ( [id://641016]=note: print w/replies, xml ) | Need Help?? |
Hash keys are always strings, so if you try to use undef it will be coerced to the empty string, with a warning ("Use of uninitialized value in hash element") if warnings are enabled. So it shouldn't actually be possible for that code to be called.
In Section
Seekers of Perl Wisdom
|
|