sub s1 { my $sub=shift; # get it! # you may want to add checks => perldoc -f ref. print "s1"; $sub->(); # execute it! }
Indeed they gave you a good suggestion: this is the best way to do what you say you want to do.
In reply to Re^3: Calling functions from different namespaces
by blazar
in thread Calling functions from different namespaces
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |