[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[MiNT] gcc -mshort question



Hi Jonathan!

OJ>Just yesterday I noticed that my gcc seems to be doing strange things
OJ>when -mshort is enabled. It reports sizeof(short)=0, long=2, int=0,
OJ>and char=4. Without -mshort shorts are 2, longs and ints 4, and chars
OJ>1, just as it should be.
Do not use %d, %u or %x  in the format string for printf(), use %ld, %lu or
%lx instead (the values returned by sizeof are 4 Bytes long)

Bye

                Joerg