in reply to Re^2: Should code that does not use strict even be considered here?
in thread Should code that does not use strict even be considered here?

That said, I agree that if "use strict;" and/or "use warnings;" doesn't affect the code one way or the other, it might be worthwhile to mention it as a guideline,
Why? There millions of "good advices" one could give, but giving it to people without having any idea whether they already know that is irritating. If you ask the way to someone, and his response is "wear your seatbelts", are you happy for the good advice given? You probably already know it, it doesn't help you at all the solve your current problem, and the one who can give you directions moves on, thinking you already got help.

Leave the uttering of irrelevant good advices to ones mother.

And don't forget to wear a coat outside, or you'll catch a cold! (I expect many ++'s for this good advice).

  • Comment on Re^3: Should code that does not use strict even be considered here?

Replies are listed 'Best First'.
Re^4: Should code that does not use strict even be considered here?
by Eimi Metamorphoumai (Deacon) on Apr 09, 2009 at 15:04 UTC
    If I ask directions from someone, and get the right answer, and I'm not wearing a seatbelt, I don't mind being told also "By the way, the cops around here are really strict about seatbelts; you might want to buckle up before you get a ticket".

    Similarly, if I see code that declares all of its variables, I probably won't mention anything. But if it's obvious that adding "strict" reveals undeclared variables or other problems, it seems worthwhile to point it out, particularly if the user seems new or not particularly knowledgeable. If they know they can ignore it; otherwise, they'll learn eventually, and probably the hard way.

    And thanks, I'd forgotten to check the weather before I left, and it is a bit chilly.

Re^4: Should code that does not use strict even be considered here?
by BrowserUk (Patriarch) on Apr 09, 2009 at 15:28 UTC