Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^2: ptkdb: 'my' variable in sub retains value between calls

by leonidlm (Pilgrim)
on Aug 10, 2008 at 16:11 UTC ( [id://703436]=note: print w/replies, xml ) Need Help??


in reply to Re: ptkdb: 'my' variable in sub retains value between calls
in thread ptkdb: 'my' variable in sub retains value between calls

Thank you all. The variable names are just for an example, of course I used a proper names in my program, it is more than 2000 lines, I don't think I would manage elsewhere.
  • Comment on Re^2: ptkdb: 'my' variable in sub retains value between calls

Replies are listed 'Best First'.
Re^3: ptkdb: 'my' variable in sub retains value between calls
by GrandFather (Saint) on Aug 10, 2008 at 22:53 UTC

    $foo and $bar are good time honored place holder names for variables and are almost as easy to type as $a and $b.


    Perl reduces RSI - it saves typing
Re^3: ptkdb: 'my' variable in sub retains value between calls
by Anonymous Monk on Aug 11, 2008 at 02:16 UTC
    If, in addition to using warnings with its very helpful message referred to in other replies, you had been using strict, Perl would never have let you make the mistake in the first place if you were using names other than $a and $b!

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (2)
As of 2026-03-15 14:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.