|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r51446 - sandbox/threadpool/boost/tp
From: oliver.kowalke_at_[hidden]
Date: 2009-02-25 15:45:54
Author: olli
Date: 2009-02-25 15:45:53 EST (Wed, 25 Feb 2009)
New Revision: 51446
URL: http://svn.boost.org/trac/boost/changeset/51446
Log:
* wait_for_any() added
* pool::wait_callback_() may not call
shutdown_( worker &) because it wouldblock the app forever
Text files modified:
sandbox/threadpool/boost/tp/pool.hpp | 2
sandbox/threadpool/boost/tp/task.hpp | 66 ++++++++++++++++++++--------------------
2 files changed, 34 insertions(+), 34 deletions(-)
Modified: sandbox/threadpool/boost/tp/pool.hpp
==============================================================================
--- sandbox/threadpool/boost/tp/pool.hpp (original)
+++ sandbox/threadpool/boost/tp/pool.hpp 2009-02-25 15:45:53 EST (Wed, 25 Feb 2009)
@@ -356,7 +356,7 @@
BOOST_ASSERT( thrd);
detail::interrupter intr;
detail::callable ca;
- while ( ! shutdown_( * w) && ! f.is_ready() )
+ while ( ! f.is_ready() )
{
next_callable_( * w, ca, intr);
if( ! ca.empty() )
Modified: sandbox/threadpool/boost/tp/task.hpp
==============================================================================
--- sandbox/threadpool/boost/tp/task.hpp (original)
+++ sandbox/threadpool/boost/tp/task.hpp 2009-02-25 15:45:53 EST (Wed, 25 Feb 2009)
@@ -262,39 +262,39 @@
void wait_for_all( T1 & t1, T2 & t2, T3 & t3, T4 & t4, T5 & t5)
{ jss::wait_for_all( t1.fut_, t2.fut_, t3.fut_, t4.fut_, t5.fut_); };
-// template<
-// typename T1,
-// typename T2
-// >
-// void wait_for_any( T1 & t1, T2 & t2)
-// { jss::wait_for_any( t1.fut_, t2.fut_); };
-//
-// template<
-// typename T1,
-// typename T2,
-// typename T3
-// >
-// void wait_for_any( T1 & t1, T2 & t2, T3 & t3)
-// { jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_); };
-//
-// template<
-// typename T1,
-// typename T2,
-// typename T3,
-// typename T4
-// >
-// void wait_for_any( T1 & t1, T2 & t2, T3 & t3, T4 & t4)
-// { jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_, t4.fut_); };
-//
-// template<
-// typename T1,
-// typename T2,
-// typename T3,
-// typename T4,
-// typename T5
-// >
-// void wait_for_any( T1 & t1, T2 & t2, T3 & t3, T4 & t4, T5 & t5)
-// { jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_, t4.fut_, t5.fut_); };
+template<
+ typename T1,
+ typename T2
+>
+void wait_for_any( T1 & t1, T2 & t2)
+{ jss::wait_for_any( t1.fut_, t2.fut_); };
+
+template<
+ typename T1,
+ typename T2,
+ typename T3
+>
+void wait_for_any( T1 & t1, T2 & t2, T3 & t3)
+{ jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_); };
+
+template<
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4
+>
+void wait_for_any( T1 & t1, T2 & t2, T3 & t3, T4 & t4)
+{ jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_, t4.fut_); };
+
+template<
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5
+>
+void wait_for_any( T1 & t1, T2 & t2, T3 & t3, T4 & t4, T5 & t5)
+{ jss::wait_for_any( t1.fut_, t2.fut_, t3.fut_, t4.fut_, t5.fut_); };
} }
#endif // BOOST_TP_TASK_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