If I were you, I would rewrite the sections in question. I might say something like, "The existing code relies on side effects and undocumented assumptions. It is fragile and could be made more clear. Here is my suggestion for an improvement."
If you lay them out side by side, it'll be obvious... assuming the other people know sufficient Perl.
I'd leave the issue of comments alone. Again, assuming the other people have a decent grasp (graps?!) of the English language, they'll likely come to the same conclusion you did without having to be told how to feel about them.
If you're in a politically charged position, you may be better off leading people to your opinion than presenting it as an opposing position -- especially if the existing code is already in place and doing its job. (For what it's worth, the only problem I have with the substr code is the need to assign to $_. That's useless.)
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
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:
Outside of code tags, you may need to use entities for some characters:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] ||