This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Warning for different pointer signedness
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: Paul Schlie <schlie at comcast dot net>
- Cc: <gcc at gcc dot gnu dot org>
- Date: Mon, 20 Dec 2004 14:57:55 -0500
- Subject: Re: Warning for different pointer signedness
- References: <BDEC9887.84F6%schlie@comcast.net>
On Dec 20, 2004, at 2:56 PM, Paul Schlie wrote:
Giovanni Bajo
since your patch:
http://gcc.gnu.org/ml/gcc-patches/2004-07/msg01284.html
has a great impact on existing codebases (linux kernel guys say it
triggers
6.5K times in full build), would you mind adding an entry about this
into
changes.html? It would help also to put a rationale there on why such
a change
was made, since we will undoubtly get this asked many times.
It would seem that the change was unnecessary, and possibly even
incorrect,
as although the objects they referance are not of the same signedness,
their pointers (which are the objects being compared) are completely
compatible, as the storage size and alignment they reference is
defined by
the objects storage class (i.e. char, short, int, long, etc.) which
would
seem to be insensitive to the objects signedness, are equivalent.
Wrong, wrong, wrong, the change only moved a warning from -pedantic
to always on, in fact some compilers reject the code as it is invalid c.
-- Pinski