Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: require & import $module_name

by ikegami (Pope)
on Jul 20, 2012 at 05:25 UTC ( #982750=note: print w/ replies, xml ) Need Help??


in reply to require & import $module_name

my $file = $package; $file =~ s{::}{/}g; $file .= '.pm'; require $file; $package->import(@imports);

if already does that, so you could do

require if; if->import(1, $package, @imports);


Comment on Re: require & import $module_name
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://982750]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2015-07-05 23:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (68 votes), past polls