in reply to subroutine refs
my $subs = { "joes_routine" => \&joesub, "marks_routine" => \&marksub, ... }; $subchoice = GetSubToUse(); @args = GetSubArgs(); $subs->{$subchoice}->(@args);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: subroutine refs
by lancer (Scribe) on Jul 25, 2015 at 14:03 UTC |