# To be honest: if you're not sure what's in $t # at all, then things begin to get silly. if ($type = ref $t) { eval { $t->isa("UNIVERSAL"); }; if ( $@=~/unblessed/ ) { print "It's a $type, not blessed.\n" } else { print "It's blessed into class $type"; } } else { print "Not a reference at all\n"; }
In reply to Re: Is reference blessed?
by clintp
in thread Is reference blessed?
by gildir
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |