g++ unsigned warning

Richard Henderson rth@redhat.com
Fri Nov 16 19:32:00 GMT 2001


On Sun, Nov 25, 2001 at 10:50:46PM -0800, Benjamin Kosnik wrote:
>   unsigned long ul1 = 4294967294;
[...]
> ?? What's the deal? It already is unsigned.

No, ul1 is already unsigned, not the number.  Try

 unsigned long ul1 = 4294967294ul;


r~



More information about the Gcc-bugs mailing list