Well, I only use double and int though, but I suppose it means the double. Is the actual number too long for double (don't remember ranges)?
Well, I only use double and int though, but I suppose it means the double. Is the actual number too long for double (don't remember ranges)?
It is with 32-bit longs, as in 32-bit systems. According to the rules of the standard, the compiler has to see if it fits into a int, and if not, try a long. If that also doesn't fit, the behaviour is, I believe, undefined. Or perhaps implementation-defined. The point is, since some platforms GCC compiles for have larger longs than ints, it really tries them in order - and when it fails, it reports that the literal won't fit into a long, since that's the last thing it tried.
I'm still confused as to why your GCC doesn't give any warnings.
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law