This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: arm.[ch] tidy ups.
- To: nickc at cygnus dot com, rearnsha at arm dot com
- Subject: Re: arm.[ch] tidy ups.
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Date: Tue, 11 Apr 2000 10:41:18 -0400 (EDT)
- Cc: gcc-patches at gcc dot gnu dot org
> From: Richard Earnshaw <rearnsha@arm.com>
>
> nickc@cygnus.com said:
> > I am going to check in the patch below which fixes a few compile
> > time warnings and errors when building gcc for arm-pe.
> >
> > One possibly interesting thing is that I have created two new macros
> > HOST_INT and HOST_UINT which can be used to specify host sized
> > integers. This not only saves space in the sources but also allows
> > us to eliminate the compile time warning about the behaviour of
> > unsuffixed integer constants under K&R compilers.
>
> I'm not convinced this is the right way to fix this problem, unless we are
> going to do it across the whole of the compiler. Surely this isn't a
> problem that affects only the ARM backend?
>
> I really don't like the fact that gcc -Wtraditional gives a warning for
>
> unsigned long x = (unsigned long) 0xffffffff;
>
> How else is one supposed to write this in a way that is acceptable to both
> K&R and ANSI compilers? How else could it be interpreted?
>
> If we are going to leave -Wtraditional on, I think this is a general
> problem that should be fixed in a common way across the whole compiler
> source tree.
> R.
Already done. The current CVS does not issue this warning unless the
base of the constant is 10. For a hex number like the above, it does
not warn.
I don't know why Nick is seeing these unless he is doing just "make"
with an older gcc, instead of "make bootstrap" and examining stage3
warnings using contrib/warn_summary.
--Kaveh
--
Kaveh R. Ghazi Engagement Manager / Project Services
ghazi@caip.rutgers.edu Qwest Internet Solutions