Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: Can't Reference a Sub by Variable when using Strictby Fletch (Bishop) |
on Oct 04, 2004 at 02:08 UTC ( [id://396094]=note: print w/replies, xml ) | Need Help?? |
Erm, because that's what use strict does. You either need to use coderefs (my %lists = ( stuff => \&test1, things => \&test2 );), or use the grandfathered goto syntax:
Read perldoc strict for more details.
In Section
Seekers of Perl Wisdom
|
|