WinNT.h contains the following lines in the VS2008 SP1 installation:
#define BitTest _bittest #define BitTestAndComplement _bittestandcomplement #define BitTestAndSet _bittestandset #define BitTestAndReset _bittestandreset #define InterlockedBitTestAndSet _interlockedbittestandset #define InterlockedBitTestAndReset _interlockedbittestandreset
I have several BitTest based templates <> ()
Does anyone know an easy way to disable these #defines?
Often, MS does provide the #define XXX character, which, if defined, will disable some of the violation of their header - for example, NOMINMAX.
I could not find such a solution to the above problem.
If you share Microsoftβs frustration with many dubious choices, read on. If not, stay here.;)
Editorializing:
- Why can't Microsoft use _bittest itself ???
- Or why they cannot use BITTEST, as everyone knows you should - always use all caps for macros!
- Microsoft is still #defining things in 2010 ?! WTF?
source share