lkml.org 
[lkml]   [2007]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: OT: Does Linux have any "Perfect Code"
Michael Gerdau wrote:

> That having said:
> I really do like such obvious (as in: for those knowing the stuff anyway)
> comments when looking at code and probably concepts I'm not familiar with.
>
> IMO there is no need to belittle this type of comment. IMO any casual
> reader not familiar with the whole set of functions possibly involved
> will be thankful for this type of comment - I certainly am.

Obvious comments explaining _what_ the code is doing are annoying.
They're fluff. You can see what the code is doing.

The critical comments are the ones that explain _why_ and _how_. The
comments should give the higher level view as to the rationale for that
code.

Of course if you've got some highly-optimized bit of black magic there
had better be some good comments explaining what's going on...but there
should also be some comments explaining why we need the magic in the
first place.

Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-11-15 18:09    [W:0.064 / U:0.376 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site