Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Re: Scope Between global and my

by ctilmes (Priest)
on Apr 01, 2004 at 18:53 UTC ( #341748=note: print w/ replies, xml ) Need Help??


in reply to Re: Scope Between global and my
in thread Scope Between global and my

I would only use the package-global variable if other packages (or main) must have access.

In this case, just use a 'package' lexical:

package Foo; my $data; sub foo { ... } sub bar { ... } 1;


Comment on Re: Re: Scope Between global and my
Download Code

Log In?
Username:
Password:

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

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

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (154 votes), past polls