P
Peter Pichler
pete said:Eric Sosman is right.
N869 or C99
6.4.4.1 Integer constants
ISO/IEC 9899: 1990
6.1.3.2 Integer constants
The type of an integer constant is the first of the
corresponding list in which its value can be represented.
Unsuffixed decimal:
int, long int, unsigned long int;
unsuffixed octal or hexadecimal:
int, unsigned int, long int, unsigned long int;
Damn, you are right! I don't know where I got it from. Must have been an
extrapolation from either char escape sequences -
"The value of an octal or hexadecimal escape sequence shall be in the
range of representable values for the type unsigned char for an integer
character constant, or the unsigned type corresponding to wchar_t for a
wide character constant."
- or printf conversion specifiers -
"o,u,x,X The unsigned int argument is converted to unsigned octal (o),
unsigned decimal (u), or unsigned hexadecimal notation (x or X) in the
style dddd; the letters abcdef are used for x conversion and the letters
ABCDEF for X conversion. The precision specifies the minimum number of
digits to appear; if the value being converted can be represented in
fewer digits, it is expanded with leading zeros. The default precision
is 1. The result of converting a zero value with a precision of zero is
no characters."
My humble apologies,
Peter