Work-around for bug in ancient SPARC Sun C compiler

Alan Modra amodra@bigpond.net.au
Mon Feb 11 05:13:00 GMT 2002
On Mon, Feb 11, 2002 at 04:47:30AM -0200, Alexandre Oliva wrote:

> +/* Some ancient Sun C compilers would not take such hex constants as
> +   unsigned, and would end up sign-extending them to form an offsetT,
> +   so use these constants instead.  */
> +#define U0xffffffffl ((((unsigned long)1 << 16) << 16) - 1)
> +#define U0x80000000l ((((unsigned long)1 << 16) << 15))

I think the defines would look better without the trailing 'l', and
you need a space after the cast to meet GNU coding guidelines.
Otherwise OK.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre



More information about the Binutils mailing list