In general, comments should discuss why something is done, its purpose and its goal. The code already shows how it is done, so commenting on this is redundant—and is a violation of the DRY principle.
Commenting source code gives you the perfect opportunity to document those elusive bits of a project that can't be documented anywhere else: engineering trade-offs, why decisions were made, what other alternatives were discarded, and so on.
- Chapter 8. Pragmatic Projects
- from The Pragmatic Programmer: From Journeyman to Master
- Publisher: Addison-Wesley Professional
- Released: October 1999
Pragmatic Programmer Pg 252
Share this highlighthttp://www.safaribooksonline.com/a/the-pragmatic-programmer/147937/