Re: [Wildly off-topic] Re: Linus is on a powertrip..

Andrej Presern (andrejp@luz.fe.uni-lj.si)
Sat, 3 Oct 1998 01:40:59 +0200


On Fri, 02 Oct 1998, David Todd wrote:
>$.02 (long winded diatribe from relative outsider):
>
>I think that what Linus is objecting to is lack of explanation.
>
>Any patch that is submitted should be explainable very briefly, but very, very
>completely. This is probably best achieved if the patch fixes or implements
>exactly one thing. I would say thing should equal one algorithm, or less.

Consider heavily commenting the code in the patch.

A patch can be then verified, such that:
a) comments in the patch make sense (patch code)
b) comments in the whole context make sense (patched code)
c) patched code actually does what is described in the comments

This means more work for the patch author. On the other hand, it also means:
a) that the author of the patch knows what he wants the code to do; he
describes it in sufficient deatil in the comments
b) since the code is now better commented, it's easier to understand, verify
and modify

Andrej

--
Andrej Presern, andrejp@luz.fe.uni-lj.si

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