in reply to Re: How to call subroutines using variables ?
in thread How to call subroutines using variables ?
It's a lot cleaner to use:
my $func_ref = main->can( $s );Checking that $func_ref is true should be sufficient. (Checking ref doesn't always work.)
|
|---|