Proper way to handle issue when porting 32 to 64 bit. Conversion from DT1 to DT2 of greater size
Posted
by grobartn
on Stack Overflow
See other posts from Stack Overflow
or by grobartn
Published on 2010-06-02T19:06:29Z
Indexed on
2010/06/02
19:14 UTC
Read the original article
Hit count: 182
So I am trying to port 32 bit to 64 bit.
I have turned on the VS2008 flag for detecting problems with 64 bit.
I am trying following:
char * pList = (char *)uiTmp);
warning C4312: 'type cast' : conversion from 'unsigned int' to 'char *' of greater size
Disregard the code itself. This is also true for any pointer, because 64 bit pointer is greater than 32 bit unsigned int or int for that purpose.
Given that you have to cast smaller type to greater how would you go about doing it so it correctly on both 32/64 bit systems
© Stack Overflow or respective owner