Trevis Rothwell skrev:
Given the following program: int main() { unsigned int squiggy = 2147483648; } Compliing on GCC 3.2.3, I get the following warning: $ gcc foo.c foo.c: In function `main': foo.c:3: warning: decimal constant is so large that it is unsigned To the best of my knowledge, 2147483648 should fit with ample room to spare in an unsigned (4-byte) integer. What's going on?
With gcc 4.1.1, I get this: $ gcc foo.c foo.c: In function 'main': foo.c:3: warning: this decimal constant is unsigned only in ISO C90