Given a reference to a subroutine, how would you go about checking the that referenced subroutine actually exists.
For example if I run
perl -e'print \¬_there'I get back the reference CODE(0xeb570) which _looks_ like a valid subroutine reference, but (of course) isn't as the subroutine it claims to reference doesn't exist.
I suppose you can find out by running the reference in an 'eval' block, but you might not want to do that if the subroutine has potentially dangerous side effects.
--In reply to Validating a Code Reference by davorg
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |