Re: ppc_8xx-gcc from eldk strange behaviour
From: Scott Wood <hidden>
Date: 2007-08-28 19:02:06
From: Scott Wood <hidden>
Date: 2007-08-28 19:02:06
On Tue, Aug 28, 2007 at 08:56:10PM +0200, DI BACCO ANTONIO - technolabs wrote:
If I compile it with host gcc, there is no warning and the message "x is negative" is printed. If I compile it with ppc_8xx-gcc there is a warning "main.c:11: warning: comparison is always false due to limited range of data type" and the program prints message "x is positive". To correct the problem I have to put signed before char.
C does not specify the signedness of char. If you care, you need to explicitly specify. -Scott