mirror of
https://github.com/boostorg/typeof.git
synced 2025-07-29 20:37:28 +02:00
Disable enable_if on compilers that does not support it.
[SVN r34999]
This commit is contained in:
@ -22,7 +22,10 @@ namespace boost { namespace type_of {
|
||||
#include <boost/utility/enable_if.hpp>
|
||||
|
||||
namespace boost { namespace type_of {
|
||||
|
||||
# ifdef BOOST_NO_SFINAE
|
||||
template<class V, class T>
|
||||
sizer<typename encode_type<V, T>::type> encode(const T&);
|
||||
# else
|
||||
template<typename T>
|
||||
typename enable_if<is_function<T>, T&>::type
|
||||
ensure_obj(T&);
|
||||
@ -30,7 +33,7 @@ namespace boost { namespace type_of {
|
||||
template<typename T>
|
||||
typename disable_if<is_function<T>, T&>::type
|
||||
ensure_obj(const T&);
|
||||
|
||||
# endif
|
||||
}}
|
||||
|
||||
#endif//BOOST_NO_SFINAE
|
||||
|
@ -34,7 +34,10 @@ namespace boost { namespace type_of {
|
||||
|
||||
//
|
||||
namespace boost { namespace type_of {
|
||||
|
||||
# ifdef BOOST_NO_SFINAE
|
||||
template<class V, class T>
|
||||
sizer<typename encode_type<V, T>::type> encode(const T&);
|
||||
# else
|
||||
template<class V, class T>
|
||||
typename enable_if<
|
||||
typename is_function<T>::type,
|
||||
@ -44,7 +47,7 @@ namespace boost { namespace type_of {
|
||||
typename disable_if<
|
||||
typename is_function<T>::type,
|
||||
sizer<typename encode_type<V, T>::type> >::type encode(const T&);
|
||||
|
||||
# endif
|
||||
}}
|
||||
//
|
||||
namespace boost { namespace type_of {
|
||||
|
Reference in New Issue
Block a user