summaryrefslogtreecommitdiff
path: root/boost/type_traits/is_same.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/type_traits/is_same.hpp')
-rw-r--r--boost/type_traits/is_same.hpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/boost/type_traits/is_same.hpp b/boost/type_traits/is_same.hpp
index c8987b07a8..d16f4b2b1a 100644
--- a/boost/type_traits/is_same.hpp
+++ b/boost/type_traits/is_same.hpp
@@ -21,25 +21,21 @@
#ifndef BOOST_TT_IS_SAME_HPP_INCLUDED
#define BOOST_TT_IS_SAME_HPP_INCLUDED
-#include <boost/type_traits/config.hpp>
-// should be the last #include
-#include <boost/type_traits/detail/bool_trait_def.hpp>
+#include <boost/type_traits/integral_constant.hpp>
namespace boost {
-BOOST_TT_AUX_BOOL_TRAIT_DEF2(is_same,T,U,false)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC2_1(typename T,is_same,T,T,true)
+ template <class T, class U> struct is_same : public false_type {};
+ template <class T> struct is_same<T,T> : public true_type {};
#if BOOST_WORKAROUND(__BORLANDC__, < 0x600)
// without this, Borland's compiler gives the wrong answer for
// references to arrays:
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC2_1(typename T,is_same,T&,T&,true)
+ template <class T> struct is_same<T&, T&> : public true_type{};
#endif
} // namespace boost
-#include <boost/type_traits/detail/bool_trait_undef.hpp>
-
#endif // BOOST_TT_IS_SAME_HPP_INCLUDED