X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=3rdparty%2Fboost%2Fboost%2Ftype_traits%2Fadd_reference.hpp;h=33e9bc79bea18d1db93e5c7ba0537e710eee88da;hb=3ddb4c5389da0b20f761551c9463caea66f04d85;hp=5e3efca6920b34f6dca5aaeb29b87689677f379e;hpb=b7a3831289aa542e309d8f645e68d6945f7ca292;p=lyx.git diff --git a/3rdparty/boost/boost/type_traits/add_reference.hpp b/3rdparty/boost/boost/type_traits/add_reference.hpp index 5e3efca692..33e9bc79be 100644 --- a/3rdparty/boost/boost/type_traits/add_reference.hpp +++ b/3rdparty/boost/boost/type_traits/add_reference.hpp @@ -9,13 +9,9 @@ #ifndef BOOST_TT_ADD_REFERENCE_HPP_INCLUDED #define BOOST_TT_ADD_REFERENCE_HPP_INCLUDED -#include #include #include -// should be the last #include -#include - namespace boost { namespace detail { @@ -26,47 +22,45 @@ namespace detail { // template -struct add_reference_rvalue_layer +struct add_reference_impl { typedef T& type; }; #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES template -struct add_reference_rvalue_layer +struct add_reference_impl { typedef T&& type; }; #endif -template -struct add_reference_impl +} // namespace detail + +template struct add_reference { - typedef typename add_reference_rvalue_layer::type type; + typedef typename boost::detail::add_reference_impl::type type; +}; +template struct add_reference +{ + typedef T& type; }; - -BOOST_TT_AUX_TYPE_TRAIT_IMPL_PARTIAL_SPEC1_1(typename T,add_reference,T&,T&) // these full specialisations are always required: -BOOST_TT_AUX_TYPE_TRAIT_IMPL_SPEC1(add_reference,void,void) +template <> struct add_reference { typedef void type; }; #ifndef BOOST_NO_CV_VOID_SPECIALIZATIONS -BOOST_TT_AUX_TYPE_TRAIT_IMPL_SPEC1(add_reference,void const,void const) -BOOST_TT_AUX_TYPE_TRAIT_IMPL_SPEC1(add_reference,void volatile,void volatile) -BOOST_TT_AUX_TYPE_TRAIT_IMPL_SPEC1(add_reference,void const volatile,void const volatile) +template <> struct add_reference { typedef const void type; }; +template <> struct add_reference { typedef const volatile void type; }; +template <> struct add_reference { typedef volatile void type; }; #endif -} // namespace detail +#if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) -BOOST_TT_AUX_TYPE_TRAIT_DEF1(add_reference,T,typename boost::detail::add_reference_impl::type) +template using add_reference_t = typename add_reference::type; -// agurt, 07/mar/03: workaround Borland's ill-formed sensitivity to an additional -// level of indirection, here -#if BOOST_WORKAROUND(__BORLANDC__, < 0x600) -BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,add_reference,T&,T&) #endif -} // namespace boost -#include +} // namespace boost #endif // BOOST_TT_ADD_REFERENCE_HPP_INCLUDED