mirror of
https://github.com/boostorg/python.git
synced 2026-01-25 06:22:15 +00:00
fix metafunctions for MPL
[SVN r17621]
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
# endif
|
||||
|
||||
# include <boost/config.hpp>
|
||||
# include <boost/mpl/bool_c.hpp>
|
||||
|
||||
namespace boost { namespace python {
|
||||
|
||||
@@ -39,16 +40,14 @@ inline pointer_wrapper<T> ptr(T t)
|
||||
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
||||
template<typename T>
|
||||
class is_pointer_wrapper
|
||||
: public mpl::false_c
|
||||
{
|
||||
public:
|
||||
BOOST_STATIC_CONSTANT(bool, value = false);
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
class is_pointer_wrapper<pointer_wrapper<T> >
|
||||
: public mpl::true_c
|
||||
{
|
||||
public:
|
||||
BOOST_STATIC_CONSTANT(bool, value = true);
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
@@ -109,8 +108,9 @@ class is_pointer_wrapper
|
||||
public:
|
||||
BOOST_STATIC_CONSTANT(
|
||||
bool, value = (
|
||||
sizeof(detail::is_pointer_wrapper_test(boost::type<T>()))
|
||||
sizeof(detail::is_pointer_wrapper_test(boost::type<T>()))
|
||||
== sizeof(detail::yes_pointer_wrapper_t)));
|
||||
typedef mpl::bool_c<value> type;
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
|
||||
Reference in New Issue
Block a user