I want to check if an object has a specific overload method in perl - for example if it has a sub dereferencing overload that would have been defined like this:
use overload
'&{}' => \&_some_sub;
sub some_sub {...}
If I dump the symbol table of the package that created the object in question I see the following:
[
"new",
"import",
"((",
"(&{}",
"ISA",
"__ANON__",
"BEGIN",
]
Does finding (&{} in the symbol table always mean that a sub deref methd exists? and does it work for other overloads too (I see ("" if I overload stringification).