BrowserUk had a similar comment, so please consider this a response to both your remarks.

Smart::Comments is cool -- I hadn't seen that before. It does satisfy a similar itch, but not the *same* itch. My interest is not in having debugging code that only runs while I'm in debugging mode (though there are times when I want that, and Smart::Comments will scratch that itch nicely).

Instead, my interest is solely in being able to add temporary code which will be physically removed from the source -- whether programatically or not -- before it is released to anyone. It's a stylistic question, and that's all. Many people marks such temporary lines of code by outdenting, surrounding them with special comments, using DEBUG: { } style labeled blocks, etc. Whatever works, you should use. The purpose of the Meditation is a style of highlighting this type of code visually that I've found interesting, with the hope that others who think in a similar way will benefit.

So, when you say "It's really confusing to have leading semi-colons because I'm so used to that having meaning in other languages.", my only real response is: this meditation is not for you then, use whatever works for you. In fact, I was sort of hoping that other people would share their preferred style for such things.

Just to be painfully clear, since I get the feeling people are reading more into this meditation than intended: this is not a suggestion for a standard, an assumption that this is better than any other method, etc., nor am I suggesting that these lines be left in any code that is shared with other people.

I hope that clears things up a bit. ;-) But thank you for pointing me at Smart::Comments, as that will be useful to me for conditional debugging code I *do* want left in.

<-radiant.matrix->
A collection of thoughts and links from the minds of geeks
The Code that can be seen is not the true Code
I haven't found a problem yet that can't be solved by a well-placed trebuchet

In reply to Re^2: Perlish Debugging Style by radiantmatrix
in thread Perlish Debugging Style by radiantmatrix

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.