Perl Monk, Perl Meditation | |
PerlMonks |
Re: Namespace variable gatheringby dsb (Chaplain) |
on Apr 24, 2002 at 21:07 UTC ( [id://161789]=note: print w/replies, xml ) | Need Help?? |
I'm not really sure what you mean by namespace: A package's namespace? All variable types with the same name(i.e. $var,@var,%var)? For this you could do a typeglob. This line sets all of the variable types with the name foo to the values of the corresponding variable types with the name bar Or do you mean all of a hash's or array's values? For this you could look into hash and array slices. Note that with the hash slice we are using the symbol normally associated with arrays. That is because this the left operand is list of keys.
Amel
In Section
Seekers of Perl Wisdom
|
|