What was with the historical typedef soup for integers in C programs?

When C began computers were less homogenous and a lot less connected than today. It was seen as more important for portability that the int types be the natural size(s) for the computer. Asking for an exactly 32-bit integer type on a 36-bit system is probably going to result in inefficient code.

And then along came pervasive networking where you are working with specific on-the-wire size fields. Now interoperability looks a whole lot different. And the ‘octet’ becomes the de facto quanta of data types.

Now you need ints of exact multiples of 8-bits, so now you get typedef soup and then eventually the standard catches up and we have standard names for them and the soup is not as needed.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)