|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r86140 - trunk/boost/thread
From: vicente.botet_at_[hidden]
Date: 2013-10-02 18:45:24
Author: viboes
Date: 2013-10-02 18:45:23 EDT (Wed, 02 Oct 2013)
New Revision: 86140
URL: http://svn.boost.org/trac/boost/changeset/86140
Log:
Thread: use boost::disable_if instead of disable_if to avoid ambiguity.
Text files modified:
trunk/boost/thread/future.hpp | 28 +++++++++++-----------------
1 files changed, 11 insertions(+), 17 deletions(-)
Modified: trunk/boost/thread/future.hpp
==============================================================================
--- trunk/boost/thread/future.hpp Wed Oct 2 17:22:03 2013 (r86139)
+++ trunk/boost/thread/future.hpp 2013-10-02 18:45:23 EDT (Wed, 02 Oct 2013) (r86140)
@@ -1553,7 +1553,7 @@
}
template <typename R2>
- typename disable_if< is_void<R2>, move_dest_type>::type
+ typename boost::disable_if< is_void<R2>, move_dest_type>::type
get_or(BOOST_THREAD_RV_REF(R2) v)
{
if(!this->future_)
@@ -1574,7 +1574,7 @@
}
template <typename R2>
- typename disable_if< is_void<R2>, move_dest_type>::type
+ typename boost::disable_if< is_void<R2>, move_dest_type>::type
get_or(R2 const& v) // EXTENSION
{
if(!this->future_)
@@ -1614,17 +1614,17 @@
then(launch policy, BOOST_THREAD_FWD_REF(F) func); // EXTENSION
template <typename R2>
- inline typename disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
+ inline typename boost::disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
fallback_to(BOOST_THREAD_RV_REF(R2) v); // EXTENSION
template <typename R2>
- inline typename disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
+ inline typename boost::disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
fallback_to(R2 const& v); // EXTENSION
#endif
//#if defined BOOST_THREAD_PROVIDES_FUTURE_UNWRAP
// inline
-// typename enable_if<
+// typename boost::enable_if<
// is_future_type<value_type>,
// value_type
// //BOOST_THREAD_FUTURE<typename is_future_type<value_type>::type>
@@ -1895,7 +1895,7 @@
}
template <typename R2>
- typename disable_if< is_void<R2>, typename detail::shared_state<R>::shared_future_get_result_type>::type
+ typename boost::disable_if< is_void<R2>, typename detail::shared_state<R>::shared_future_get_result_type>::type
get_or(BOOST_THREAD_RV_REF(R2) v) // EXTENSION
{
if(!this->future_)
@@ -1930,7 +1930,7 @@
#endif
//#if defined BOOST_THREAD_PROVIDES_FUTURE_UNWRAP
// inline
-// typename enable_if_c<
+// typename boost::enable_if_c<
// is_future_type<value_type>::value,
// BOOST_THREAD_FUTURE<typename is_future_type<value_type>::type>
// >::type
@@ -3102,7 +3102,7 @@
#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
template <class F>
explicit packaged_task(BOOST_THREAD_FWD_REF(F) f
- , typename disable_if<is_same<typename decay<F>::type, packaged_task>, dummy* >::type=0
+ , typename boost::disable_if<is_same<typename decay<F>::type, packaged_task>, dummy* >::type=0
)
{
typedef typename remove_cv<typename remove_reference<F>::type>::type FR;
@@ -3123,7 +3123,7 @@
#else
template <class F>
explicit packaged_task(F const& f
- , typename disable_if<is_same<typename decay<F>::type, packaged_task>, dummy* >::type=0
+ , typename boost::disable_if<is_same<typename decay<F>::type, packaged_task>, dummy* >::type=0
)
{
#if defined BOOST_THREAD_PROVIDES_SIGNATURE_PACKAGED_TASK
@@ -3957,7 +3957,6 @@
}
else
{
- //BOOST_THREAD_ASSERT_PRECONDITION(false && "invalid launch parameter", std::logic_error("invalid launch parameter"));
return BOOST_THREAD_MAKE_RV_REF((boost::detail::make_future_async_continuation_shared_state<BOOST_THREAD_FUTURE<R>, future_type, F>(
lock, boost::move(*this), boost::forward<F>(func)
)));
@@ -3990,7 +3989,6 @@
}
else
{
- //BOOST_THREAD_ASSERT_PRECONDITION(false && "invalid launch parameter", std::logic_error("invalid launch parameter"));
return boost::detail::make_future_async_continuation_shared_state<BOOST_THREAD_FUTURE<R>, future_type, F>(
lock, boost::move(*this), boost::forward<F>(func)
);
@@ -4075,7 +4073,6 @@
}
else
{
- //BOOST_THREAD_ASSERT_PRECONDITION(false && "invalid launch parameter", std::logic_error("invalid launch parameter"));
return BOOST_THREAD_MAKE_RV_REF((boost::detail::make_future_async_continuation_shared_state<shared_future<R>, future_type, F>(
lock, boost::move(*this), boost::forward<F>(func)
)));
@@ -4108,7 +4105,6 @@
}
else
{
- //BOOST_THREAD_ASSERT_PRECONDITION(false && "invalid launch parameter", std::logic_error("invalid launch parameter"));
return boost::detail::make_future_async_continuation_shared_state<shared_future<R>, future_type, F>(
lock, boost::move(*this), boost::forward<F>(func)
);
@@ -4153,7 +4149,7 @@
template <typename R>
template <typename R2>
- inline typename disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
+ inline typename boost::disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
BOOST_THREAD_FUTURE<R>::fallback_to(BOOST_THREAD_RV_REF(R2) v)
{
return then(detail::mfallbacker_to<R>(boost::move(v)));
@@ -4161,7 +4157,7 @@
template <typename R>
template <typename R2>
- inline typename disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
+ inline typename boost::disable_if< is_void<R2>, BOOST_THREAD_FUTURE<R> >::type
BOOST_THREAD_FUTURE<R>::fallback_to(R2 const& v)
{
return then(detail::cfallbacker_to<R>(v));
@@ -4206,8 +4202,6 @@
make_future_unwrap_shared_state(boost::unique_lock<boost::mutex> &lock, BOOST_THREAD_RV_REF(F) f)
{
shared_ptr<future_unwrap_shared_state<F, Rp> >
- //shared_ptr<basic_future<Rp> >
- //typename boost::detail::basic_future<Rp>::future_ptr
h(new future_unwrap_shared_state<F, Rp>(boost::move(f)));
h->parent.future_->set_continuation_ptr(h, lock);
return BOOST_THREAD_FUTURE<Rp>(h);
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk