Update: Don't keep fatalsToBrowser in your production script. See postings below for reasons.

You've also got fatalsToBrowser in there - however once your program is done and dusted I would have thought it best to remove it?

I disagree. In the same line of thought, you could propose to remove use strict/use warnings after your program is thoroughly tested. This is somewhat like asking your children to forget their good education once they are grown up :-).

The only reason I can come up with to remove any of the three is to to improve speed, and even that one is not sufficient: I challenge you to prove that the speed gain is more than marginal.

My experience shows that for many scripts I "finished" at a certain time, there is another time I have to go back and make some changes. Software is not like a statue that you once create and never change. But if you are going to change it, you better leave all the security mechanisms in place, or else you'll shoot yourself in the foot.

Even software that you are "sure" you will never modify might fail mysteriously due to not-yet uncovered bugs, a section of code you never really tested, an error condition that never ocurred before etc. For this, it's good to have FatalsToBrowser.

Apart from that, I like to treat every piece of software I write seriously. It helps me to acquire good coding habits, and it tends to save me a lot of work later.


In reply to Forgetting your good education by crenz
in thread Writing a perl quiz. Need advice. by DigitalKitty

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.