You start a 32-bit UINT with a 64-bit pointer. This is suicide - you are trying to point to something, but forgot half of this place! You absolutely SHOULD take UINT_PTR. When you point to an int pointer, the behavior will only be OK if the int is the same size as the pointer. This is also the end of your access violation application environment.
Edit:
Why does the compiler consider it a bad idea to distinguish a larger font?
RE above
What is the best way to get rid of a warning? (I do not want to turn it off.)
Solve the problem of. This code will almost certainly be instacrash.
Doing a double type like this: (HMENU) (UINT_PTR) id gets rid of the warning. Why / how?
This is because the excellent match UINT UINT_PTR - UINT_PTR is just an integral type, there is no data loss.
Disabling "Detect 64-bit portability problems" (Wp64) also resolves the warning. Why is wp64 outdated? Should I use it?
It is out of date, because in fact I canβt remember why. I think this is warning too easy. But for the main "Don't throw integer types and pointers", you should definitely leave it.
Puppy
source share