Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: useless Useless warning

by aufflick (Deacon)
on Jun 25, 2008 at 01:51 UTC ( #693860=note: print w/ replies, xml ) Need Help??


in reply to Re: useless Useless warning
in thread useless Useless warning

Thanks - I hadn't looked at the diagnostics output.

So really the problem is in the assumption that there is no side effect, wheras in fact there is. The side effect is that the variable is made present in a a new scope which prevents the object from being destroyed (and the destructor has side effects).

Hm, or does it. Since I'm not assigning it to a variable the refcount won't be being increased. But surely it can't be destroyed while it's still in scope - in a void context or not...

I'll test it out and report back.


Comment on Re^2: useless Useless warning
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (11)
As of 2014-09-02 20:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (29 votes), past polls