Re: [RFC] [PATCH] omnibus header cleanup, certification

From: Urs Thuermann (urs@isnogud.escape.de)
Date: Tue Nov 27 2001 - 03:32:09 EST


"H. Peter Anvin" <hpa@zytor.com> writes:

> It's also worth noting that there is nothing that it can get confused
> with and still have a compilable expression.

Well, there are cases, where -1 and (-1) make a difference (see below)
but these are extremely unlikely to appear in the kernel src code.
Thus, I also think these patches are unnecessary.

For example,

    int *p; and int *p
    -1[p]; (-1)[p];

are both valid and compilable code segments, with no undefined or
implementation-defined behavior (as long as p points to an element of
an array other than the first and last), and both code segments do
different things.

> I don't believe the unary-expression patches are necessary. They are,
> of course, harmless, except for the fact that my eyes glazed over
> staring at page after page of these, which very few actual potential (!)
> bugs (there were a couple, like the iopage+ ones...)

ack.

urs
-
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/



This archive was generated by hypermail 2b29 : Fri Nov 30 2001 - 21:00:26 EST