aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrobot-contrib <robot-contrib@yandex-team.com>2023-04-26 21:57:21 +0300
committerrobot-contrib <robot-contrib@yandex-team.com>2023-04-26 21:57:21 +0300
commitb9de8851261b66d38f22b8fe68efffb722880d58 (patch)
treef9ff3bea35e2fed83efcd2ca38fa516979c76737
parentcba33106b7713d13fe59f92c3156eaaffa3b167f (diff)
downloadydb-b9de8851261b66d38f22b8fe68efffb722880d58.tar.gz
Update contrib/restricted/boost/core to 1.82.0
-rw-r--r--contrib/restricted/boost/config/include/boost/config/header_deprecated.hpp26
-rw-r--r--contrib/restricted/boost/core/include/boost/core/allocator_access.hpp8
-rw-r--r--contrib/restricted/boost/core/include/boost/core/detail/is_same.hpp39
-rw-r--r--contrib/restricted/boost/core/include/boost/core/is_same.hpp25
-rw-r--r--contrib/restricted/boost/core/include/boost/core/ref.hpp39
-rw-r--r--contrib/restricted/boost/core/include/boost/core/swap.hpp35
6 files changed, 129 insertions, 43 deletions
diff --git a/contrib/restricted/boost/config/include/boost/config/header_deprecated.hpp b/contrib/restricted/boost/config/include/boost/config/header_deprecated.hpp
new file mode 100644
index 00000000000..120b4b3a92f
--- /dev/null
+++ b/contrib/restricted/boost/config/include/boost/config/header_deprecated.hpp
@@ -0,0 +1,26 @@
+#ifndef BOOST_CONFIG_HEADER_DEPRECATED_HPP_INCLUDED
+#define BOOST_CONFIG_HEADER_DEPRECATED_HPP_INCLUDED
+
+// Copyright 2017 Peter Dimov.
+//
+// Distributed under the Boost Software License, Version 1.0.
+//
+// See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt
+//
+// BOOST_HEADER_DEPRECATED("<alternative>")
+//
+// Expands to the equivalent of
+// BOOST_PRAGMA_MESSAGE("This header is deprecated. Use <alternative> instead.")
+//
+// Note that this header is C compatible.
+
+#include <boost/config/pragma_message.hpp>
+
+#if defined(BOOST_ALLOW_DEPRECATED_HEADERS) || defined(BOOST_ALLOW_DEPRECATED)
+# define BOOST_HEADER_DEPRECATED(a)
+#else
+# define BOOST_HEADER_DEPRECATED(a) BOOST_PRAGMA_MESSAGE("This header is deprecated. Use " a " instead.")
+#endif
+
+#endif // BOOST_CONFIG_HEADER_DEPRECATED_HPP_INCLUDED
diff --git a/contrib/restricted/boost/core/include/boost/core/allocator_access.hpp b/contrib/restricted/boost/core/include/boost/core/allocator_access.hpp
index 567b448becd..8e33ebb0472 100644
--- a/contrib/restricted/boost/core/include/boost/core/allocator_access.hpp
+++ b/contrib/restricted/boost/core/include/boost/core/allocator_access.hpp
@@ -807,14 +807,14 @@ using allocator_rebind_t = typename allocator_rebind<A, T>::type;
} /* boost */
-#if defined(_LIBCPP_SUPPRESS_DEPRECATED_POP)
-_LIBCPP_SUPPRESS_DEPRECATED_POP
+#if defined(_MSC_VER)
+#pragma warning(pop)
#endif
#if defined(_STL_RESTORE_DEPRECATED_WARNING)
_STL_RESTORE_DEPRECATED_WARNING
#endif
-#if defined(_MSC_VER)
-#pragma warning(pop)
+#if defined(_LIBCPP_SUPPRESS_DEPRECATED_POP)
+_LIBCPP_SUPPRESS_DEPRECATED_POP
#endif
#endif
diff --git a/contrib/restricted/boost/core/include/boost/core/detail/is_same.hpp b/contrib/restricted/boost/core/include/boost/core/detail/is_same.hpp
new file mode 100644
index 00000000000..634d300480e
--- /dev/null
+++ b/contrib/restricted/boost/core/include/boost/core/detail/is_same.hpp
@@ -0,0 +1,39 @@
+#ifndef BOOST_CORE_DETAIL_IS_SAME_HPP_INCLUDED
+#define BOOST_CORE_DETAIL_IS_SAME_HPP_INCLUDED
+
+// is_same<T1,T2>::value is true when T1 == T2
+//
+// Copyright 2014 Peter Dimov
+//
+// Distributed under the Boost Software License, Version 1.0.
+// See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt
+
+#include <boost/config.hpp>
+
+#if defined(BOOST_HAS_PRAGMA_ONCE)
+# pragma once
+#endif
+
+namespace boost
+{
+namespace core
+{
+namespace detail
+{
+
+template< class T1, class T2 > struct is_same
+{
+ BOOST_STATIC_CONSTANT( bool, value = false );
+};
+
+template< class T > struct is_same< T, T >
+{
+ BOOST_STATIC_CONSTANT( bool, value = true );
+};
+
+} // namespace detail
+} // namespace core
+} // namespace boost
+
+#endif // #ifndef BOOST_CORE_DETAIL_IS_SAME_HPP_INCLUDED
diff --git a/contrib/restricted/boost/core/include/boost/core/is_same.hpp b/contrib/restricted/boost/core/include/boost/core/is_same.hpp
index f373c654d5e..111cbd18b7f 100644
--- a/contrib/restricted/boost/core/include/boost/core/is_same.hpp
+++ b/contrib/restricted/boost/core/include/boost/core/is_same.hpp
@@ -1,12 +1,6 @@
#ifndef BOOST_CORE_IS_SAME_HPP_INCLUDED
#define BOOST_CORE_IS_SAME_HPP_INCLUDED
-// MS compatible compilers support #pragma once
-
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
-# pragma once
-#endif
-
// is_same<T1,T2>::value is true when T1 == T2
//
// Copyright 2014 Peter Dimov
@@ -16,6 +10,15 @@
// http://www.boost.org/LICENSE_1_0.txt
#include <boost/config.hpp>
+#include <boost/core/detail/is_same.hpp>
+
+#if defined(BOOST_HAS_PRAGMA_ONCE)
+# pragma once
+#endif
+
+#include <boost/config/header_deprecated.hpp>
+
+BOOST_HEADER_DEPRECATED("<boost/type_traits/is_same.hpp>")
namespace boost
{
@@ -23,15 +26,7 @@ namespace boost
namespace core
{
-template< class T1, class T2 > struct is_same
-{
- BOOST_STATIC_CONSTANT( bool, value = false );
-};
-
-template< class T > struct is_same< T, T >
-{
- BOOST_STATIC_CONSTANT( bool, value = true );
-};
+using boost::core::detail::is_same;
} // namespace core
diff --git a/contrib/restricted/boost/core/include/boost/core/ref.hpp b/contrib/restricted/boost/core/include/boost/core/ref.hpp
index a416cbdd344..d29a4d6fb3c 100644
--- a/contrib/restricted/boost/core/include/boost/core/ref.hpp
+++ b/contrib/restricted/boost/core/include/boost/core/ref.hpp
@@ -1,17 +1,15 @@
#ifndef BOOST_CORE_REF_HPP
#define BOOST_CORE_REF_HPP
-// MS compatible compilers support #pragma once
-
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
-# pragma once
-#endif
-
#include <boost/config.hpp>
#include <boost/config/workaround.hpp>
#include <boost/core/addressof.hpp>
#include <boost/core/enable_if.hpp>
+#if defined(BOOST_HAS_PRAGMA_ONCE)
+# pragma once
+#endif
+
//
// ref.hpp - ref/cref, useful helper functions
//
@@ -61,9 +59,11 @@ template< class Y, class T > struct ref_convertible
enum _vt { value = sizeof( (f)( static_cast<Y*>(0) ) ) == sizeof(yes) };
};
+#if defined(BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS)
struct ref_empty
{
};
+#endif
} // namespace detail
@@ -92,11 +92,11 @@ public:
@remark Does not throw.
*/
- BOOST_FORCEINLINE explicit reference_wrapper(T& t): t_(boost::addressof(t)) {}
+ BOOST_FORCEINLINE explicit reference_wrapper(T& t) BOOST_NOEXCEPT : t_(boost::addressof(t)) {}
#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, == 1600 )
- BOOST_FORCEINLINE explicit reference_wrapper( T & t, ref_workaround_tag ): t_( boost::addressof( t ) ) {}
+ BOOST_FORCEINLINE explicit reference_wrapper( T & t, ref_workaround_tag ) BOOST_NOEXCEPT : t_( boost::addressof( t ) ) {}
#endif
@@ -117,30 +117,37 @@ public:
@remark Only enabled when `Y*` is convertible to `T*`.
@remark Does not throw.
*/
+#if !defined(BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS)
+ template<class Y, class = typename enable_if_c<boost::detail::ref_convertible<Y, T>::value>::type>
+ reference_wrapper( reference_wrapper<Y> r ) BOOST_NOEXCEPT : t_( r.t_ )
+ {
+ }
+#else
template<class Y> reference_wrapper( reference_wrapper<Y> r,
typename enable_if_c<boost::detail::ref_convertible<Y, T>::value,
- boost::detail::ref_empty>::type = boost::detail::ref_empty() ): t_( r.t_ )
+ boost::detail::ref_empty>::type = boost::detail::ref_empty() ) BOOST_NOEXCEPT : t_( r.t_ )
{
}
+#endif
/**
@return The stored reference.
@remark Does not throw.
*/
- BOOST_FORCEINLINE operator T& () const { return *t_; }
+ BOOST_FORCEINLINE operator T& () const BOOST_NOEXCEPT { return *t_; }
/**
@return The stored reference.
@remark Does not throw.
*/
- BOOST_FORCEINLINE T& get() const { return *t_; }
+ BOOST_FORCEINLINE T& get() const BOOST_NOEXCEPT { return *t_; }
/**
@return A pointer to the object referenced by the stored
reference.
@remark Does not throw.
*/
- BOOST_FORCEINLINE T* get_pointer() const { return t_; }
+ BOOST_FORCEINLINE T* get_pointer() const BOOST_NOEXCEPT { return t_; }
private:
@@ -165,7 +172,7 @@ private:
@return `reference_wrapper<T>(t)`
@remark Does not throw.
*/
-template<class T> BOOST_FORCEINLINE reference_wrapper<T> BOOST_REF_CONST ref( T & t )
+template<class T> BOOST_FORCEINLINE reference_wrapper<T> BOOST_REF_CONST ref( T & t ) BOOST_NOEXCEPT
{
#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, == 1600 )
@@ -184,7 +191,7 @@ template<class T> BOOST_FORCEINLINE reference_wrapper<T> BOOST_REF_CONST ref( T
@return `reference_wrapper<T const>(t)`
@remark Does not throw.
*/
-template<class T> BOOST_FORCEINLINE reference_wrapper<T const> BOOST_REF_CONST cref( T const & t )
+template<class T> BOOST_FORCEINLINE reference_wrapper<T const> BOOST_REF_CONST cref( T const & t ) BOOST_NOEXCEPT
{
return reference_wrapper<T const>(t);
}
@@ -315,7 +322,7 @@ template<typename T> struct unwrap_reference< reference_wrapper<T> const volatil
@return `unwrap_reference<T>::type&(t)`
@remark Does not throw.
*/
-template<class T> BOOST_FORCEINLINE typename unwrap_reference<T>::type& unwrap_ref( T & t )
+template<class T> BOOST_FORCEINLINE typename unwrap_reference<T>::type& unwrap_ref( T & t ) BOOST_NOEXCEPT
{
return t;
}
@@ -325,7 +332,7 @@ template<class T> BOOST_FORCEINLINE typename unwrap_reference<T>::type& unwrap_r
/**
@cond
*/
-template<class T> BOOST_FORCEINLINE T* get_pointer( reference_wrapper<T> const & r )
+template<class T> BOOST_FORCEINLINE T* get_pointer( reference_wrapper<T> const & r ) BOOST_NOEXCEPT
{
return r.get_pointer();
}
diff --git a/contrib/restricted/boost/core/include/boost/core/swap.hpp b/contrib/restricted/boost/core/include/boost/core/swap.hpp
index 49e1b2dbb6e..7add2fbf8b9 100644
--- a/contrib/restricted/boost/core/include/boost/core/swap.hpp
+++ b/contrib/restricted/boost/core/include/boost/core/swap.hpp
@@ -13,10 +13,10 @@
// - swap_impl is put outside the boost namespace, to avoid infinite
// recursion (causing stack overflow) when swapping objects of a primitive
// type.
-// - swap_impl has a using-directive, rather than a using-declaration,
-// because some compilers (including MSVC 7.1, Borland 5.9.3, and
-// Intel 8.1) don't do argument-dependent lookup when it has a
-// using-declaration instead.
+// - std::swap is imported with a using-directive, rather than
+// a using-declaration, because some compilers (including MSVC 7.1,
+// Borland 5.9.3, and Intel 8.1) don't do argument-dependent lookup
+// when it has a using-declaration instead.
// - boost::swap has two template arguments, instead of one, to
// avoid ambiguity when swapping objects of a Boost type that does
// not have its own boost::swap overload.
@@ -30,6 +30,17 @@
#endif
#include <cstddef> // for std::size_t
+#ifdef BOOST_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
+#if defined(BOOST_GCC) && (BOOST_GCC < 40700)
+// gcc 4.6 ICEs on noexcept specifications below
+#define BOOST_CORE_SWAP_NOEXCEPT_IF(x)
+#else
+#define BOOST_CORE_SWAP_NOEXCEPT_IF(x) BOOST_NOEXCEPT_IF(x)
+#endif
+
namespace boost_swap_impl
{
// we can't use type_traits here
@@ -37,17 +48,22 @@ namespace boost_swap_impl
template<class T> struct is_const { enum _vt { value = 0 }; };
template<class T> struct is_const<T const> { enum _vt { value = 1 }; };
+ // Use std::swap if argument dependent lookup fails.
+ // We need to have this at namespace scope to be able to use unqualified swap() call
+ // in noexcept specification.
+ using namespace std;
+
template<class T>
BOOST_GPU_ENABLED
- void swap_impl(T& left, T& right)
+ void swap_impl(T& left, T& right) BOOST_CORE_SWAP_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(swap(left, right)))
{
- using namespace std;//use std::swap if argument dependent lookup fails
- swap(left,right);
+ swap(left, right);
}
template<class T, std::size_t N>
BOOST_GPU_ENABLED
void swap_impl(T (& left)[N], T (& right)[N])
+ BOOST_CORE_SWAP_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(::boost_swap_impl::swap_impl(left[0], right[0])))
{
for (std::size_t i = 0; i < N; ++i)
{
@@ -62,9 +78,12 @@ namespace boost
BOOST_GPU_ENABLED
typename enable_if_c< !boost_swap_impl::is_const<T1>::value && !boost_swap_impl::is_const<T2>::value >::type
swap(T1& left, T2& right)
+ BOOST_CORE_SWAP_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(::boost_swap_impl::swap_impl(left, right)))
{
::boost_swap_impl::swap_impl(left, right);
}
}
-#endif
+#undef BOOST_CORE_SWAP_NOEXCEPT_IF
+
+#endif // BOOST_CORE_SWAP_HPP