Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Referncing a local array outside

by welchavw (Pilgrim)
on Dec 16, 2003 at 15:37 UTC ( #315073=note: print w/ replies, xml ) Need Help??


in reply to Referncing a local array outside

Richard,

The suggestions that you use my, not local, are completely correct and should be followed. However, in the interest of completely answering your questions, I wanted to add that it is my understanding that "early" garbage collection of your localized vars would not happen. Localized variables are gc'd like other variables - if outstanding references exist, such variables are not eligible for gc.

BTW, I am writing this without reference to any particular documentation, just my experience of dynamic scoping. If my understanding here is incorrect, I will be shocked and would much appreciate learning the error of my ways from those that know better (part of the reason I post this).

,welchavw


Comment on Re: Referncing a local array outside

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (6)
As of 2015-07-04 22:48 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 (60 votes), past polls