$pm =~ s{::}{/}g; $pm .= '.pm'; eval { require $pm } or die("Unable to load plugin $plugin: $@\n");
Just one question, I'm all against string eval most of the time, but in this case would it be much different to avoid the self-made $plugin "conversion" and do
eval qq{ require $plugin } or die("Unable to load plugin $plugin: $@\n");
instead?
In reply to Re^2: loading modules at runtime
by blazar
in thread loading modules at runtime
by zer
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |