Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^3: Automatically importing a subroutine for a particular namespace

by Anonymous Monk
on Jul 05, 2008 at 01:28 UTC ( #695637=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Automatically importing a subroutine for a particular namespace
in thread Automatically importing a subroutine for a particular namespace

All Exporter does is manipulate symbol tables (%PACKAGE::NAME::) ... if you search on cpan, you'll find http://search.cpan.org/~ktat/ExportTo-0.02/lib/ExportTo.pm ...


Comment on Re^3: Automatically importing a subroutine for a particular namespace
Re^4: Automatically importing a subroutine for a particular namespace
by jacques (Priest) on Jul 05, 2008 at 02:30 UTC
    That looks like exactly what I wanted. Thanks!
      Note that you would have to take care that the exporting takes place at the right time (which would be before the packages are loaded) if you want to have the same semantics as my solution. That's completely possible, of course (at least if you're not making it too complicated), but it may lead to confusion and/or spurious warnings if you're doing it wrong.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2014-08-23 01:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (169 votes), past polls