struct something
{
char number1;
unsigned short number2;
};
sizeof(something) = 4
why is this true? I mean a char is one byte and an unsigned short is a word, that is 2 bytes.. therefore the size should be 3 bytes.. but in Visual c++ 6 it is 4..
With your permission, GameDev.net uses analytics cookies to understand how people use the platform.
You can accept analytics or continue with necessary cookies only.
Learn more