variant-lite
variant-lite copied to clipboard
Compile failed on msvc v90
No std::add_pointer, std::is_same and std::enable_if but have std::tr1::add_pointer and std::tr1::is_same. I modify macro and compile successfully:
#define variant_HAVE_CONDITIONAL variant_CPP11_120
#define variant_HAVE_REMOVE_CV variant_CPP11_120
#define variant_HAVE_STD_ADD_POINTER variant_CPP11_100 // <--
#define variant_HAVE_TYPE_TRAITS variant_CPP11_90
#define variant_HAVE_ENABLE_IF variant_CPP11_100 // <--
#define variant_HAVE_IS_SAME variant_CPP11_100 // <--
#define variant_HAVE_TR1_TYPE_TRAITS (!! variant_COMPILER_GNUC_VERSION )
#define variant_HAVE_TR1_ADD_POINTER (!! variant_COMPILER_GNUC_VERSION || variant_CPP11_90 ) // <--
But I'm not sure my std headers is correct.
Thanks @Elite-stay, looks like it now works with MSVC 9.