While most people are encouraged to comment code in any programs or scripts that they produce you may want to revisit that concept now….
Why?
Well imagine if someone left a comment that wasn’t that flattering in the midst of it all. For example:
“the user is a w**nker”
I’m sure we’ve all done it 🙂
I haven’t ever written that much code, so I’m less likely to have (thankfully!)
See full story – and who said Apple were boring? 🙂
winds says
Commenting your code is fine. But this is not code commentary – it’s messing, childish and immature. Part of me is not surprised, however.
Why castigate good and useful commentary because of some idiots? My code commentary is for the benefit of the person coming after me and having had to maintain uncommented code I attach a great deal of importance to decently documented code.
Ken McGuire says
There was a time when I was a little humourous with code commenting but I’ll try stick to the point now…. Most of the time its notes to myself as much as other people but it all helps!
Chris Byrne says
I remember a colleague who used to use “Do until hell freezes over” in his code (many many years back, I might add) A quick search shows this is still common practice. But seriously, commenting is a key documentary aid and can add elegance to well crafted code. No place for wisecracks.
David Neylon says
I’d have to say commenting your code is a must but definitely keep the personal comments out. I’ve spent too much time wading through somebody else’s thought processes not to appreciate good comments.