summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbugaevskiy <[email protected]>2022-08-08 10:52:37 +0300
committerbugaevskiy <[email protected]>2022-08-08 10:52:37 +0300
commitba5aa0c93165f068c5f861477a71c945a6041575 (patch)
tree0d3765a3832eaad913a06851f2ec4bf27ace2477
parentc686824a6a211135a990b7b58d4785ecfdd177cf (diff)
Reimport boost/type_index as a separate project
-rw-r--r--CMakeLists.darwin.txt1
-rw-r--r--CMakeLists.linux.txt1
-rw-r--r--contrib/restricted/boost/CMakeLists.txt1
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast.hpp28
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp46
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp57
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/pointer_cast.hpp74
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/reference_cast.hpp66
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/register_runtime_class.hpp138
-rw-r--r--contrib/restricted/boost/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp46
-rw-r--r--contrib/restricted/boost/type_index/CMakeLists.txt26
-rw-r--r--contrib/restricted/boost/type_index/README.md18
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index.hpp (renamed from contrib/restricted/boost/boost/type_index.hpp)0
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/ctti_type_index.hpp (renamed from contrib/restricted/boost/boost/type_index/ctti_type_index.hpp)0
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/detail/compile_time_type_info.hpp (renamed from contrib/restricted/boost/boost/type_index/detail/compile_time_type_info.hpp)0
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/detail/ctti_register_class.hpp (renamed from contrib/restricted/boost/boost/type_index/detail/ctti_register_class.hpp)0
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/detail/stl_register_class.hpp (renamed from contrib/restricted/boost/boost/type_index/detail/stl_register_class.hpp)0
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/stl_type_index.hpp (renamed from contrib/restricted/boost/boost/type_index/stl_type_index.hpp)10
-rw-r--r--contrib/restricted/boost/type_index/include/boost/type_index/type_index_facade.hpp (renamed from contrib/restricted/boost/boost/type_index/type_index_facade.hpp)0
19 files changed, 54 insertions, 458 deletions
diff --git a/CMakeLists.darwin.txt b/CMakeLists.darwin.txt
index 099d8dfe795..63f45e035ca 100644
--- a/CMakeLists.darwin.txt
+++ b/CMakeLists.darwin.txt
@@ -390,6 +390,7 @@ add_subdirectory(contrib/restricted/boost/polygon)
add_subdirectory(contrib/restricted/boost/qvm)
add_subdirectory(contrib/restricted/boost/rational)
add_subdirectory(contrib/restricted/boost/tti)
+add_subdirectory(contrib/restricted/boost/type_index)
add_subdirectory(contrib/restricted/boost/vmd)
add_subdirectory(contrib/restricted/fast_float)
add_subdirectory(contrib/restricted/thrift)
diff --git a/CMakeLists.linux.txt b/CMakeLists.linux.txt
index 2ff850458d6..52bfb623e79 100644
--- a/CMakeLists.linux.txt
+++ b/CMakeLists.linux.txt
@@ -393,6 +393,7 @@ add_subdirectory(contrib/restricted/boost/polygon)
add_subdirectory(contrib/restricted/boost/qvm)
add_subdirectory(contrib/restricted/boost/rational)
add_subdirectory(contrib/restricted/boost/tti)
+add_subdirectory(contrib/restricted/boost/type_index)
add_subdirectory(contrib/restricted/boost/vmd)
add_subdirectory(contrib/restricted/fast_float)
add_subdirectory(contrib/restricted/thrift)
diff --git a/contrib/restricted/boost/CMakeLists.txt b/contrib/restricted/boost/CMakeLists.txt
index 55f55ca2080..d49d324a9e0 100644
--- a/contrib/restricted/boost/CMakeLists.txt
+++ b/contrib/restricted/boost/CMakeLists.txt
@@ -45,6 +45,7 @@ target_link_libraries(contrib-restricted-boost INTERFACE
restricted-boost-throw_exception
restricted-boost-tti
restricted-boost-tuple
+ restricted-boost-type_index
restricted-boost-type_traits
restricted-boost-typeof
restricted-boost-utility
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast.hpp
deleted file mode 100644
index c72b11916b1..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast.hpp
+++ /dev/null
@@ -1,28 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_HPP
-
-/// \file runtime_cast.hpp
-/// \brief Contains the basic utilities necessary to fully emulate
-/// dynamic_cast for language level constructs (raw pointers and references).
-///
-/// boost::typeindex::runtime_cast is a drop in replacement for dynamic_cast
-/// that can be used in situations where traditional rtti is either unavailable
-/// or undesirable.
-
-#include <boost/type_index/runtime_cast/register_runtime_class.hpp>
-#include <boost/type_index/runtime_cast/pointer_cast.hpp>
-#include <boost/type_index/runtime_cast/reference_cast.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp
deleted file mode 100644
index e31f19d7286..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp
+++ /dev/null
@@ -1,46 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_BOOST_SHARED_PTR_CAST_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_BOOST_SHARED_PTR_CAST_HPP
-
-/// \file boost_shared_ptr_cast.hpp
-/// \brief Contains the overload of boost::typeindex::runtime_pointer_cast for
-/// boost::shared_ptr types.
-
-#include <boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp>
-#include <boost/type_traits/is_base_and_derived.hpp>
-#include <boost/smart_ptr/shared_ptr.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-/// \brief Creates a new instance of std::shared_ptr whose stored pointer is obtained from u's
-/// stored pointer using a runtime_cast.
-///
-/// The new shared_ptr will share ownership with u, except that it is empty if the runtime_cast
-/// performed by runtime_pointer_cast returns a null pointer.
-/// \tparam T The desired target type to return a pointer of.
-/// \tparam U A complete class type of the source instance pointed to from u.
-/// \return If there exists a valid conversion from U* to T*, returns a boost::shared_ptr<T>
-/// that points to an address suitably offset from u.
-/// If no such conversion exists, returns boost::shared_ptr<T>();
-template<typename T, typename U>
-boost::shared_ptr<T> runtime_pointer_cast(boost::shared_ptr<U> const& u) {
- T* value = detail::runtime_cast_impl<T>(u.get(), boost::is_base_and_derived<T, U>());
- if(value)
- return boost::shared_ptr<T>(u, value);
- return boost::shared_ptr<T>();
-}
-
-}} // namespace boost::typeindex
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_BOOST_SHARED_PTR_CAST_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp
deleted file mode 100644
index 6181df60f58..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp
+++ /dev/null
@@ -1,57 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_DETAIL_RUNTIME_CAST_IMPL_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_DETAIL_RUNTIME_CAST_IMPL_HPP
-
-/// \file runtime_cast_impl.hpp
-/// \brief Contains the overload of boost::typeindex::runtime_cast for
-/// pointer types.
-///
-/// boost::typeindex::runtime_cast can be used to emulate dynamic_cast
-/// functionality on platorms that don't provide it or should the user
-/// desire opt in functionality instead of enabling it system wide.
-
-#include <boost/type_index.hpp>
-#include <boost/type_traits/integral_constant.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-namespace detail {
-
-template<typename T, typename U>
-T* runtime_cast_impl(U* u, boost::true_type) BOOST_NOEXCEPT {
- return u;
-}
-
-template<typename T, typename U>
-T const* runtime_cast_impl(U const* u, boost::true_type) BOOST_NOEXCEPT {
- return u;
-}
-
-template<typename T, typename U>
-T* runtime_cast_impl(U* u, boost::false_type) BOOST_NOEXCEPT {
- return const_cast<T*>(static_cast<T const*>(
- u->boost_type_index_find_instance_(boost::typeindex::type_id<T>())
- ));
-}
-
-template<typename T, typename U>
-T const* runtime_cast_impl(U const* u, boost::false_type) BOOST_NOEXCEPT {
- return static_cast<T const*>(u->boost_type_index_find_instance_(boost::typeindex::type_id<T>()));
-}
-
-} // namespace detail
-
-}} // namespace boost::typeindex
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_DETAIL_RUNTIME_CAST_IMPL_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/pointer_cast.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/pointer_cast.hpp
deleted file mode 100644
index 49a761390ca..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/pointer_cast.hpp
+++ /dev/null
@@ -1,74 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_POINTER_CAST_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_POINTER_CAST_HPP
-
-/// \file pointer_class.hpp
-/// \brief Contains the function overloads of boost::typeindex::runtime_cast for
-/// pointer types.
-#include <boost/type_index.hpp>
-#include <boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp>
-#include <boost/type_traits/is_base_and_derived.hpp>
-#include <boost/type_traits/remove_pointer.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-/// \brief Safely converts pointers to classes up, down, and sideways along the inheritance hierarchy.
-/// \tparam T The desired target type. Like dynamic_cast, must be a pointer to complete class type.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U* to T, returns a T that points to
-/// an address suitably offset from u. If no such conversion exists, returns NULL.
-template<typename T, typename U>
-T runtime_cast(U* u) BOOST_NOEXCEPT {
- typedef typename boost::remove_pointer<T>::type impl_type;
- return detail::runtime_cast_impl<impl_type>(u, boost::is_base_and_derived<T, U>());
-}
-
-/// \brief Safely converts pointers to classes up, down, and sideways along the inheritance hierarchy.
-/// \tparam T The desired target type. Like dynamic_cast, must be a pointer to complete class type.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U* to T, returns a T that points to
-/// an address suitably offset from u. If no such conversion exists, returns NULL.
-template<typename T, typename U>
-T runtime_cast(U const* u) BOOST_NOEXCEPT {
- typedef typename boost::remove_pointer<T>::type impl_type;
- return detail::runtime_cast_impl<impl_type>(u, boost::is_base_and_derived<T, U>());
-}
-
-/// \brief Safely converts pointers to classes up, down, and sideways along the inheritance
-/// hierarchy.
-/// \tparam T The desired target type to return a pointer to.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U const* to T*, returns a T*
-/// that points to an address suitably offset from u.
-/// If no such conversion exists, returns NULL.
-template<typename T, typename U>
-T* runtime_pointer_cast(U* u) BOOST_NOEXCEPT {
- return detail::runtime_cast_impl<T>(u, boost::is_base_and_derived<T, U>());
-}
-
-/// \brief Safely converts pointers to classes up, down, and sideways along the inheritance
-/// hierarchy.
-/// \tparam T The desired target type to return a pointer to.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U const* to T const*, returns a T const*
-/// that points to an address suitably offset from u.
-/// If no such conversion exists, returns NULL.
-template<typename T, typename U>
-T const* runtime_pointer_cast(U const* u) BOOST_NOEXCEPT {
- return detail::runtime_cast_impl<T>(u, boost::is_base_and_derived<T, U>());
-}
-
-}} // namespace boost::typeindex
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_POINTER_CAST_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/reference_cast.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/reference_cast.hpp
deleted file mode 100644
index 1511f7d0313..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/reference_cast.hpp
+++ /dev/null
@@ -1,66 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_REFERENCE_CAST_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_REFERENCE_CAST_HPP
-
-/// \file reference_cast.hpp
-/// \brief Contains the overload of boost::typeindex::runtime_cast for
-/// reference types.
-
-#include <boost/core/addressof.hpp>
-#include <boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp>
-#include <boost/throw_exception.hpp>
-#include <boost/type_traits/add_reference.hpp>
-#include <boost/type_traits/remove_reference.hpp>
-#include <boost/type_traits/is_base_and_derived.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-/// \brief Indicates that runtime_cast was unable to perform the desired cast operation
-/// because the source instance was not also an instance of the target type.
-struct bad_runtime_cast : std::exception
-{};
-
-/// \brief Safely converts references to classes up, down, and sideways along the inheritance hierarchy.
-/// \tparam T The desired target type. Like dynamic_cast, must be a pointer to complete class type.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U& to T, returns a T that references an address
-/// suitably offset from u. If no such conversion exists, throws boost::typeindex::bad_runtime_cast.
-template<typename T, typename U>
-typename boost::add_reference<T>::type runtime_cast(U& u) {
- typedef typename boost::remove_reference<T>::type impl_type;
- impl_type* value = detail::runtime_cast_impl<impl_type>(
- boost::addressof(u), boost::is_base_and_derived<T, U>());
- if(!value)
- BOOST_THROW_EXCEPTION(bad_runtime_cast());
- return *value;
-}
-
-/// \brief Safely converts references to classes up, down, and sideways along the inheritance hierarchy.
-/// \tparam T The desired target type. Like dynamic_cast, must be a pointer to complete class type.
-/// \tparam U A complete class type of the source instance, u.
-/// \return If there exists a valid conversion from U const& to T const, returns a T const that references an address
-/// suitably offset from u. If no such conversion exists, throws boost::typeindex::bad_runtime_cast.
-template<typename T, typename U>
-typename boost::add_reference<const T>::type runtime_cast(U const& u) {
- typedef typename boost::remove_reference<T>::type impl_type;
- impl_type* value = detail::runtime_cast_impl<impl_type>(
- boost::addressof(u), boost::is_base_and_derived<T, U>());
- if(!value)
- BOOST_THROW_EXCEPTION(bad_runtime_cast());
- return *value;
-}
-
-}} // namespace boost::typeindex
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_REFERENCE_CAST_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/register_runtime_class.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/register_runtime_class.hpp
deleted file mode 100644
index 995007487bd..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/register_runtime_class.hpp
+++ /dev/null
@@ -1,138 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_REGISTER_RUNTIME_CLASS_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_REGISTER_RUNTIME_CLASS_HPP
-
-/// \file register_runtime_class.hpp
-/// \brief Contains the macros BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST and
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS
-#include <boost/type_index.hpp>
-#include <boost/preprocessor/seq/for_each.hpp>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-namespace detail {
-
-template<typename T>
-inline type_index runtime_class_construct_type_id(T const*) {
- return type_id<T>();
-}
-
-} // namespace detail
-
-}} // namespace boost::typeindex
-
-/// @cond
-
-#define BOOST_TYPE_INDEX_CHECK_BASE_(r, data, Base) \
- if(void const* ret_val = this->Base::boost_type_index_find_instance_(idx)) return ret_val;
-
-/// @endcond
-
-/// \def BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS
-/// \brief Macro used to make a class compatible with boost::typeindex::runtime_cast
-///
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS generates a virtual function
-/// in the current class that, when combined with the supplied base class information, allows
-/// boost::typeindex::runtime_cast to accurately convert between dynamic types of instances of
-/// the current class.
-///
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS also adds support for boost::typeindex::type_id_runtime
-/// by including BOOST_TYPE_INDEX_REGISTER_CLASS. It is typical that these features are used together,
-/// but in the event that BOOST_TYPE_INDEX_REGISTER_CLASS is undesirable in the current class,
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST is provided.
-///
-/// \b Example:
-/// \code
-/// struct base1 {
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS(BOOST_TYPE_INDEX_NO_BASE_CLASS)
-/// virtual ~base1();
-/// };
-///
-/// struct base2 {
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS(BOOST_TYPE_INDEX_NO_BASE_CLASS)
-/// virtual ~base2();
-/// };
-///
-/// struct derived1 : base1 {
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS((base1))
-/// };
-///
-/// struct derived2 : base1, base2 {
-/// BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS((base1)(base2))
-/// };
-///
-/// ...
-///
-/// base1* pb1 = get_object();
-/// if(derived2* pb2 = boost::typeindex::runtime_cast<derived2*>(pb1)) {
-/// assert(boost::typeindex::type_id_runtime(*pb1)) == boost::typeindex::type_id<derived2>());
-/// }
-/// \endcode
-///
-/// \param base_class_seq A Boost.Preprocessor sequence of the current class' direct bases, or
-/// BOOST_TYPE_INDEX_NO_BASE_CLASS if this class has no direct base classes.
-#define BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS(base_class_seq) \
- BOOST_TYPE_INDEX_REGISTER_CLASS \
- BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST(base_class_seq)
-
-/// \def BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST
-/// \brief Macro used to make a class compatible with boost::typeindex::runtime_cast without including
-/// support for boost::typeindex::type_id_runtime.
-///
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST is provided as an alternative to BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS
-/// in the event that support for boost::typeindex::type_id_runtime is undesirable.
-///
-/// \b Example:
-/// \code
-/// struct base1 {
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST(BOOST_TYPE_INDEX_NO_BASE_CLASS)
-/// virtual ~base1();
-/// };
-///
-/// struct base2 {
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST(BOOST_TYPE_INDEX_NO_BASE_CLASS)
-/// virtual ~base2();
-/// };
-///
-/// struct derived1 : base1 {
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST((base1))
-/// };
-///
-/// struct derived2 : base1, base2 {
-/// BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST((base1)(base2))
-/// };
-///
-/// ...
-///
-/// base1* pb1 = get_object();
-/// if(derived2* pb2 = boost::typeindex::runtime_cast<derived2*>(pb1))
-/// { /* can't call boost::typeindex::type_id_runtime(*pb1) here */ }
-/// \endcode
-///
-/// \param base_class_seq A Boost.Preprocessor sequence of the current class' direct bases, or
-/// BOOST_TYPE_INDEX_NO_BASE_CLASS if this class has no direct base classes.
-#define BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST(base_class_seq) \
- virtual void const* boost_type_index_find_instance_(boost::typeindex::type_index const& idx) const BOOST_NOEXCEPT { \
- if(idx == boost::typeindex::detail::runtime_class_construct_type_id(this)) \
- return this; \
- BOOST_PP_SEQ_FOR_EACH(BOOST_TYPE_INDEX_CHECK_BASE_, _, base_class_seq) \
- return NULL; \
- }
-
-/// \def BOOST_TYPE_INDEX_NO_BASE_CLASS
-/// \brief Instructs BOOST_TYPE_INDEX_REGISTER_RUNTIME_CLASS and BOOST_TYPE_INDEX_IMPLEMENT_RUNTIME_CAST
-/// that this class has no base classes.
-#define BOOST_TYPE_INDEX_NO_BASE_CLASS BOOST_PP_SEQ_NIL
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_REGISTER_RUNTIME_CLASS_HPP
diff --git a/contrib/restricted/boost/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp b/contrib/restricted/boost/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp
deleted file mode 100644
index 277a5242600..00000000000
--- a/contrib/restricted/boost/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp
+++ /dev/null
@@ -1,46 +0,0 @@
-//
-// Copyright (c) Chris Glover, 2016.
-//
-//
-// 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)
-//
-
-#ifndef BOOST_TYPE_INDEX_RUNTIME_CAST_STD_SHARED_PTR_CAST_HPP
-#define BOOST_TYPE_INDEX_RUNTIME_CAST_STD_SHARED_PTR_CAST_HPP
-
-/// \file std_shared_ptr_cast.hpp
-/// \brief Contains the overload of boost::typeindex::runtime_pointer_cast for
-/// std::shared_ptr types.
-
-#include <boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp>
-#include <boost/type_traits/is_base_and_derived.hpp>
-#include <memory>
-
-#ifdef BOOST_HAS_PRAGMA_ONCE
-# pragma once
-#endif
-
-namespace boost { namespace typeindex {
-
-/// \brief Creates a new instance of std::shared_ptr whose stored pointer is obtained from u's
-/// stored pointer using a runtime_cast.
-///
-/// The new shared_ptr will share ownership with u, except that it is empty if the runtime_cast
-/// performed by runtime_pointer_cast returns a null pointer.
-/// \tparam T The desired target type to return a pointer of.
-/// \tparam U A complete class type of the source instance pointed to from u.
-/// \return If there exists a valid conversion from U* to T*, returns a std::shared_ptr<T>
-/// that points to an address suitably offset from u.
-/// If no such conversion exists, returns std::shared_ptr<T>();
-template<typename T, typename U>
-std::shared_ptr<T> runtime_pointer_cast(std::shared_ptr<U> const& u) {
- T* value = detail::runtime_cast_impl<T>(u.get(), boost::is_base_and_derived<T, U>());
- if(value)
- return std::shared_ptr<T>(u, value);
- return std::shared_ptr<T>();
-}
-
-}} // namespace boost::typeindex
-
-#endif // BOOST_TYPE_INDEX_RUNTIME_CAST_STD_SHARED_PTR_CAST_HPP
diff --git a/contrib/restricted/boost/type_index/CMakeLists.txt b/contrib/restricted/boost/type_index/CMakeLists.txt
new file mode 100644
index 00000000000..5a8d3251ebd
--- /dev/null
+++ b/contrib/restricted/boost/type_index/CMakeLists.txt
@@ -0,0 +1,26 @@
+
+# This file was gererated by the build system used internally in the Yandex monorepo.
+# Only simple modifications are allowed (adding source-files to targets, adding simple properties
+# like target_include_directories). These modifications will be ported to original
+# ya.make files by maintainers. Any complex modifications which can't be ported back to the
+# original buildsystem will not be accepted.
+
+
+
+add_library(restricted-boost-type_index INTERFACE)
+target_include_directories(restricted-boost-type_index INTERFACE
+ ${CMAKE_SOURCE_DIR}/contrib/restricted/boost/type_index/include
+)
+target_link_libraries(restricted-boost-type_index INTERFACE
+ contrib-libs-cxxsupp
+ yutil
+ restricted-boost-config
+ restricted-boost-container_hash
+ restricted-boost-core
+ restricted-boost-mpl
+ restricted-boost-preprocessor
+ restricted-boost-smart_ptr
+ restricted-boost-static_assert
+ restricted-boost-throw_exception
+ restricted-boost-type_traits
+)
diff --git a/contrib/restricted/boost/type_index/README.md b/contrib/restricted/boost/type_index/README.md
new file mode 100644
index 00000000000..19db50381a4
--- /dev/null
+++ b/contrib/restricted/boost/type_index/README.md
@@ -0,0 +1,18 @@
+# [Boost.TypeIndex](http://boost.org/libs/type_index)
+Boost.TypeIndex is a part of the [Boost C++ Libraries](http://github.com/boostorg). It is a runtime/compile time copyable type info.
+
+### Test results
+
+@ | Build | Tests coverage | More info
+----------------|-------------- | -------------- |-----------
+Develop branch: | [![Build Status](https://travis-ci.org/apolukhin/type_index.svg?branch=develop)](https://travis-ci.org/apolukhin/type_index) [![Build status](https://ci.appveyor.com/api/projects/status/197a5imq10dqx6r8/branch/develop?svg=true)](https://ci.appveyor.com/project/apolukhin/type-index/branch/develop) | [![Coverage Status](https://coveralls.io/repos/apolukhin/type_index/badge.png?branch=develop)](https://coveralls.io/r/apolukhin/type_index?branch=develop) | [details...](http://www.boost.org/development/tests/develop/developer/type_index.html)
+Master branch: | [![Build Status](https://travis-ci.org/apolukhin/type_index.svg?branch=master)](https://travis-ci.org/apolukhin/type_index) [![Build status](https://ci.appveyor.com/api/projects/status/197a5imq10dqx6r8/branch/master?svg=true)](https://ci.appveyor.com/project/apolukhin/type-index/branch/master) | [![Coverage Status](https://coveralls.io/repos/apolukhin/type_index/badge.png?branch=master)](https://coveralls.io/r/apolukhin/type_index?branch=master) | [details...](http://www.boost.org/development/tests/master/developer/type_index.html)
+
+
+[Open Issues](https://svn.boost.org/trac/boost/query?status=!closed&component=type_index)
+
+[Latest developer documentation](http://boostorg.github.com/type_index/index.html)
+
+### License
+
+Distributed under the [Boost Software License, Version 1.0](http://boost.org/LICENSE_1_0.txt).
diff --git a/contrib/restricted/boost/boost/type_index.hpp b/contrib/restricted/boost/type_index/include/boost/type_index.hpp
index 5311ac87956..5311ac87956 100644
--- a/contrib/restricted/boost/boost/type_index.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index.hpp
diff --git a/contrib/restricted/boost/boost/type_index/ctti_type_index.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/ctti_type_index.hpp
index a59b2d80a7f..a59b2d80a7f 100644
--- a/contrib/restricted/boost/boost/type_index/ctti_type_index.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/ctti_type_index.hpp
diff --git a/contrib/restricted/boost/boost/type_index/detail/compile_time_type_info.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/detail/compile_time_type_info.hpp
index 4eb2017ffc2..4eb2017ffc2 100644
--- a/contrib/restricted/boost/boost/type_index/detail/compile_time_type_info.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/detail/compile_time_type_info.hpp
diff --git a/contrib/restricted/boost/boost/type_index/detail/ctti_register_class.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/detail/ctti_register_class.hpp
index a8cef2c4972..a8cef2c4972 100644
--- a/contrib/restricted/boost/boost/type_index/detail/ctti_register_class.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/detail/ctti_register_class.hpp
diff --git a/contrib/restricted/boost/boost/type_index/detail/stl_register_class.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/detail/stl_register_class.hpp
index 95a26f7b0ee..95a26f7b0ee 100644
--- a/contrib/restricted/boost/boost/type_index/detail/stl_register_class.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/detail/stl_register_class.hpp
diff --git a/contrib/restricted/boost/boost/type_index/stl_type_index.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/stl_type_index.hpp
index 17177fd2aa9..3a9834d6854 100644
--- a/contrib/restricted/boost/boost/type_index/stl_type_index.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/stl_type_index.hpp
@@ -12,7 +12,7 @@
/// \file stl_type_index.hpp
/// \brief Contains boost::typeindex::stl_type_index class.
///
-/// boost::typeindex::stl_type_index class can be used as a drop-in replacement
+/// boost::typeindex::stl_type_index class can be used as a drop-in replacement
/// for std::type_index.
///
/// It is used in situations when RTTI is enabled or typeid() method is available.
@@ -62,13 +62,13 @@ namespace boost { namespace typeindex {
/// This class requires typeid() to work. For cases when RTTI is disabled see ctti_type_index.
class stl_type_index
: public type_index_facade<
- stl_type_index,
+ stl_type_index,
#ifdef BOOST_NO_STD_TYPEINFO
type_info
#else
std::type_info
#endif
- >
+ >
{
public:
#ifdef BOOST_NO_STD_TYPEINFO
@@ -115,7 +115,11 @@ inline const stl_type_index::type_info_t& stl_type_index::type_info() const BOOS
inline const char* stl_type_index::raw_name() const BOOST_NOEXCEPT {
+#ifdef _MSC_VER
+ return data_->raw_name();
+#else
return data_->name();
+#endif
}
inline const char* stl_type_index::name() const BOOST_NOEXCEPT {
diff --git a/contrib/restricted/boost/boost/type_index/type_index_facade.hpp b/contrib/restricted/boost/type_index/include/boost/type_index/type_index_facade.hpp
index e6dde8f3f98..e6dde8f3f98 100644
--- a/contrib/restricted/boost/boost/type_index/type_index_facade.hpp
+++ b/contrib/restricted/boost/type_index/include/boost/type_index/type_index_facade.hpp