Do you know where your variables are? | |
PerlMonks |
Re: elegant array assignmentby snoopy (Curate) |
on Feb 16, 2008 at 00:08 UTC ( [id://668282]=note: print w/replies, xml ) | Need Help?? |
If an object has been blessed, Perls ref built in will return the class, not its type. Thus this code might not do what you expect for blessed array references.
Scalar::Util's reftype function consistantly returns the type and might be a better choice here:
In Section
Seekers of Perl Wisdom
|
|