I'm running Xcode in OS X 10.6 on a Core 2 Duo. Here's a short program:
#include <stdio.h>
int main () {
long a = 8589934592L;
printf("a = %li\n", a);
return 0;
}
When I compile this from the command line (gcc -pedantic) I get no errors or warning. When I compile this in Xcode in debug configuration, I get no errors or warnings. When I compile this in Xcode in release configuration, I get a warning: "Overflow in implicit constant conversion".
Longs should be 64-bit. And the program runs fine. So what's going on, and how do I get rid of this warning?