Re: GCC 3.4 Heads-up

From: H. Peter Anvin
Date: Fri Dec 26 2003 - 01:15:34 EST


Linus Torvalds wrote:

Similarly, what the _hell_ does the gcc extension

int a;

(char)a += b;

really mean? The whole extension is just braindamaged, again probably because there were non-C people involved at some point. It's very much against the C philosophy. I bet 99% of the people on this list have no clue what the exact semantics of the above are.


Oh, right. When I heard "cast as lvalue" I envisioned:

*(char *)foo = bar;

... being a warning, but that's not a cast, even though the pointer is.

-hpa



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