|The stupid question is the question not asked|
Is reference blessed?by gildir (Pilgrim)
|on Nov 23, 2001 at 14:22 UTC||Need Help??|
gildir has asked for the wisdom of the Perl Monks concerning the following question:
I want to check if some reference (say $r) is blessed or not.
And another question: How do I get the real type of reference, even if it is blessed. I mean, that is I have an object $o of class Foo::Bar, ref $o allways returns Foo::Bar. How do I chcek if $o is blessed reference to HASH or to ARRAY or whatever?
I have been peeking into some modules around (Data::Dumper I think) and found only this ugly code
Is this the only way?
I have considered perl an elegant language (when used correctly) a I do not like this.