mirror of
https://github.com/boostorg/thread.git
synced 2026-01-31 08:42:17 +00:00
Thread: Added BOOST_THREAD_NO_CXX11_HDR_TUPLE to wrokarround msvc 10.0 behavior providing <tuple> without move semantics
[SVN r82410]
This commit is contained in:
@@ -69,8 +69,13 @@
|
||||
|
||||
#if defined BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX || defined BOOST_NO_CXX11_HDR_INITIALIZER_LIST
|
||||
#define BOOST_THREAD_NO_CXX11_HDR_INITIALIZER_LIST
|
||||
//#elif defined __GNUC__ && (__GNUC__ < 4 || ( __GNUC__ == 4 && __GNUC_MINOR__ <= 6 ))
|
||||
//#define BOOST_THREAD_NO_CXX11_HDR_INITIALIZER_LIST
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_NO_CXX11_HDR_TUPLE) || defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
|
||||
#define BOOST_THREAD_NO_CXX11_HDR_TUPLE
|
||||
#elif defined _MSC_VER && _MSC_VER <= 1600
|
||||
// C++ features supported by VC++ 10 (aka 2010)
|
||||
#define BOOST_THREAD_NO_CXX11_HDR_TUPLE
|
||||
#endif
|
||||
|
||||
/// BASIC_THREAD_ID
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
#include <boost/thread/lock_types.hpp>
|
||||
#include <boost/thread/lock_algorithms.hpp>
|
||||
#if ! defined(BOOST_NO_CXX11_HDR_TUPLE)
|
||||
#if ! defined(BOOST_THREAD_NO_CXX11_HDR_TUPLE)
|
||||
#include <tuple> // todo change to <boost/tuple.hpp> once Boost.Tuple or Boost.Fusion provides Move semantics.
|
||||
#endif
|
||||
#include <boost/config/abi_prefix.hpp>
|
||||
@@ -39,7 +39,7 @@ namespace boost
|
||||
{
|
||||
return unique_lock<Lockable> (mtx, try_to_lock);
|
||||
}
|
||||
#if ! defined(BOOST_NO_CXX11_HDR_TUPLE) && ! defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
|
||||
#if ! defined(BOOST_THREAD_NO_CXX11_HDR_TUPLE)
|
||||
|
||||
#if ! defined BOOST_NO_CXX11_VARIADIC_TEMPLATES
|
||||
template <typename ...Lockable>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
#include <boost/thread/thread.hpp>
|
||||
#include <boost/detail/lightweight_test.hpp>
|
||||
|
||||
#if ! defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && ! defined BOOST_NO_CXX11_HDR_TUPLE && ! defined BOOST_NO_CXX11_RVALUE_REFERENCES
|
||||
#if ! defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && ! defined BOOST_THREAD_NO_CXX11_HDR_TUPLE && ! defined BOOST_NO_CXX11_RVALUE_REFERENCES
|
||||
|
||||
boost::mutex m1;
|
||||
boost::mutex m2;
|
||||
|
||||
Reference in New Issue
Block a user