Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r84198 - in branches/release: boost/thread boost/thread/detail libs/thread libs/thread/doc libs/thread/example libs/thread/test
From: vicente.botet_at_[hidden]
Date: 2013-05-09 00:49:20


Author: viboes
Date: 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
New Revision: 84198
URL: http://svn.boost.org/trac/boost/changeset/84198

Log:
Thread: merge last externally°locked evolution + async_funct.
Added:
   branches/release/libs/thread/test/test_8508.cpp
      - copied unchanged from r84190, /trunk/libs/thread/test/test_8508.cpp
Properties modified:
   branches/release/boost/thread/ (props changed)
   branches/release/libs/thread/ (props changed)
Text files modified:
   branches/release/boost/thread/detail/async_func.hpp | 943 +++++++++++++++++++--------------------
   branches/release/boost/thread/detail/config.hpp | 7
   branches/release/boost/thread/externally_locked.hpp | 3
   branches/release/boost/thread/externally_locked_stream.hpp | 31
   branches/release/boost/thread/strict_lock.hpp | 23
   branches/release/libs/thread/doc/compliance.qbk | 159 ++++++
   branches/release/libs/thread/doc/sync_queues_ref.qbk | 4
   branches/release/libs/thread/doc/sync_streams.qbk | 89 +++
   branches/release/libs/thread/example/not_interleaved.cpp | 4
   branches/release/libs/thread/example/tennis.cpp | 4
   10 files changed, 736 insertions(+), 531 deletions(-)

Modified: branches/release/boost/thread/detail/async_func.hpp
==============================================================================
--- branches/release/boost/thread/detail/async_func.hpp (original)
+++ branches/release/boost/thread/detail/async_func.hpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -30,7 +30,6 @@
 #include <boost/thread/detail/invoke.hpp>
 #include <boost/thread/detail/make_tuple_indices.hpp>
 
-
 #if ! defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && \
     ! defined(BOOST_NO_CXX11_HDR_TUPLE)
 #include <tuple>
@@ -46,537 +45,525 @@
 #if ! defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && \
     ! defined(BOOST_NO_CXX11_HDR_TUPLE)
 
- template <class Fp, class... Args>
+ template <class Fp, class ... Args>
     class async_func
     {
- std::tuple<Fp, Args...> f_;
+ std::tuple<Fp, Args...> f_;
 
     public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- //typedef typename invoke_of<_Fp, _Args...>::type Rp;
- typedef typename result_of<Fp(Args...)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f, BOOST_THREAD_RV_REF(Args)... args)
- : f_(boost::move(f), boost::move(args)...) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<1+sizeof...(Args), 1>::type Index;
- return execute(Index());
- }
- private:
- template <size_t ...Indices>
- result_type
- execute(tuple_indices<Indices...>)
- {
- return invoke(boost::move(std::get<0>(f_)), boost::move(std::get<Indices>(f_))...);
- }
+ BOOST_THREAD_MOVABLE_ONLY( async_func)
+ //typedef typename invoke_of<_Fp, _Args...>::type Rp;
+ typedef typename result_of<Fp(Args...)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f, BOOST_THREAD_RV_REF(Args)... args)
+ : f_(boost::move(f), boost::move(args)...)
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_))
+ {}
+
+ result_type operator()()
+ {
+ typedef typename make_tuple_indices<1+sizeof...(Args), 1>::type Index;
+ return execute(Index());
+ }
+ private:
+ template <size_t ...Indices>
+ result_type
+ execute(tuple_indices<Indices...>)
+ {
+ return invoke(boost::move(std::get<0>(f_)), boost::move(std::get<Indices>(f_))...);
+ }
     };
     //BOOST_THREAD_DCL_MOVABLE_BEG(X) async_func<Fp> BOOST_THREAD_DCL_MOVABLE_END
 #else
     template <class Fp,
- class T0 = tuples::null_type, class T1 = tuples::null_type, class T2 = tuples::null_type,
- class T3 = tuples::null_type, class T4 = tuples::null_type, class T5 = tuples::null_type,
- class T6 = tuples::null_type, class T7 = tuples::null_type, class T8 = tuples::null_type
- , class T9 = tuples::null_type>
+ class T0 = tuples::null_type, class T1 = tuples::null_type, class T2 = tuples::null_type,
+ class T3 = tuples::null_type, class T4 = tuples::null_type, class T5 = tuples::null_type,
+ class T6 = tuples::null_type, class T7 = tuples::null_type, class T8 = tuples::null_type
+ , class T9 = tuples::null_type
+ >
     class async_func;
 
     template <class Fp,
- class T0 , class T1 , class T2 ,
- class T3 , class T4 , class T5 ,
- class T6 , class T7 , class T8 >
+ class T0 , class T1 , class T2 ,
+ class T3 , class T4 , class T5 ,
+ class T6 , class T7 , class T8 >
     class async_func<Fp, T0, T1, T2, T3, T4, T5, T6, T7, T8>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3, T4, T5, T6, T7, T8> f_;
-
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6, T7, T8)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- , BOOST_THREAD_RV_REF(T4) a4
- , BOOST_THREAD_RV_REF(T5) a5
- , BOOST_THREAD_RV_REF(T6) a6
- , BOOST_THREAD_RV_REF(T7) a7
- , BOOST_THREAD_RV_REF(T8) a8
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- , boost::move(a4)
- , boost::move(a5)
- , boost::move(a6)
- , boost::move(a7)
- , boost::move(a8)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<10, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2,
- std::size_t I3, std::size_t I4, std::size_t I5,
- std::size_t I6, std::size_t I7, std::size_t I8
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3, I4, I5, I6, I7, I8>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- , boost::move(boost::get<I4>(f_))
- , boost::move(boost::get<I5>(f_))
- , boost::move(boost::get<I6>(f_))
- , boost::move(boost::get<I7>(f_))
- , boost::move(boost::get<I8>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ T4 v4_;
+ T5 v5_;
+ T6 v6_;
+ T7 v7_;
+ T8 v8_;
+ //::boost::tuple<Fp, T0, T1, T2, T3, T4, T5, T6, T7, T8> f_;
+
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6, T7, T8)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ , BOOST_THREAD_RV_REF(T4) a4
+ , BOOST_THREAD_RV_REF(T5) a5
+ , BOOST_THREAD_RV_REF(T6) a6
+ , BOOST_THREAD_RV_REF(T7) a7
+ , BOOST_THREAD_RV_REF(T8) a8
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ , v4_(boost::move(a4))
+ , v5_(boost::move(a5))
+ , v6_(boost::move(a6))
+ , v7_(boost::move(a7))
+ , v8_(boost::move(a8))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ , v4_(boost::move(f.a4))
+ , v5_(boost::move(f.a5))
+ , v6_(boost::move(f.a6))
+ , v7_(boost::move(f.a7))
+ , v8_(boost::move(f.a8))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ , boost::move(v4_)
+ , boost::move(v5_)
+ , boost::move(v6_)
+ , boost::move(v7_)
+ , boost::move(v8_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2, class T3, class T4, class T5, class T6, class T7 >
     class async_func<Fp, T0, T1, T2, T3, T4, T5, T6, T7>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3, T4, T5, T6, T7> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6, T7)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- , BOOST_THREAD_RV_REF(T4) a4
- , BOOST_THREAD_RV_REF(T5) a5
- , BOOST_THREAD_RV_REF(T6) a6
- , BOOST_THREAD_RV_REF(T7) a7
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- , boost::move(a4)
- , boost::move(a5)
- , boost::move(a6)
- , boost::move(a7)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<9, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2,
- std::size_t I3, std::size_t I4, std::size_t I5,
- std::size_t I6, std::size_t I7
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3, I4, I5, I6, I7>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- , boost::move(boost::get<I4>(f_))
- , boost::move(boost::get<I5>(f_))
- , boost::move(boost::get<I6>(f_))
- , boost::move(boost::get<I7>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ T4 v4_;
+ T5 v5_;
+ T6 v6_;
+ T7 v7_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6, T7)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ , BOOST_THREAD_RV_REF(T4) a4
+ , BOOST_THREAD_RV_REF(T5) a5
+ , BOOST_THREAD_RV_REF(T6) a6
+ , BOOST_THREAD_RV_REF(T7) a7
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ , v4_(boost::move(a4))
+ , v5_(boost::move(a5))
+ , v6_(boost::move(a6))
+ , v7_(boost::move(a7))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ , v4_(boost::move(f.a4))
+ , v5_(boost::move(f.a5))
+ , v6_(boost::move(f.a6))
+ , v7_(boost::move(f.a7))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ , boost::move(v4_)
+ , boost::move(v5_)
+ , boost::move(v6_)
+ , boost::move(v7_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2, class T3, class T4, class T5, class T6>
     class async_func<Fp, T0, T1, T2, T3, T4, T5, T6>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3, T4, T5, T6> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- , BOOST_THREAD_RV_REF(T4) a4
- , BOOST_THREAD_RV_REF(T5) a5
- , BOOST_THREAD_RV_REF(T6) a6
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- , boost::move(a4)
- , boost::move(a5)
- , boost::move(a6)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<8, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2, std::size_t I3, std::size_t I4, std::size_t I5, std::size_t I6
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3, I4, I5, I6>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- , boost::move(boost::get<I4>(f_))
- , boost::move(boost::get<I5>(f_))
- , boost::move(boost::get<I6>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ T4 v4_;
+ T5 v5_;
+ T6 v6_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5, T6)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ , BOOST_THREAD_RV_REF(T4) a4
+ , BOOST_THREAD_RV_REF(T5) a5
+ , BOOST_THREAD_RV_REF(T6) a6
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ , v4_(boost::move(a4))
+ , v5_(boost::move(a5))
+ , v6_(boost::move(a6))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ , v4_(boost::move(f.a4))
+ , v5_(boost::move(f.a5))
+ , v6_(boost::move(f.a6))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ , boost::move(v4_)
+ , boost::move(v5_)
+ , boost::move(v6_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2, class T3, class T4, class T5>
     class async_func<Fp, T0, T1, T2, T3, T4, T5>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3, T4, T5> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- , BOOST_THREAD_RV_REF(T4) a4
- , BOOST_THREAD_RV_REF(T5) a5
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- , boost::move(a4)
- , boost::move(a5)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<7, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2, std::size_t I3, std::size_t I4, std::size_t I5
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3, I4, I5>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- , boost::move(boost::get<I4>(f_))
- , boost::move(boost::get<I5>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ T4 v4_;
+ T5 v5_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3, T4, T5)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ , BOOST_THREAD_RV_REF(T4) a4
+ , BOOST_THREAD_RV_REF(T5) a5
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ , v4_(boost::move(a4))
+ , v5_(boost::move(a5))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ , v4_(boost::move(f.a4))
+ , v5_(boost::move(f.a5))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ , boost::move(v4_)
+ , boost::move(v5_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2, class T3, class T4>
     class async_func<Fp, T0, T1, T2, T3, T4>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3, T4> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3, T4)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- , BOOST_THREAD_RV_REF(T4) a4
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- , boost::move(a4)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<6, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2, std::size_t I3, std::size_t I4
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3, I4>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- , boost::move(boost::get<I4>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ T4 v4_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3, T4)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ , BOOST_THREAD_RV_REF(T4) a4
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ , v4_(boost::move(a4))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ , v4_(boost::move(f.a4))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ , boost::move(v4_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2, class T3>
     class async_func<Fp, T0, T1, T2, T3>
     {
- ::boost::tuple<Fp, T0, T1, T2, T3> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2, T3)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- , BOOST_THREAD_RV_REF(T3) a3
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- , boost::move(a3)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<5, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2, std::size_t I3
- >
- result_type
- execute(tuple_indices<I0, I1, I2, I3>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- , boost::move(boost::get<I3>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ T3 v3_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2, T3)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ , BOOST_THREAD_RV_REF(T3) a3
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ , v3_(boost::move(a3))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ , v3_(boost::move(f.a3))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ , boost::move(v3_)
+ );
+ }
     };
     template <class Fp, class T0, class T1, class T2>
     class async_func<Fp, T0, T1, T2>
     {
- ::boost::tuple<Fp, T0, T1, T2> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1, T2)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- , BOOST_THREAD_RV_REF(T2) a2
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- , boost::move(a2)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<4, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1, std::size_t I2
- >
- result_type
- execute(tuple_indices<I0, I1, I2>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- , boost::move(boost::get<I2>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ T2 v2_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1, T2)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ , BOOST_THREAD_RV_REF(T2) a2
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ , v2_(boost::move(a2))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ , v2_(boost::move(f.a2))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ , boost::move(v2_)
+ );
+ }
     };
     template <class Fp, class T0, class T1>
     class async_func<Fp, T0, T1>
     {
- ::boost::tuple<Fp, T0, T1> f_;
- public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0, T1)>::type result_type;
-
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- , BOOST_THREAD_RV_REF(T1) a1
- )
- : f_(boost::move(f)
- , boost::move(a0)
- , boost::move(a1)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<3, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0, std::size_t I1
- >
- result_type
- execute(tuple_indices<I0, I1>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- , boost::move(boost::get<I1>(f_))
- );
- }
+ Fp fp_;
+ T0 v0_;
+ T1 v1_;
+ public:
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0, T1)>::type result_type;
+
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ , BOOST_THREAD_RV_REF(T1) a1
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ , v1_(boost::move(a1))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ , v1_(boost::move(f.a1))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ , boost::move(v1_)
+ );
+ }
     };
     template <class Fp, class T0>
     class async_func<Fp, T0>
     {
- ::boost::tuple<Fp, T0> f_;
+ Fp fp_;
+ T0 v0_;
     public:
- BOOST_THREAD_MOVABLE_ONLY(async_func)
- typedef typename result_of<Fp(T0)>::type result_type;
+ BOOST_THREAD_MOVABLE_ONLY(async_func)
+ typedef typename result_of<Fp(T0)>::type result_type;
 
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_RV_REF(Fp) f
- , BOOST_THREAD_RV_REF(T0) a0
- )
- : f_(boost::move(f)
- , boost::move(a0)
- ) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_RV_REF(async_func) f) : f_(boost::move(f.f_)) {}
-
- result_type operator()()
- {
- typedef typename make_tuple_indices<2, 1>::type Index;
- return execute(Index());
- }
- private:
- template <
- std::size_t I0
- >
- result_type
- execute(tuple_indices<I0>)
- {
- return invoke(boost::move(boost::get<0>(f_))
- , boost::move(boost::get<I0>(f_))
- );
- }
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_RV_REF(Fp) f
+ , BOOST_THREAD_RV_REF(T0) a0
+ )
+ : fp_(boost::move(f))
+ , v0_(boost::move(a0))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_RV_REF(async_func) f)
+ : fp_(boost::move(f.fp))
+ , v0_(boost::move(f.a0))
+ {}
+
+ result_type operator()()
+ {
+ return invoke(boost::move(fp_)
+ , boost::move(v0_)
+ );
+ }
     };
     template <class Fp>
     class async_func<Fp>
     {
- Fp f_;
+ Fp fp_;
     public:
- BOOST_THREAD_COPYABLE_AND_MOVABLE(async_func)
- typedef typename result_of<Fp()>::type result_type;
- BOOST_SYMBOL_VISIBLE
- explicit async_func(BOOST_THREAD_FWD_REF(Fp) f)
- : f_(boost::move(f)) {}
-
- BOOST_SYMBOL_VISIBLE
- async_func(BOOST_THREAD_FWD_REF(async_func) f) : f_(boost::move(f.f_)) {}
- result_type operator()()
- {
- return execute();
- }
- private:
- result_type
- execute()
- {
- return f_();
- }
+ BOOST_THREAD_COPYABLE_AND_MOVABLE(async_func)
+ typedef typename result_of<Fp()>::type result_type;
+ BOOST_SYMBOL_VISIBLE
+ explicit async_func(BOOST_THREAD_FWD_REF(Fp) f)
+ : fp_(boost::move(f))
+ {}
+
+ BOOST_SYMBOL_VISIBLE
+ async_func(BOOST_THREAD_FWD_REF(async_func) f)
+ : fp_(boost::move(f.fp_))
+ {}
+ result_type operator()()
+ {
+ return fp_();
+ }
     };
 #endif
-//#else
-// template <class Fp>
-// class async_func
-// {
-// Fp f_;
-// public:
-// BOOST_THREAD_COPYABLE_AND_MOVABLE(async_func)
-// typedef typename result_of<Fp()>::type result_type;
-// BOOST_SYMBOL_VISIBLE
-// explicit async_func(BOOST_THREAD_FWD_REF(Fp) f)
-// : f_(boost::move(f)) {}
-//
-// BOOST_SYMBOL_VISIBLE
-// async_func(BOOST_THREAD_FWD_REF(async_func) f) : f_(boost::move(f.f_)) {}
-// result_type operator()()
-// {
-// return execute();
-// }
-// private:
-// result_type
-// execute()
-// {
-// return f_();
-// }
-// };
-// //BOOST_THREAD_DCL_MOVABLE_BEG(Fp) async_func<Fp> BOOST_THREAD_DCL_MOVABLE_END
-//#endif
 
   }
 }

Modified: branches/release/boost/thread/detail/config.hpp
==============================================================================
--- branches/release/boost/thread/detail/config.hpp (original)
+++ branches/release/boost/thread/detail/config.hpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -29,13 +29,6 @@
   #define BOOST_THREAD_ATTRIBUTE_MAY_ALIAS
 #endif
 
-#if ! defined BOOST_THREAD_NOEXCEPT_OR_THROW
-#ifdef BOOST_NO_CXX11_NOEXCEPT
-# define BOOST_THREAD_NOEXCEPT_OR_THROW throw()
-#else
-# define BOOST_THREAD_NOEXCEPT_OR_THROW noexcept
-#endif
-#endif
 
 #if defined BOOST_THREAD_THROW_IF_PRECONDITION_NOT_SATISFIED
 #define BOOST_THREAD_ASSERT_PRECONDITION(EXPR, EX) \

Modified: branches/release/boost/thread/externally_locked.hpp
==============================================================================
--- branches/release/boost/thread/externally_locked.hpp (original)
+++ branches/release/boost/thread/externally_locked.hpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -156,7 +156,6 @@
       BOOST_STATIC_ASSERT( (is_strict_lock<Lock>::value)); /*< lk is a strict lock "sur parolle" >*/
       BOOST_STATIC_ASSERT( (is_same<mutex_type, typename Lock::mutex_type>::value)); /*< that locks the same type >*/
 
- //BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(), lock_error() ); /*< run time check throw if no locked >*/
       BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(mtx_), lock_error() ); /*< run time check throw if not locks the same >*/
 
       return obj_;
@@ -295,7 +294,6 @@
       BOOST_CONCEPT_ASSERT(( StrictLock<Lock> ));
       BOOST_STATIC_ASSERT( (is_strict_lock<Lock>::value)); /*< lk is a strict lock "sur parolle" >*/
       BOOST_STATIC_ASSERT( (is_same<mutex_type, typename Lock::mutex_type>::value)); /*< that locks the same type >*/
- //BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(), lock_error() ); /*< run time check throw if no locked >*/
       BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(mtx_), lock_error() ); /*< run time check throw if not locks the same >*/
       return *obj_;
     }
@@ -312,7 +310,6 @@
       BOOST_CONCEPT_ASSERT(( StrictLock<Lock> ));
       BOOST_STATIC_ASSERT( (is_strict_lock<Lock>::value)); /*< lk is a strict lock "sur parolle" >*/
       BOOST_STATIC_ASSERT( (is_same<mutex_type, typename Lock::mutex_type>::value)); /*< that locks the same type >*/
- //BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(), lock_error() ); /*< run time check throw if no locked >*/
       BOOST_THREAD_ASSERT_PRECONDITION( lk.owns_lock(mtx_), lock_error() ); /*< run time check throw if not locks the same >*/
       return *obj_;
     }

Modified: branches/release/boost/thread/externally_locked_stream.hpp
==============================================================================
--- branches/release/boost/thread/externally_locked_stream.hpp (original)
+++ branches/release/boost/thread/externally_locked_stream.hpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -21,12 +21,6 @@
 namespace boost
 {
 
- // inline static recursive_mutex& terminal_mutex()
- // {
- // static recursive_mutex mtx;
- // return mtx;
- // }
-
   template <typename Stream, typename RecursiveMutex=recursive_mutex>
   class externally_locked_stream;
 
@@ -51,7 +45,7 @@
     {
     }
 
- stream_guard(BOOST_THREAD_RV_REF(stream_guard) rhs)
+ stream_guard(BOOST_THREAD_RV_REF(stream_guard) rhs) BOOST_NOEXCEPT
     : mtx_(rhs.mtx_)
     {
       rhs.mtx_= 0;
@@ -62,15 +56,24 @@
       if (mtx_ != 0) mtx_->unlock();
     }
 
- bool owns_lock(mutex_type const* l) const BOOST_NOEXCEPT
+ bool owns_lock(const mutex_type * l) const BOOST_NOEXCEPT
     {
       return l == mtx_->mutex();
     }
 
+ /**
+ * @Requires mtx_
+ */
     Stream& get() const
     {
+ BOOST_THREAD_ASSERT_PRECONDITION( mtx_, lock_error() );
       return mtx_->get(*this);
     }
+ Stream& bypass() const
+ {
+ return get();
+ }
+
 
   private:
     externally_locked_stream<Stream, RecursiveMutex>* mtx_;
@@ -98,22 +101,20 @@
     /**
      * Effects: Constructs an externally locked object storing the cloaked reference object.
      */
- externally_locked_stream(Stream& stream, RecursiveMutex& mtx) :
+ externally_locked_stream(Stream& stream, RecursiveMutex& mtx) BOOST_NOEXCEPT :
       base_type(stream, mtx)
     {
     }
 
- stream_guard<Stream, RecursiveMutex> hold()
+ stream_guard<Stream, RecursiveMutex> hold() BOOST_NOEXCEPT
     {
       return stream_guard<Stream, RecursiveMutex> (*this);
     }
-
- Stream& hold(strict_lock<RecursiveMutex>& lk)
+ Stream& bypass() const
     {
- return this->get(lk);
+ stream_guard<Stream, RecursiveMutex> lk(*this);
+ return get(lk);
     }
-
-
   };
   //]
 

Modified: branches/release/boost/thread/strict_lock.hpp
==============================================================================
--- branches/release/boost/thread/strict_lock.hpp (original)
+++ branches/release/boost/thread/strict_lock.hpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -73,7 +73,6 @@
 
 
     // observers
- private:
 
     /**
      * @return the owned mutex.
@@ -82,12 +81,19 @@
     {
       return &mtx_;
     }
- public:
+
+ /**
+ * @return whether this lock is locking a mutex.
+ */
+ bool owns_lock() const BOOST_NOEXCEPT
+ {
+ return true;
+ }
 
     /**
      * @return whether this lock is locking that mutex.
      */
- bool owns_lock(mutex_type const* l) const BOOST_NOEXCEPT
+ bool owns_lock(const mutex_type* l) const BOOST_NOEXCEPT
     {
       return l == mutex();
     } /*< strict locks specific function >*/
@@ -173,7 +179,6 @@
     }
 
     // observers
-private:
     /**
      * return @c the owned mutex.
      */
@@ -181,7 +186,15 @@
     {
       return tmp_lk_.mutex();
     }
-public:
+
+ /**
+ * @return whether this lock is locking a mutex.
+ */
+ bool owns_lock() const BOOST_NOEXCEPT
+ {
+ return true;
+ }
+
     /**
      * @return whether if this lock is locking that mutex.
      */

Modified: branches/release/libs/thread/doc/compliance.qbk
==============================================================================
--- branches/release/libs/thread/doc/compliance.qbk (original)
+++ branches/release/libs/thread/doc/compliance.qbk 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -9,6 +9,8 @@
 
 [section:cpp11 C++11 standard Thread library]
 
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2012/n3376.html C++11 standard]]
+
 
 [table C++11 standard Conformance
     [[Section] [Description] [Status] [Comments] [Ticket]]
@@ -86,24 +88,155 @@
 [endsect]
 
 
-[section:shared Shared Locking extensions]
+[section:cxx14 C++14 standard Thread library - accepted changes]
+
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2012/n3485.html C++14 on-going standard]]
+
+
+[table [@http://isocpp.org/files/papers/N3659.html N3659 Shared locking in C++ revision 2] Conformance
+ [[Section] [Description] [Status] [Comments]]
+ [[30.4.1.4] [Shared Lockables Types] [Yes] [ - ]]
+ [[30.4.1.4.1] [shared_mutex class] [Yes] [ - ]]
+ [[30.4.2.3] [Class template shared_lock] [Yes] [-]]
+]
+
+[endsect]
+
+[section:cxx1y C++1y TS Concurrency - On going proposals]
+
+[section:latch C++ Latches and Barriers]
+
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3600.html N3659 C++ Latches and Barriers]]
+
+[table C++ Latches and Barriers Conformance
+ [[Section] [Description] [Status] [Comments]]
+ [[X.1] [Class latch] [Partial] [ A new class latch has been added. The interface is a super set of the one of the proposal, taking some of the functions of the class barrier.]]
+ [[X.2] [Class barrier] [No] [ Even if Boost.Thread has a class boost:barrier it doesn't provides the same kind of services. There is an experimental completion_latch that could be used instead. ]]
+]
+
+[endsect]
+[section:queue C++ Concurrent Queues]
+
+[note [@ http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3533.html N3533 C++ Concurrent Queues]]
+
+[table C++ Concurrent Queues Conformance
+ [[Section] [Description] [Status] [Comments]]
+ [[X.1] [Conceptual interface] [Partial] [ The interface provided has some differences respect to this proposal. All the functions having a queue_op_status are not provided. No lock-free concrete classes ]]
+ [[X.1.1] [Basic Operations] [Partial] [ - ]]
+ [[X.1.1.1] [push] [yes] [ - ]]
+ [[X.1.1.2] [value_pop] [no] [ renamed pull with two flavors + a ptr_pull that returns a sharted_ptr<>. ]]
+ [[X.1.2] [Non-waiting operations] [] [ - ]]
+ [[X.1.2.1] [try_push] [Partial] [ return bool instead ]]
+ [[X.1.2.2] [try_pop] [Partial] [ renamed try_pull, returns null ]]
+ [[X.1.3] [Non-blocking operations] [] [ - ]]
+ [[X.1.3.1] [nonblocking_push] [Partial] [ renamed try_push(no_block, ]]
+ [[X.1.3.2] [nonblocking_pop] [Partial] [ renamed try_pop(no_block, ]]
+ [[X.1.4] [Push-front operations] [No] [ - ]]
+ [[X.1.5] [Closed queues] [Partial] [ - ]]
+ [[X.1.5.1] [close] [Yes] [ - ]]
+ [[X.1.5.2] [is_closed] [Yes] [ - ]]
+ [[X.1.5.3] [wait_push] [Partial] [ - ]]
+ [[X.1.5.4] [wait_pop] [Partial] [ - ]]
+ [[X.1.5.5] [wait_push_front] [no] [ - ]]
+ [[X.1.5.6] [wait_pop] [Partial] [ - ]]
+ [[X.1.5.6] [open] [no] [ - ]]
+ [[X.1.6] [Empty and Full Queues] [Yes] [ - ]]
+ [[X.1.6.1] [is_empty] [Yes] [ - ]]
+ [[X.1.6.2] [is_full] [Yes] [ Added capacity ]]
+ [[X.1.7] [Queue Names] [No] [ Not considere a must for the time been. ]]
+ [[X.1.8] [Element Type Requirements] [Yes?] [ - ]]
+ [[X.1.9] [Exception Handling] [Yes?] [ - ]]
+ [[X.1.10] [Queue Ordering] [Yes?] [ - ]]
+ [[X.1.11] [Lock-Free Implementations] [No] [ waiting to stabilize the lock-based interface. Will use Boost.LockFree once it is Move aware. ]]
+ [[X.2] [Concrete queues] [Partial] [ ]]
+ [[X.2.1] [Locking Buffer Queue] [Partial] [ classes sync_queue and a sync_bounded_queue. ]]
+ [[X.2.1] [Lock-Free Buffer Queue] [No] [ ]]
+ [[X.3] [Additional Conceptual Tools] [No] [ ]]
+ [[X.3.1] [Fronts and Backs] [No] [ ]]
+ [[X.3.2] [Streaming Iterators] [No] [ ]]
+ [[X.3.3] [Storage Iterators] [No] [ ]]
+ [[X.3.4] [Binary Interfaces] [No] [ ]]
+ [[X.3.4] [Managed Indirection] [No] [ ]]
+]
+[endsect]
+
+
+[section:executors Asynchronous Executors]
+
+While Boost.Thread implementation of executors would not use dynamic polymorphism, it is worth comparing with the current trend on the standard.
+
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2012/n3378.pdf N3378 A preliminary proposal for work executors]]
+
+
+[table Asynchronous Executors
+ [[Section] [Description] [Status] [Comments]]
+ [[30.X.1] [Class executor] [No] [ - ]]
+ [[30.X.1.1] [add] [No] [ renamed with a function template submit ]]
+ [[30.X.1.1] [num_of_pendin_closures] [??] [ ]]
+ [[30.X.2] [Class sceduled_executor] [No] [ - ]]
+ [[30.X.2.1] [add_at] [No] [ renamed with a function template submit_at ]]
+ [[30.X.2.2] [add_after] [No] [ renamed with a function template submit_after ]]
+ [[30.X.3] [Executor utilities functions] [No] [ - ]]
+ [[30.X.3.1] [default_executor] [No] [ - ]]
+ [[30.X.3.2] [set_default_executor] [No] [ - ]]
+ [[30.X.3.3] [singleton_inline_executor] [No] [ - ]]
+ [[30.X.4] [Concrete executor classes] [No] [ - ]]
+ [[30.X.4.1] [loop_executor] [No] [ - ]]
+ [[30.X.4.1] [serial_executor] [No] [ - ]]
+ [[30.X.4.1] [thread_pool] [No] [ #8513 ]]
+]
+
+[endsect]
+
+
+[section:async A Standardized Representation of Asynchronous Operations]
+
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3558.pdf N3558 A Standardized Representation of Asynchronous Operations]]
+
+[table A Standardized Representation of Asynchronous Operations Conformance
+ [[Section] [Description] [Status] [Comments]]
+ [[30.6.6] [Class template future] [Partial] [ - ]]
+ [[30.6.6.1] [then] [Partial] [ executor interface missing #8516 ]]
+ [[30.6.6.2] [unwrap] [No] [ #XXXX ]]
+ [[30.6.6.3] [ready] [yes] [ is_ready ]]
+ [[30.6.7] [Class template shared_future] [Partial] [ - ]]
+ [[30.6.7.1] [then] [No] [ #8515 ]]
+ [[30.6.7.2] [unwrap] [No] [ #XXXX ]]
+ [[30.6.7.3] [ready] [Yes] [ is_ready ]]
+ [[30.6.X] [Function template when_any] [No] [ #7446 ]]
+ [[30.6.X] [Function template when_all] [No] [ #7447 ]]
+ [[30.6.X] [Function template make_ready_future] [Yes] [ - ]]
+ [[30.6.8] [Function template async ] [No] [ executor interface missing #7448 ]]
+]
+
+[endsect]
+
+[section:stream_mutex C++ Stream Mutexes]
+
+While Boost.Thread implementation of stream mutexes differ in the approach, it is worth comparing with the current trend on the standard.
+
+[note [@http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3535.html N3535 - C++ Stream Mutexes]]
 
-[table Howard's Shared Locking Proposal Conformance
+[table C++ C++ Stream MutexesConformance
     [[Section] [Description] [Status] [Comments]]
- [[X] [Shared Locking] [Yes] [Needs `BOOST_THREAD_PROVIDES_SHARED_MUTEX_UPWARDS_CONVERSION]]
- [[X.1] [Shared Lockables Concepts] [Yes] [ - ]]
- [[X.1.1] [SharedLockable concept] [Yes] [ - ]]
- [[X.1.2] [UpgradeLockable concept] [Yes] [ - ]]
- [[X.2] [Shared Mutex Types] [Yes] [ - ]]
- [[X.2.1] [shared_mutex class] [Yes] [ - ]]
- [[X.2.2] [upgrade_mutex class] [Yes] [ - ]]
- [[X.3] [Locks] [Yes] [-]]
- [[X.3.1] [unique_lock class adaptations] [Yes] [-]]
- [[X.3.2] [shared_lock class] [Yes] [ - ]]
- [[X.3.3] [upgrade_lock class] [Yes] [-]]
+ [[X.1] [Class template stream_mutex] [Partial] [ externally_locked_stream<> ]]
+ [[X.2.1] [constructor] [Partial] [ externally_locked_stream needs a mutex in addition as argumement. ]]
+ [[X.2.2] [lock] [yes] [ - ]]
+ [[X.2.3] [unlock] [yes] [ - ]]
+ [[X.2.4] [try_lock] [yes] [ - ]]
+ [[X.2.5] [hold] [Yes] [ - ]]
+ [[X.2.6] [bypass] [Yes] [ - ]]
+ [[X.2] [Class template stream_guard] [Yes] [ - ]]
+ [[X.2.1] [stream_guard] [Yes] [ - ]]
+ [[X.2.2] [~stream_guard] [Yes] [ - ]]
+ [[X.2.3] [bypass] [Yes] [ - ]]
+ [[X.3] [Stream Operators] [Yes] [.]]
+ [[X.4] [Predefined Objects] [No] [.]]
 ]
 
 [endsect]
 
 
 [endsect]
+
+[endsect]

Modified: branches/release/libs/thread/doc/sync_queues_ref.qbk
==============================================================================
--- branches/release/libs/thread/doc/sync_queues_ref.qbk (original)
+++ branches/release/libs/thread/doc/sync_queues_ref.qbk 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -381,7 +381,7 @@
 
 [endsect]
 
-[section:sync_bounded_queue Class `sync_bounded_queue<>`]
+[section:sync_bounded_queue Class template `sync_bounded_queue<>`]
 
   #include <boost/thread/sync_bounded_queue.hpp>
   namespace boost
@@ -470,7 +470,7 @@
     sync_queue<ValueType>& operator>>(sync_queue<ValueType>& sbq, ValueType &elem);
   }
 
-[section:sync_queue Class `sync_queue<>`]
+[section:sync_queue Class template `sync_queue<>`]
 
   #include <boost/thread/sync_queue.hpp>
 

Modified: branches/release/libs/thread/doc/sync_streams.qbk
==============================================================================
--- branches/release/libs/thread/doc/sync_streams.qbk (original)
+++ branches/release/libs/thread/doc/sync_streams.qbk 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -65,15 +65,76 @@
       stream_guard& operator=(stream_guard const&) = delete;
       stream_guard(externally_locked_stream<Stream, RecursiveMutex>& mtx);
       stream_guard(externally_locked_stream<Stream, RecursiveMutex>& mtx, adopt_lock_t);
- stream_guard(BOOST_THREAD_RV_REF(stream_guard) rhs);
+ stream_guard(stream_guard&& rhs);
       ~stream_guard();
 
       // Observers
       bool owns_lock(mutex_type const* l) const BOOST_NOEXCEPT;
       Stream& get() const;
+ Stream& bypass() const;
+
     };
   }
 
+`stream_guard` is a model of __StrictLock.
+
+[section:constructor `stream_guard(mutex_type & m)`]
+
+[variablelist
+
+[[Effects:] [Stores a reference to `m`. Invokes [lock_ref_link `m.lock()`].]]
+
+[[Throws:] [Any exception thrown by the call to [lock_ref_link `m.lock()`].]]
+
+]
+
+[endsect]
+
+[section:constructor_adopt `stream_guard(mutex_type & m,boost::adopt_lock_t)`]
+
+[variablelist
+
+[[Precondition:] [The current thread owns a lock on `m` equivalent to one
+obtained by a call to [lock_ref_link `m.lock()`].]]
+
+[[Effects:] [Stores a reference to `m`. Takes ownership of the lock state of
+`m`.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
+
+[section:move_constructor `stream_guard(stream_guard && m)`]
+
+
+[variablelist
+
+[[Effects:] [Stores a reference to `m`. Invokes [lock_ref_link `m.lock()`].]]
+
+[[Throws:] [Any exception thrown by the call to [lock_ref_link `m.lock()`].]]
+
+]
+
+[endsect]
+
+
+[section:destructor `~stream_guard()`]
+
+[variablelist
+
+[[Effects:] [Invokes [unlock_ref_link `m.unlock()`] on the __lockable_concept_type__
+object passed to the constructor.]]
+
+[[Throws:] [Nothing.]]
+
+]
+
+[endsect]
+
+
 [endsect]
 [section:externally_locked_stream Class `externally_locked_stream `]
 
@@ -87,12 +148,12 @@
       // Constructors, Assignment and Destructors
       externally_locked_stream(externally_locked_stream const&) = delete;
       externally_locked_stream& operator=(externally_locked_stream const&) = delete;
- // Effects: Constructs an externally locked object storing the cloaked reference object.
       externally_locked_stream(Stream& stream, RecursiveMutex& mtx);
   
- // Observers
+ // Modifiers
       stream_guard<Stream, RecursiveMutex> hold();
- Stream& hold(strict_lock<RecursiveMutex>& lk);
+ Stream& bypass() const;
+
     };
   }
 
@@ -101,6 +162,26 @@
 pass a reference to a strict lock object.
 
 
+[section:constructor `externally_locked_stream(Stream&, RecursiveMutex&)`]
+
+[variablelist
+
+[[Effects:] [Constructs an externally locked object storing the cloaked reference object and its locking mutex.]]
+
+]
+
+[endsect]
+
+[section:hold `hold()`]
+
+[variablelist
+
+[[Returns:] [A stream_guard which will hold the mutex during it lifetime .]]
+
+]
+
+[endsect]
+
 [endsect]
 
 

Modified: branches/release/libs/thread/example/not_interleaved.cpp
==============================================================================
--- branches/release/libs/thread/example/not_interleaved.cpp (original)
+++ branches/release/libs/thread/example/not_interleaved.cpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -50,8 +50,8 @@
   std::string nm;
   {
     strict_lock<recursive_mutex> lk(terminal_mutex);
- std::ostream & gcout = mcout.hold(lk);
- //std::istream & gcin = mcin.hold(lk);
+ std::ostream & gcout = mcout.get(lk);
+ //std::istream & gcin = mcin.get(lk);
     gcout << "Enter name: ";
     //gcin >> nm;
   }

Modified: branches/release/libs/thread/example/tennis.cpp
==============================================================================
--- branches/release/libs/thread/example/tennis.cpp (original)
+++ branches/release/libs/thread/example/tennis.cpp 2013-05-09 00:49:18 EDT (Thu, 09 May 2013)
@@ -29,7 +29,7 @@
 boost::mutex mutex;
 boost::condition cond;
 
-char* player_name(int state)
+const char* player_name(int state)
 {
     if (state == PLAYER_A)
         return "PLAYER-A";
@@ -95,7 +95,7 @@
     void* _param;
 };
 
-int main(int argc, char* argv[])
+int main()
 {
     state = START;
 


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