delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/06/06/23:38:38

Date: Tue, 6 Jun 1995 22:32:23 -0400
From: dj (DJ Delorie)
To: Lorin DOT Lund AT LDDSNet DOT Com
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Re: VOTE: CODE STANDARDS

>      My experience is that those of my colleagues that write good comments 
>      write such organized code that the comments are hardly necessary.  
>      Those who write code that functions correctly but is harder to read, 
>      usually have their minds so much into the program that anything they 
>      write wouldn't make much sense to the un-initiated anyway.

One exception.

When a programmer is *required* to write obfuscated code in order to
make the function work correctly, it is a good idea to include a
comment that says "hey, I meant to do that.  Here's why...".

Comments should answer the question "why", not "how".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019