summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Markmann <tm@ayena.de>2014-10-19 20:22:58 (GMT)
committerTobias Markmann <tm@ayena.de>2014-10-20 13:49:33 (GMT)
commit6b22dfcf59474dd016a0355a3102a1dd3692d92c (patch)
tree2b1fd33be433a91e81fee84fdc2bf1b52575d934 /3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp
parent38b0cb785fea8eae5e48fae56440695fdfd10ee1 (diff)
downloadswift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.zip
swift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.tar.bz2
Update Boost in 3rdParty to version 1.56.0.
This updates Boost in our 3rdParty directory to version 1.56.0. Updated our update.sh script to stop on error. Changed error reporting in SwiftTools/CrashReporter.cpp to SWIFT_LOG due to missing include of <iostream> with newer Boost. Change-Id: I4b35c77de951333979a524097f35f5f83d325edc
Diffstat (limited to '3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp')
-rw-r--r--3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp125
1 files changed, 78 insertions, 47 deletions
diff --git a/3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp b/3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp
index 02b1361..9dc0d52 100644
--- a/3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp
+++ b/3rdParty/Boost/src/boost/intrusive/detail/mpl.hpp
@@ -1,6 +1,7 @@
/////////////////////////////////////////////////////////////////////////////
//
-// (C) Copyright Ion Gaztanaga 2006-2012
+// (C) Copyright Ion Gaztanaga 2006-2014
+// (C) Copyright Microsoft Corporation 2014
//
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
@@ -20,6 +21,59 @@ namespace boost {
namespace intrusive {
namespace detail {
+template <typename T, typename U>
+struct is_same
+{
+ static const bool value = false;
+};
+
+template <typename T>
+struct is_same<T, T>
+{
+ static const bool value = true;
+};
+
+template<typename T>
+struct add_const
+{ typedef const T type; };
+
+template<typename T>
+struct remove_const
+{ typedef T type; };
+
+template<typename T>
+struct remove_const<const T>
+{ typedef T type; };
+
+template<typename T>
+struct remove_cv
+{ typedef T type; };
+
+template<typename T>
+struct remove_cv<const T>
+{ typedef T type; };
+
+template<typename T>
+struct remove_cv<const volatile T>
+{ typedef T type; };
+
+template<typename T>
+struct remove_cv<volatile T>
+{ typedef T type; };
+
+template<class T>
+struct remove_reference
+{
+ typedef T type;
+};
+
+template<class T>
+struct remove_reference<T&>
+{
+ typedef T type;
+};
+
+
typedef char one;
struct two {one _[2];};
@@ -29,6 +83,12 @@ struct bool_
static const bool value = C_;
};
+template< class Integer, Integer Value >
+struct integer
+{
+ static const Integer value = Value;
+};
+
typedef bool_<true> true_;
typedef bool_<false> false_;
@@ -58,18 +118,32 @@ struct apply
typedef typename F::template apply<Param>::type type;
};
+#if defined(_MSC_VER) && (_MSC_VER >= 1400)
+
+template <class T, class U>
+struct is_convertible
+{
+ static const bool value = __is_convertible_to(T, U);
+};
+
+#else
+
template <class T, class U>
class is_convertible
{
typedef char true_t;
class false_t { char dummy[2]; };
- static true_t dispatch(U);
+ //use any_conversion as first parameter since in MSVC
+ //overaligned types can't go through ellipsis
static false_t dispatch(...);
- static const T &trigger();
+ static true_t dispatch(U);
+ static typename remove_reference<T>::type &trigger();
public:
static const bool value = sizeof(dispatch(trigger())) == sizeof(true_t);
};
+#endif
+
template<
bool C
, typename T1
@@ -130,7 +204,7 @@ struct identity
#define BOOST_INTRUSIVE_TT_DECL
#endif
-#if defined(_MSC_EXTENSIONS) && !defined(__BORLAND__) && !defined(_WIN64) && !defined(UNDER_CE)
+#if defined(_MSC_EXTENSIONS) && !defined(__BORLAND__) && !defined(_WIN64) && !defined(_M_ARM) && !defined(UNDER_CE)
#define BOOST_INTRUSIVE_TT_TEST_MSC_FUNC_SIGS
#endif
@@ -280,49 +354,6 @@ struct alignment_of
>::value;
};
-template <typename T, typename U>
-struct is_same
-{
- typedef char yes_type;
- struct no_type
- {
- char padding[8];
- };
-
- template <typename V>
- static yes_type is_same_tester(V*, V*);
- static no_type is_same_tester(...);
-
- static T *t;
- static U *u;
-
- static const bool value = sizeof(yes_type) == sizeof(is_same_tester(t,u));
-};
-
-template<typename T>
-struct add_const
-{ typedef const T type; };
-
-template<typename T>
-struct remove_const
-{ typedef T type; };
-
-template<typename T>
-struct remove_const<const T>
-{ typedef T type; };
-
-template<class T>
-struct remove_reference
-{
- typedef T type;
-};
-
-template<class T>
-struct remove_reference<T&>
-{
- typedef T type;
-};
-
template<class Class>
class is_empty_class
{