use overload '%{}'=>sub{{}}; sub new { bless [] } $ref = new(); eval { keys %$ref } ; print "is it a hash?" unless $@;
In reply to Re^2: Is there a way to find out what kind of ref an object is?
by ysth
in thread Is there a way to find out what kind of ref an object is?
by johnnywang
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |