ONJava.com -- The Independent Source for Enterprise Java
oreilly.comSafari Books Online.Conferences.

advertisement

AddThis Social Bookmark Button
Weblog:   OSCON 2.1: Perl Best Practices
Subject:   One rec. I disagree with...
Date:   2005-08-03 14:11:03
From:   KLEstes
Reading from another article on best practices, which I assume this practice is from the book: leaving off the parenthesis in subroutine calls only reserved for built in functions.


The first reason I disagree: it's weak - doesn't make an appreciable difference.


The second reason - built-ins aren't holy. They are pretty good, which is the reason they were included, but they deserve no special syntax in my judgement.


The third reason - if a built-in can do it, I want to do it. I hate that I have to use prototypes to get rid of the parenthesis. If a built-in can do something, then it is a good enough concept for me to use. The strength of perl is that it pretty much allows you to do just that. Lvalued subs ? You can do it. Drop the stinkin' parenthesis from your calls ? You can do it - but you will have to uglify your code to do so.


So I disagree with a couple of practices - if even two or three practices make a good difference in my development strategy the book will be well worth it. As it is, I suspect this just might be the Perl book of the year :) Only a mindless dolt (or an utter beginner) will agree with everything anyway.


The author of the article summed it up elegantly, when he said that if Conway's book made you think (even if you disagree) then Conway accomplished his goal. To which I can only add: Conway is the devil !


1 to 1 of 1
1 to 1 of 1