Closed DjArt closed 5 years ago
Please, could you add the report you are getting?
@viboes, sorry for the long wait. Error C2440: int can't be converted to void*.
Don't worry.
If the function doesn't returns a void
, but an int
, why do we want to store it on a void *
?
void*
used as platform-unspecified(by size) pointer. So, I think that's better variant for saving original idea of code.
Oh, I see.
So IIUC, iso_volatile_load64 returned always a int64 and iso_volatile_load32 returned always int32.
And this size corresponds to the size of a pointer depending on whether _M_ARM64 is defined or not.
How it is that this worked before, Andrei, what do you think?
I think, or this code was untested before, or MSVC for ARM has become more strict then before. x86/x86_64 compiler doesn't consider it as mistake.
I believe the code needs a static assert about the size of both types. Could you add it, please?
Due assign in interlocked_read.hpp: