good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: Behaving appropriately based on ref() resultby bsb (Priest) |
on Jan 09, 2006 at 07:52 UTC ( [id://521864]=note: print w/replies, xml ) | Need Help?? |
Data::Rmap has code doing something like this and may meet your needs. It just uses Scalar::Utils::reftype and if/elses.
ref() can return anything for blessed objects
Scalar util's reftype is better for this job.
In Section
Seekers of Perl Wisdom
|
|