]> git.lyx.org Git - lyx.git/blobdiff - boost/boost/detail/indirect_traits.hpp
Don't allow newline characters in document settings.
[lyx.git] / boost / boost / detail / indirect_traits.hpp
old mode 100755 (executable)
new mode 100644 (file)
index 57f5af6..f9c0cd6
@@ -11,6 +11,7 @@
 # include <boost/type_traits/is_const.hpp>
 # include <boost/type_traits/is_volatile.hpp>
 # include <boost/type_traits/is_member_function_pointer.hpp>
+# include <boost/type_traits/is_member_pointer.hpp>
 # include <boost/type_traits/remove_cv.hpp>
 # include <boost/type_traits/remove_reference.hpp>
 # include <boost/type_traits/remove_pointer.hpp>
@@ -18,6 +19,7 @@
 # include <boost/type_traits/detail/ice_and.hpp>
 # include <boost/detail/workaround.hpp>
 
+# include <boost/mpl/eval_if.hpp>
 # include <boost/mpl/if.hpp>
 # include <boost/mpl/bool.hpp>
 # include <boost/mpl/and.hpp>
@@ -251,6 +253,7 @@ struct is_reference_to_function_aux
     static T t;
     BOOST_STATIC_CONSTANT(
         bool, value = sizeof(detail::is_function_ref_tester(t,0)) == sizeof(::boost::type_traits::yes_type));
+    typedef mpl::bool_<value> type;
  };
 
 template <class T>
@@ -330,6 +333,8 @@ struct is_reference_to_non_const_helper1
         BOOST_STATIC_CONSTANT(
             bool, value
             = sizeof(reference_to_const_helper(t)) == sizeof(inner_no_type));
+        
+        typedef mpl::bool_<value> type;
     };
 };
 
@@ -343,6 +348,7 @@ template <class T>
 struct is_reference_to_non_const
     : is_reference_to_non_const_helper1<is_reference<T>::value>::template apply<T>
 {
+    BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_non_const,(T))
 };
 
 
@@ -361,6 +367,7 @@ struct is_reference_to_volatile_helper1
         BOOST_STATIC_CONSTANT(
             bool, value
             = sizeof(reference_to_volatile_helper(t)) == sizeof(inner_yes_type));
+        typedef mpl::bool_<value> type;
     };
 };
 
@@ -381,23 +388,27 @@ typename is_pointer_help<V>::type reference_to_pointer_helper(V&);
 outer_no_type reference_to_pointer_helper(...);
 
 template <class T>
-struct is_reference_to_pointer
+struct reference_to_pointer_impl
 {
     static T t;
     BOOST_STATIC_CONSTANT(
         bool, value
-        = (is_reference<T>::value
-           && sizeof((reference_to_pointer_helper)(t)) == sizeof(inner_yes_type))
+        = (sizeof((reference_to_pointer_helper)(t)) == sizeof(inner_yes_type))
         );
+    
+    typedef mpl::bool_<value> type;
+};
+    
+template <class T>
+struct is_reference_to_pointer
+  : mpl::eval_if<is_reference<T>, reference_to_pointer_impl<T>, mpl::false_>::type
+{   
+    BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_pointer,(T))
 };
 
 template <class T>
 struct is_reference_to_function_pointer
-    : mpl::if_<
-        is_reference<T>
-        , is_pointer_to_function_aux<T>
-        , mpl::bool_<false>
-     >::type
+  : mpl::eval_if<is_reference<T>, is_pointer_to_function_aux<T>, mpl::false_>::type
 {
     BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_function_pointer,(T))
 };
@@ -463,6 +474,7 @@ struct is_pointer_to_class
         = (is_pointer<T>::value
            && sizeof(pointer_to_class_helper(t)) == sizeof(inner_yes_type))
         );
+    typedef mpl::bool_<value> type;
 };
 #  endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION