There's such thing as __w64 in Visual C++ 9. I came across it while trying to port my native C++ DLL to 64 bit. In particular in crtdefs.h
there's this nice snippet:
#if !defined(_W64)
#if !defined(__midl) && (defined(_X86_) || defined (_M_IX86)) && _MSC_VER >= 1300
#define _W64 __w64
#else
#define _W64
#endif
#endif
which if I get it right implies that for 64 bit _W64 is defined as an empty string and has no effect, but for 32 bit it is defined as __w64
.
I tried defining _W64 to be an empty string and __w64
in turn and at least both time the project compiles fine in 64-bit configuration.
That said both _W64
and __w64
look useless. How am I intended to use them and how should I define _W64
in 64-bit projects?