Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
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 drinking their drinks and smoking their pipes about the Monastery: (8)
As of 2015-07-30 09:33 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 (270 votes), past polls