Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: RFC: Perl-Critic policy: ProhibitInlineSystemArgs

by adrianh (Chancellor)
on Jul 02, 2006 at 12:34 UTC ( [id://558847]=note: print w/replies, xml ) Need Help??


in reply to Re^2: RFC: Perl-Critic policy: ProhibitInlineSystemArgs
in thread RFC: Perl-Critic policy: ProhibitInlineSystemArgs

Defacto-standards get applied as blanket requirements by PHBs, weak coders who want someone else to make their decisions and obsessive-compulsive paranoid pedants that once bitten through lack of knowledge or care, become twice shy about using their own faculties.

All true.

But what about folk like me who find tools like Perl::Critic useful aids in approaching lumps of bad legacy code, who are (hopefully) bright enough to realise that a code smell is just a smell and not necessarily evil in all cases. Who can read through PBP and agree with some things and disagree with others.

Are we supposed to throw away useful tools like Perl::Critic because some idiots misuse them?

In this particular instance it's been my experience - which obviously differs from yours - that people are always throwing unclean user input into single-string calls to system. I'd love a tool that helps me find these instances more quickly.

Replies are listed 'Best First'.
Re^4: RFC: Perl-Critic policy: ProhibitInlineSystemArgs
by BrowserUk (Patriarch) on Jul 02, 2006 at 14:45 UTC

    Then you are the perfect audience for such a tool, and you will derive great benefit from it so long as you are in a position, (of sufficient authority), to make personal judgements about which rules to apply and when.

    But just as many experienced drivers are capable of deciding that 55/65/70 mph is too fast in fog/driving rain/icy/high traffic volume conditions, they are also capable of deciding that it is unnecessarially slow on an empty highway, on a dry, sunny, Sunday morning, but the power-that-be are most unlikely to take a favourable view of them making the latter judgement. Unfortunately, the law is an ass simply because the is no way to enshrine the concept of good judgement into it.

    In Germany on certain sections of autobahn, and I believe in Montana on some highways, there is the concept of unlimited speed. If the right vehicle is being driven in the right conditions, in the right way, then there is no set limit over which you can be prosecuted for speeding per se. However, you can be prosecuted for the full range of other road offences--undue care; dangerous driving; endangering other road users; under the various national guises.

    So, if you are sure that the vehicle your are in is capable, and the road conditions permit, and you are sure that you will not encounter a policeman who is disgruntled because his application to be on duty at the stadium where the national team are playing Brazil was turned down, then by all means put your foot down. 'scuse me while I let my mind wander.

    The point is that you may well be in a position of sufficient authority that you can make appropriate judgements, but for most programmers, most of the time, such rules tend to become black and white enforcements by people who do not understand the reasons underlying them. Second generation management that inherit a flexible system but decide rigid enforcement will better cover their deriars.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      But just as many experienced drivers are capable of deciding that 55/65/70 mph is too fast in fog/driving rain/icy/high traffic volume conditions, they are also capable of deciding that it is unnecessarially slow on an empty highway, on a dry, sunny, Sunday morning, but the power-that-be are most unlikely to take a favourable view of them making the latter judgement. Unfortunately, the law is an ass simply because the is no way to enshrine the concept of good judgement into it.

      True.

      Unfortunately there is a rather large chunk of the world that thinks they have good judgement when they manifestly do not. Given the occasions where I have been given a Big Ball Of Mud to maintain I'm not entirely certain that I wouldn't be better off if there weren't a lot more people slavishly obeying things like the rules PBP.

      I know for certain that I'm better off now that I've forced some people at $WORK to read it :-)

        I'm not entirely certain that I wouldn't be better off if there weren't a lot more people slavishly obeying things like the rules PBP.

        Trouble is, there are an awful lot of people that like you, feel that they know enough to impose their judgements upon those mythical others.

        Whilst I do not doubt that you have both the knowledge and experience to back up your judgement, there is a rather large chunk of the world that thinks they have [the] good judgement [to so impose] when they manifestly do not.


        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.

      In Germany on certain sections of autobahn..

      My understanding is that any driver over 130km is automatically personally responsible for anything that occurs. Smash your car up at 160km and well, if you survive the experience your insurance wont be doing much more than "nice paper-weight!" And if you are in an accident you will be charged for with much more serious things than just speeding, and probably speeding as well. In fact a colleague here has a friend who got a nice brand new porsche and managed to write it off at something like 200km. Of course his insurance just laughed. But the worst thing? It was the first drive he had after getting it off the lot!

      This isnt meant to be a correction, just a clarification. :-)

      ---
      $world=~s/war/peace/g

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (2)
As of 2024-03-19 06:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found