This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH INSTALLED]: Fix -Wc++-compat warnings in toplevel [t-z]*.c files
"Richard Guenther" <richard.guenther@gmail.com> writes:
> On Fri, Jun 20, 2008 at 8:42 PM, Kaveh R. GHAZI <ghazi@caip.rutgers.edu> wrote:
>> This patch fixes the -Wc++-compat warnings in the toplevel [t-z]*.c files.
>> All obvious stuff, i.e. casts etc. We're down to about 520 warnings or
>> 1/2 way through these. (Not including Ada or other targets yet.)
>>
>> Bootstrapped on x86_64-unknown-linux-gnu, no regressions.
>
> I don't like this sprinkling casts all over the place. Since we
> didn't agree to that being the
> right or wrong way to go I alos think these patches are not obvious.
Most of them are casts away from void*. We did agree a while back
that gcc would be coded in the C/C++ subset. That means that you
can't assign from a void* pointer to a pointer of a different type
without a cast. So either we add casts or we do something else. But
what?
Ian