You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/dev-libs/boost/files/boost-1.45.0-lambda_bind.patch

43 lines
1.6 KiB

Index: trunk/boost/lambda/detail/function_adaptors.hpp
===================================================================
--- a/trunk/boost/lambda/detail/function_adaptors.hpp
+++ b/trunk/boost/lambda/detail/function_adaptors.hpp
@@ -17,4 +17,7 @@
#include "boost/type_traits/same_traits.hpp"
#include "boost/type_traits/remove_reference.hpp"
+#include "boost/type_traits/remove_cv.hpp"
+#include "boost/type_traits/add_const.hpp"
+#include "boost/type_traits/add_volatile.hpp"
#include "boost/utility/result_of.hpp"
@@ -238,12 +241,14 @@
template<class Args> class sig {
typedef typename boost::tuples::element<1, Args>::type argument_type;
-
- typedef typename detail::IF<boost::is_const<argument_type>::value,
+ typedef typename boost::remove_reference<
+ argument_type
+ >::type unref_type;
+
+ typedef typename detail::IF<boost::is_const<unref_type>::value,
typename boost::add_const<T>::type,
T
>::RET properly_consted_return_type;
- typedef typename detail::IF<
- boost::is_volatile<properly_consted_return_type>::value,
+ typedef typename detail::IF<boost::is_volatile<unref_type>::value,
typename boost::add_volatile<properly_consted_return_type>::type,
properly_consted_return_type
@@ -252,6 +257,8 @@
public:
- typedef typename
- boost::add_reference<properly_cvd_return_type>::type type;
+ typedef typename detail::IF<boost::is_reference<argument_type>::value,
+ typename boost::add_reference<properly_cvd_return_type>::type,
+ typename boost::remove_cv<T>::type
+ >::RET type;
};