Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
Syntactic Confectionery Delight
 
PerlMonks  

Re: when is destroy function called

by aitap (Chaplain)
on Feb 27, 2013 at 16:44 UTC ( #1020923=note: print w/ replies, xml ) Need Help??


in reply to when is destroy function called

As perldoc perlobj says,

When the last reference to an object goes away, the object is destroyed. If you only have one reference to an object stored in a lexical scalar, the object is destroyed when that scalar goes out of scope.
So you can safely copy the file after the object was undefined.
Sorry if my advice was wrong.


Comment on Re: when is destroy function called

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (11)
As of 2014-04-18 19:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (471 votes), past polls