Integers: Sign extension | |||||||||||
We may need to change the number of bits used to represent a number. | |||||||||||
For example, C has int, short int, and long int to represent integers. | |||||||||||
The language doesn't specify the exact size of each form, but | |||||||||||
sizeof (short int) <= sizeof (int) <= sizeof (long int) | |||||||||||
How do we cast from one kind of int to a larger number of bits? | |||||||||||