2 ms·
Rust portability is to have types like i16, i32 and i64, which is a trick that C programmers have used for decades to dodge real portability. The first machine
by kazinator 2y ago
Rust portability is to have types like i16, i32 and i64, which is a trick that C programmers have used for decades to dodge real portability.
The first machine that see right on didn't even have 16 bit types. The int type was 18 bits.
Modern C does not guarantee that the inttypes.h header will make available int16_t or any of the other exact width types.
Real portability means not knowing exactly how wide the types is yet making your code work anyway.
- kazinator 2y agos/see right on/C ran on/