in reply to Data Structures design help to represent function args for testing
or something similar.my %functions = ( function1 => [ "arg1", { arg2 => val2 }], function2 => [ ... ], .... ); while (my ($func,$args) = each %functions) { no strict 'refs'; &{"harcommon::$func"}(@$args); }
updated s/wile/while/. thanks to FunkyMonk
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Data Structures design help to represent function args for testing
by goibhniu (Hermit) on Sep 21, 2007 at 00:50 UTC | |
by GrandFather (Saint) on Sep 21, 2007 at 03:06 UTC |