K
Keith Thompson
I thougth that using int8_t would be more portable. Anyway, in my code
I also use int8_t, int16_t, int32_t (and their unsigned versions)
instead of using int, short, long ... Should I use the intx_t or the
int, short, etc? My main aim is portability among platforms.
Use whatever type is appropriate to your task. If you need an 8-bit
2's-complement type with no padding bits, use int8_t (assuming you
have a C99 implementation) -- but chances are you don't really need
all those properties.
If you need a signed type that's at least 16 bits, use int_least16_t.
Or use int.
And if you need to represent characters, use char; that's what it's
for.