Don't ask to ask, just ask | |
PerlMonks |
Re: Encapsulate function and variablesby gaal (Parson) |
on Jun 19, 2007 at 11:46 UTC ( [id://621996]=note: print w/replies, xml ) | Need Help?? |
For most practical purposes, you can treat a namespace exactly as if it were a hash.
An alternative is to load everything into a dummy package with a throwaway name, then to export everything out of it. Of course, both these proposals break if foo.pl switches namespaces itself, and that's hard to catch.
In Section
Seekers of Perl Wisdom
|
|