Re: condingstyle, was Re: utrace comments

From: David Howells
Date: Wed May 02 2007 - 08:06:05 EST


Eric W. Biederman <ebiederm@xxxxxxxxxxxx> wrote:

> > But the condition doesn't line up with the code:
>
> Exactly. The condition not lining up with the following code helps
> code helps separate the two.

Sorry about that: I realised you were agreeing with me about 5s after I sent
the message.

> However there is the practical way to solve this if you have
> a sufficiently large conditional, or the conditional appears
> several times.

That doesn't necessarily work - for instance if the condition has side effects
on local variables (eg: postinc). OTOH, large complex conditions with side
effects have to be abused with care and preferably avoided. goto is your
friend:-)

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