Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^2: What does this mean?

by tobyink (Abbot)
on Aug 20, 2012 at 22:24 UTC ( #988525=note: print w/ replies, xml ) Need Help??


in reply to Re: What does this mean?
in thread What does this mean?

I don't know if it was necessarily intended to act as a getter+setter. It's probably just a setter that happens to include a quick check to prevent people from setting the ID to undef. It happens to also return the current ID, but I'd assume that's just incidental. A method needs to return something; might as well be something vaguely useful.

perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'


Comment on Re^2: What does this mean?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2014-12-22 08:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (112 votes), past polls