Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^4: Preferred technique for named subroutine parameters?

by shmem (Chancellor)
on May 23, 2009 at 11:30 UTC ( [id://765817]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Preferred technique for named subroutine parameters?
in thread Preferred technique for named subroutine parameters?

Yes, of course. Your benchmark is even more appropriate to show the overhead, which consists in creating, populating and destroying a hash (call with hashref) vs. populating a hash already allocated on the subroutine's pad (call with list).

Might be small, but might sum up. Call it a micro-de-optimization, but I see no value in making perl slower for a questionable gain and a loss of readability.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-03-29 06:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found