in reply to Commenting One's Code In A GNU/GPL/OpenSource World

What if you guess the purpose of the code incorrectly?

If you don't want code comments to explain *what* the code is doing, that's fine. If you object to comments that explain *why* the code exists, that's silly.

This past week, I've been bugfixing a pile of code best described as "misguided". It features the same dozen lines of code repeated thirty times, with different category names.

There's a purpose to the repetition. It's not a good one, but there was a reason for it. Since there were no comments, I had to read the original programmer's mind.

Good luck.

  • Comment on Re: Commenting One's Code In A GNU/GPL/OpenSource World

Replies are listed 'Best First'.
Re: Re: Commenting One's Code In A GNU/GPL/OpenSource World
by stephen (Priest) on Apr 01, 2002 at 06:10 UTC
    Or to coin a slogan: "It's easier to read the programmer's mind if the programmer writes it down." :)

    stephen