here is what i want to accomplish: $self->&$testname($system). Execute sub '$testname' with '$system' as parameter in object '$self'.
Depends what do you mean by "... in object $self"?
I see two possible interpretations of that:
$testname->( $system );
You'll probably need no strict 'refs'; for that.
$self->$testname( $system );
Seems to work fine with full strict.
In reply to Re^3: how to call a sub via variable in library
by BrowserUk
in thread how to call a sub via variable in library
by glenn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |