On Tue, Mar 30, 2010 at 09:11:07PM +0100, Charles Forsyth wrote:
> on 64-bit machines, int and long are 32 bits,
> long long (vlong) is 64 bits, just as on 32-bit machines,
> but pointers are 64 bits. <u.h> defines uintptr
> as the integer type that will hold a pointer.
> u8int, u16int, u32int and u64int are used in device drivers
> and elsewhere to declare values (eg, in memory-mapped
> structures or protocol buffers) that must be a precise length.
Thanks. As suggested by many, I will read u.h.
Since I wanted to keep the code pure C89, going with "long" will do
without trying to be smarter. Second option, goes POSIX/APE and use
uint32_t/u32int incarnations. I think I will go the former.
--
Thierry Laronde (Alceste) <tlaronde +AT+ polynum +dot+ com>
http://www.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C