From: Václav Slavík Date: Wed, 30 Jan 2008 08:49:42 +0000 (+0000) Subject: do the VC6 hacks only when compiling with VC6 X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/04e5392a8dbcdb3a65b3bb9732c82f9e9a2c1a5b?ds=inline do the VC6 hacks only when compiling with VC6 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@51454 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/meta/if.h b/include/wx/meta/if.h index 450ef24bf1..3de045a61f 100644 --- a/include/wx/meta/if.h +++ b/include/wx/meta/if.h @@ -53,7 +53,11 @@ struct wxIfImpl { template struct Result { +#if defined(__VISUALC__) && !wxCHECK_VISUALC_VERSION(7) struct value : TTrue { }; +#else + typedef TTrue value; +#endif }; }; @@ -63,7 +67,11 @@ struct wxIfImpl { template struct Result { +#if defined(__VISUALC__) && !wxCHECK_VISUALC_VERSION(7) struct value : TFalse { }; +#else + typedef TFalse value; +#endif }; }; @@ -77,9 +85,15 @@ struct wxIfImpl template struct wxIf { +#if defined(__VISUALC__) && !wxCHECK_VISUALC_VERSION(7) // notice that value can't be a typedef, VC6 refuses to use it as a base // class in this case struct value : wxPrivate::wxIfImpl::Result::value { }; +#else // !VC6++ + typedef typename wxPrivate::wxIfImpl + ::template Result::value + value; +#endif }; #endif // _WX_META_IF_H_