in reply to Exporting subs from package required in an eval
use calls require and then import(). If you need to import symbols, you'll have to call import() manually. Untested, almost pseudo-code follows:
my $package = "Bot::Protocol::$proto"; eval { require $package }; $package->import();
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Exporting subs from package required in an eval
by cfreak (Chaplain) on Jun 25, 2003 at 01:41 UTC | |
|
Re^2: Exporting subs from package required in an eval
by Anonymous Monk on May 06, 2010 at 14:02 UTC | |
by Corion (Patriarch) on May 06, 2010 at 14:10 UTC | |
by Anonymous Monk on May 06, 2010 at 15:04 UTC |