Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re (tilly) 3: use slack;

by tilly (Archbishop)
on Dec 22, 2000 at 00:10 UTC ( [id://47885]=note: print w/replies, xml ) Need Help??


in reply to Re: use slack;
in thread use slack;

I agree that in the AUTOLOAD example it is probably best to just turn off strict rather than to use a weird workaround.

In the example that he started with, I prefer looking up the correct function in a hash to scanning a list for it. YMMV. But the two wins I see are that you don't have to synchronize the name of the function with the name of the element in the list, and you don't get cow-orkers tempted to drop the scan and just jump to the function if it exists. (Which takes you from a safe use of symbolic references to a potentially very dangerous one.)

Also the conceptual step of knowing that you can keep functions in a hash is (in my eyes) a worthwhile step forward in sophistication.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (4)
As of 2024-04-24 19:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found