Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^12: Modern Perl and the Future of Perl

by chromatic (Archbishop)
on Dec 23, 2007 at 02:46 UTC ( [id://658733]=note: print w/replies, xml ) Need Help??


in reply to Re^11: Modern Perl and the Future of Perl
in thread Modern Perl and the Future of Perl

To what end will they use Perl::Critic?

That really depends on what they want to accomplish. You're not going to convince me that the existence of P::C and your emboldened clause will suddenly turn good coders into raging lunatics, and you're not going to convince me that telling everyone not to use a good and useful tool because raging lunatics might misuse it is a smart idea.

Spammers often use Perl, and Template, for example. They could use Mail::Bulkmail if they wanted. If I didn't have a mailing list manager at work, I might use it to send out the Perl newsletter.

Perl::Critic alienates what has to be a programmer's internal state into a technical instrument, which is wrong.

Valgrind and gdb take what could be my internal state of reading through a program, reasoning about what it does and when, and turn it into a technical instrument, and you can take them away from me when I retire from programming for good.

Perl::Tidy takes what I could do manually -- format code -- and turns it into a technical process. Sure, someone could write a pre-commit hook that runs P::T over a chunk of code and rejects the commit if there are any variations from the coding standard. Anyone who does that is a passive-aggressive lunatic control freak though, and it's not the tool's fault.

If you, or I, or Max K-A, or anyone shuts off your, my, his, or her brain when using P::T or P::C or strict or warnings, it's not the tool's fault, and telling people not to use the tool isn't going to fix that. People looking for shortcuts won't stop looking for shortcuts if P::C goes away, and they're not magically going to create good code and write thoughtfully and become great developers just because you've taken away one shortcut. (Believing the converse is, in my mind, a shortcut of the same kind.)

In conclusion:

Perl::Critic is an extensible framework for creating and applying coding standards to Perl source code. Essentially, it is a static source code analysis engine. Perl::Critic is distributed with a number of Perl::Critic::Policy modules that attempt to enforce various coding guidelines. Most Policy modules are based on Damian Conway's book Perl Best Practices. However, Perl::Critic is not limited to PBP and will even support Policies that contradict Conway. You can enable, disable, and customize those Polices through the Perl::Critic interface. You can also create new Policy modules that suit your own tastes.

Emphasis mine. Thank you for the discussion.

  • Comment on Re^12: Modern Perl and the Future of Perl

Replies are listed 'Best First'.
Re^13: Modern Perl and the Future of Perl
by Cop (Initiate) on Dec 23, 2007 at 03:00 UTC

    Keep fighting until you win, because you don't care about truth. By looking at you and your behavior, I not only |SUSPECT perl 6 is dead, I KNOW it is dead.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2024-04-19 21:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found