Re: "dselect" replacement team
On 19 Apr 1997, Kai Henningsen wrote:
> email@example.com (Jason Gunthorpe) wrote on 13.04.97 in <Pine.A22.214.171.1240413164332.54672Ifirstname.lastname@example.org>:
> > Now, in my definition clear code requires a very high comment density,
> Interestingly enough, I, on the other hand, think that code with a high
> comment density is very unclear and hard to read.
> Maybe that's because I believe that _most_ code should be written (and
> _can_ be written) to be easily understandable without any comments at all.
> That's what descriptive names are for.
Yes, if you already know what the code should be doing, consider:
Now, please tell me what that does :> Now you can guess to a quite high
degree of detail, but I imagine you really don't know what ElementMask is.
You don't really know were this 'DataBase' is either. Now, if I only put
comments in 'strange' places then you will have to lookup
Writer::ElementMask, Write::CreateDataBase and Writer::StreamOut, READ
them all and determine exactly when them an all their subfunctions do
before you can understand what those 3 lines actuall do. This could
easially amount to forcing you to -READ- >500 lines of code, not just
I on the other hand think it's perfectly clear because I alread know what
the database is of, what the masking function does and other details. I
can tell you with many well placed comment and save you alot of time, esp
if you don't really care what CreateDataBase does internally, only
Strange meaning places of code that are not clear if you already know the
rest of the code.
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
Trouble? e-mail to email@example.com .