M
Manda Rajo
Guest
When I want to use an integer with exact size 32 bits, I don't know what to use, 'UINT' or 'ULONG'? People says that the size of 'int' depends on the compiler, but I will always use Visual Studio forever instead of using GCC otherwise my program won't work.
Here is a quote from this Is the size of C "int" 2 bytes or 4 bytes?
>> Fixed wrong statement that int is 8 bytes on most 64-bit systems. For example, it is 4 bytes on 64-bit GCC.
>> For instance long in Win64 is 4 bytes whereas long in Linux64 is 8 bytes.
I'm afraid that in the future, the size of 'int' will becomes 8 bytes, then my program will crash if it suddenly change like that.
So, my question is: "Is the size of 'int' will always be 4 bytes FOREVER?".
I'm wondering, why Microsoft give up 'long' in HLSL? I mean, 'long' is no longer suppored by HLSL? Does Microsoft plan to use 'int' as 4 bytes forever and give up 'long'?
Continue reading...
Here is a quote from this Is the size of C "int" 2 bytes or 4 bytes?
>> Fixed wrong statement that int is 8 bytes on most 64-bit systems. For example, it is 4 bytes on 64-bit GCC.
>> For instance long in Win64 is 4 bytes whereas long in Linux64 is 8 bytes.
I'm afraid that in the future, the size of 'int' will becomes 8 bytes, then my program will crash if it suddenly change like that.
So, my question is: "Is the size of 'int' will always be 4 bytes FOREVER?".
I'm wondering, why Microsoft give up 'long' in HLSL? I mean, 'long' is no longer suppored by HLSL? Does Microsoft plan to use 'int' as 4 bytes forever and give up 'long'?
Continue reading...