diff --git a/CMakeModules/FindPythia8.cmake b/CMakeModules/FindPythia8.cmake index 8d8612f34fe3b59c58bb38c30ca76386582aebf3..8248388e445da6510db6f34ed1f760cc9506fec6 100644 --- a/CMakeModules/FindPythia8.cmake +++ b/CMakeModules/FindPythia8.cmake @@ -13,7 +13,7 @@ # run pythia8-config and interpret result # -function (_Pythia8_CONFIG_ option variable type doc) +function (Pythia8_CONFIG_ option variable type doc) execute_process(COMMAND ${Pythia8_CONFIG} ${option} OUTPUT_VARIABLE _local_out_ RESULT_VARIABLE _local_res_) @@ -23,7 +23,7 @@ function (_Pythia8_CONFIG_ option variable type doc) else () set (${variable} "${_local_out_}" CACHE ${type} ${doc}) endif () -endfunction (_Pythia8_CONFIG_) +endfunction (Pythia8_CONFIG_) @@ -33,10 +33,11 @@ endfunction (_Pythia8_CONFIG_) # # This module defines # Pythia8_INCLUDE_DIR where to locate Pythia.h file -# Pythia8_LIBRARIES (not cached) the libraries to link against to use Pythia8 +# Pythia8_LIBRARY (not cached) the libraries to link against to use Pythia8 +# Pythia8_VERSION # -set (_SEARCH_Pythia8_ +set (SEARCH_Pythia8_ ${PYTHIA8_DIR} $ENV{PYTHIA8_DIR} ${PYTHIA8} @@ -49,37 +50,43 @@ set (_SEARCH_Pythia8_ find_program (Pythia8_CONFIG NAME pythia8-config - PATHS ${_SEARCH_PYTHIA8_} + PATHS ${SEARCH_Pythia8_} PATH_SUFFIXES "/bin" DOC "The location of the pythia8-config script") if (Pythia8_CONFIG) set (HAVE_Pythia8 1 CACHE BOOL "presence of pythia8, found via pythia8-config") - - _Pythia8_CONFIG_ ("--includedir" Pythia8_INCLUDE_DIR PATH "pythia8 include directory") - _Pythia8_CONFIG_ ("--libdir" Pythia8_LIBRARY_DIR PATH "pythia8 lib directory") -else() + Pythia8_CONFIG_ ("--includedir" Pythia8_INCLUDE_DIR PATH "pythia8 include directory") + Pythia8_CONFIG_ ("--prefix" Pythia8_PREFIX PATH "pythia8 prefix directory") + find_library (Pythia8_LIBRARY NAMES "libpythia8.a" "libpythia8.so" PATH_SUFFIXES "lib" PATHS ${Pythia8_PREFIX} NO_DEFAULT_PATH DOC "pythia8 library") + set (Pythia8_VERSION "n/a") +else () + set (HAVE_Pythia8 1 CACHE BOOL "presence of pythia8, found via include/lib") # if we get here, pythia8-config was not found by CMake so we use # CMake to try and find Pythia8 for us (but let the user know first). # We set these variables to exactly match the format of pythia8-config. # If any one of the variables is not found, CMake will automatically report # that Pythia8 is NOT FOUND (which is what we want). - message(WARNING - "pythia8-config was not found. Attempting to manually locate Pythia8...") + message ("pythia8-config was not found. Attempting to manually locate Pythia8...") # find the main header - find_path(Pythia8_INCLUDE_DIR "Pythia8/Pythia.h") + find_path (Pythia8_INCLUDE_DIR NAME "Pythia8/Pythia.h" PATH_SUFFIXES "include" PATHS ${SEARCH_Pythia8_}) # and find the main library - find_library(Pythia8_LIBRARY_DIR "libpythia8.so") + find_library (Pythia8_LIBRARY NAMES "libpythia8.a" "libpythia8.so" PATH_SUFFIXES "lib" PATHS ${SEARCH_Pythia8_}) +endif () - # and set our best guess - message("Found Pythia.h in ${Pythia8_INCLUDE_DIR}") - message("Found libpythia8.so at ${Pythia8_LIBRARY_DIR}") +# also determine Pythia8 detailed version number +if (EXISTS "${Pythia8_INCLUDE_DIR}/Pythia8/Pythia.h") + file (READ "${Pythia8_INCLUDE_DIR}/Pythia8/Pythia.h" PYTHIA_H_DATA) + string (REGEX MATCH "#define PYTHIA_VERSION_INTEGER ([0-9]*)" test "${PYTHIA_H_DATA}") + set (Pythia8_VERSION ${CMAKE_MATCH_1}) endif () # standard cmake infrastructure: include (FindPackageHandleStandardArgs) -find_package_handle_standard_args (Pythia8 DEFAULT_MSG Pythia8_CONFIG) -mark_as_advanced (Pythia8_INCLUDE_DIR Pythia8_LIBRARY_DIR) +find_package_handle_standard_args (Pythia8 + "Did not find system-level Pythia8. Switching to CORSIKA version." + Pythia8_INCLUDE_DIR Pythia8_LIBRARY Pythia8_VERSION) +mark_as_advanced (Pythia8_INCLUDE_DIR Pythia8_LIBRARY Pythia8_VERSION) diff --git a/Processes/CMakeLists.txt b/Processes/CMakeLists.txt index d9083f29920de52f0391ed39f25d2b904ea15a98..d9c8d628ef5ea85a45ae6c721b489c28eb3a093c 100644 --- a/Processes/CMakeLists.txt +++ b/Processes/CMakeLists.txt @@ -5,9 +5,9 @@ add_subdirectory (TrackingLine) # hadron interaction models add_subdirectory (Sibyll) add_subdirectory (QGSJetII) -if (PYTHIA8_FOUND) +if (Pythia8_FOUND) add_subdirectory (Pythia) -endif (PYTHIA8_FOUND) +endif (Pythia8_FOUND) add_subdirectory (HadronicElasticModel) add_subdirectory (UrQMD) @@ -31,9 +31,9 @@ add_subdirectory (SwitchProcess) add_library (CORSIKAprocesses INTERFACE) add_dependencies(CORSIKAprocesses ProcessNullModel) add_dependencies(CORSIKAprocesses ProcessSibyll) -if (PYTHIA8_FOUND) +if (Pythia8_FOUND) add_dependencies(CORSIKAprocesses ProcessPythia) -endif (PYTHIA8_FOUND) +endif (Pythia8_FOUND) add_dependencies(CORSIKAprocesses ProcessStackInspector) add_dependencies(CORSIKAprocesses ProcessTrackingLine) add_dependencies(CORSIKAprocesses ProcessEnergyLoss) diff --git a/ThirdParty/CMakeLists.txt b/ThirdParty/CMakeLists.txt index e2b4d06dfde83fdd6ceb9add90ed23cea0e264b0..e3cd96354a0b212a81cffbb9296e41dd7a646fcb 100644 --- a/ThirdParty/CMakeLists.txt +++ b/ThirdParty/CMakeLists.txt @@ -1,4 +1,3 @@ - include(ExternalProject) add_library (CORSIKAthirdparty INTERFACE) @@ -16,11 +15,11 @@ install (DIRECTORY catch2 DESTINATION include/ThirdParty/) add_library (CORSIKAboost INTERFACE IMPORTED GLOBAL) if (NOT Boost_FOUND) - set (_C8_Boost_VERSION "107000") + set (_C8_Boost_VERSION "107300") message ("Building ThirdParty/boost using boost-${_C8_Boost_VERSION}.tar.bz2") ExternalProject_Add (boost URL ${CMAKE_CURRENT_SOURCE_DIR}/boost-${_C8_Boost_VERSION}.tar.bz2 - URL_MD5 8ffed5895a851894ad866888d4e64685 + URL_MD5 895e35757f133f01c451fc93229aae6b SOURCE_DIR ${CMAKE_CURRENT_BINARY_DIR}/boost/install/boost INSTALL_DIR ${CMAKE_CURRENT_BINARY_DIR}/boost/install/boost CONFIGURE_COMMAND "" @@ -109,7 +108,8 @@ if (NOT Pythia8_FOUND) message ("This will take a bit.....") ExternalProject_Add (pythia8 URL ${CMAKE_CURRENT_SOURCE_DIR}/pythia${_C8_Pythia8_VERSION}-stripped.tar.bz2 - URL_MD5 53e1b5925a53875dedcf4ff2e3ba4cb9 + URL_MD5 83132880c0594b808bd7fd37fb642606 + SOURCE_DIR ${CMAKE_CURRENT_BINARY_DIR}/pythia8/source INSTALL_DIR ${CMAKE_CURRENT_BINARY_DIR}/pythia8/install CONFIGURE_COMMAND ./configure --cxx-common=-Wno-deprecated-copy --prefix=${CMAKE_CURRENT_BINARY_DIR}/pythia8/install BUILD_IN_SOURCE ON @@ -121,7 +121,7 @@ if (NOT Pythia8_FOUND) set (Pythia8_VERSION ${_C8_Pythia8_VERSION} CACHE STRING "Version of Pythia8") set (Pythia8_PREFIX ${INSTALL_DIR}) set (Pythia8_INCLUDE_DIR ${Pythia8_PREFIX}/include) - set (Pythia8_LIBRARY_DIR ${Pythia8_PREFIX}/lib) + set (Pythia8_LIBRARY ${Pythia8_PREFIX}/lib/libpythia8.a) add_dependencies (CORSIKAPythia8 pythia8) # create include directory at config time @@ -132,7 +132,7 @@ if (NOT Pythia8_FOUND) set_target_properties ( CORSIKAPythia8 PROPERTIES - IMPORTED_LOCATION ${Pythia8_LIBRARY_DIR}/libpythia8.a + IMPORTED_LOCATION ${Pythia8_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES dl INTERFACE_INCLUDE_DIRECTORIES $<BUILD_INTERFACE:${Pythia8_INCLUDE_DIR}> @@ -143,7 +143,7 @@ else (NOT Pythia8_FOUND) message ("Using Pythia8 Version ${Pythia8_VERSION}") set_target_properties ( CORSIKAPythia8 PROPERTIES - IMPORTED_LOCATION ${Pythia8_LIBRARY_DIR}/libpythia8.a + IMPORTED_LOCATION ${Pythia8_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES dl INTERFACE_INCLUDE_DIRECTORIES ${Pythia8_INCLUDE_DIR} ) diff --git a/ThirdParty/ThirdParty.dox b/ThirdParty/ThirdParty.dox index 7db1a1513de18d77dac8e67f8adceef7e3472819..887e03e98fab64582147c07a4388f9f7eededee0 100644 --- a/ThirdParty/ThirdParty.dox +++ b/ThirdParty/ThirdParty.dox @@ -61,4 +61,10 @@ Run these commands: ./dist/bin/bcp mp11 iterator core format interval optional type_index histogram ./dist mv ./dist/boost <CORSIKA-path>/ThirdParty/boost +@section Pythia8 + +There is a tar file provided with a default version of Pythia8. Some +files have been removed from this with respect to the original +distribution to save space. + */ diff --git a/ThirdParty/boost-107000.tar.bz2 b/ThirdParty/boost-107000.tar.bz2 deleted file mode 100644 index 1f7b46f13bb2e430407a24abf0a52e3cf698a283..0000000000000000000000000000000000000000 Binary files a/ThirdParty/boost-107000.tar.bz2 and /dev/null differ diff --git a/ThirdParty/boost-107300.tar.bz2 b/ThirdParty/boost-107300.tar.bz2 new file mode 100644 index 0000000000000000000000000000000000000000..b57363d93398d865b290130be2dcdfbc86d8122a Binary files /dev/null and b/ThirdParty/boost-107300.tar.bz2 differ diff --git a/ThirdParty/boost/algorithm/cxx11/all_of.hpp b/ThirdParty/boost/algorithm/cxx11/all_of.hpp deleted file mode 100644 index f7ee311b28e7f4648e25ec2d5de59f26314ab7f5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/algorithm/cxx11/all_of.hpp +++ /dev/null @@ -1,84 +0,0 @@ -/* - Copyright (c) Marshall Clow 2008-2012. - - 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) -*/ - -/// \file all_of.hpp -/// \brief Test ranges to see if all elements match a value or predicate. -/// \author Marshall Clow - -#ifndef BOOST_ALGORITHM_ALL_OF_HPP -#define BOOST_ALGORITHM_ALL_OF_HPP - -#include <boost/config.hpp> -#include <boost/range/begin.hpp> -#include <boost/range/end.hpp> - -namespace boost { namespace algorithm { - -/// \fn all_of ( InputIterator first, InputIterator last, Predicate p ) -/// \return true if all elements in [first, last) satisfy the predicate 'p' -/// \note returns true on an empty range -/// -/// \param first The start of the input sequence -/// \param last One past the end of the input sequence -/// \param p A predicate for testing the elements of the sequence -/// -/// \note This function is part of the C++2011 standard library. -template<typename InputIterator, typename Predicate> -BOOST_CXX14_CONSTEXPR bool all_of ( InputIterator first, InputIterator last, Predicate p ) -{ - for ( ; first != last; ++first ) - if ( !p(*first)) - return false; - return true; -} - -/// \fn all_of ( const Range &r, Predicate p ) -/// \return true if all elements in the range satisfy the predicate 'p' -/// \note returns true on an empty range -/// -/// \param r The input range -/// \param p A predicate for testing the elements of the range -/// -template<typename Range, typename Predicate> -BOOST_CXX14_CONSTEXPR bool all_of ( const Range &r, Predicate p ) -{ - return boost::algorithm::all_of ( boost::begin (r), boost::end (r), p ); -} - -/// \fn all_of_equal ( InputIterator first, InputIterator last, const T &val ) -/// \return true if all elements in [first, last) are equal to 'val' -/// \note returns true on an empty range -/// -/// \param first The start of the input sequence -/// \param last One past the end of the input sequence -/// \param val A value to compare against -/// -template<typename InputIterator, typename T> -BOOST_CXX14_CONSTEXPR bool all_of_equal ( InputIterator first, InputIterator last, const T &val ) -{ - for ( ; first != last; ++first ) - if ( val != *first ) - return false; - return true; -} - -/// \fn all_of_equal ( const Range &r, const T &val ) -/// \return true if all elements in the range are equal to 'val' -/// \note returns true on an empty range -/// -/// \param r The input range -/// \param val A value to compare against -/// -template<typename Range, typename T> -BOOST_CXX14_CONSTEXPR bool all_of_equal ( const Range &r, const T &val ) -{ - return boost::algorithm::all_of_equal ( boost::begin (r), boost::end (r), val ); -} - -}} // namespace boost and algorithm - -#endif // BOOST_ALGORITHM_ALL_OF_HPP diff --git a/ThirdParty/boost/algorithm/string/iter_find.hpp b/ThirdParty/boost/algorithm/string/iter_find.hpp deleted file mode 100644 index d76a819896e8cdc735203efca6621f6c31fde68d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/algorithm/string/iter_find.hpp +++ /dev/null @@ -1,201 +0,0 @@ -// Boost string_algo library iter_find.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// 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) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_ITER_FIND_HPP -#define BOOST_STRING_ITER_FIND_HPP - -#include <boost/algorithm/string/config.hpp> -#include <algorithm> -#include <iterator> -#include <boost/iterator/transform_iterator.hpp> - -#include <boost/range/iterator_range_core.hpp> -#include <boost/range/begin.hpp> -#include <boost/range/end.hpp> -#include <boost/range/iterator.hpp> -#include <boost/range/value_type.hpp> -#include <boost/range/as_literal.hpp> - -#include <boost/algorithm/string/concept.hpp> -#include <boost/algorithm/string/find_iterator.hpp> -#include <boost/algorithm/string/detail/util.hpp> - -/*! \file - Defines generic split algorithms. Split algorithms can be - used to divide a sequence into several part according - to a given criteria. Result is given as a 'container - of containers' where elements are copies or references - to extracted parts. - - There are two algorithms provided. One iterates over matching - substrings, the other one over the gaps between these matches. -*/ - -namespace boost { - namespace algorithm { - -// iterate find ---------------------------------------------------// - - //! Iter find algorithm - /*! - This algorithm executes a given finder in iteration on the input, - until the end of input is reached, or no match is found. - Iteration is done using built-in find_iterator, so the real - searching is performed only when needed. - In each iteration new match is found and added to the result. - - \param Result A 'container container' to contain the result of search. - Both outer and inner container must have constructor taking a pair - of iterators as an argument. - Typical type of the result is - \c std::vector<boost::iterator_range<iterator>> - (each element of such a vector will container a range delimiting - a match). - \param Input A container which will be searched. - \param Finder A Finder object used for searching - \return A reference to the result - - \note Prior content of the result will be overwritten. - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename FinderT > - inline SequenceSequenceT& - iter_find( - SequenceSequenceT& Result, -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - RangeT&& Input, -#else - RangeT& Input, -#endif - FinderT Finder ) - { - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_iterator<RangeT>::type> - )); - - iterator_range<BOOST_STRING_TYPENAME range_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); - - typedef BOOST_STRING_TYPENAME - range_iterator<RangeT>::type input_iterator_type; - typedef find_iterator<input_iterator_type> find_iterator_type; - typedef detail::copy_iterator_rangeF< - BOOST_STRING_TYPENAME - range_value<SequenceSequenceT>::type, - input_iterator_type> copy_range_type; - - input_iterator_type InputEnd=::boost::end(lit_input); - - typedef transform_iterator<copy_range_type, find_iterator_type> - transform_iter_type; - - transform_iter_type itBegin= - ::boost::make_transform_iterator( - find_iterator_type( ::boost::begin(lit_input), InputEnd, Finder ), - copy_range_type()); - - transform_iter_type itEnd= - ::boost::make_transform_iterator( - find_iterator_type(), - copy_range_type()); - - SequenceSequenceT Tmp(itBegin, itEnd); - - Result.swap(Tmp); - return Result; - } - -// iterate split ---------------------------------------------------// - - //! Split find algorithm - /*! - This algorithm executes a given finder in iteration on the input, - until the end of input is reached, or no match is found. - Iteration is done using built-in find_iterator, so the real - searching is performed only when needed. - Each match is used as a separator of segments. These segments are then - returned in the result. - - \param Result A 'container container' to contain the result of search. - Both outer and inner container must have constructor taking a pair - of iterators as an argument. - Typical type of the result is - \c std::vector<boost::iterator_range<iterator>> - (each element of such a vector will container a range delimiting - a match). - \param Input A container which will be searched. - \param Finder A finder object used for searching - \return A reference to the result - - \note Prior content of the result will be overwritten. - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename FinderT > - inline SequenceSequenceT& - iter_split( - SequenceSequenceT& Result, -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - RangeT&& Input, -#else - RangeT& Input, -#endif - FinderT Finder ) - { - BOOST_CONCEPT_ASSERT(( - FinderConcept<FinderT, - BOOST_STRING_TYPENAME range_iterator<RangeT>::type> - )); - - iterator_range<BOOST_STRING_TYPENAME range_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); - - typedef BOOST_STRING_TYPENAME - range_iterator<RangeT>::type input_iterator_type; - typedef split_iterator<input_iterator_type> find_iterator_type; - typedef detail::copy_iterator_rangeF< - BOOST_STRING_TYPENAME - range_value<SequenceSequenceT>::type, - input_iterator_type> copy_range_type; - - input_iterator_type InputEnd=::boost::end(lit_input); - - typedef transform_iterator<copy_range_type, find_iterator_type> - transform_iter_type; - - transform_iter_type itBegin= - ::boost::make_transform_iterator( - find_iterator_type( ::boost::begin(lit_input), InputEnd, Finder ), - copy_range_type() ); - - transform_iter_type itEnd= - ::boost::make_transform_iterator( - find_iterator_type(), - copy_range_type() ); - - SequenceSequenceT Tmp(itBegin, itEnd); - - Result.swap(Tmp); - return Result; - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::iter_find; - using algorithm::iter_split; - -} // namespace boost - - -#endif // BOOST_STRING_ITER_FIND_HPP diff --git a/ThirdParty/boost/algorithm/string/split.hpp b/ThirdParty/boost/algorithm/string/split.hpp deleted file mode 100644 index e0b30fb35349eeb4aea4cebe7b529afbff648a9a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/algorithm/string/split.hpp +++ /dev/null @@ -1,175 +0,0 @@ -// Boost string_algo library split.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// 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) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_SPLIT_HPP -#define BOOST_STRING_SPLIT_HPP - -#include <boost/algorithm/string/config.hpp> - -#include <boost/algorithm/string/iter_find.hpp> -#include <boost/algorithm/string/finder.hpp> -#include <boost/algorithm/string/compare.hpp> - -/*! \file - Defines basic split algorithms. - Split algorithms can be used to divide a string - into several parts according to given criteria. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector<std::string> - or \c std::list<boost::iterator_range<std::string::iterator>> -*/ - -namespace boost { - namespace algorithm { - -// find_all ------------------------------------------------------------// - - //! Find all algorithm - /*! - This algorithm finds all occurrences of the search string - in the input. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector<std::string> - or \c std::list<boost::iterator_range<std::string::iterator>> - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Search A substring to be searched for. - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T, typename Range2T > - inline SequenceSequenceT& find_all( - SequenceSequenceT& Result, -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - Range1T&& Input, -#else - Range1T& Input, -#endif - const Range2T& Search) - { - return ::boost::algorithm::iter_find( - Result, - Input, - ::boost::algorithm::first_finder(Search) ); - } - - //! Find all algorithm ( case insensitive ) - /*! - This algorithm finds all occurrences of the search string - in the input. - Each part is copied and added as a new element to the - output container. Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector<std::string> - or \c std::list<boost::iterator_range<std::string::iterator>> - - Searching is case insensitive. - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Search A substring to be searched for. - \param Loc A locale used for case insensitive comparison - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T, typename Range2T > - inline SequenceSequenceT& ifind_all( - SequenceSequenceT& Result, -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - Range1T&& Input, -#else - Range1T& Input, -#endif - const Range2T& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::iter_find( - Result, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc) ) ); - } - - -// tokenize -------------------------------------------------------------// - - //! Split algorithm - /*! - Tokenize expression. This function is equivalent to C strtok. Input - sequence is split into tokens, separated by separators. Separators - are given by means of the predicate. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector<std::string> - or \c std::list<boost::iterator_range<std::string::iterator>> - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Pred A predicate to identify separators. This predicate is - supposed to return true if a given element is a separator. - \param eCompress If eCompress argument is set to token_compress_on, adjacent - separators are merged together. Otherwise, every two separators - delimit a token. - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename RangeT, typename PredicateT > - inline SequenceSequenceT& split( - SequenceSequenceT& Result, -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - RangeT&& Input, -#else - RangeT& Input, -#endif - PredicateT Pred, - token_compress_mode_type eCompress=token_compress_off ) - { - return ::boost::algorithm::iter_split( - Result, - Input, - ::boost::algorithm::token_finder( Pred, eCompress ) ); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::find_all; - using algorithm::ifind_all; - using algorithm::split; - -} // namespace boost - - -#endif // BOOST_STRING_SPLIT_HPP - diff --git a/ThirdParty/boost/any.hpp b/ThirdParty/boost/any.hpp deleted file mode 100644 index cb0cb259338f47c40bb249d4c54b77c65c12eec2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/any.hpp +++ /dev/null @@ -1,342 +0,0 @@ -// See http://www.boost.org/libs/any for Documentation. - -#ifndef BOOST_ANY_INCLUDED -#define BOOST_ANY_INCLUDED - -#if defined(_MSC_VER) -# pragma once -#endif - -// what: variant type boost::any -// who: contributed by Kevlin Henney, -// with features contributed and bugs found by -// Antony Polukhin, Ed Brey, Mark Rodgers, -// Peter Dimov, and James Curran -// when: July 2001, April 2013 - 2020 - -#include <boost/config.hpp> -#include <boost/type_index.hpp> -#include <boost/type_traits/remove_reference.hpp> -#include <boost/type_traits/decay.hpp> -#include <boost/type_traits/remove_cv.hpp> -#include <boost/type_traits/add_reference.hpp> -#include <boost/type_traits/is_reference.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/throw_exception.hpp> -#include <boost/static_assert.hpp> -#include <boost/utility/enable_if.hpp> -#include <boost/core/addressof.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/conditional.hpp> - -namespace boost -{ - class any - { - public: // structors - - BOOST_CONSTEXPR any() BOOST_NOEXCEPT - : content(0) - { - } - - template<typename ValueType> - any(const ValueType & value) - : content(new holder< - BOOST_DEDUCED_TYPENAME remove_cv<BOOST_DEDUCED_TYPENAME decay<const ValueType>::type>::type - >(value)) - { - } - - any(const any & other) - : content(other.content ? other.content->clone() : 0) - { - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - // Move constructor - any(any&& other) BOOST_NOEXCEPT - : content(other.content) - { - other.content = 0; - } - - // Perfect forwarding of ValueType - template<typename ValueType> - any(ValueType&& value - , typename boost::disable_if<boost::is_same<any&, ValueType> >::type* = 0 // disable if value has type `any&` - , typename boost::disable_if<boost::is_const<ValueType> >::type* = 0) // disable if value has type `const ValueType&&` - : content(new holder< typename decay<ValueType>::type >(static_cast<ValueType&&>(value))) - { - } -#endif - - ~any() BOOST_NOEXCEPT - { - delete content; - } - - public: // modifiers - - any & swap(any & rhs) BOOST_NOEXCEPT - { - placeholder* tmp = content; - content = rhs.content; - rhs.content = tmp; - return *this; - } - - -#ifdef BOOST_NO_CXX11_RVALUE_REFERENCES - template<typename ValueType> - any & operator=(const ValueType & rhs) - { - any(rhs).swap(*this); - return *this; - } - - any & operator=(any rhs) - { - rhs.swap(*this); - return *this; - } - -#else - any & operator=(const any& rhs) - { - any(rhs).swap(*this); - return *this; - } - - // move assignment - any & operator=(any&& rhs) BOOST_NOEXCEPT - { - rhs.swap(*this); - any().swap(rhs); - return *this; - } - - // Perfect forwarding of ValueType - template <class ValueType> - any & operator=(ValueType&& rhs) - { - any(static_cast<ValueType&&>(rhs)).swap(*this); - return *this; - } -#endif - - public: // queries - - bool empty() const BOOST_NOEXCEPT - { - return !content; - } - - void clear() BOOST_NOEXCEPT - { - any().swap(*this); - } - - const boost::typeindex::type_info& type() const BOOST_NOEXCEPT - { - return content ? content->type() : boost::typeindex::type_id<void>().type_info(); - } - -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS - private: // types -#else - public: // types (public so any_cast can be non-friend) -#endif - - class BOOST_SYMBOL_VISIBLE placeholder - { - public: // structors - - virtual ~placeholder() - { - } - - public: // queries - - virtual const boost::typeindex::type_info& type() const BOOST_NOEXCEPT = 0; - - virtual placeholder * clone() const = 0; - - }; - - template<typename ValueType> - class holder -#ifndef BOOST_NO_CXX11_FINAL - final -#endif - : public placeholder - { - public: // structors - - holder(const ValueType & value) - : held(value) - { - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - holder(ValueType&& value) - : held(static_cast< ValueType&& >(value)) - { - } -#endif - public: // queries - - virtual const boost::typeindex::type_info& type() const BOOST_NOEXCEPT - { - return boost::typeindex::type_id<ValueType>().type_info(); - } - - virtual placeholder * clone() const - { - return new holder(held); - } - - public: // representation - - ValueType held; - - private: // intentionally left unimplemented - holder & operator=(const holder &); - }; - -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS - - private: // representation - - template<typename ValueType> - friend ValueType * any_cast(any *) BOOST_NOEXCEPT; - - template<typename ValueType> - friend ValueType * unsafe_any_cast(any *) BOOST_NOEXCEPT; - -#else - - public: // representation (public so any_cast can be non-friend) - -#endif - - placeholder * content; - - }; - - inline void swap(any & lhs, any & rhs) BOOST_NOEXCEPT - { - lhs.swap(rhs); - } - - class BOOST_SYMBOL_VISIBLE bad_any_cast : -#ifndef BOOST_NO_RTTI - public std::bad_cast -#else - public std::exception -#endif - { - public: - virtual const char * what() const BOOST_NOEXCEPT_OR_NOTHROW - { - return "boost::bad_any_cast: " - "failed conversion using boost::any_cast"; - } - }; - - template<typename ValueType> - ValueType * any_cast(any * operand) BOOST_NOEXCEPT - { - return operand && operand->type() == boost::typeindex::type_id<ValueType>() - ? boost::addressof( - static_cast<any::holder<BOOST_DEDUCED_TYPENAME remove_cv<ValueType>::type> *>(operand->content)->held - ) - : 0; - } - - template<typename ValueType> - inline const ValueType * any_cast(const any * operand) BOOST_NOEXCEPT - { - return any_cast<ValueType>(const_cast<any *>(operand)); - } - - template<typename ValueType> - ValueType any_cast(any & operand) - { - typedef BOOST_DEDUCED_TYPENAME remove_reference<ValueType>::type nonref; - - - nonref * result = any_cast<nonref>(boost::addressof(operand)); - if(!result) - boost::throw_exception(bad_any_cast()); - - // Attempt to avoid construction of a temporary object in cases when - // `ValueType` is not a reference. Example: - // `static_cast<std::string>(*result);` - // which is equal to `std::string(*result);` - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_reference<ValueType>::value, - ValueType, - BOOST_DEDUCED_TYPENAME boost::add_reference<ValueType>::type - >::type ref_type; - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable: 4172) // "returning address of local variable or temporary" but *result is not local! -#endif - return static_cast<ref_type>(*result); -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - } - - template<typename ValueType> - inline ValueType any_cast(const any & operand) - { - typedef BOOST_DEDUCED_TYPENAME remove_reference<ValueType>::type nonref; - return any_cast<const nonref &>(const_cast<any &>(operand)); - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - template<typename ValueType> - inline ValueType any_cast(any&& operand) - { - BOOST_STATIC_ASSERT_MSG( - boost::is_rvalue_reference<ValueType&&>::value /*true if ValueType is rvalue or just a value*/ - || boost::is_const< typename boost::remove_reference<ValueType>::type >::value, - "boost::any_cast shall not be used for getting nonconst references to temporary objects" - ); - return any_cast<ValueType>(operand); - } -#endif - - - // Note: The "unsafe" versions of any_cast are not part of the - // public interface and may be removed at any time. They are - // required where we know what type is stored in the any and can't - // use typeid() comparison, e.g., when our types may travel across - // different shared libraries. - template<typename ValueType> - inline ValueType * unsafe_any_cast(any * operand) BOOST_NOEXCEPT - { - return boost::addressof( - static_cast<any::holder<ValueType> *>(operand->content)->held - ); - } - - template<typename ValueType> - inline const ValueType * unsafe_any_cast(const any * operand) BOOST_NOEXCEPT - { - return unsafe_any_cast<ValueType>(const_cast<any *>(operand)); - } -} - -// Copyright Kevlin Henney, 2000, 2001, 2002. All rights reserved. -// Copyright Antony Polukhin, 2013-2020. -// -// 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) - -#endif diff --git a/ThirdParty/boost/assert/source_location.hpp b/ThirdParty/boost/assert/source_location.hpp deleted file mode 100644 index a85e6795260ae3fbdab2431d7dbdfdcb47dceabf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/assert/source_location.hpp +++ /dev/null @@ -1,93 +0,0 @@ -#ifndef BOOST_ASSERT_SOURCE_LOCATION_HPP_INCLUDED -#define BOOST_ASSERT_SOURCE_LOCATION_HPP_INCLUDED - -// http://www.boost.org/libs/assert -// -// Copyright 2019 Peter Dimov -// Distributed under the Boost Software License, Version 1.0. -// http://www.boost.org/LICENSE_1_0.txt - -#include <boost/current_function.hpp> -#include <boost/config.hpp> -#include <boost/cstdint.hpp> -#include <iosfwd> - -namespace boost -{ - -struct source_location -{ -private: - - char const * file_; - char const * function_; - boost::uint_least32_t line_; - boost::uint_least32_t column_; - -public: - - BOOST_CONSTEXPR source_location() BOOST_NOEXCEPT: file_( "(unknown)" ), function_( "(unknown)" ), line_( 0 ), column_( 0 ) - { - } - - BOOST_CONSTEXPR source_location( char const * file, boost::uint_least32_t ln, char const * function, boost::uint_least32_t col = 0 ) BOOST_NOEXCEPT: file_( file ), function_( function ), line_( ln ), column_( col ) - { - } - - BOOST_CONSTEXPR char const * file_name() const BOOST_NOEXCEPT - { - return file_; - } - - BOOST_CONSTEXPR char const * function_name() const BOOST_NOEXCEPT - { - return function_; - } - - BOOST_CONSTEXPR boost::uint_least32_t line() const BOOST_NOEXCEPT - { - return line_; - } - - BOOST_CONSTEXPR boost::uint_least32_t column() const BOOST_NOEXCEPT - { - return column_; - } -}; - -template<class E, class T> std::basic_ostream<E, T> & operator<<( std::basic_ostream<E, T> & os, source_location const & loc ) -{ - os.width( 0 ); - - if( loc.line() == 0 ) - { - os << "(unknown source location)"; - } - else - { - os << loc.file_name() << ':' << loc.line(); - - if( loc.column() ) - { - os << ':' << loc.column(); - } - - os << ": in function '" << loc.function_name() << '\''; - } - - return os; -} - -} // namespace boost - -#if defined( BOOST_DISABLE_CURRENT_LOCATION ) - -# define BOOST_CURRENT_LOCATION ::boost::source_location() - -#else - -# define BOOST_CURRENT_LOCATION ::boost::source_location(__FILE__, __LINE__, BOOST_CURRENT_FUNCTION) - -#endif - -#endif // #ifndef BOOST_ASSERT_SOURCE_LOCATION_HPP_INCLUDED diff --git a/ThirdParty/boost/bind.hpp b/ThirdParty/boost/bind.hpp deleted file mode 100644 index 48cc4094cfee0e6f68200822d40d3f5869acfb0a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/bind.hpp +++ /dev/null @@ -1,60 +0,0 @@ -#ifndef BOOST_BIND_HPP_INCLUDED -#define BOOST_BIND_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// bind.hpp - binds function objects to arguments -// -// Copyright (c) 2009, 2015 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 -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// -// For backward compatibility, this header includes -// <boost/bind/bind.hpp> and then imports the placeholders _1, _2, -// _3, ... into the global namespace. Definitions in the global -// namespace are not a good practice and this use is deprecated. -// Please switch to including <boost/bind/bind.hpp> directly, -// adding the using directive locally where appropriate. -// Alternatively, the existing behavior may be preserved by defining -// the macro BOOST_BIND_GLOBAL_PLACEHOLDERS. - -#include <boost/bind/bind.hpp> -#include <boost/config/pragma_message.hpp> - -#ifndef BOOST_BIND_NO_PLACEHOLDERS - -#if !defined(BOOST_BIND_GLOBAL_PLACEHOLDERS) - -BOOST_PRAGMA_MESSAGE( - "The practice of declaring the Bind placeholders (_1, _2, ...) " - "in the global namespace is deprecated. Please use " - "<boost/bind/bind.hpp> + using namespace boost::placeholders, " - "or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior." -) - -#endif - -#if defined(BOOST_CLANG) -# pragma clang diagnostic push -# if __has_warning("-Wheader-hygiene") -# pragma clang diagnostic ignored "-Wheader-hygiene" -# endif -#endif - -using namespace boost::placeholders; - -#if defined(BOOST_CLANG) -# pragma clang diagnostic pop -#endif - -#endif // #ifndef BOOST_BIND_NO_PLACEHOLDERS - -#endif // #ifndef BOOST_BIND_HPP_INCLUDED diff --git a/ThirdParty/boost/bind/bind.hpp b/ThirdParty/boost/bind/bind.hpp deleted file mode 100644 index 711e0001e4f5bbb525a115152c0fe1e84eae1058..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/bind/bind.hpp +++ /dev/null @@ -1,2365 +0,0 @@ -#ifndef BOOST_BIND_BIND_HPP_INCLUDED -#define BOOST_BIND_BIND_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind.hpp - binds function objects to arguments -// -// Copyright (c) 2001-2004 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2001 David Abrahams -// Copyright (c) 2005 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) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include <boost/config.hpp> -#include <boost/ref.hpp> -#include <boost/mem_fn.hpp> -#include <boost/type.hpp> -#include <boost/is_placeholder.hpp> -#include <boost/bind/arg.hpp> -#include <boost/detail/workaround.hpp> -#include <boost/visit_each.hpp> -#include <boost/core/enable_if.hpp> -#include <boost/core/is_same.hpp> - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) -#include <utility> // std::forward -#endif - -// Borland-specific bug, visit_each() silently fails to produce code - -#if defined(__BORLANDC__) -# define BOOST_BIND_VISIT_EACH boost::visit_each -#else -# define BOOST_BIND_VISIT_EACH visit_each -#endif - -#include <boost/bind/storage.hpp> - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable: 4512) // assignment operator could not be generated -#endif - -namespace boost -{ - -template<class T> class weak_ptr; - -namespace _bi // implementation details -{ - -// result_traits - -template<class R, class F> struct result_traits -{ - typedef R type; -}; - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -struct unspecified {}; - -template<class F> struct result_traits<unspecified, F> -{ - typedef typename F::result_type type; -}; - -template<class F> struct result_traits< unspecified, reference_wrapper<F> > -{ - typedef typename F::result_type type; -}; - -#endif - -// ref_compare - -template<class T> bool ref_compare( T const & a, T const & b, long ) -{ - return a == b; -} - -template<int I> bool ref_compare( arg<I> const &, arg<I> const &, int ) -{ - return true; -} - -template<int I> bool ref_compare( arg<I> (*) (), arg<I> (*) (), int ) -{ - return true; -} - -template<class T> bool ref_compare( reference_wrapper<T> const & a, reference_wrapper<T> const & b, int ) -{ - return a.get_pointer() == b.get_pointer(); -} - -// bind_t forward declaration for listN - -template<class R, class F, class L> class bind_t; - -template<class R, class F, class L> bool ref_compare( bind_t<R, F, L> const & a, bind_t<R, F, L> const & b, int ) -{ - return a.compare( b ); -} - -// value - -template<class T> class value -{ -public: - - value(T const & t): t_(t) {} - - T & get() { return t_; } - T const & get() const { return t_; } - - bool operator==(value const & rhs) const - { - return t_ == rhs.t_; - } - -private: - - T t_; -}; - -// ref_compare for weak_ptr - -template<class T> bool ref_compare( value< weak_ptr<T> > const & a, value< weak_ptr<T> > const & b, int ) -{ - return !(a.get() < b.get()) && !(b.get() < a.get()); -} - -// type - -template<class T> class type {}; - -// unwrap - -template<class F> struct unwrapper -{ - static inline F & unwrap( F & f, long ) - { - return f; - } - - template<class F2> static inline F2 & unwrap( reference_wrapper<F2> rf, int ) - { - return rf.get(); - } - - template<class R, class T> static inline _mfi::dm<R, T> unwrap( R T::* pm, int ) - { - return _mfi::dm<R, T>( pm ); - } -}; - -// listN - -class list0 -{ -public: - - list0() {} - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A &, long) - { - return unwrapper<F>::unwrap(f, 0)(); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A &, long) const - { - return unwrapper<F const>::unwrap(f, 0)(); - } - - template<class F, class A> void operator()(type<void>, F & f, A &, int) - { - unwrapper<F>::unwrap(f, 0)(); - } - - template<class F, class A> void operator()(type<void>, F const & f, A &, int) const - { - unwrapper<F const>::unwrap(f, 0)(); - } - - template<class V> void accept(V &) const - { - } - - bool operator==(list0 const &) const - { - return true; - } -}; - -#ifdef BOOST_MSVC -// MSVC is bright enough to realise that the parameter rhs -// in operator==may be unused for some template argument types: -#pragma warning(push) -#pragma warning(disable:4100) -#endif - -template< class A1 > class list1: private storage1< A1 > -{ -private: - - typedef storage1< A1 > base_type; - -public: - - explicit list1( A1 a1 ): base_type( a1 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list1 const & rhs) const - { - return ref_compare(base_type::a1_, rhs.a1_, 0); - } -}; - -struct logical_and; -struct logical_or; - -template< class A1, class A2 > class list2: private storage2< A1, A2 > -{ -private: - - typedef storage2< A1, A2 > base_type; - -public: - - list2( A1 a1, A2 a2 ): base_type( a1, a2 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template<class A> bool operator()( type<bool>, logical_and & /*f*/, A & a, int ) - { - return a[ base_type::a1_ ] && a[ base_type::a2_ ]; - } - - template<class A> bool operator()( type<bool>, logical_and const & /*f*/, A & a, int ) const - { - return a[ base_type::a1_ ] && a[ base_type::a2_ ]; - } - - template<class A> bool operator()( type<bool>, logical_or & /*f*/, A & a, int ) - { - return a[ base_type::a1_ ] || a[ base_type::a2_ ]; - } - - template<class A> bool operator()( type<bool>, logical_or const & /*f*/, A & a, int ) const - { - return a[ base_type::a1_ ] || a[ base_type::a2_ ]; - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list2 const & rhs) const - { - return ref_compare(base_type::a1_, rhs.a1_, 0) && ref_compare(base_type::a2_, rhs.a2_, 0); - } -}; - -template< class A1, class A2, class A3 > class list3: private storage3< A1, A2, A3 > -{ -private: - - typedef storage3< A1, A2, A3 > base_type; - -public: - - list3( A1 a1, A2 a2, A3 a3 ): base_type( a1, a2, a3 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list3 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4 > class list4: private storage4< A1, A2, A3, A4 > -{ -private: - - typedef storage4< A1, A2, A3, A4 > base_type; - -public: - - list4( A1 a1, A2 a2, A3 a3, A4 a4 ): base_type( a1, a2, a3, a4 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list4 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5 > class list5: private storage5< A1, A2, A3, A4, A5 > -{ -private: - - typedef storage5< A1, A2, A3, A4, A5 > base_type; - -public: - - list5( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5 ): base_type( a1, a2, a3, a4, a5 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list5 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ); - } -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6> class list6: private storage6< A1, A2, A3, A4, A5, A6 > -{ -private: - - typedef storage6< A1, A2, A3, A4, A5, A6 > base_type; - -public: - - list6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6 ): base_type( a1, a2, a3, a4, a5, a6 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list6 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ); - } -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> class list7: private storage7< A1, A2, A3, A4, A5, A6, A7 > -{ -private: - - typedef storage7< A1, A2, A3, A4, A5, A6, A7 > base_type; - -public: - - list7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7 ): base_type( a1, a2, a3, a4, a5, a6, a7 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list7 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8 > class list8: private storage8< A1, A2, A3, A4, A5, A6, A7, A8 > -{ -private: - - typedef storage8< A1, A2, A3, A4, A5, A6, A7, A8 > base_type; - -public: - - list8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8 ): base_type( a1, a2, a3, a4, a5, a6, a7, a8 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - A8 operator[] (boost::arg<8>) const { return base_type::a8_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - A8 operator[] (boost::arg<8> (*) ()) const { return base_type::a8_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list8 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ) && - ref_compare( base_type::a8_, rhs.a8_, 0 ); - } -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> class list9: private storage9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > -{ -private: - - typedef storage9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > base_type; - -public: - - list9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9 ): base_type( a1, a2, a3, a4, a5, a6, a7, a8, a9 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - A8 operator[] (boost::arg<8>) const { return base_type::a8_; } - A9 operator[] (boost::arg<9>) const { return base_type::a9_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - A8 operator[] (boost::arg<8> (*) ()) const { return base_type::a8_; } - A9 operator[] (boost::arg<9> (*) ()) const { return base_type::a9_; } - - template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } - - template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } - - template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) - { - return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const - { - return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template<class F, class A> void operator()(type<void>, F & f, A & a, int) - { - unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const - { - unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template<class V> void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list9 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ) && - ref_compare( base_type::a8_, rhs.a8_, 0 ) && - ref_compare( base_type::a9_, rhs.a9_, 0 ); - } -}; - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -// bind_t - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -template< class A1 > class rrlist1 -{ -private: - - A1 & a1_; // not A1&& because of msvc-10.0 - -public: - - explicit rrlist1( A1 & a1 ): a1_( a1 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } // not static_cast because of g++ 4.9 - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist1<A1&> a( a1_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist1<A1&> a( a1_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2 > class rrlist2 -{ -private: - - A1 & a1_; - A2 & a2_; - -public: - - rrlist2( A1 & a1, A2 & a2 ): a1_( a1 ), a2_( a2 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist2<A1&, A2&> a( a1_, a2_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist2<A1&, A2&> a( a1_, a2_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3 > class rrlist3 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - -public: - - rrlist3( A1 & a1, A2 & a2, A3 & a3 ): a1_( a1 ), a2_( a2 ), a3_( a3 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist3<A1&, A2&, A3&> a( a1_, a2_, a3_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist3<A1&, A2&, A3&> a( a1_, a2_, a3_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4 > class rrlist4 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - -public: - - rrlist4( A1 & a1, A2 & a2, A3 & a3, A4 & a4 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist4<A1&, A2&, A3&, A4&> a( a1_, a2_, a3_, a4_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist4<A1&, A2&, A3&, A4&> a( a1_, a2_, a3_, a4_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5 > class rrlist5 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - A5 & a5_; - -public: - - rrlist5( A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ), a5_( a5 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5>) const { return std::forward<A5>( a5_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5> (*) ()) const { return std::forward<A5>( a5_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist5<A1&, A2&, A3&, A4&, A5&> a( a1_, a2_, a3_, a4_, a5_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist5<A1&, A2&, A3&, A4&, A5&> a( a1_, a2_, a3_, a4_, a5_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6 > class rrlist6 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - A5 & a5_; - A6 & a6_; - -public: - - rrlist6( A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ), a5_( a5 ), a6_( a6 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5>) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6>) const { return std::forward<A6>( a6_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5> (*) ()) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6> (*) ()) const { return std::forward<A6>( a6_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist6<A1&, A2&, A3&, A4&, A5&, A6&> a( a1_, a2_, a3_, a4_, a5_, a6_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist6<A1&, A2&, A3&, A4&, A5&, A6&> a( a1_, a2_, a3_, a4_, a5_, a6_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6, class A7 > class rrlist7 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - A5 & a5_; - A6 & a6_; - A7 & a7_; - -public: - - rrlist7( A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ), a5_( a5 ), a6_( a6 ), a7_( a7 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5>) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6>) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7>) const { return std::forward<A7>( a7_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5> (*) ()) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6> (*) ()) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7> (*) ()) const { return std::forward<A7>( a7_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist7<A1&, A2&, A3&, A4&, A5&, A6&, A7&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist7<A1&, A2&, A3&, A4&, A5&, A6&, A7&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8 > class rrlist8 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - A5 & a5_; - A6 & a6_; - A7 & a7_; - A8 & a8_; - -public: - - rrlist8( A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ), a5_( a5 ), a6_( a6 ), a7_( a7 ), a8_( a8 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5>) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6>) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7>) const { return std::forward<A7>( a7_ ); } - A8 && operator[] (boost::arg<8>) const { return std::forward<A8>( a8_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5> (*) ()) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6> (*) ()) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7> (*) ()) const { return std::forward<A7>( a7_ ); } - A8 && operator[] (boost::arg<8> (*) ()) const { return std::forward<A8>( a8_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist8<A1&, A2&, A3&, A4&, A5&, A6&, A7&, A8&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_, a8_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist8<A1&, A2&, A3&, A4&, A5&, A6&, A7&, A8&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_, a8_ ); - return b.eval( a ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9 > class rrlist9 -{ -private: - - A1 & a1_; - A2 & a2_; - A3 & a3_; - A4 & a4_; - A5 & a5_; - A6 & a6_; - A7 & a7_; - A8 & a8_; - A9 & a9_; - -public: - - rrlist9( A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9 ): a1_( a1 ), a2_( a2 ), a3_( a3 ), a4_( a4 ), a5_( a5 ), a6_( a6 ), a7_( a7 ), a8_( a8 ), a9_( a9 ) {} - - A1 && operator[] (boost::arg<1>) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2>) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3>) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4>) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5>) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6>) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7>) const { return std::forward<A7>( a7_ ); } - A8 && operator[] (boost::arg<8>) const { return std::forward<A8>( a8_ ); } - A9 && operator[] (boost::arg<9>) const { return std::forward<A9>( a9_ ); } - - A1 && operator[] (boost::arg<1> (*) ()) const { return std::forward<A1>( a1_ ); } - A2 && operator[] (boost::arg<2> (*) ()) const { return std::forward<A2>( a2_ ); } - A3 && operator[] (boost::arg<3> (*) ()) const { return std::forward<A3>( a3_ ); } - A4 && operator[] (boost::arg<4> (*) ()) const { return std::forward<A4>( a4_ ); } - A5 && operator[] (boost::arg<5> (*) ()) const { return std::forward<A5>( a5_ ); } - A6 && operator[] (boost::arg<6> (*) ()) const { return std::forward<A6>( a6_ ); } - A7 && operator[] (boost::arg<7> (*) ()) const { return std::forward<A7>( a7_ ); } - A8 && operator[] (boost::arg<8> (*) ()) const { return std::forward<A8>( a8_ ); } - A9 && operator[] (boost::arg<9> (*) ()) const { return std::forward<A9>( a9_ ); } - - template<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } - - template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } - - template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const - { - rrlist9<A1&, A2&, A3&, A4&, A5&, A6&, A7&, A8&, A9&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_, a8_, a9_ ); - return b.eval( a ); - } - - template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const - { - rrlist9<A1&, A2&, A3&, A4&, A5&, A6&, A7&, A8&, A9&> a( a1_, a2_, a3_, a4_, a5_, a6_, a7_, a8_, a9_ ); - return b.eval( a ); - } -}; - -template<class R, class F, class L> class bind_t -{ -private: - - F f_; - L l_; - -public: - - typedef typename result_traits<R, F>::type result_type; - typedef bind_t this_type; - - bind_t( F f, L const & l ): f_( f ), l_( l ) {} - - // - - result_type operator()() - { - list0 a; - return l_( type<result_type>(), f_, a, 0 ); - } - - result_type operator()() const - { - list0 a; - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1> result_type operator()( A1 && a1 ) - { - rrlist1< A1 > a( a1 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1> result_type operator()( A1 && a1 ) const - { - rrlist1< A1 > a( a1 ); - return l_(type<result_type>(), f_, a, 0); - } - - template<class A1, class A2> result_type operator()( A1 && a1, A2 && a2 ) - { - rrlist2< A1, A2 > a( a1, a2 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2> result_type operator()( A1 && a1, A2 && a2 ) const - { - rrlist2< A1, A2 > a( a1, a2 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3> result_type operator()( A1 && a1, A2 && a2, A3 && a3 ) - { - rrlist3< A1, A2, A3 > a( a1, a2, a3 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3> result_type operator()( A1 && a1, A2 && a2, A3 && a3 ) const - { - rrlist3< A1, A2, A3 > a( a1, a2, a3 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4 ) - { - rrlist4< A1, A2, A3, A4 > a( a1, a2, a3, a4 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4 ) const - { - rrlist4< A1, A2, A3, A4 > a( a1, a2, a3, a4 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5 ) - { - rrlist5< A1, A2, A3, A4, A5 > a( a1, a2, a3, a4, a5 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5 ) const - { - rrlist5< A1, A2, A3, A4, A5 > a( a1, a2, a3, a4, a5 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6 ) - { - rrlist6< A1, A2, A3, A4, A5, A6 > a( a1, a2, a3, a4, a5, a6 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6 ) const - { - rrlist6< A1, A2, A3, A4, A5, A6 > a( a1, a2, a3, a4, a5, a6 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7 ) - { - rrlist7< A1, A2, A3, A4, A5, A6, A7 > a( a1, a2, a3, a4, a5, a6, a7 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7 ) const - { - rrlist7< A1, A2, A3, A4, A5, A6, A7 > a( a1, a2, a3, a4, a5, a6, a7 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7, A8 && a8 ) - { - rrlist8< A1, A2, A3, A4, A5, A6, A7, A8 > a( a1, a2, a3, a4, a5, a6, a7, a8 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7, A8 && a8 ) const - { - rrlist8< A1, A2, A3, A4, A5, A6, A7, A8 > a( a1, a2, a3, a4, a5, a6, a7, a8 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7, A8 && a8, A9 && a9 ) - { - rrlist9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > a( a1, a2, a3, a4, a5, a6, a7, a8, a9 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> result_type operator()( A1 && a1, A2 && a2, A3 && a3, A4 && a4, A5 && a5, A6 && a6, A7 && a7, A8 && a8, A9 && a9 ) const - { - rrlist9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > a( a1, a2, a3, a4, a5, a6, a7, a8, a9 ); - return l_( type<result_type>(), f_, a, 0 ); - } - - // - - template<class A> result_type eval( A & a ) - { - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class A> result_type eval( A & a ) const - { - return l_( type<result_type>(), f_, a, 0 ); - } - - template<class V> void accept( V & v ) const - { -#if !defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) && !defined( __BORLANDC__ ) - using boost::visit_each; -#endif - - BOOST_BIND_VISIT_EACH( v, f_, 0 ); - l_.accept( v ); - } - - bool compare( this_type const & rhs ) const - { - return ref_compare( f_, rhs.f_, 0 ) && l_ == rhs.l_; - } -}; - -#elif !defined( BOOST_NO_VOID_RETURNS ) - -template<class R, class F, class L> class bind_t -{ -public: - - typedef bind_t this_type; - - bind_t(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN return -#include <boost/bind/bind_template.hpp> -#undef BOOST_BIND_RETURN - -}; - -#else // no void returns - -template<class R> struct bind_t_generator -{ - -template<class F, class L> class implementation -{ -public: - - typedef implementation this_type; - - implementation(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN return -#include <boost/bind/bind_template.hpp> -#undef BOOST_BIND_RETURN - -}; - -}; - -template<> struct bind_t_generator<void> -{ - -template<class F, class L> class implementation -{ -private: - - typedef void R; - -public: - - typedef implementation this_type; - - implementation(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN -#include <boost/bind/bind_template.hpp> -#undef BOOST_BIND_RETURN - -}; - -}; - -template<class R2, class F, class L> class bind_t: public bind_t_generator<R2>::BOOST_NESTED_TEMPLATE implementation<F, L> -{ -public: - - bind_t(F f, L const & l): bind_t_generator<R2>::BOOST_NESTED_TEMPLATE implementation<F, L>(f, l) {} - -}; - -#endif - -// function_equal - -#ifndef BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// put overloads in _bi, rely on ADL - -# ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -template<class R, class F, class L> bool function_equal( bind_t<R, F, L> const & a, bind_t<R, F, L> const & b ) -{ - return a.compare(b); -} - -# else - -template<class R, class F, class L> bool function_equal_impl( bind_t<R, F, L> const & a, bind_t<R, F, L> const & b, int ) -{ - return a.compare(b); -} - -# endif // #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -#else // BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// put overloads in boost - -} // namespace _bi - -# ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -template<class R, class F, class L> bool function_equal( _bi::bind_t<R, F, L> const & a, _bi::bind_t<R, F, L> const & b ) -{ - return a.compare(b); -} - -# else - -template<class R, class F, class L> bool function_equal_impl( _bi::bind_t<R, F, L> const & a, _bi::bind_t<R, F, L> const & b, int ) -{ - return a.compare(b); -} - -# endif // #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -namespace _bi -{ - -#endif // BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// add_value - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) || (__SUNPRO_CC >= 0x530) - -#if defined( __BORLANDC__ ) && BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x582) ) - -template<class T> struct add_value -{ - typedef _bi::value<T> type; -}; - -#else - -template< class T, int I > struct add_value_2 -{ - typedef boost::arg<I> type; -}; - -template< class T > struct add_value_2< T, 0 > -{ - typedef _bi::value< T > type; -}; - -template<class T> struct add_value -{ - typedef typename add_value_2< T, boost::is_placeholder< T >::value >::type type; -}; - -#endif - -template<class T> struct add_value< value<T> > -{ - typedef _bi::value<T> type; -}; - -template<class T> struct add_value< reference_wrapper<T> > -{ - typedef reference_wrapper<T> type; -}; - -template<int I> struct add_value< arg<I> > -{ - typedef boost::arg<I> type; -}; - -template<int I> struct add_value< arg<I> (*) () > -{ - typedef boost::arg<I> (*type) (); -}; - -template<class R, class F, class L> struct add_value< bind_t<R, F, L> > -{ - typedef bind_t<R, F, L> type; -}; - -#else - -template<int I> struct _avt_0; - -template<> struct _avt_0<1> -{ - template<class T> struct inner - { - typedef T type; - }; -}; - -template<> struct _avt_0<2> -{ - template<class T> struct inner - { - typedef value<T> type; - }; -}; - -typedef char (&_avt_r1) [1]; -typedef char (&_avt_r2) [2]; - -template<class T> _avt_r1 _avt_f(value<T>); -template<class T> _avt_r1 _avt_f(reference_wrapper<T>); -template<int I> _avt_r1 _avt_f(arg<I>); -template<int I> _avt_r1 _avt_f(arg<I> (*) ()); -template<class R, class F, class L> _avt_r1 _avt_f(bind_t<R, F, L>); - -_avt_r2 _avt_f(...); - -template<class T> struct add_value -{ - static T t(); - typedef typename _avt_0<sizeof(_avt_f(t()))>::template inner<T>::type type; -}; - -#endif - -// list_av_N - -template<class A1> struct list_av_1 -{ - typedef typename add_value<A1>::type B1; - typedef list1<B1> type; -}; - -template<class A1, class A2> struct list_av_2 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef list2<B1, B2> type; -}; - -template<class A1, class A2, class A3> struct list_av_3 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef list3<B1, B2, B3> type; -}; - -template<class A1, class A2, class A3, class A4> struct list_av_4 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef list4<B1, B2, B3, B4> type; -}; - -template<class A1, class A2, class A3, class A4, class A5> struct list_av_5 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef typename add_value<A5>::type B5; - typedef list5<B1, B2, B3, B4, B5> type; -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6> struct list_av_6 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef typename add_value<A5>::type B5; - typedef typename add_value<A6>::type B6; - typedef list6<B1, B2, B3, B4, B5, B6> type; -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> struct list_av_7 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef typename add_value<A5>::type B5; - typedef typename add_value<A6>::type B6; - typedef typename add_value<A7>::type B7; - typedef list7<B1, B2, B3, B4, B5, B6, B7> type; -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> struct list_av_8 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef typename add_value<A5>::type B5; - typedef typename add_value<A6>::type B6; - typedef typename add_value<A7>::type B7; - typedef typename add_value<A8>::type B8; - typedef list8<B1, B2, B3, B4, B5, B6, B7, B8> type; -}; - -template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> struct list_av_9 -{ - typedef typename add_value<A1>::type B1; - typedef typename add_value<A2>::type B2; - typedef typename add_value<A3>::type B3; - typedef typename add_value<A4>::type B4; - typedef typename add_value<A5>::type B5; - typedef typename add_value<A6>::type B6; - typedef typename add_value<A7>::type B7; - typedef typename add_value<A8>::type B8; - typedef typename add_value<A9>::type B9; - typedef list9<B1, B2, B3, B4, B5, B6, B7, B8, B9> type; -}; - -// operator! - -struct logical_not -{ - template<class V> bool operator()(V const & v) const { return !v; } -}; - -template<class R, class F, class L> - bind_t< bool, logical_not, list1< bind_t<R, F, L> > > - operator! (bind_t<R, F, L> const & f) -{ - typedef list1< bind_t<R, F, L> > list_type; - return bind_t<bool, logical_not, list_type> ( logical_not(), list_type(f) ); -} - -// relational operators - -#define BOOST_BIND_OPERATOR( op, name ) \ -\ -struct name \ -{ \ - template<class V, class W> bool operator()(V const & v, W const & w) const { return v op w; } \ -}; \ - \ -template<class R, class F, class L, class A2> \ - bind_t< bool, name, list2< bind_t<R, F, L>, typename add_value<A2>::type > > \ - operator op (bind_t<R, F, L> const & f, A2 a2) \ -{ \ - typedef typename add_value<A2>::type B2; \ - typedef list2< bind_t<R, F, L>, B2> list_type; \ - return bind_t<bool, name, list_type> ( name(), list_type(f, a2) ); \ -} - -BOOST_BIND_OPERATOR( ==, equal ) -BOOST_BIND_OPERATOR( !=, not_equal ) - -BOOST_BIND_OPERATOR( <, less ) -BOOST_BIND_OPERATOR( <=, less_equal ) - -BOOST_BIND_OPERATOR( >, greater ) -BOOST_BIND_OPERATOR( >=, greater_equal ) - -BOOST_BIND_OPERATOR( &&, logical_and ) -BOOST_BIND_OPERATOR( ||, logical_or ) - -#undef BOOST_BIND_OPERATOR - -#if defined(__GNUC__) && BOOST_WORKAROUND(__GNUC__, < 3) - -// resolve ambiguity with rel_ops - -#define BOOST_BIND_OPERATOR( op, name ) \ -\ -template<class R, class F, class L> \ - bind_t< bool, name, list2< bind_t<R, F, L>, bind_t<R, F, L> > > \ - operator op (bind_t<R, F, L> const & f, bind_t<R, F, L> const & g) \ -{ \ - typedef list2< bind_t<R, F, L>, bind_t<R, F, L> > list_type; \ - return bind_t<bool, name, list_type> ( name(), list_type(f, g) ); \ -} - -BOOST_BIND_OPERATOR( !=, not_equal ) -BOOST_BIND_OPERATOR( <=, less_equal ) -BOOST_BIND_OPERATOR( >, greater ) -BOOST_BIND_OPERATOR( >=, greater_equal ) - -#endif - -// visit_each, ADL - -#if !defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) && !defined( __BORLANDC__ ) \ - && !(defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) - -template<class V, class T> void visit_each( V & v, value<T> const & t, int ) -{ - using boost::visit_each; - BOOST_BIND_VISIT_EACH( v, t.get(), 0 ); -} - -template<class V, class R, class F, class L> void visit_each( V & v, bind_t<R, F, L> const & t, int ) -{ - t.accept( v ); -} - -#endif - -} // namespace _bi - -// visit_each, no ADL - -#if defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) || defined( __BORLANDC__ ) \ - || (defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) - -template<class V, class T> void visit_each( V & v, _bi::value<T> const & t, int ) -{ - BOOST_BIND_VISIT_EACH( v, t.get(), 0 ); -} - -template<class V, class R, class F, class L> void visit_each( V & v, _bi::bind_t<R, F, L> const & t, int ) -{ - t.accept( v ); -} - -#endif - -// is_bind_expression - -template< class T > struct is_bind_expression -{ - enum _vt { value = 0 }; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class R, class F, class L > struct is_bind_expression< _bi::bind_t< R, F, L > > -{ - enum _vt { value = 1 }; -}; - -#endif - -// bind - -#ifndef BOOST_BIND -#define BOOST_BIND bind -#endif - -// generic function objects - -template<class R, class F> - _bi::bind_t<R, F, _bi::list0> - BOOST_BIND(F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t<R, F, list_type> (f, list_type()); -} - -template<class R, class F, class A1> - _bi::bind_t<R, F, typename _bi::list_av_1<A1>::type> - BOOST_BIND(F f, A1 a1) -{ - typedef typename _bi::list_av_1<A1>::type list_type; - return _bi::bind_t<R, F, list_type> (f, list_type(a1)); -} - -template<class R, class F, class A1, class A2> - _bi::bind_t<R, F, typename _bi::list_av_2<A1, A2>::type> - BOOST_BIND(F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2<A1, A2>::type list_type; - return _bi::bind_t<R, F, list_type> (f, list_type(a1, a2)); -} - -template<class R, class F, class A1, class A2, class A3> - _bi::bind_t<R, F, typename _bi::list_av_3<A1, A2, A3>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3)); -} - -template<class R, class F, class A1, class A2, class A3, class A4> - _bi::bind_t<R, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5> - _bi::bind_t<R, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6> - _bi::bind_t<R, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> - _bi::bind_t<R, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> - _bi::bind_t<R, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> - _bi::bind_t<R, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -// generic function objects, alternative syntax - -template<class R, class F> - _bi::bind_t<R, F, _bi::list0> - BOOST_BIND(boost::type<R>, F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t<R, F, list_type> (f, list_type()); -} - -template<class R, class F, class A1> - _bi::bind_t<R, F, typename _bi::list_av_1<A1>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1) -{ - typedef typename _bi::list_av_1<A1>::type list_type; - return _bi::bind_t<R, F, list_type> (f, list_type(a1)); -} - -template<class R, class F, class A1, class A2> - _bi::bind_t<R, F, typename _bi::list_av_2<A1, A2>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2<A1, A2>::type list_type; - return _bi::bind_t<R, F, list_type> (f, list_type(a1, a2)); -} - -template<class R, class F, class A1, class A2, class A3> - _bi::bind_t<R, F, typename _bi::list_av_3<A1, A2, A3>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3)); -} - -template<class R, class F, class A1, class A2, class A3, class A4> - _bi::bind_t<R, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5> - _bi::bind_t<R, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6> - _bi::bind_t<R, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> - _bi::bind_t<R, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> - _bi::bind_t<R, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> - _bi::bind_t<R, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> - BOOST_BIND(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; - return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -// adaptable function objects - -template<class F> - _bi::bind_t<_bi::unspecified, F, _bi::list0> - BOOST_BIND(F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type()); -} - -template<class F, class A1> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_1<A1>::type> - BOOST_BIND(F f, A1 a1) -{ - typedef typename _bi::list_av_1<A1>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1)); -} - -template<class F, class A1, class A2> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_2<A1, A2>::type> - BOOST_BIND(F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2<A1, A2>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1, a2)); -} - -template<class F, class A1, class A2, class A3> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_3<A1, A2, A3>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3)); -} - -template<class F, class A1, class A2, class A3, class A4> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4)); -} - -template<class F, class A1, class A2, class A3, class A4, class A5> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); -} - -template<class F, class A1, class A2, class A3, class A4, class A5, class A6> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -#endif // !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -// function pointers - -#define BOOST_BIND_CC -#define BOOST_BIND_ST -#define BOOST_BIND_NOEXCEPT - -#include <boost/bind/bind_cc.hpp> - -# if defined( __cpp_noexcept_function_type ) || defined( _NOEXCEPT_TYPES_SUPPORTED ) -# undef BOOST_BIND_NOEXCEPT -# define BOOST_BIND_NOEXCEPT noexcept -# include <boost/bind/bind_cc.hpp> -# endif - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST -#undef BOOST_BIND_NOEXCEPT - -#if defined(BOOST_BIND_ENABLE_STDCALL) && !defined(_M_X64) - -#define BOOST_BIND_CC __stdcall -#define BOOST_BIND_ST -#define BOOST_BIND_NOEXCEPT - -#include <boost/bind/bind_cc.hpp> - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST -#undef BOOST_BIND_NOEXCEPT - -#endif - -#if defined(BOOST_BIND_ENABLE_FASTCALL) && !defined(_M_X64) - -#define BOOST_BIND_CC __fastcall -#define BOOST_BIND_ST -#define BOOST_BIND_NOEXCEPT - -#include <boost/bind/bind_cc.hpp> - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST -#undef BOOST_BIND_NOEXCEPT - -#endif - -#ifdef BOOST_BIND_ENABLE_PASCAL - -#define BOOST_BIND_ST pascal -#define BOOST_BIND_CC -#define BOOST_BIND_NOEXCEPT - -#include <boost/bind/bind_cc.hpp> - -#undef BOOST_BIND_ST -#undef BOOST_BIND_CC -#undef BOOST_BIND_NOEXCEPT - -#endif - -// member function pointers - -#define BOOST_BIND_MF_NAME(X) X -#define BOOST_BIND_MF_CC -#define BOOST_BIND_MF_NOEXCEPT - -#include <boost/bind/bind_mf_cc.hpp> -#include <boost/bind/bind_mf2_cc.hpp> - -# if defined( __cpp_noexcept_function_type ) || defined( _NOEXCEPT_TYPES_SUPPORTED ) -# undef BOOST_BIND_MF_NOEXCEPT -# define BOOST_BIND_MF_NOEXCEPT noexcept -# include <boost/bind/bind_mf_cc.hpp> -# endif - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC -#undef BOOST_BIND_MF_NOEXCEPT - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_BIND_MF_NAME(X) X##_cdecl -#define BOOST_BIND_MF_CC __cdecl -#define BOOST_BIND_MF_NOEXCEPT - -#include <boost/bind/bind_mf_cc.hpp> -#include <boost/bind/bind_mf2_cc.hpp> - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC -#undef BOOST_BIND_MF_NOEXCEPT - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_STDCALL) && !defined(_M_X64) - -#define BOOST_BIND_MF_NAME(X) X##_stdcall -#define BOOST_BIND_MF_CC __stdcall -#define BOOST_BIND_MF_NOEXCEPT - -#include <boost/bind/bind_mf_cc.hpp> -#include <boost/bind/bind_mf2_cc.hpp> - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC -#undef BOOST_BIND_MF_NOEXCEPT - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_FASTCALL) && !defined(_M_X64) - -#define BOOST_BIND_MF_NAME(X) X##_fastcall -#define BOOST_BIND_MF_CC __fastcall -#define BOOST_BIND_MF_NOEXCEPT - -#include <boost/bind/bind_mf_cc.hpp> -#include <boost/bind/bind_mf2_cc.hpp> - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC -#undef BOOST_BIND_MF_NOEXCEPT - -#endif - -// data member pointers - -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) || defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - || ( defined(__BORLANDC__) && BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x620 ) ) ) - -template<class R, class T, class A1> -_bi::bind_t< R, _mfi::dm<R, T>, typename _bi::list_av_1<A1>::type > - BOOST_BIND(R T::*f, A1 a1) -{ - typedef _mfi::dm<R, T> F; - typedef typename _bi::list_av_1<A1>::type list_type; - return _bi::bind_t<R, F, list_type>( F(f), list_type(a1) ); -} - -#else - -namespace _bi -{ - -template< class Pm, int I > struct add_cref; - -template< class M, class T > struct add_cref< M T::*, 0 > -{ - typedef M type; -}; - -template< class M, class T > struct add_cref< M T::*, 1 > -{ -#ifdef BOOST_MSVC -#pragma warning(push) -#pragma warning(disable:4180) -#endif - typedef M const & type; -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif -}; - -template< class R, class T > struct add_cref< R (T::*) (), 1 > -{ - typedef void type; -}; - -#if !defined(__IBMCPP__) || __IBMCPP_FUNC_CV_TMPL_ARG_DEDUCTION - -template< class R, class T > struct add_cref< R (T::*) () const, 1 > -{ - typedef void type; -}; - -#if defined( __cpp_noexcept_function_type ) || defined( _NOEXCEPT_TYPES_SUPPORTED ) - -template< class R, class T > struct add_cref< R (T::*) () const noexcept, 1 > -{ - typedef void type; -}; - -#endif // __cpp_noexcept_function_type - -#endif // __IBMCPP__ - -template<class R> struct isref -{ - enum value_type { value = 0 }; -}; - -template<class R> struct isref< R& > -{ - enum value_type { value = 1 }; -}; - -template<class R> struct isref< R* > -{ - enum value_type { value = 1 }; -}; - -template<class Pm, class A1> struct dm_result -{ - typedef typename add_cref< Pm, 1 >::type type; -}; - -template<class Pm, class R, class F, class L> struct dm_result< Pm, bind_t<R, F, L> > -{ - typedef typename bind_t<R, F, L>::result_type result_type; - typedef typename add_cref< Pm, isref< result_type >::value >::type type; -}; - -} // namespace _bi - -template< class A1, class M, class T > - -_bi::bind_t< - typename _bi::dm_result< M T::*, A1 >::type, - _mfi::dm<M, T>, - typename _bi::list_av_1<A1>::type -> - -BOOST_BIND( M T::*f, A1 a1 ) -{ - typedef typename _bi::dm_result< M T::*, A1 >::type result_type; - typedef _mfi::dm<M, T> F; - typedef typename _bi::list_av_1<A1>::type list_type; - return _bi::bind_t< result_type, F, list_type >( F( f ), list_type( a1 ) ); -} - -#endif - -} // namespace boost - -#ifndef BOOST_BIND_NO_PLACEHOLDERS - -# include <boost/bind/placeholders.hpp> - -#endif - -#ifdef BOOST_MSVC -# pragma warning(default: 4512) // assignment operator could not be generated -# pragma warning(pop) -#endif - -#endif // #ifndef BOOST_BIND_BIND_HPP_INCLUDED diff --git a/ThirdParty/boost/bind/mem_fn.hpp b/ThirdParty/boost/bind/mem_fn.hpp deleted file mode 100644 index 5afb0a1a89a74c122c8a887ad9b8999b57518611..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/bind/mem_fn.hpp +++ /dev/null @@ -1,403 +0,0 @@ -#ifndef BOOST_BIND_MEM_FN_HPP_INCLUDED -#define BOOST_BIND_MEM_FN_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// mem_fn.hpp - a generalization of std::mem_fun[_ref] -// -// Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2001 David Abrahams -// Copyright (c) 2003-2005 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) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -#include <boost/config.hpp> -#include <boost/get_pointer.hpp> -#include <boost/detail/workaround.hpp> - -namespace boost -{ - -#if defined(BOOST_NO_VOID_RETURNS) - -#define BOOST_MEM_FN_CLASS_F , class F -#define BOOST_MEM_FN_TYPEDEF(X) - -namespace _mfi // mem_fun_impl -{ - -template<class V> struct mf -{ - -#define BOOST_MEM_FN_RETURN return - -#define BOOST_MEM_FN_NAME(X) inner_##X -#define BOOST_MEM_FN_CC - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_STDCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_FASTCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -}; // struct mf<V> - -template<> struct mf<void> -{ - -#define BOOST_MEM_FN_RETURN - -#define BOOST_MEM_FN_NAME(X) inner_##X -#define BOOST_MEM_FN_CC - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -}; // struct mf<void> - -#undef BOOST_MEM_FN_CLASS_F -#undef BOOST_MEM_FN_TYPEDEF_F - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_NAME2(X) inner_##X -#define BOOST_MEM_FN_CC - -#include <boost/bind/mem_fn_vw.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_NAME2(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include <boost/bind/mem_fn_vw.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_NAME2(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include <boost/bind/mem_fn_vw.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_NAME2(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include <boost/bind/mem_fn_vw.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -} // namespace _mfi - -#else // #ifdef BOOST_NO_VOID_RETURNS - -#define BOOST_MEM_FN_CLASS_F -#define BOOST_MEM_FN_TYPEDEF(X) typedef X; - -namespace _mfi -{ - -#define BOOST_MEM_FN_RETURN return - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_CC - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_STDCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_FASTCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include <boost/bind/mem_fn_template.hpp> - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -} // namespace _mfi - -#undef BOOST_MEM_FN_CLASS_F -#undef BOOST_MEM_FN_TYPEDEF - -#endif // #ifdef BOOST_NO_VOID_RETURNS - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_CC -#define BOOST_MEM_FN_NOEXCEPT - -#include <boost/bind/mem_fn_cc.hpp> - -#if defined( __cpp_noexcept_function_type ) || defined( _NOEXCEPT_TYPES_SUPPORTED ) -# undef BOOST_MEM_FN_NOEXCEPT -# define BOOST_MEM_FN_NOEXCEPT noexcept -# include <boost/bind/mem_fn_cc.hpp> -#endif - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NOEXCEPT - -#if defined(BOOST_MEM_FN_ENABLE_CDECL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_CC __cdecl -#define BOOST_MEM_FN_NOEXCEPT - -#include <boost/bind/mem_fn_cc.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NOEXCEPT - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_STDCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_CC __stdcall -#define BOOST_MEM_FN_NOEXCEPT - -#include <boost/bind/mem_fn_cc.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NOEXCEPT - -#endif - -#if defined(BOOST_MEM_FN_ENABLE_FASTCALL) && !defined(_M_X64) - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_CC __fastcall -#define BOOST_MEM_FN_NOEXCEPT - -#include <boost/bind/mem_fn_cc.hpp> - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NOEXCEPT - -#endif - -// data member support - -namespace _mfi -{ - -template<class R, class T> class dm -{ -public: - - typedef R const & result_type; - typedef T const * argument_type; - -private: - - typedef R (T::*F); - F f_; - - template<class U> R const & call(U & u, T const *) const - { - return (u.*f_); - } - - template<class U> R const & call(U & u, void const *) const - { - return (get_pointer(u)->*f_); - } - -public: - - explicit dm(F f): f_(f) {} - - R & operator()(T * p) const - { - return (p->*f_); - } - - R const & operator()(T const * p) const - { - return (p->*f_); - } - - template<class U> R const & operator()(U const & u) const - { - return call(u, &u); - } - -#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300) && !BOOST_WORKAROUND(__MWERKS__, < 0x3200) - - R & operator()(T & t) const - { - return (t.*f_); - } - - R const & operator()(T const & t) const - { - return (t.*f_); - } - -#endif - - bool operator==(dm const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(dm const & rhs) const - { - return f_ != rhs.f_; - } -}; - -} // namespace _mfi - -template<class R, class T> _mfi::dm<R, T> mem_fn(R T::*f) -{ - return _mfi::dm<R, T>(f); -} - -} // namespace boost - -#endif // #ifndef BOOST_BIND_MEM_FN_HPP_INCLUDED diff --git a/ThirdParty/boost/bind/mem_fn_cc.hpp b/ThirdParty/boost/bind/mem_fn_cc.hpp deleted file mode 100644 index 03e38300a5620fae912f33f26eb67f0d864505e9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/bind/mem_fn_cc.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// -// bind/mem_fn_cc.hpp - support for different calling conventions -// -// Do not include this header directly. -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// 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) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -template<class R, class T> _mfi::BOOST_MEM_FN_NAME(mf0)<R, T> mem_fn(R (BOOST_MEM_FN_CC T::*f) () BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf0)<R, T>(f); -} - -template<class R, class T> _mfi::BOOST_MEM_FN_NAME(cmf0)<R, T> mem_fn(R (BOOST_MEM_FN_CC T::*f) () const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf0)<R, T>(f); -} - -template<class R, class T, class A1> _mfi::BOOST_MEM_FN_NAME(mf1)<R, T, A1> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf1)<R, T, A1>(f); -} - -template<class R, class T, class A1> _mfi::BOOST_MEM_FN_NAME(cmf1)<R, T, A1> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf1)<R, T, A1>(f); -} - -template<class R, class T, class A1, class A2> _mfi::BOOST_MEM_FN_NAME(mf2)<R, T, A1, A2> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf2)<R, T, A1, A2>(f); -} - -template<class R, class T, class A1, class A2> _mfi::BOOST_MEM_FN_NAME(cmf2)<R, T, A1, A2> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf2)<R, T, A1, A2>(f); -} - -template<class R, class T, class A1, class A2, class A3> _mfi::BOOST_MEM_FN_NAME(mf3)<R, T, A1, A2, A3> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf3)<R, T, A1, A2, A3>(f); -} - -template<class R, class T, class A1, class A2, class A3> _mfi::BOOST_MEM_FN_NAME(cmf3)<R, T, A1, A2, A3> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf3)<R, T, A1, A2, A3>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4> _mfi::BOOST_MEM_FN_NAME(mf4)<R, T, A1, A2, A3, A4> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf4)<R, T, A1, A2, A3, A4>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4> _mfi::BOOST_MEM_FN_NAME(cmf4)<R, T, A1, A2, A3, A4> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf4)<R, T, A1, A2, A3, A4>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5> _mfi::BOOST_MEM_FN_NAME(mf5)<R, T, A1, A2, A3, A4, A5> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf5)<R, T, A1, A2, A3, A4, A5>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5> _mfi::BOOST_MEM_FN_NAME(cmf5)<R, T, A1, A2, A3, A4, A5> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf5)<R, T, A1, A2, A3, A4, A5>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6> _mfi::BOOST_MEM_FN_NAME(mf6)<R, T, A1, A2, A3, A4, A5, A6> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf6)<R, T, A1, A2, A3, A4, A5, A6>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6> _mfi::BOOST_MEM_FN_NAME(cmf6)<R, T, A1, A2, A3, A4, A5, A6> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf6)<R, T, A1, A2, A3, A4, A5, A6>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7> _mfi::BOOST_MEM_FN_NAME(mf7)<R, T, A1, A2, A3, A4, A5, A6, A7> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf7)<R, T, A1, A2, A3, A4, A5, A6, A7>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7> _mfi::BOOST_MEM_FN_NAME(cmf7)<R, T, A1, A2, A3, A4, A5, A6, A7> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf7)<R, T, A1, A2, A3, A4, A5, A6, A7>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> _mfi::BOOST_MEM_FN_NAME(mf8)<R, T, A1, A2, A3, A4, A5, A6, A7, A8> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7, A8) BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(mf8)<R, T, A1, A2, A3, A4, A5, A6, A7, A8>(f); -} - -template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> _mfi::BOOST_MEM_FN_NAME(cmf8)<R, T, A1, A2, A3, A4, A5, A6, A7, A8> mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7, A8) const BOOST_MEM_FN_NOEXCEPT) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf8)<R, T, A1, A2, A3, A4, A5, A6, A7, A8>(f); -} diff --git a/ThirdParty/boost/chrono/detail/inlined/win/chrono.hpp b/ThirdParty/boost/chrono/detail/inlined/win/chrono.hpp deleted file mode 100644 index 5c753f5e2884f3ae2335e8f4de309362db856029..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/chrono/detail/inlined/win/chrono.hpp +++ /dev/null @@ -1,151 +0,0 @@ -// win/chrono.cpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2008 -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -//----------------------------------------------------------------------------// -// Windows // -//----------------------------------------------------------------------------// -#ifndef BOOST_CHRONO_DETAIL_INLINED_WIN_CHRONO_HPP -#define BOOST_CHRONO_DETAIL_INLINED_WIN_CHRONO_HPP - -#include <boost/winapi/time.hpp> -#include <boost/winapi/timers.hpp> -#include <boost/winapi/get_last_error.hpp> -#include <boost/winapi/error_codes.hpp> -#include <boost/assert.hpp> - -namespace boost -{ -namespace chrono -{ -namespace chrono_detail -{ - - BOOST_CHRONO_INLINE double get_nanosecs_per_tic() BOOST_NOEXCEPT - { - boost::winapi::LARGE_INTEGER_ freq; - if ( !boost::winapi::QueryPerformanceFrequency( &freq ) ) - return 0.0L; - return double(1000000000.0L / freq.QuadPart); - } - -} - - steady_clock::time_point steady_clock::now() BOOST_NOEXCEPT - { - double nanosecs_per_tic = chrono_detail::get_nanosecs_per_tic(); - - boost::winapi::LARGE_INTEGER_ pcount; - if ( nanosecs_per_tic <= 0.0L ) - { - BOOST_ASSERT(0 && "Boost::Chrono - get_nanosecs_per_tic Internal Error"); - return steady_clock::time_point(); - } - unsigned times=0; - while ( ! boost::winapi::QueryPerformanceCounter( &pcount ) ) - { - if ( ++times > 3 ) - { - BOOST_ASSERT(0 && "Boost::Chrono - QueryPerformanceCounter Internal Error"); - return steady_clock::time_point(); - } - } - - return steady_clock::time_point(steady_clock::duration( - static_cast<steady_clock::rep>((nanosecs_per_tic) * pcount.QuadPart))); - } - - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - steady_clock::time_point steady_clock::now( system::error_code & ec ) - { - double nanosecs_per_tic = chrono_detail::get_nanosecs_per_tic(); - - boost::winapi::LARGE_INTEGER_ pcount; - if ( (nanosecs_per_tic <= 0.0L) - || (!boost::winapi::QueryPerformanceCounter( &pcount )) ) - { - boost::winapi::DWORD_ cause = - ((nanosecs_per_tic <= 0.0L) - ? boost::winapi::ERROR_NOT_SUPPORTED_ - : boost::winapi::GetLastError()); - if (::boost::chrono::is_throws(ec)) { - boost::throw_exception( - system::system_error( - cause, - ::boost::system::system_category(), - "chrono::steady_clock" )); - } - else - { - ec.assign( cause, ::boost::system::system_category() ); - return steady_clock::time_point(duration(0)); - } - } - - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - return time_point(duration( - static_cast<steady_clock::rep>(nanosecs_per_tic * pcount.QuadPart))); - } -#endif - - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::now() BOOST_NOEXCEPT - { - boost::winapi::FILETIME_ ft; - boost::winapi::GetSystemTimeAsFileTime( &ft ); // never fails - return system_clock::time_point( - system_clock::duration( - ((static_cast<__int64>( ft.dwHighDateTime ) << 32) | ft.dwLowDateTime) - - 116444736000000000LL - //- (134775LL*864000000000LL) - ) - ); - } - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::now( system::error_code & ec ) - { - boost::winapi::FILETIME_ ft; - boost::winapi::GetSystemTimeAsFileTime( &ft ); // never fails - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - return system_clock::time_point( - system_clock::duration( - ((static_cast<__int64>( ft.dwHighDateTime ) << 32) | ft.dwLowDateTime) - - 116444736000000000LL - //- (134775LL*864000000000LL) - )); - } -#endif - - BOOST_CHRONO_INLINE - std::time_t system_clock::to_time_t(const system_clock::time_point& t) BOOST_NOEXCEPT - { - __int64 temp = t.time_since_epoch().count(); - temp /= 10000000; - return static_cast<std::time_t>( temp ); - } - - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::from_time_t(std::time_t t) BOOST_NOEXCEPT - { - __int64 temp = t; - temp *= 10000000; - return time_point(duration(temp)); - } - -} // namespace chrono -} // namespace boost - -#endif diff --git a/ThirdParty/boost/chrono/detail/inlined/win/process_cpu_clocks.hpp b/ThirdParty/boost/chrono/detail/inlined/win/process_cpu_clocks.hpp deleted file mode 100644 index 87b5d4af199feceb9e155974e0f2a552d086335c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/chrono/detail/inlined/win/process_cpu_clocks.hpp +++ /dev/null @@ -1,281 +0,0 @@ -// boost process_timer.cpp -----------------------------------------------------------// - -// Copyright Beman Dawes 1994, 2006, 2008 -// Copyright 2009-2010 Vicente J. Botet Escriba -// Copyright (c) Microsoft Corporation 2014 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// See http://www.boost.org/libs/chrono for documentation. - -//--------------------------------------------------------------------------------------// -#ifndef BOOST_CHRONO_DETAIL_INLINED_WIN_PROCESS_CLOCK_HPP -#define BOOST_CHRONO_DETAIL_INLINED_WIN_PROCESS_CLOCK_HPP - -#include <boost/chrono/config.hpp> -#include <boost/chrono/process_cpu_clocks.hpp> -#include <cassert> -#include <time.h> -#include <boost/assert.hpp> - -#include <boost/winapi/get_last_error.hpp> -#include <boost/winapi/get_current_process.hpp> -#if BOOST_PLAT_WINDOWS_DESKTOP -#include <boost/winapi/get_process_times.hpp> -#endif - -namespace boost -{ -namespace chrono -{ - -process_real_cpu_clock::time_point process_real_cpu_clock::now() BOOST_NOEXCEPT -{ - clock_t c = ::clock(); - if ( c == clock_t(-1) ) // error - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - } - typedef ratio_divide<giga, ratio<CLOCKS_PER_SEC> >::type R; - return time_point( - duration(static_cast<rep>(c)*R::num/R::den) - ); -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -process_real_cpu_clock::time_point process_real_cpu_clock::now( - system::error_code & ec) -{ - clock_t c = ::clock(); - if ( c == clock_t(-1) ) // error - { - boost::throw_exception( - system::system_error( - errno, - ::boost::system::system_category(), - "chrono::process_real_cpu_clock" )); - } - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - typedef ratio_divide<giga, ratio<CLOCKS_PER_SEC> >::type R; - return time_point( - duration(static_cast<rep>(c)*R::num/R::den) - ); -} -#endif - -#if BOOST_PLAT_WINDOWS_DESKTOP -process_user_cpu_clock::time_point process_user_cpu_clock::now() BOOST_NOEXCEPT -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - return time_point(duration( - ((static_cast<process_user_cpu_clock::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime) * 100 - )); - } - else - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - return time_point(); - } - -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -process_user_cpu_clock::time_point process_user_cpu_clock::now( - system::error_code & ec) -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - return time_point(duration( - ((static_cast<process_user_cpu_clock::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime) * 100 - )); - } - else - { - boost::winapi::DWORD_ cause = boost::winapi::GetLastError(); - if (::boost::chrono::is_throws(ec)) - { - boost::throw_exception( - system::system_error( - cause, - ::boost::system::system_category(), - "chrono::process_user_cpu_clock" )); - } - else - { - ec.assign( cause, ::boost::system::system_category() ); - return time_point(); - } - } - -} -#endif - -process_system_cpu_clock::time_point process_system_cpu_clock::now() BOOST_NOEXCEPT -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - return time_point(duration( - ((static_cast<process_system_cpu_clock::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime) * 100 - )); - } - else - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - return time_point(); - } - -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -process_system_cpu_clock::time_point process_system_cpu_clock::now( - system::error_code & ec) -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - return time_point(duration( - ((static_cast<process_system_cpu_clock::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime) * 100 - )); - } - else - { - boost::winapi::DWORD_ cause = boost::winapi::GetLastError(); - if (::boost::chrono::is_throws(ec)) - { - boost::throw_exception( - system::system_error( - cause, - ::boost::system::system_category(), - "chrono::process_system_cpu_clock" )); - } - else - { - ec.assign( cause, ::boost::system::system_category() ); - return time_point(); - } - } - -} -#endif - -process_cpu_clock::time_point process_cpu_clock::now() BOOST_NOEXCEPT -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - time_point::rep r(process_real_cpu_clock::now().time_since_epoch().count() - , - ((static_cast<process_user_cpu_clock::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime - ) * 100, - ((static_cast<process_system_cpu_clock::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime - ) * 100 - ); - return time_point(duration(r)); - } - else - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - return time_point(); - } - -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -process_cpu_clock::time_point process_cpu_clock::now( - system::error_code & ec ) -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetProcessTimes( - boost::winapi::GetCurrentProcess(), &creation, &exit, - &system_time, &user_time ) ) - { - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - time_point::rep r(process_real_cpu_clock::now().time_since_epoch().count() - , - ((static_cast<process_user_cpu_clock::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime - ) * 100, - ((static_cast<process_system_cpu_clock::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime - ) * 100 - ); - return time_point(duration(r)); - } - else - { - boost::winapi::DWORD_ cause = boost::winapi::GetLastError(); - if (::boost::chrono::is_throws(ec)) - { - boost::throw_exception( - system::system_error( - cause, - ::boost::system::system_category(), - "chrono::process_cpu_clock" )); - } - else - { - ec.assign( cause, ::boost::system::system_category() ); - return time_point(); - } - } - -} -#endif -#endif -} // namespace chrono -} // namespace boost - -#endif diff --git a/ThirdParty/boost/chrono/detail/inlined/win/thread_clock.hpp b/ThirdParty/boost/chrono/detail/inlined/win/thread_clock.hpp deleted file mode 100644 index 9c9490d0ba39a72837f1739098161b05e3db417f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/chrono/detail/inlined/win/thread_clock.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// boost thread_clock.cpp -----------------------------------------------------------// - -// Copyright 2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// See http://www.boost.org/libs/chrono for documentation. - -//--------------------------------------------------------------------------------------// -#ifndef BOOST_CHRONO_DETAIL_INLINED_WIN_THREAD_CLOCK_HPP -#define BOOST_CHRONO_DETAIL_INLINED_WIN_THREAD_CLOCK_HPP - -#include <boost/chrono/config.hpp> -#include <boost/chrono/thread_clock.hpp> -#include <cassert> -#include <boost/assert.hpp> - -#include <boost/winapi/get_last_error.hpp> -#include <boost/winapi/get_current_thread.hpp> -#include <boost/winapi/get_thread_times.hpp> - -namespace boost -{ -namespace chrono -{ - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -thread_clock::time_point thread_clock::now( system::error_code & ec ) -{ - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetThreadTimes( - boost::winapi::GetCurrentThread (), &creation, &exit, - &system_time, &user_time ) ) - { - duration user = duration( - ((static_cast<duration::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime) * 100 ); - - duration system = duration( - ((static_cast<duration::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime) * 100 ); - - if (!::boost::chrono::is_throws(ec)) - { - ec.clear(); - } - return time_point(system+user); - - } - else - { - if (::boost::chrono::is_throws(ec)) - { - boost::throw_exception( - system::system_error( - boost::winapi::GetLastError(), - ::boost::system::system_category(), - "chrono::thread_clock" )); - } - else - { - ec.assign( boost::winapi::GetLastError(), ::boost::system::system_category() ); - return thread_clock::time_point(duration(0)); - } - } -} -#endif - -thread_clock::time_point thread_clock::now() BOOST_NOEXCEPT -{ - - // note that Windows uses 100 nanosecond ticks for FILETIME - boost::winapi::FILETIME_ creation, exit, user_time, system_time; - - if ( boost::winapi::GetThreadTimes( - boost::winapi::GetCurrentThread (), &creation, &exit, - &system_time, &user_time ) ) - { - duration user = duration( - ((static_cast<duration::rep>(user_time.dwHighDateTime) << 32) - | user_time.dwLowDateTime) * 100 ); - - duration system = duration( - ((static_cast<duration::rep>(system_time.dwHighDateTime) << 32) - | system_time.dwLowDateTime) * 100 ); - - return time_point(system+user); - } - else - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - return time_point(); - } - -} - -} // namespace chrono -} // namespace boost - -#endif diff --git a/ThirdParty/boost/config/auto_link.hpp b/ThirdParty/boost/config/auto_link.hpp deleted file mode 100644 index e74f3c10e96ed8031ebf6b58b584db62c607f9bd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/auto_link.hpp +++ /dev/null @@ -1,485 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to 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) - - /* - * LOCATION: see http://www.boost.org for most recent version. - * FILE auto_link.hpp - * VERSION see <boost/version.hpp> - * DESCRIPTION: Automatic library inclusion for Borland/Microsoft compilers. - */ - -/************************************************************************* - -USAGE: -~~~~~~ - -Before including this header you must define one or more of define the following macros: - -BOOST_LIB_NAME: Required: A string containing the basename of the library, - for example boost_regex. -BOOST_LIB_TOOLSET: Optional: the base name of the toolset. -BOOST_DYN_LINK: Optional: when set link to dll rather than static library. -BOOST_LIB_DIAGNOSTIC: Optional: when set the header will print out the name - of the library selected (useful for debugging). -BOOST_AUTO_LINK_NOMANGLE: Specifies that we should link to BOOST_LIB_NAME.lib, - rather than a mangled-name version. -BOOST_AUTO_LINK_TAGGED: Specifies that we link to libraries built with the --layout=tagged option. - This is essentially the same as the default name-mangled version, but without - the compiler name and version, or the Boost version. Just the build options. -BOOST_AUTO_LINK_SYSTEM: Specifies that we link to libraries built with the --layout=system option. - This is essentially the same as the non-name-mangled version, but with - the prefix to differentiate static and dll builds - -These macros will be undef'ed at the end of the header, further this header -has no include guards - so be sure to include it only once from your library! - -Algorithm: -~~~~~~~~~~ - -Libraries for Borland and Microsoft compilers are automatically -selected here, the name of the lib is selected according to the following -formula: - -BOOST_LIB_PREFIX - + BOOST_LIB_NAME - + "_" - + BOOST_LIB_TOOLSET - + BOOST_LIB_THREAD_OPT - + BOOST_LIB_RT_OPT - + BOOST_LIB_ARCH_AND_MODEL_OPT - "-" - + BOOST_LIB_VERSION - -These are defined as: - -BOOST_LIB_PREFIX: "lib" for static libraries otherwise "". - -BOOST_LIB_NAME: The base name of the lib ( for example boost_regex). - -BOOST_LIB_TOOLSET: The compiler toolset name (vc6, vc7, bcb5 etc). - -BOOST_LIB_THREAD_OPT: "-mt" for multithread builds, otherwise nothing. - -BOOST_LIB_RT_OPT: A suffix that indicates the runtime library used, - contains one or more of the following letters after - a hyphen: - - s static runtime (dynamic if not present). - g debug/diagnostic runtime (release if not present). - y Python debug/diagnostic runtime (release if not present). - d debug build (release if not present). - p STLport build. - n STLport build without its IOStreams. - -BOOST_LIB_ARCH_AND_MODEL_OPT: The architecture and address model - (-x32 or -x64 for x86/32 and x86/64 respectively) - -BOOST_LIB_VERSION: The Boost version, in the form x_y, for Boost version x.y. - - -***************************************************************************/ - -#ifdef __cplusplus -# ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -# endif -#elif defined(_MSC_VER) && !defined(__MWERKS__) && !defined(__EDG_VERSION__) -// -// C language compatability (no, honestly) -// -# define BOOST_MSVC _MSC_VER -# define BOOST_STRINGIZE(X) BOOST_DO_STRINGIZE(X) -# define BOOST_DO_STRINGIZE(X) #X -#endif -// -// Only include what follows for known and supported compilers: -// -#if defined(BOOST_MSVC) \ - || defined(__BORLANDC__) \ - || (defined(__MWERKS__) && defined(_WIN32) && (__MWERKS__ >= 0x3000)) \ - || (defined(__ICL) && defined(_MSC_EXTENSIONS) && (_MSC_VER >= 1200)) \ - || (defined(BOOST_CLANG) && defined(BOOST_WINDOWS) && defined(_MSC_VER) && (__clang_major__ >= 4)) - -#ifndef BOOST_VERSION_HPP -# include <boost/version.hpp> -#endif - -#ifndef BOOST_LIB_NAME -# error "Macro BOOST_LIB_NAME not set (internal error)" -#endif - -// -// error check: -// -#if defined(__MSVC_RUNTIME_CHECKS) && !defined(_DEBUG) -# pragma message("Using the /RTC option without specifying a debug runtime will lead to linker errors") -# pragma message("Hint: go to the code generation options and switch to one of the debugging runtimes") -# error "Incompatible build options" -#endif -// -// select toolset if not defined already: -// -#ifndef BOOST_LIB_TOOLSET -# if defined(BOOST_MSVC) && (BOOST_MSVC < 1200) - // Note: no compilers before 1200 are supported -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1300) - -# ifdef UNDER_CE - // eVC4: -# define BOOST_LIB_TOOLSET "evc4" -# else - // vc6: -# define BOOST_LIB_TOOLSET "vc6" -# endif - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1310) - - // vc7: -# define BOOST_LIB_TOOLSET "vc7" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1400) - - // vc71: -# define BOOST_LIB_TOOLSET "vc71" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1500) - - // vc80: -# define BOOST_LIB_TOOLSET "vc80" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1600) - - // vc90: -# define BOOST_LIB_TOOLSET "vc90" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1700) - - // vc10: -# define BOOST_LIB_TOOLSET "vc100" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1800) - - // vc11: -# define BOOST_LIB_TOOLSET "vc110" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1900) - - // vc12: -# define BOOST_LIB_TOOLSET "vc120" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1910) - - // vc14: -# define BOOST_LIB_TOOLSET "vc140" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1920) - - // vc14.1: -# define BOOST_LIB_TOOLSET "vc141" - -# elif defined(BOOST_MSVC) - - // vc14.2: -# define BOOST_LIB_TOOLSET "vc142" - -# elif defined(__BORLANDC__) - - // CBuilder 6: -# define BOOST_LIB_TOOLSET "bcb" - -# elif defined(__ICL) - - // Intel C++, no version number: -# define BOOST_LIB_TOOLSET "iw" - -# elif defined(__MWERKS__) && (__MWERKS__ <= 0x31FF ) - - // Metrowerks CodeWarrior 8.x -# define BOOST_LIB_TOOLSET "cw8" - -# elif defined(__MWERKS__) && (__MWERKS__ <= 0x32FF ) - - // Metrowerks CodeWarrior 9.x -# define BOOST_LIB_TOOLSET "cw9" - -# elif defined(BOOST_CLANG) && defined(BOOST_WINDOWS) && defined(_MSC_VER) && (__clang_major__ >= 4) - - // Clang on Windows -# define BOOST_LIB_TOOLSET "clangw" BOOST_STRINGIZE(__clang_major__) - -# endif -#endif // BOOST_LIB_TOOLSET - -// -// select thread opt: -// -#if defined(_MT) || defined(__MT__) -# define BOOST_LIB_THREAD_OPT "-mt" -#else -# define BOOST_LIB_THREAD_OPT -#endif - -#if defined(_MSC_VER) || defined(__MWERKS__) - -# ifdef _DLL - -# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS)) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydp" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-gdp" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gdp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-p" -# endif - -# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydpn" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-gdpn" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gdpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-pn" -# endif - -# else - -# if defined(_DEBUG) && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gyd" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gd" -# else -# define BOOST_LIB_RT_OPT -# endif - -# endif - -# else - -# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS)) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydp" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-sgdp" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgdp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-sp" -# endif - -# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydpn" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-sgdpn" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgdpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-spn" -# endif - -# else - -# if defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgyd" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgd" -# else -# define BOOST_LIB_RT_OPT "-s" -# endif - -# endif - -# endif - -#elif defined(__BORLANDC__) - -// -// figure out whether we want the debug builds or not: -// -#if __BORLANDC__ > 0x561 -#pragma defineonoption BOOST_BORLAND_DEBUG -v -#endif -// -// sanity check: -// -#if defined(__STL_DEBUG) || defined(_STLP_DEBUG) -#error "Pre-built versions of the Boost libraries are not provided in STLport-debug form" -#endif - -# ifdef _RTLDLL - -# if defined(BOOST_BORLAND_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-yd" -# elif defined(BOOST_BORLAND_DEBUG) -# define BOOST_LIB_RT_OPT "-d" -# elif defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT -y -# else -# define BOOST_LIB_RT_OPT -# endif - -# else - -# if defined(BOOST_BORLAND_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-syd" -# elif defined(BOOST_BORLAND_DEBUG) -# define BOOST_LIB_RT_OPT "-sd" -# elif defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sy" -# else -# define BOOST_LIB_RT_OPT "-s" -# endif - -# endif - -#endif - -// -// BOOST_LIB_ARCH_AND_MODEL_OPT -// - -#if defined( _M_IX86 ) -# define BOOST_LIB_ARCH_AND_MODEL_OPT "-x32" -#elif defined( _M_X64 ) -# define BOOST_LIB_ARCH_AND_MODEL_OPT "-x64" -#elif defined( _M_ARM ) -# define BOOST_LIB_ARCH_AND_MODEL_OPT "-a32" -#elif defined( _M_ARM64 ) -# define BOOST_LIB_ARCH_AND_MODEL_OPT "-a64" -#endif - -// -// select linkage opt: -// -#if (defined(_DLL) || defined(_RTLDLL)) && defined(BOOST_DYN_LINK) -# define BOOST_LIB_PREFIX -#elif defined(BOOST_DYN_LINK) -# error "Mixing a dll boost library with a static runtime is a really bad idea..." -#else -# define BOOST_LIB_PREFIX "lib" -#endif - -// -// now include the lib: -// -#if defined(BOOST_LIB_NAME) \ - && defined(BOOST_LIB_PREFIX) \ - && defined(BOOST_LIB_TOOLSET) \ - && defined(BOOST_LIB_THREAD_OPT) \ - && defined(BOOST_LIB_RT_OPT) \ - && defined(BOOST_LIB_ARCH_AND_MODEL_OPT) \ - && defined(BOOST_LIB_VERSION) - -#ifdef BOOST_AUTO_LINK_TAGGED -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT ".lib") -# endif -#elif defined(BOOST_AUTO_LINK_SYSTEM) -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# endif -#elif defined(BOOST_AUTO_LINK_NOMANGLE) -# pragma comment(lib, BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# endif -#elif defined(BOOST_LIB_BUILDID) -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT "-" BOOST_LIB_VERSION "-" BOOST_STRINGIZE(BOOST_LIB_BUILDID) ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT "-" BOOST_LIB_VERSION "-" BOOST_STRINGIZE(BOOST_LIB_BUILDID) ".lib") -# endif -#else -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT "-" BOOST_LIB_VERSION ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT BOOST_LIB_ARCH_AND_MODEL_OPT "-" BOOST_LIB_VERSION ".lib") -# endif -#endif - -#else -# error "some required macros where not defined (internal logic error)." -#endif - - -#endif // _MSC_VER || __BORLANDC__ - -// -// finally undef any macros we may have set: -// -#ifdef BOOST_LIB_PREFIX -# undef BOOST_LIB_PREFIX -#endif -#if defined(BOOST_LIB_NAME) -# undef BOOST_LIB_NAME -#endif -// Don't undef this one: it can be set by the user and should be the -// same for all libraries: -//#if defined(BOOST_LIB_TOOLSET) -//# undef BOOST_LIB_TOOLSET -//#endif -#if defined(BOOST_LIB_THREAD_OPT) -# undef BOOST_LIB_THREAD_OPT -#endif -#if defined(BOOST_LIB_RT_OPT) -# undef BOOST_LIB_RT_OPT -#endif -#if defined(BOOST_LIB_ARCH_AND_MODEL_OPT) -# undef BOOST_LIB_ARCH_AND_MODEL_OPT -#endif -#if defined(BOOST_LIB_LINK_OPT) -# undef BOOST_LIB_LINK_OPT -#endif -#if defined(BOOST_LIB_DEBUG_OPT) -# undef BOOST_LIB_DEBUG_OPT -#endif -#if defined(BOOST_DYN_LINK) -# undef BOOST_DYN_LINK -#endif - - diff --git a/ThirdParty/boost/config/compiler/borland.hpp b/ThirdParty/boost/config/compiler/borland.hpp deleted file mode 100644 index cd4710abcdcd4d423d4f26b05b8ae190360ea717..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/borland.hpp +++ /dev/null @@ -1,336 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Borland C++ compiler setup: - -// -// versions check: -// we don't support Borland prior to version 5.4: -#if __BORLANDC__ < 0x540 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// last known compiler version: -#if (__BORLANDC__ > 0x613) -//# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -//# else -//# pragma message( "boost: Unknown compiler version - please run the configure tests and report the results") -//# endif -#elif (__BORLANDC__ == 0x600) -# error "CBuilderX preview compiler is no longer supported" -#endif - -// -// Support macros to help with standard library detection -#if (__BORLANDC__ < 0x560) || defined(_USE_OLD_RW_STL) -# define BOOST_BCB_WITH_ROGUE_WAVE -#elif __BORLANDC__ < 0x570 -# define BOOST_BCB_WITH_STLPORT -#else -# define BOOST_BCB_WITH_DINKUMWARE -#endif - -// -// Version 5.0 and below: -# if __BORLANDC__ <= 0x0550 -// Borland C++Builder 4 and 5: -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# if __BORLANDC__ == 0x0550 -// Borland C++Builder 5, command-line compiler 5.5: -# define BOOST_NO_OPERATORS_IN_NAMESPACE -# endif -// Variadic macros do not exist for C++ Builder versions 5 and below -#define BOOST_NO_CXX11_VARIADIC_MACROS -# endif - -// Version 5.51 and below: -#if (__BORLANDC__ <= 0x551) -# define BOOST_NO_CV_SPECIALIZATIONS -# define BOOST_NO_CV_VOID_SPECIALIZATIONS -# define BOOST_NO_DEDUCED_TYPENAME -// workaround for missing WCHAR_MAX/WCHAR_MIN: -#ifdef __cplusplus -#include <climits> -#include <cwchar> -#else -#include <limits.h> -#include <wchar.h> -#endif // __cplusplus -#ifndef WCHAR_MAX -# define WCHAR_MAX 0xffff -#endif -#ifndef WCHAR_MIN -# define WCHAR_MIN 0 -#endif -#endif - -// Borland C++ Builder 6 and below: -#if (__BORLANDC__ <= 0x564) - -# if defined(NDEBUG) && defined(__cplusplus) - // fix broken <cstring> so that Boost.test works: -# include <cstring> -# undef strcmp -# endif - // fix broken errno declaration: -# include <errno.h> -# ifndef errno -# define errno errno -# endif - -#endif - -// -// new bug in 5.61: -#if (__BORLANDC__ >= 0x561) && (__BORLANDC__ <= 0x580) - // this seems to be needed by the command line compiler, but not the IDE: -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -#endif - -// Borland C++ Builder 2006 Update 2 and below: -#if (__BORLANDC__ <= 0x582) -# define BOOST_NO_SFINAE -# define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -# define BOOST_NO_TEMPLATE_TEMPLATES - -# define BOOST_NO_PRIVATE_IN_AGGREGATE - -# ifdef _WIN32 -# define BOOST_NO_SWPRINTF -# elif defined(linux) || defined(__linux__) || defined(__linux) - // we should really be able to do without this - // but the wcs* functions aren't imported into std:: -# define BOOST_NO_STDC_NAMESPACE - // _CPPUNWIND doesn't get automatically set for some reason: -# pragma defineonoption BOOST_CPPUNWIND -x -# endif -#endif - -#if (__BORLANDC__ <= 0x613) // Beman has asked Alisdair for more info - // we shouldn't really need this - but too many things choke - // without it, this needs more investigation: -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_IS_ABSTRACT -# define BOOST_NO_FUNCTION_TYPE_SPECIALIZATIONS -# define BOOST_NO_USING_TEMPLATE -# define BOOST_SP_NO_SP_CONVERTIBLE - -// Temporary workaround -#define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS -#endif - -// Borland C++ Builder 2008 and below: -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE -# define BOOST_NO_NESTED_FRIENDSHIP -# define BOOST_NO_TYPENAME_WITH_CTOR -#if (__BORLANDC__ < 0x600) -# define BOOST_ILLEGAL_CV_REFERENCES -#endif - -// -// Positive Feature detection -// -// Borland C++ Builder 2008 and below: -#if (__BORLANDC__ >= 0x599) -# pragma defineonoption BOOST_CODEGEAR_0X_SUPPORT -Ax -#endif -// -// C++0x Macros: -// -#if !defined( BOOST_CODEGEAR_0X_SUPPORT ) || (__BORLANDC__ < 0x610) -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_CXX11_STATIC_ASSERT -#else -# define BOOST_HAS_ALIGNOF -# define BOOST_HAS_CHAR16_T -# define BOOST_HAS_CHAR32_T -# define BOOST_HAS_DECLTYPE -# define BOOST_HAS_EXPLICIT_CONVERSION_OPS -# define BOOST_HAS_REF_QUALIFIER -# define BOOST_HAS_RVALUE_REFS -# define BOOST_HAS_STATIC_ASSERT -#endif - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DEFAULTED_MOVES -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS // UTF-8 still not supported -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#if __BORLANDC__ >= 0x590 -# define BOOST_HAS_TR1_HASH - -# define BOOST_HAS_MACRO_USE_FACET -#endif - -// -// Post 0x561 we have long long and stdint.h: -#if __BORLANDC__ >= 0x561 -# ifndef __NO_LONG_LONG -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif - // On non-Win32 platforms let the platform config figure this out: -# ifdef _WIN32 -# define BOOST_HAS_STDINT_H -# endif -#endif - -// Borland C++Builder 6 defaults to using STLPort. If _USE_OLD_RW_STL is -// defined, then we have 0x560 or greater with the Rogue Wave implementation -// which presumably has the std::DBL_MAX bug. -#if defined( BOOST_BCB_WITH_ROGUE_WAVE ) -// <climits> is partly broken, some macros define symbols that are really in -// namespace std, so you end up having to use illegal constructs like -// std::DBL_MAX, as a fix we'll just include float.h and have done with: -#include <float.h> -#endif -// -// __int64: -// -#if (__BORLANDC__ >= 0x530) && !defined(__STRICT_ANSI__) -# define BOOST_HAS_MS_INT64 -#endif -// -// check for exception handling support: -// -#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif -// -// all versions have a <dirent.h>: -// -#ifndef __STRICT_ANSI__ -# define BOOST_HAS_DIRENT_H -#endif -// -// all versions support __declspec: -// -#if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif -// -// ABI fixing headers: -// -#if __BORLANDC__ != 0x600 // not implemented for version 6 compiler yet -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp" -#endif -#endif -// -// Disable Win32 support in ANSI mode: -// -#if __BORLANDC__ < 0x600 -# pragma defineonoption BOOST_DISABLE_WIN32 -A -#elif defined(__STRICT_ANSI__) -# define BOOST_DISABLE_WIN32 -#endif -// -// MSVC compatibility mode does some nasty things: -// TODO: look up if this doesn't apply to the whole 12xx range -// -#if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -# define BOOST_NO_VOID_RETURNS -#endif - -// Borland did not implement value-initialization completely, as I reported -// in 2007, Borland Report 51854, "Value-initialization: POD struct should be -// zero-initialized", http://qc.embarcadero.com/wc/qcmain.aspx?d=51854 -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, April 2010) -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION - -#define BOOST_COMPILER "Borland C++ version " BOOST_STRINGIZE(__BORLANDC__) diff --git a/ThirdParty/boost/config/compiler/clang.hpp b/ThirdParty/boost/config/compiler/clang.hpp deleted file mode 100644 index 1a15f6b0559bb72bccd50fbda27849252fc6e3bf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/clang.hpp +++ /dev/null @@ -1,352 +0,0 @@ -// (C) Copyright Douglas Gregor 2010 -// -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Clang compiler setup. - -#define BOOST_HAS_PRAGMA_ONCE - -// Detecting `-fms-extension` compiler flag assuming that _MSC_VER defined when that flag is used. -#if defined (_MSC_VER) && (__clang_major__ > 3 || (__clang_major__ == 3 && __clang_minor__ >= 4)) -# define BOOST_HAS_PRAGMA_DETECT_MISMATCH -#endif - -// When compiling with clang before __has_extension was defined, -// even if one writes 'defined(__has_extension) && __has_extension(xxx)', -// clang reports a compiler error. So the only workaround found is: - -#ifndef __has_extension -#define __has_extension __has_feature -#endif - -#ifndef __has_attribute -#define __has_attribute(x) 0 -#endif - -#ifndef __has_cpp_attribute -#define __has_cpp_attribute(x) 0 -#endif - -#if !__has_feature(cxx_exceptions) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_TYPEID) -# define BOOST_NO_TYPEID -#endif - -#if !__has_feature(cxx_thread_local) -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -#ifdef __is_identifier -#if !__is_identifier(__int64) && !defined(__GNUC__) -# define BOOST_HAS_MS_INT64 -#endif -#endif - -#if __has_include(<stdint.h>) -# define BOOST_HAS_STDINT_H -#endif - -#if (defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)) && !defined(_CRAYC) -#if (__clang_major__ >= 4) && defined(__has_include) -#if __has_include(<quadmath.h>) -# define BOOST_HAS_FLOAT128 -#endif -#endif -#endif - - -#define BOOST_HAS_NRVO - -// Branch prediction hints -#if !defined (__c2__) && defined(__has_builtin) -#if __has_builtin(__builtin_expect) -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) -#endif -#endif - -// Clang supports "long long" in all compilation modes. -#define BOOST_HAS_LONG_LONG - -// -// We disable this if the compiler is really nvcc with C++03 as it -// doesn't actually support __int128 as of CUDA_VERSION=7500 -// even though it defines __SIZEOF_INT128__. -// See https://svn.boost.org/trac/boost/ticket/10418 -// https://svn.boost.org/trac/boost/ticket/11852 -// Only re-enable this for nvcc if you're absolutely sure -// of the circumstances under which it's supported. -// Similarly __SIZEOF_INT128__ is defined when targetting msvc -// compatibility even though the required support functions are absent. -// -#if defined(__CUDACC__) -# if defined(BOOST_GCC_CXX11) -# define BOOST_NVCC_CXX11 -# else -# define BOOST_NVCC_CXX03 -# endif -#endif - -#if defined(__SIZEOF_INT128__) && !defined(BOOST_NVCC_CXX03) && !defined(_MSC_VER) -# define BOOST_HAS_INT128 -#endif - - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if defined(_WIN32) || defined(__WIN32__) || defined(WIN32) || defined(__CYGWIN__) -# define BOOST_HAS_DECLSPEC -# define BOOST_SYMBOL_EXPORT __attribute__((__dllexport__)) -# define BOOST_SYMBOL_IMPORT __attribute__((__dllimport__)) -#else -# define BOOST_SYMBOL_EXPORT __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_IMPORT -#endif - -// -// The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through -// between switch labels. -// -#if __cplusplus >= 201103L && defined(__has_warning) -# if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") -# define BOOST_FALLTHROUGH [[clang::fallthrough]] -# endif -#endif - -#if !__has_feature(cxx_auto_type) -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif - -// -// Currently clang on Windows using VC++ RTL does not support C++11's char16_t or char32_t -// -#if (defined(_MSC_VER) && (_MSC_VER < 1900)) || !(defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L) -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -#endif - -#if defined(_MSC_VER) && (_MSC_VER >= 1800) && !defined(__GNUC__) -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_LOG1P -#endif - -#if !__has_feature(cxx_constexpr) -# define BOOST_NO_CXX11_CONSTEXPR -#endif - -#if !__has_feature(cxx_decltype) -# define BOOST_NO_CXX11_DECLTYPE -#endif - -#if !__has_feature(cxx_decltype_incomplete_return_types) -# define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -#if !__has_feature(cxx_defaulted_functions) -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#endif - -#if !__has_feature(cxx_deleted_functions) -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -#endif - -#if !__has_feature(cxx_explicit_conversions) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif - -#if !__has_feature(cxx_default_function_template_args) -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#if !__has_feature(cxx_lambdas) -# define BOOST_NO_CXX11_LAMBDAS -#endif - -#if !__has_feature(cxx_local_type_template_args) -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif - -#if !__has_feature(cxx_noexcept) -# define BOOST_NO_CXX11_NOEXCEPT -#endif - -#if !__has_feature(cxx_nullptr) -# define BOOST_NO_CXX11_NULLPTR -#endif - -#if !__has_feature(cxx_range_for) -# define BOOST_NO_CXX11_RANGE_BASED_FOR -#endif - -#if !__has_feature(cxx_raw_string_literals) -# define BOOST_NO_CXX11_RAW_LITERALS -#endif - -#if !__has_feature(cxx_reference_qualified_functions) -# define BOOST_NO_CXX11_REF_QUALIFIERS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -#if !__has_feature(cxx_rvalue_references) -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif - -#if !__has_feature(cxx_strong_enums) -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -#if !__has_feature(cxx_static_assert) -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif - -#if !__has_feature(cxx_alias_templates) -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -#endif - -#if !__has_feature(cxx_unicode_literals) -# define BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -#if !__has_feature(cxx_variadic_templates) -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif - -#if !__has_feature(cxx_user_literals) -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#endif - -#if !__has_feature(cxx_alignas) -# define BOOST_NO_CXX11_ALIGNAS -#endif - -#if !__has_feature(cxx_trailing_return) -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -#if !__has_feature(cxx_inline_namespaces) -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -#if !__has_feature(cxx_override_control) -# define BOOST_NO_CXX11_FINAL -#endif - -#if !__has_feature(cxx_unrestricted_unions) -# define BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif - -#if !(__has_feature(__cxx_binary_literals__) || __has_extension(__cxx_binary_literals__)) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif - -#if !__has_feature(__cxx_decltype_auto__) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif - -#if !__has_feature(__cxx_aggregate_nsdmi__) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif - -#if !__has_feature(__cxx_init_captures__) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif - -#if !__has_feature(__cxx_generic_lambdas__) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif - -// clang < 3.5 has a defect with dependent type, like following. -// -// template <class T> -// constexpr typename enable_if<pred<T> >::type foo(T &) -// { } // error: no return statement in constexpr function -// -// This issue also affects C++11 mode, but C++11 constexpr requires return stmt. -// Therefore we don't care such case. -// -// Note that we can't check Clang version directly as the numbering system changes depending who's -// creating the Clang release (see https://github.com/boostorg/config/pull/39#issuecomment-59927873) -// so instead verify that we have a feature that was introduced at the same time as working C++14 -// constexpr (generic lambda's in this case): -// -#if !__has_feature(__cxx_generic_lambdas__) || !__has_feature(__cxx_relaxed_constexpr__) -# define BOOST_NO_CXX14_CONSTEXPR -#endif - -#if !__has_feature(__cxx_return_type_deduction__) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif - -#if !__has_feature(__cxx_variable_templates__) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif - -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -// Clang 3.9+ in c++1z -#if !__has_cpp_attribute(fallthrough) || __cplusplus < 201406L -# define BOOST_NO_CXX17_INLINE_VARIABLES -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif - -#if __cplusplus < 201103L -#define BOOST_NO_CXX11_SFINAE_EXPR -#endif - -#if __cplusplus < 201400 -// All versions with __cplusplus above this value seem to support this: -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -// -// __builtin_unreachable: -#if defined(__has_builtin) && __has_builtin(__builtin_unreachable) -#define BOOST_UNREACHABLE_RETURN(x) __builtin_unreachable(); -#endif - -#if (__clang_major__ == 3) && (__clang_minor__ == 0) -// Apparently a clang bug: -# define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#endif - -// Clang has supported the 'unused' attribute since the first release. -#define BOOST_ATTRIBUTE_UNUSED __attribute__((__unused__)) - -// Type aliasing hint. -#if __has_attribute(__may_alias__) -# define BOOST_MAY_ALIAS __attribute__((__may_alias__)) -#endif - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "Clang version " __clang_version__ -#endif - -// Macro used to identify the Clang compiler. -#define BOOST_CLANG 1 - diff --git a/ThirdParty/boost/config/compiler/codegear.hpp b/ThirdParty/boost/config/compiler/codegear.hpp deleted file mode 100644 index 91f40a92c820e03724e9944fa09dd352ade7a96c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/codegear.hpp +++ /dev/null @@ -1,240 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// CodeGear C++ compiler setup: - -#if !defined( BOOST_WITH_CODEGEAR_WARNINGS ) -// these warnings occur frequently in optimized template code -# pragma warn -8004 // var assigned value, but never used -# pragma warn -8008 // condition always true/false -# pragma warn -8066 // dead code can never execute -# pragma warn -8104 // static members with ctors not threadsafe -# pragma warn -8105 // reference member in class without ctors -#endif -// -// versions check: -// last known and checked version is 0x621 -#if (__CODEGEARC__ > 0x621) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# else -# pragma message( "boost: Unknown compiler version - please run the configure tests and report the results") -# endif -#endif - -// CodeGear C++ Builder 2009 -#if (__CODEGEARC__ <= 0x613) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_PRIVATE_IN_AGGREGATE -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE - // we shouldn't really need this - but too many things choke - // without it, this needs more investigation: -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_SP_NO_SP_CONVERTIBLE -#endif - -// CodeGear C++ Builder 2010 -#if (__CODEGEARC__ <= 0x621) -# define BOOST_NO_TYPENAME_WITH_CTOR // Cannot use typename keyword when making temporaries of a dependant type -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_NESTED_FRIENDSHIP // TC1 gives nested classes access rights as any other member -# define BOOST_NO_USING_TEMPLATE -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -// Temporary hack, until specific MPL preprocessed headers are generated -# define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS - -// CodeGear has not yet completely implemented value-initialization, for -// example for array types, as I reported in 2010: Embarcadero Report 83751, -// "Value-initialization: arrays should have each element value-initialized", -// http://qc.embarcadero.com/wc/qcmain.aspx?d=83751 -// Last checked version: Embarcadero C++ 6.21 -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, April 2010) -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION - -# if defined(NDEBUG) && defined(__cplusplus) - // fix broken <cstring> so that Boost.test works: -# include <cstring> -# undef strcmp -# endif - // fix broken errno declaration: -# include <errno.h> -# ifndef errno -# define errno errno -# endif - -#endif - -// Reportedly, #pragma once is supported since C++ Builder 2010 -#if (__CODEGEARC__ >= 0x620) -# define BOOST_HAS_PRAGMA_ONCE -#endif - -// -// C++0x macros: -// -#if (__CODEGEARC__ <= 0x620) -#define BOOST_NO_CXX11_STATIC_ASSERT -#else -#define BOOST_HAS_STATIC_ASSERT -#endif -#define BOOST_HAS_CHAR16_T -#define BOOST_HAS_CHAR32_T -#define BOOST_HAS_LONG_LONG -// #define BOOST_HAS_ALIGNOF -#define BOOST_HAS_DECLTYPE -#define BOOST_HAS_EXPLICIT_CONVERSION_OPS -// #define BOOST_HAS_RVALUE_REFS -#define BOOST_HAS_SCOPED_ENUM -// #define BOOST_HAS_STATIC_ASSERT -#define BOOST_HAS_STD_TYPE_TRAITS - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif - -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif - -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif - -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -// -// TR1 macros: -// -#define BOOST_HAS_TR1_HASH -#define BOOST_HAS_TR1_TYPE_TRAITS -#define BOOST_HAS_TR1_UNORDERED_MAP -#define BOOST_HAS_TR1_UNORDERED_SET - -#define BOOST_HAS_MACRO_USE_FACET - -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST - -// On non-Win32 platforms let the platform config figure this out: -#ifdef _WIN32 -# define BOOST_HAS_STDINT_H -#endif - -// -// __int64: -// -#if !defined(__STRICT_ANSI__) -# define BOOST_HAS_MS_INT64 -#endif -// -// check for exception handling support: -// -#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif -// -// all versions have a <dirent.h>: -// -#if !defined(__STRICT_ANSI__) -# define BOOST_HAS_DIRENT_H -#endif -// -// all versions support __declspec: -// -#if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif -// -// ABI fixing headers: -// -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp" -#endif -// -// Disable Win32 support in ANSI mode: -// -# pragma defineonoption BOOST_DISABLE_WIN32 -A -// -// MSVC compatibility mode does some nasty things: -// TODO: look up if this doesn't apply to the whole 12xx range -// -#if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -# define BOOST_NO_VOID_RETURNS -#endif - -#define BOOST_COMPILER "CodeGear C++ version " BOOST_STRINGIZE(__CODEGEARC__) - diff --git a/ThirdParty/boost/config/compiler/common_edg.hpp b/ThirdParty/boost/config/compiler/common_edg.hpp deleted file mode 100644 index 1cb3c98edd62837d96affcac5aa992df621d1273..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/common_edg.hpp +++ /dev/null @@ -1,161 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright Markus Schoepflin 2005. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// -// Options common to all edg based compilers. -// -// This is included from within the individual compiler mini-configs. - -#ifndef __EDG_VERSION__ -# error This file requires that __EDG_VERSION__ be defined. -#endif - -#if (__EDG_VERSION__ <= 238) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_SFINAE -#endif - -#if (__EDG_VERSION__ <= 240) -# define BOOST_NO_VOID_RETURNS -#endif - -#if (__EDG_VERSION__ <= 241) && !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -#endif - -#if (__EDG_VERSION__ <= 244) && !defined(BOOST_NO_TEMPLATE_TEMPLATES) -# define BOOST_NO_TEMPLATE_TEMPLATES -#endif - -#if (__EDG_VERSION__ < 300) && !defined(BOOST_NO_IS_ABSTRACT) -# define BOOST_NO_IS_ABSTRACT -#endif - -#if (__EDG_VERSION__ <= 303) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// See also kai.hpp which checks a Kai-specific symbol for EH -# if !defined(__KCC) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -# endif - -# if !defined(__NO_LONG_LONG) -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif - -// Not sure what version was the first to support #pragma once, but -// different EDG-based compilers (e.g. Intel) supported it for ages. -// Add a proper version check if it causes problems. -#define BOOST_HAS_PRAGMA_ONCE - -// -// C++0x features -// -// See above for BOOST_NO_LONG_LONG -// -#if (__EDG_VERSION__ < 310) -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if (__EDG_VERSION__ <= 310) -// No support for initializer lists -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif -#if (__EDG_VERSION__ < 400) -# define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif - -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#ifdef c_plusplus -// EDG has "long long" in non-strict mode -// However, some libraries have insufficient "long long" support -// #define BOOST_HAS_LONG_LONG -#endif diff --git a/ThirdParty/boost/config/compiler/cray.hpp b/ThirdParty/boost/config/compiler/cray.hpp deleted file mode 100644 index 4c73e9ac377eb6b31ab776481059baa93c5681e1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/cray.hpp +++ /dev/null @@ -1,442 +0,0 @@ -// Copyright 2011 John Maddock -// Copyright 2013, 2017-2018 Cray, Inc. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Cray C++ compiler setup. -// -// There are a few parameters that affect the macros defined in this file: -// -// - What version of CCE (Cray Compiling Environment) are we running? This -// comes from the '_RELEASE_MAJOR', '_RELEASE_MINOR', and -// '_RELEASE_PATCHLEVEL' macros. -// - What C++ standards conformance level are we using (e.g. '-h -// std=c++14')? This comes from the '__cplusplus' macro. -// - Are we using GCC extensions ('-h gnu' or '-h nognu')? If we have '-h -// gnu' then CCE emulates GCC, and the macros '__GNUC__', -// '__GNUC_MINOR__', and '__GNUC_PATCHLEVEL__' are defined. -// -// This file is organized as follows: -// -// - Verify that the combination of parameters listed above is supported. -// If we have an unsupported combination, we abort with '#error'. -// - Establish baseline values for all Boost macros. -// - Apply changes to the baseline macros based on compiler version. These -// changes are cummulative so each version section only describes the -// changes since the previous version. -// - Within each version section, we may also apply changes based on -// other parameters (i.e. C++ standards conformance level and GCC -// extensions). -// -// To test changes to this file: -// -// ``` -// module load cce/8.6.5 # Pick the version you want to test. -// cd boost/libs/config/test/all -// b2 -j 8 toolset=cray cxxstd=03 cxxstd=11 cxxstd=14 cxxstd-dialect=gnu linkflags=-lrt -// ``` -// Note: Using 'cxxstd-dialect=iso' is not supported at this time (the -// tests run, but many tests fail). -// -// Note: 'linkflags=-lrt' is needed in Cray Linux Environment. Otherwise -// you get an 'undefined reference to clock_gettime' error. -// -// Note: If a test '*_fail.cpp' file compiles, but fails to run, then it is -// reported as a defect. However, this is not actually a defect. This is an -// area where the test system is somewhat broken. Tests that are failing -// because of this problem are noted in the comments. -// -// Pay attention to the macro definitions for the macros you wish to -// modify. For example, only macros categorized as compiler macros should -// appear in this file; platform macros should not appear in this file. -// Also, some macros have to be defined to specific values; it is not -// always enough to define or undefine a macro. -// -// Macro definitions are available in the source code at: -// -// `boost/libs/config/doc/html/boost_config/boost_macro_reference.html` -// -// Macro definitions are also available online at: -// -// http://www.boost.org/doc/libs/master/libs/config/doc/html/boost_config/boost_macro_reference.html -// -// Typically, if you enable a feature, and the tests pass, then you have -// nothing to worry about. However, it's sometimes hard to figure out if a -// disabled feature needs to stay disabled. To get a list of disabled -// features, run 'b2' in 'boost/libs/config/checks'. These are the macros -// you should pay attention to (in addition to macros that cause test -// failures). - -//// -//// Front matter -//// - -// In a developer build of the Cray compiler (i.e. a compiler built by a -// Cray employee), the release patch level is reported as "x". This gives -// versions that look like e.g. "8.6.x". -// -// To accomplish this, the the Cray compiler preprocessor inserts: -// -// #define _RELEASE_PATCHLEVEL x -// -// If we are using a developer build of the compiler, we want to use the -// configuration macros for the most recent patch level of the release. To -// accomplish this, we'll pretend that _RELEASE_PATCHLEVEL is 99. -// -// However, it's difficult to detect if _RELEASE_PATCHLEVEL is x. We must -// consider that the x will be expanded if x is defined as a macro -// elsewhere. For example, imagine if someone put "-D x=3" on the command -// line, and _RELEASE_PATCHLEVEL is x. Then _RELEASE_PATCHLEVEL would -// expand to 3, and we could not distinguish it from an actual -// _RELEASE_PATCHLEVEL of 3. This problem only affects developer builds; in -// production builds, _RELEASE_PATCHLEVEL is always an integer. -// -// IMPORTANT: In developer builds, if x is defined as a macro, you will get -// an incorrect configuration. The behavior in this case is undefined. -// -// Even if x is not defined, we have to use some trickery to detect if -// _RELEASE_PATCHLEVEL is x. First we define BOOST_CRAY_x to some arbitrary -// magic value, 9867657. Then we use BOOST_CRAY_APPEND to append the -// expanded value of _RELEASE_PATCHLEVEL to the string "BOOST_CRAY_". -// -// - If _RELEASE_PATCHLEVEL is undefined, we get "BOOST_CRAY_". -// - If _RELEASE_PATCHLEVEL is 5, we get "BOOST_CRAY_5". -// - If _RELEASE_PATCHLEVEL is x (and x is not defined) we get -// "BOOST_CRAY_x": -// -// Then we check if BOOST_CRAY_x is equal to the output of -// BOOST_CRAY_APPEND. In other words, the output of BOOST_CRAY_APPEND is -// treated as a macro name, and expanded again. If we can safely assume -// that BOOST_CRAY_ is not a macro defined as our magic number, and -// BOOST_CRAY_5 is not a macro defined as our magic number, then the only -// way the equality test can pass is if _RELEASE_PATCHLEVEL expands to x. -// -// So, that is how we detect if we are using a developer build of the Cray -// compiler. - -#define BOOST_CRAY_x 9867657 // Arbitrary number -#define BOOST_CRAY_APPEND(MACRO) BOOST_CRAY_APPEND_INTERNAL(MACRO) -#define BOOST_CRAY_APPEND_INTERNAL(MACRO) BOOST_CRAY_##MACRO - -#if BOOST_CRAY_x == BOOST_CRAY_APPEND(_RELEASE_PATCHLEVEL) - - // This is a developer build. - // - // - _RELEASE_PATCHLEVEL is defined as x, and x is not defined as a macro. - - // Pretend _RELEASE_PATCHLEVEL is 99, so we get the configuration for the - // most recent patch level in this release. - - #define BOOST_CRAY_VERSION (_RELEASE_MAJOR * 10000 + _RELEASE_MINOR * 100 + 99) - -#else - - // This is a production build. - // - // _RELEASE_PATCHLEVEL is not defined as x, or x is defined as a macro. - - #define BOOST_CRAY_VERSION (_RELEASE_MAJOR * 10000 + _RELEASE_MINOR * 100 + _RELEASE_PATCHLEVEL) - -#endif // BOOST_CRAY_x == BOOST_CRAY_APPEND(_RELEASE_PATCHLEVEL) - -#undef BOOST_CRAY_APPEND_INTERNAL -#undef BOOST_CRAY_APPEND -#undef BOOST_CRAY_x - - -#ifdef __GNUC__ -# define BOOST_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#endif - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "Cray C++ version " BOOST_STRINGIZE(_RELEASE_MAJOR) "." BOOST_STRINGIZE(_RELEASE_MINOR) "." BOOST_STRINGIZE(_RELEASE_PATCHLEVEL) -#endif - -// Since the Cray compiler defines '__GNUC__', we have to emulate some -// additional GCC macros in order to make everything work. -// -// FIXME: Perhaps Cray should fix the compiler to define these additional -// macros for GCC emulation? - -#if __cplusplus >= 201103L && defined(__GNUC__) && !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define __GXX_EXPERIMENTAL_CXX0X__ 1 -#endif - -//// -//// Parameter validation -//// - -// FIXME: Do we really need to support compilers before 8.5? Do they pass -// the Boost.Config tests? - -#if BOOST_CRAY_VERSION < 80000 -# error "Boost is not configured for Cray compilers prior to version 8, please try the configure script." -#endif - -// We only support recent EDG based compilers. - -#ifndef __EDG__ -# error "Unsupported Cray compiler, please try running the configure script." -#endif - -//// -//// Baseline values -//// - -#include <boost/config/compiler/common_edg.hpp> - -#define BOOST_HAS_NRVO -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNRESTRICTED_UNION -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP - -//#define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -#define BOOST_MATH_DISABLE_STD_FPCLASSIFY -//#define BOOST_HAS_FPCLASSIFY - -#define BOOST_SP_USE_PTHREADS -#define BOOST_AC_USE_PTHREADS - -// -// Everything that follows is working around what are thought to be -// compiler shortcomings. Revist all of these regularly. -// - -//#define BOOST_USE_ENUM_STATIC_ASSERT -//#define BOOST_BUGGY_INTEGRAL_CONSTANT_EXPRESSIONS //(this may be implied by the previous #define - -// These constants should be provided by the compiler. - -#ifndef __ATOMIC_RELAXED -#define __ATOMIC_RELAXED 0 -#define __ATOMIC_CONSUME 1 -#define __ATOMIC_ACQUIRE 2 -#define __ATOMIC_RELEASE 3 -#define __ATOMIC_ACQ_REL 4 -#define __ATOMIC_SEQ_CST 5 -#endif - -//// -//// Version changes -//// - -// -// 8.5.0 -// - -#if BOOST_CRAY_VERSION >= 80500 - -#if __cplusplus >= 201103L - -#undef BOOST_HAS_NRVO -#undef BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#undef BOOST_NO_CXX11_AUTO_DECLARATIONS -#undef BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#undef BOOST_NO_CXX11_CHAR16_T -#undef BOOST_NO_CXX11_CHAR32_T -#undef BOOST_NO_CXX11_CONSTEXPR -#undef BOOST_NO_CXX11_DECLTYPE -#undef BOOST_NO_CXX11_DECLTYPE_N3276 -#undef BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#undef BOOST_NO_CXX11_DELETED_FUNCTIONS -#undef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#undef BOOST_NO_CXX11_FINAL -#undef BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#undef BOOST_NO_CXX11_LAMBDAS -#undef BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#undef BOOST_NO_CXX11_NOEXCEPT -#undef BOOST_NO_CXX11_NULLPTR -#undef BOOST_NO_CXX11_RANGE_BASED_FOR -#undef BOOST_NO_CXX11_RAW_LITERALS -#undef BOOST_NO_CXX11_REF_QUALIFIERS -#undef BOOST_NO_CXX11_RVALUE_REFERENCES -#undef BOOST_NO_CXX11_SCOPED_ENUMS -#undef BOOST_NO_CXX11_SFINAE_EXPR -#undef BOOST_NO_CXX11_STATIC_ASSERT -#undef BOOST_NO_CXX11_TEMPLATE_ALIASES -#undef BOOST_NO_CXX11_THREAD_LOCAL -#undef BOOST_NO_CXX11_UNICODE_LITERALS -#undef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#undef BOOST_NO_CXX11_USER_DEFINED_LITERALS -#undef BOOST_NO_CXX11_VARIADIC_MACROS -#undef BOOST_NO_CXX11_VARIADIC_TEMPLATES -#undef BOOST_NO_CXX11_UNRESTRICTED_UNION -#undef BOOST_NO_SFINAE_EXPR -#undef BOOST_NO_TWO_PHASE_NAME_LOOKUP -#undef BOOST_MATH_DISABLE_STD_FPCLASSIFY -#undef BOOST_SP_USE_PTHREADS -#undef BOOST_AC_USE_PTHREADS - -#define BOOST_HAS_VARIADIC_TMPL -#define BOOST_HAS_UNISTD_H -#define BOOST_HAS_TR1_COMPLEX_INVERSE_TRIG -#define BOOST_HAS_TR1_COMPLEX_OVERLOADS -#define BOOST_HAS_STDINT_H -#define BOOST_HAS_STATIC_ASSERT -#define BOOST_HAS_SIGACTION -#define BOOST_HAS_SCHED_YIELD -#define BOOST_HAS_RVALUE_REFS -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_PTHREAD_YIELD -#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -#define BOOST_HAS_PARTIAL_STD_ALLOCATOR -#define BOOST_HAS_NRVO -#define BOOST_HAS_NL_TYPES_H -#define BOOST_HAS_NANOSLEEP -#define BOOST_NO_CXX11_SMART_PTR -#define BOOST_NO_CXX11_HDR_FUNCTIONAL -#define BOOST_NO_CXX14_CONSTEXPR -#define BOOST_HAS_LONG_LONG -#define BOOST_HAS_FLOAT128 - -#if __cplusplus < 201402L -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif // __cplusplus < 201402L - -#endif // __cplusplus >= 201103L - -#endif // BOOST_CRAY_VERSION >= 80500 - -// -// 8.6.4 -// (versions prior to 8.6.5 do not define _RELEASE_PATCHLEVEL) -// - -#if BOOST_CRAY_VERSION >= 80600 - -#if __cplusplus >= 199711L -#define BOOST_HAS_FLOAT128 -#define BOOST_HAS_PTHREAD_YIELD // This is a platform macro, but it improves test results. -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION // This is correct. Test compiles, but fails to run. -#undef BOOST_NO_CXX11_CHAR16_T -#undef BOOST_NO_CXX11_CHAR32_T -#undef BOOST_NO_CXX11_INLINE_NAMESPACES -#undef BOOST_NO_CXX11_FINAL -#undef BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#undef BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_SFINAE_EXPR // This is correct, even though '*_fail.cpp' test fails. -#undef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#undef BOOST_NO_CXX11_VARIADIC_MACROS -#undef BOOST_NO_CXX11_VARIADIC_TEMPLATES -// 'BOOST_NO_DEDUCED_TYPENAME' test is broken. The test files are enabled / -// disabled with an '#ifdef BOOST_DEDUCED_TYPENAME'. However, -// 'boost/libs/config/include/boost/config/detail/suffix.hpp' ensures that -// 'BOOST_DEDUCED_TYPENAME' is always defined (the value it is defined as -// depends on 'BOOST_NO_DEDUCED_TYPENAME'). So, modifying -// 'BOOST_NO_DEDUCED_TYPENAME' has no effect on which tests are run. -// -// The 'no_ded_typename_pass.cpp' test should always compile and run -// successfully, because 'BOOST_DEDUCED_TYPENAME' must always have an -// appropriate value (it's not just something that you turn on or off). -// Therefore, if you wish to test changes to 'BOOST_NO_DEDUCED_TYPENAME', -// you have to modify 'no_ded_typename_pass.cpp' to unconditionally include -// 'boost_no_ded_typename.ipp'. -#undef BOOST_NO_DEDUCED_TYPENAME // This is correct. Test is broken. -#undef BOOST_NO_SFINAE_EXPR -#undef BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif // __cplusplus >= 199711L - -#if __cplusplus >= 201103L -#undef BOOST_NO_CXX11_ALIGNAS -#undef BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_HDR_ATOMIC -#undef BOOST_NO_CXX11_HDR_FUNCTIONAL -#define BOOST_NO_CXX11_HDR_REGEX // This is correct. Test compiles, but fails to run. -#undef BOOST_NO_CXX11_SFINAE_EXPR -#undef BOOST_NO_CXX11_SMART_PTR -#undef BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif // __cplusplus >= 201103L - -#if __cplusplus >= 201402L -#undef BOOST_NO_CXX14_CONSTEXPR -#define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif // __cplusplus == 201402L - -#endif // BOOST_CRAY_VERSION >= 80600 - -// -// 8.6.5 -// (no change from 8.6.4) -// - -// -// 8.7.0 -// - -#if BOOST_CRAY_VERSION >= 80700 - -#if __cplusplus >= 199711L -#endif // __cplusplus >= 199711L - -#if __cplusplus >= 201103L -#undef BOOST_NO_CXX11_HDR_ATOMIC -#undef BOOST_NO_CXX11_HDR_REGEX -#endif // __cplusplus >= 201103L - -#if __cplusplus >= 201402L -#endif // __cplusplus == 201402L - -#endif // BOOST_CRAY_VERSION >= 80700 - -// -// Next release -// - -#if BOOST_CRAY_VERSION > 80799 - -#if __cplusplus >= 199711L -#endif // __cplusplus >= 199711L - -#if __cplusplus >= 201103L -#endif // __cplusplus >= 201103L - -#if __cplusplus >= 201402L -#endif // __cplusplus == 201402L - -#endif // BOOST_CRAY_VERSION > 80799 - -//// -//// Remove temporary macros -//// - -// I've commented out some '#undef' statements to signify that we purposely -// want to keep certain macros. - -//#undef __GXX_EXPERIMENTAL_CXX0X__ -//#undef BOOST_COMPILER -#undef BOOST_GCC_VERSION -#undef BOOST_CRAY_VERSION diff --git a/ThirdParty/boost/config/compiler/digitalmars.hpp b/ThirdParty/boost/config/compiler/digitalmars.hpp deleted file mode 100644 index 82029f902eabfbfe8276580f255f51bea30472b8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/digitalmars.hpp +++ /dev/null @@ -1,141 +0,0 @@ -// Copyright (C) Christof Meerwald 2003 -// Copyright (C) Dan Watkins 2003 -// -// Use, modification and distribution are subject to 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) - -// Digital Mars C++ compiler setup: -#define BOOST_COMPILER __DMC_VERSION_STRING__ - -#define BOOST_HAS_LONG_LONG -#define BOOST_HAS_PRAGMA_ONCE - -#if !defined(BOOST_STRICT_CONFIG) -#define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#define BOOST_NO_OPERATORS_IN_NAMESPACE -#define BOOST_NO_UNREACHABLE_RETURN_DETECTION -#define BOOST_NO_SFINAE -#define BOOST_NO_USING_TEMPLATE -#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// -// has macros: -#define BOOST_HAS_DIRENT_H -#define BOOST_HAS_STDINT_H -#define BOOST_HAS_WINTHREADS - -#if (__DMC__ >= 0x847) -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_LOG1P -#endif - -// -// Is this really the best way to detect whether the std lib is in namespace std? -// -#ifdef __cplusplus -#include <cstddef> -#endif -#if !defined(__STL_IMPORT_VENDOR_CSTD) && !defined(_STLP_IMPORT_VENDOR_CSTD) -# define BOOST_NO_STDC_NAMESPACE -#endif - - -// check for exception handling support: -#if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -// -// C++0x features -// -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#if (__DMC__ <= 0x840) -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is ...: -#if (__DMC__ > 0x848) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif diff --git a/ThirdParty/boost/config/compiler/gcc.hpp b/ThirdParty/boost/config/compiler/gcc.hpp deleted file mode 100644 index 78f1ae398ea3897b1a4d39e5b73e9381f9309d3b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/gcc.hpp +++ /dev/null @@ -1,367 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Jens Maurer 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Douglas Gregor 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Synge Todo 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// GNU C++ compiler setup. - -// -// Define BOOST_GCC so we know this is "real" GCC and not some pretender: -// -#define BOOST_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#if !defined(__CUDACC__) -#define BOOST_GCC BOOST_GCC_VERSION -#endif - -#if defined(__GXX_EXPERIMENTAL_CXX0X__) || (__cplusplus >= 201103L) -# define BOOST_GCC_CXX11 -#endif - -#if __GNUC__ == 3 -# if defined (__PATHSCALE__) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# define BOOST_NO_IS_ABSTRACT -# endif - -# if __GNUC_MINOR__ < 4 -# define BOOST_NO_IS_ABSTRACT -# endif -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if __GNUC__ < 4 -// -// All problems to gcc-3.x and earlier here: -// -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# ifdef __OPEN64__ -# define BOOST_NO_IS_ABSTRACT -# endif -#endif - -// GCC prior to 3.4 had #pragma once too but it didn't work well with filesystem links -#if BOOST_GCC_VERSION >= 30400 -#define BOOST_HAS_PRAGMA_ONCE -#endif - -#if BOOST_GCC_VERSION < 40400 -// Previous versions of GCC did not completely implement value-initialization: -// GCC Bug 30111, "Value-initialization of POD base class doesn't initialize -// members", reported by Jonathan Wakely in 2006, -// http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30111 (fixed for GCC 4.4) -// GCC Bug 33916, "Default constructor fails to initialize array members", -// reported by Michael Elizabeth Chastain in 2007, -// http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33916 (fixed for GCC 4.2.4) -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#endif - -#if !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - - -// -// Threading support: Turn this on unconditionally here (except for -// those platforms where we can know for sure). It will get turned off again -// later if no threading API is detected. -// -#if !defined(__MINGW32__) && !defined(linux) && !defined(__linux) && !defined(__linux__) -# define BOOST_HAS_THREADS -#endif - -// -// gcc has "long long" -// Except on Darwin with standard compliance enabled (-pedantic) -// Apple gcc helpfully defines this macro we can query -// -#if !defined(__DARWIN_NO_LONG_LONG) -# define BOOST_HAS_LONG_LONG -#endif - -// -// gcc implements the named return value optimization since version 3.1 -// -#define BOOST_HAS_NRVO - -// Branch prediction hints -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if __GNUC__ >= 4 -# if defined(_WIN32) || defined(__WIN32__) || defined(WIN32) || defined(__CYGWIN__) - // All Win32 development environments, including 64-bit Windows and MinGW, define - // _WIN32 or one of its variant spellings. Note that Cygwin is a POSIX environment, - // so does not define _WIN32 or its variants, but still supports dllexport/dllimport. -# define BOOST_HAS_DECLSPEC -# define BOOST_SYMBOL_EXPORT __attribute__((__dllexport__)) -# define BOOST_SYMBOL_IMPORT __attribute__((__dllimport__)) -# else -# define BOOST_SYMBOL_EXPORT __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_IMPORT -# endif -# define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) -#else -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif - -// -// RTTI and typeinfo detection is possible post gcc-4.3: -// -#if BOOST_GCC_VERSION > 40300 -# ifndef __GXX_RTTI -# ifndef BOOST_NO_TYPEID -# define BOOST_NO_TYPEID -# endif -# ifndef BOOST_NO_RTTI -# define BOOST_NO_RTTI -# endif -# endif -#endif - -// -// Recent GCC versions have __int128 when in 64-bit mode. -// -// We disable this if the compiler is really nvcc with C++03 as it -// doesn't actually support __int128 as of CUDA_VERSION=7500 -// even though it defines __SIZEOF_INT128__. -// See https://svn.boost.org/trac/boost/ticket/8048 -// https://svn.boost.org/trac/boost/ticket/11852 -// Only re-enable this for nvcc if you're absolutely sure -// of the circumstances under which it's supported: -// -#if defined(__CUDACC__) -# if defined(BOOST_GCC_CXX11) -# define BOOST_NVCC_CXX11 -# else -# define BOOST_NVCC_CXX03 -# endif -#endif - -#if defined(__SIZEOF_INT128__) && !defined(BOOST_NVCC_CXX03) -# define BOOST_HAS_INT128 -#endif -// -// Recent GCC versions have a __float128 native type, we need to -// include a std lib header to detect this - not ideal, but we'll -// be including <cstddef> later anyway when we select the std lib. -// -// Nevertheless, as of CUDA 7.5, using __float128 with the host -// compiler in pre-C++11 mode is still not supported. -// See https://svn.boost.org/trac/boost/ticket/11852 -// -#ifdef __cplusplus -#include <cstddef> -#else -#include <stddef.h> -#endif -#if defined(_GLIBCXX_USE_FLOAT128) && !defined(__STRICT_ANSI__) && !defined(BOOST_NVCC_CXX03) -# define BOOST_HAS_FLOAT128 -#endif - -// C++0x features in 4.3.n and later -// -#if (BOOST_GCC_VERSION >= 40300) && defined(BOOST_GCC_CXX11) -// C++0x features are only enabled when -std=c++0x or -std=gnu++0x are -// passed on the command line, which in turn defines -// __GXX_EXPERIMENTAL_CXX0X__. -# define BOOST_HAS_DECLTYPE -# define BOOST_HAS_RVALUE_REFS -# define BOOST_HAS_STATIC_ASSERT -# define BOOST_HAS_VARIADIC_TMPL -#else -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif - -// C++0x features in 4.4.n and later -// -#if (BOOST_GCC_VERSION < 40400) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif - -#if BOOST_GCC_VERSION < 40500 -# define BOOST_NO_SFINAE_EXPR -#endif - -// GCC 4.5 forbids declaration of defaulted functions in private or protected sections -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ == 5) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS -#endif - -// C++0x features in 4.5.0 and later -// -#if (BOOST_GCC_VERSION < 40500) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -// C++0x features in 4.5.1 and later -// -#if (BOOST_GCC_VERSION < 40501) || !defined(BOOST_GCC_CXX11) -// scoped enums have a serious bug in 4.4.0, so define BOOST_NO_CXX11_SCOPED_ENUMS before 4.5.1 -// See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38064 -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -// C++0x features in 4.6.n and later -// -#if (BOOST_GCC_VERSION < 40600) || !defined(BOOST_GCC_CXX11) -#define BOOST_NO_CXX11_DEFAULTED_MOVES -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -// C++0x features in 4.7.n and later -// -#if (BOOST_GCC_VERSION < 40700) || !defined(BOOST_GCC_CXX11) -// Note that while constexpr is partly supported in gcc-4.6 it's a -// pre-std version with several bugs: -# define BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_CXX11_FINAL -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#endif - -// C++0x features in 4.8.n and later -// -#if (BOOST_GCC_VERSION < 40800) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_THREAD_LOCAL -# define BOOST_NO_CXX11_SFINAE_EXPR -#endif - -// C++0x features in 4.8.1 and later -// -#if (BOOST_GCC_VERSION < 40801) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_DECLTYPE_N3276 -# define BOOST_NO_CXX11_REF_QUALIFIERS -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif - -// C++0x features in 5.1 and later -// -#if (BOOST_GCC_VERSION < 50100) || !defined(BOOST_GCC_CXX11) -# define BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif - -// C++14 features in 4.9.0 and later -// -#if (BOOST_GCC_VERSION < 40900) || (__cplusplus < 201300) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -# define BOOST_NO_CXX14_DECLTYPE_AUTO -# if !((BOOST_GCC_VERSION >= 40801) && (BOOST_GCC_VERSION < 40900) && defined(BOOST_GCC_CXX11)) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -# endif -#endif - - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if (BOOST_GCC_VERSION < 50200) || !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#if __GNUC__ >= 7 -# define BOOST_FALLTHROUGH __attribute__((fallthrough)) -#endif - -#if defined(__MINGW32__) && !defined(__MINGW64__) -// Currently (March 2019) thread_local is broken on mingw for all current 32bit compiler releases, see -// https://sourceforge.net/p/mingw-w64/bugs/527/ -// Not setting this causes program termination on thread exit. -#define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -// -// Unused attribute: -#if __GNUC__ >= 4 -# define BOOST_ATTRIBUTE_UNUSED __attribute__((__unused__)) -#endif - -// Type aliasing hint. Supported since gcc 3.3. -#define BOOST_MAY_ALIAS __attribute__((__may_alias__)) - -// -// __builtin_unreachable: -#if BOOST_GCC_VERSION >= 40500 -#define BOOST_UNREACHABLE_RETURN(x) __builtin_unreachable(); -#endif - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "GNU C++ version " __VERSION__ -#endif - -// ConceptGCC compiler: -// http://www.generic-programming.org/software/ConceptGCC/ -#ifdef __GXX_CONCEPTS__ -# define BOOST_HAS_CONCEPTS -# define BOOST_COMPILER "ConceptGCC version " __VERSION__ -#endif - -// versions check: -// we don't know gcc prior to version 3.30: -#if (BOOST_GCC_VERSION< 30300) -# error "Compiler not configured - please reconfigure" -#endif -// -// last known and checked version is 8.1: -#if (BOOST_GCC_VERSION > 80100) -# if defined(BOOST_ASSERT_CONFIG) -# error "Boost.Config is older than your compiler - please check for an updated Boost release." -# else -// we don't emit warnings here anymore since there are no defect macros defined for -// gcc post 3.4, so any failures are gcc regressions... -//# warning "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - diff --git a/ThirdParty/boost/config/compiler/gcc_xml.hpp b/ThirdParty/boost/config/compiler/gcc_xml.hpp deleted file mode 100644 index 4d14b42af76440c3e12f16e20655e1f9d1d23b55..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/gcc_xml.hpp +++ /dev/null @@ -1,112 +0,0 @@ -// (C) Copyright John Maddock 2006. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// GCC-XML C++ compiler setup: - -# if !defined(__GCCXML_GNUC__) || ((__GCCXML_GNUC__ <= 3) && (__GCCXML_GNUC_MINOR__ <= 3)) -# define BOOST_NO_IS_ABSTRACT -# endif - -// -// Threading support: Turn this on unconditionally here (except for -// those platforms where we can know for sure). It will get turned off again -// later if no threading API is detected. -// -#if !defined(__MINGW32__) && !defined(_MSC_VER) && !defined(linux) && !defined(__linux) && !defined(__linux__) -# define BOOST_HAS_THREADS -#endif - -// -// gcc has "long long" -// -#define BOOST_HAS_LONG_LONG - -// C++0x features: -// -# define BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE_N3276 -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_VARIADIC_MACROS -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_SFINAE_EXPR -# define BOOST_NO_CXX11_SFINAE_EXPR -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_UNICODE_LITERALS -# define BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES -# define BOOST_NO_CXX11_REF_QUALIFIERS -# define BOOST_NO_CXX11_FINAL -# define BOOST_NO_CXX11_THREAD_LOCAL -# define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#define BOOST_COMPILER "GCC-XML C++ version " __GCCXML__ - - diff --git a/ThirdParty/boost/config/compiler/hp_acc.hpp b/ThirdParty/boost/config/compiler/hp_acc.hpp deleted file mode 100644 index cf5667b5200dcdc009efba30b8bed222f9746e7c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/hp_acc.hpp +++ /dev/null @@ -1,148 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Toon Knapen 2003. -// (C) Copyright Boris Gubenko 2006 - 2007. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// HP aCC C++ compiler setup: - -#if defined(__EDG__) -#include <boost/config/compiler/common_edg.hpp> -#endif - -#if (__HP_aCC <= 33100) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_OPERATORS_IN_NAMESPACE -# if !defined(_NAMESPACE_STD) -# define BOOST_NO_STD_LOCALE -# define BOOST_NO_STRINGSTREAM -# endif -#endif - -#if (__HP_aCC <= 33300) -// member templates are sufficiently broken that we disable them for now -# define BOOST_NO_MEMBER_TEMPLATES -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE -#endif - -#if (__HP_aCC <= 38000) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -#if (__HP_aCC > 50000) && (__HP_aCC < 60000) -# define BOOST_NO_UNREACHABLE_RETURN_DETECTION -# define BOOST_NO_TEMPLATE_TEMPLATES -# define BOOST_NO_SWPRINTF -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_IS_ABSTRACT -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#endif - -// optional features rather than defects: -#if (__HP_aCC >= 33900) -# define BOOST_HAS_LONG_LONG -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -#endif - -#if (__HP_aCC >= 50000 ) && (__HP_aCC <= 53800 ) || (__HP_aCC < 31300 ) -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -#endif - -// This macro should not be defined when compiling in strict ansi -// mode, but, currently, we don't have the ability to determine -// what standard mode we are compiling with. Some future version -// of aCC6 compiler will provide predefined macros reflecting the -// compilation options, including the standard mode. -#if (__HP_aCC >= 60000) || ((__HP_aCC > 38000) && defined(__hpxstd98)) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -#define BOOST_COMPILER "HP aCC version " BOOST_STRINGIZE(__HP_aCC) - -// -// versions check: -// we don't support HP aCC prior to version 33000: -#if __HP_aCC < 33000 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// -// Extended checks for supporting aCC on PA-RISC -#if __HP_aCC > 30000 && __HP_aCC < 50000 -# if __HP_aCC < 38000 - // versions prior to version A.03.80 not supported -# error "Compiler version not supported - version A.03.80 or higher is required" -# elif !defined(__hpxstd98) - // must compile using the option +hpxstd98 with version A.03.80 and above -# error "Compiler option '+hpxstd98' is required for proper support" -# endif //PA-RISC -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if !defined(__EDG__) - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -/* - See https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443331 and - https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443436 -*/ - -#if (__HP_aCC < 62500) || !defined(HP_CXX0x_SOURCE) - #define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#endif - -// -// last known and checked version for HP-UX/ia64 is 61300 -// last known and checked version for PA-RISC is 38000 -#if ((__HP_aCC > 61300) || ((__HP_aCC > 38000) && defined(__hpxstd98))) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif diff --git a/ThirdParty/boost/config/compiler/intel.hpp b/ThirdParty/boost/config/compiler/intel.hpp deleted file mode 100644 index 2247bc713cd8285cf966a24f00d5cecdc91adfa6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/intel.hpp +++ /dev/null @@ -1,574 +0,0 @@ -// (C) Copyright John Maddock 2001-8. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002 - 2003. -// (C) Copyright Guillaume Melquiond 2002 - 2003. -// (C) Copyright Beman Dawes 2003. -// (C) Copyright Martin Wille 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Intel compiler setup: - -#if defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1500) && (defined(_MSC_VER) || defined(__GNUC__)) - -#ifdef _MSC_VER - -#include <boost/config/compiler/visualc.hpp> - -#undef BOOST_MSVC -#undef BOOST_MSVC_FULL_VER - -#if (__INTEL_COMPILER >= 1500) && (_MSC_VER >= 1900) -// -// These appear to be supported, even though VC++ may not support them: -// -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_LOG1P -#undef BOOST_NO_CXX14_BINARY_LITERALS -// This one may be a little risky to enable?? -#undef BOOST_NO_SFINAE_EXPR - -#endif - -#if (__INTEL_COMPILER <= 1600) && !defined(BOOST_NO_CXX14_VARIABLE_TEMPLATES) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -#else // defined(_MSC_VER) - -#include <boost/config/compiler/gcc.hpp> - -#undef BOOST_GCC_VERSION -#undef BOOST_GCC_CXX11 -#undef BOOST_GCC -#undef BOOST_FALLTHROUGH - -// Broken in all versions up to 17 (newer versions not tested) -#if (__INTEL_COMPILER <= 1700) && !defined(BOOST_NO_CXX14_CONSTEXPR) -# define BOOST_NO_CXX14_CONSTEXPR -#endif - -#if (__INTEL_COMPILER >= 1800) && (__cplusplus >= 201703) -# define BOOST_FALLTHROUGH [[fallthrough]] -#endif - -#endif // defined(_MSC_VER) - -#undef BOOST_COMPILER - -#if defined(__INTEL_COMPILER) -#if __INTEL_COMPILER == 9999 -# define BOOST_INTEL_CXX_VERSION 1200 // Intel bug in 12.1. -#else -# define BOOST_INTEL_CXX_VERSION __INTEL_COMPILER -#endif -#elif defined(__ICL) -# define BOOST_INTEL_CXX_VERSION __ICL -#elif defined(__ICC) -# define BOOST_INTEL_CXX_VERSION __ICC -#elif defined(__ECC) -# define BOOST_INTEL_CXX_VERSION __ECC -#endif - -// Flags determined by comparing output of 'icpc -dM -E' with and without '-std=c++0x' -#if (!(defined(_WIN32) || defined(_WIN64)) && defined(__STDC_HOSTED__) && (__STDC_HOSTED__ && (BOOST_INTEL_CXX_VERSION <= 1200))) || defined(__GXX_EXPERIMENTAL_CPP0X__) || defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_INTEL_STDCXX0X -#endif -#if defined(_MSC_VER) && (_MSC_VER >= 1600) -# define BOOST_INTEL_STDCXX0X -#endif - -#ifdef __GNUC__ -# define BOOST_INTEL_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#endif - -#if !defined(BOOST_COMPILER) -# if defined(BOOST_INTEL_STDCXX0X) -# define BOOST_COMPILER "Intel C++ C++0x mode version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -# else -# define BOOST_COMPILER "Intel C++ version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -# endif -#endif - -#define BOOST_INTEL BOOST_INTEL_CXX_VERSION - -#if defined(_WIN32) || defined(_WIN64) -# define BOOST_INTEL_WIN BOOST_INTEL -#else -# define BOOST_INTEL_LINUX BOOST_INTEL -#endif - -#else // defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1500) && (defined(_MSC_VER) || defined(__GNUC__)) - -#include <boost/config/compiler/common_edg.hpp> - -#if defined(__INTEL_COMPILER) -#if __INTEL_COMPILER == 9999 -# define BOOST_INTEL_CXX_VERSION 1200 // Intel bug in 12.1. -#else -# define BOOST_INTEL_CXX_VERSION __INTEL_COMPILER -#endif -#elif defined(__ICL) -# define BOOST_INTEL_CXX_VERSION __ICL -#elif defined(__ICC) -# define BOOST_INTEL_CXX_VERSION __ICC -#elif defined(__ECC) -# define BOOST_INTEL_CXX_VERSION __ECC -#endif - -// Flags determined by comparing output of 'icpc -dM -E' with and without '-std=c++0x' -#if (!(defined(_WIN32) || defined(_WIN64)) && defined(__STDC_HOSTED__) && (__STDC_HOSTED__ && (BOOST_INTEL_CXX_VERSION <= 1200))) || defined(__GXX_EXPERIMENTAL_CPP0X__) || defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_INTEL_STDCXX0X -#endif -#if defined(_MSC_VER) && (_MSC_VER >= 1600) -# define BOOST_INTEL_STDCXX0X -#endif - -#ifdef __GNUC__ -# define BOOST_INTEL_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#endif - -#if !defined(BOOST_COMPILER) -# if defined(BOOST_INTEL_STDCXX0X) -# define BOOST_COMPILER "Intel C++ C++0x mode version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -# else -# define BOOST_COMPILER "Intel C++ version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -# endif -#endif - -#define BOOST_INTEL BOOST_INTEL_CXX_VERSION - -#if defined(_WIN32) || defined(_WIN64) -# define BOOST_INTEL_WIN BOOST_INTEL -#else -# define BOOST_INTEL_LINUX BOOST_INTEL -#endif - -#if (BOOST_INTEL_CXX_VERSION <= 600) - -# if defined(_MSC_VER) && (_MSC_VER <= 1300) // added check for <= VC 7 (Peter Dimov) - -// Boost libraries assume strong standard conformance unless otherwise -// indicated by a config macro. As configured by Intel, the EDG front-end -// requires certain compiler options be set to achieve that strong conformance. -// Particularly /Qoption,c,--arg_dep_lookup (reported by Kirk Klobe & Thomas Witt) -// and /Zc:wchar_t,forScope. See boost-root/tools/build/intel-win32-tools.jam for -// details as they apply to particular versions of the compiler. When the -// compiler does not predefine a macro indicating if an option has been set, -// this config file simply assumes the option has been set. -// Thus BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP will not be defined, even if -// the compiler option is not enabled. - -# define BOOST_NO_SWPRINTF -# endif - -// Void returns, 64 bit integrals don't work when emulating VC 6 (Peter Dimov) - -# if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_VOID_RETURNS -# define BOOST_NO_INTEGRAL_INT64_T -# endif - -#endif - -#if (BOOST_INTEL_CXX_VERSION <= 710) && defined(_WIN32) -# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS -#endif - -// See http://aspn.activestate.com/ASPN/Mail/Message/boost/1614864 -#if BOOST_INTEL_CXX_VERSION < 600 -# define BOOST_NO_INTRINSIC_WCHAR_T -#else -// We should test the macro _WCHAR_T_DEFINED to check if the compiler -// supports wchar_t natively. *BUT* there is a problem here: the standard -// headers define this macro if they typedef wchar_t. Anyway, we're lucky -// because they define it without a value, while Intel C++ defines it -// to 1. So we can check its value to see if the macro was defined natively -// or not. -// Under UNIX, the situation is exactly the same, but the macro _WCHAR_T -// is used instead. -# if ((_WCHAR_T_DEFINED + 0) == 0) && ((_WCHAR_T + 0) == 0) -# define BOOST_NO_INTRINSIC_WCHAR_T -# endif -#endif - -#if defined(__GNUC__) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -// -// Figure out when Intel is emulating this gcc bug -// (All Intel versions prior to 9.0.26, and versions -// later than that if they are set up to emulate gcc 3.2 -// or earlier): -// -# if ((__GNUC__ == 3) && (__GNUC_MINOR__ <= 2)) || (BOOST_INTEL < 900) || (__INTEL_COMPILER_BUILD_DATE < 20050912) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# endif -#endif -#if (defined(__GNUC__) && (__GNUC__ < 4)) || (defined(_WIN32) && (BOOST_INTEL_CXX_VERSION <= 1200)) || (BOOST_INTEL_CXX_VERSION <= 1200) -// GCC or VC emulation: -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif -// -// Verify that we have actually got BOOST_NO_INTRINSIC_WCHAR_T -// set correctly, if we don't do this now, we will get errors later -// in type_traits code among other things, getting this correct -// for the Intel compiler is actually remarkably fragile and tricky: -// -#ifdef __cplusplus -#if defined(BOOST_NO_INTRINSIC_WCHAR_T) -#include <cwchar> -template< typename T > struct assert_no_intrinsic_wchar_t; -template<> struct assert_no_intrinsic_wchar_t<wchar_t> { typedef void type; }; -// if you see an error here then you need to unset BOOST_NO_INTRINSIC_WCHAR_T -// where it is defined above: -typedef assert_no_intrinsic_wchar_t<unsigned short>::type assert_no_intrinsic_wchar_t_; -#else -template< typename T > struct assert_intrinsic_wchar_t; -template<> struct assert_intrinsic_wchar_t<wchar_t> {}; -// if you see an error here then define BOOST_NO_INTRINSIC_WCHAR_T on the command line: -template<> struct assert_intrinsic_wchar_t<unsigned short> {}; -#endif -#endif - -#if defined(_MSC_VER) && (_MSC_VER+0 >= 1000) -# if _MSC_VER >= 1200 -# define BOOST_HAS_MS_INT64 -# endif -# define BOOST_NO_SWPRINTF -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#elif defined(_WIN32) -# define BOOST_DISABLE_WIN32 -#endif - -// I checked version 6.0 build 020312Z, it implements the NRVO. -// Correct this as you find out which version of the compiler -// implemented the NRVO first. (Daniel Frey) -#if (BOOST_INTEL_CXX_VERSION >= 600) -# define BOOST_HAS_NRVO -#endif - -// Branch prediction hints -// I'm not sure 8.0 was the first version to support these builtins, -// update the condition if the version is not accurate. (Andrey Semashev) -#if defined(__GNUC__) && BOOST_INTEL_CXX_VERSION >= 800 -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) -#endif - -// RTTI -// __RTTI is the EDG macro -// __INTEL_RTTI__ is the Intel macro -// __GXX_RTTI is the g++ macro -// _CPPRTTI is the MSVC++ macro -#if !defined(__RTTI) && !defined(__INTEL_RTTI__) && !defined(__GXX_RTTI) && !defined(_CPPRTTI) - -#if !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -// in MS mode, static typeid works even when RTTI is off -#if !defined(_MSC_VER) && !defined(BOOST_NO_TYPEID) -# define BOOST_NO_TYPEID -#endif - -#endif - -// -// versions check: -// we don't support Intel prior to version 6.0: -#if BOOST_INTEL_CXX_VERSION < 600 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// Intel on MacOS requires -#if defined(__APPLE__) && defined(__INTEL_COMPILER) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -// Intel on Altix Itanium -#if defined(__itanium__) && defined(__INTEL_COMPILER) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -// -// An attempt to value-initialize a pointer-to-member may trigger an -// internal error on Intel <= 11.1 (last checked version), as was -// reported by John Maddock, Intel support issue 589832, May 2010. -// Moreover, according to test results from Huang-Vista-x86_32_intel, -// intel-vc9-win-11.1 may leave a non-POD array uninitialized, in some -// cases when it should be value-initialized. -// (Niels Dekker, LKEB, May 2010) -// Apparently Intel 12.1 (compiler version number 9999 !!) has the same issue (compiler regression). -#if defined(__INTEL_COMPILER) -# if (__INTEL_COMPILER <= 1110) || (__INTEL_COMPILER == 9999) || (defined(_WIN32) && (__INTEL_COMPILER < 1600)) -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# endif -#endif - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -# define BOOST_SYMBOL_EXPORT __attribute__((visibility("default"))) -# define BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_VISIBLE __attribute__((visibility("default"))) -#endif - -// Type aliasing hint -#if defined(__GNUC__) && (BOOST_INTEL_CXX_VERSION >= 1300) -# define BOOST_MAY_ALIAS __attribute__((__may_alias__)) -#endif - -// -// C++0x features -// For each feature we need to check both the Intel compiler version, -// and the version of MSVC or GCC that we are emulating. -// See http://software.intel.com/en-us/articles/c0x-features-supported-by-intel-c-compiler/ -// for a list of which features were implemented in which Intel releases. -// -#if defined(BOOST_INTEL_STDCXX0X) -// BOOST_NO_CXX11_CONSTEXPR: -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40600)) && !defined(_MSC_VER) -// Available in earlier Intel versions, but fail our tests: -# undef BOOST_NO_CXX11_CONSTEXPR -#endif -// BOOST_NO_CXX11_NULLPTR: -#if (BOOST_INTEL_CXX_VERSION >= 1210) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40600)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_NULLPTR -#endif -// BOOST_NO_CXX11_TEMPLATE_ALIASES -#if (BOOST_INTEL_CXX_VERSION >= 1210) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40700)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_TEMPLATE_ALIASES -#endif - -// BOOST_NO_CXX11_DECLTYPE -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40300)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_DECLTYPE -#endif - -// BOOST_NO_CXX11_DECLTYPE_N3276 -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40800)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -// BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40300)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif - -// BOOST_NO_CXX11_RVALUE_REFERENCES -#if (BOOST_INTEL_CXX_VERSION >= 1300) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40300)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -// This is available from earlier Intel versions, but breaks Filesystem and other libraries: -# undef BOOST_NO_CXX11_RVALUE_REFERENCES -#endif - -// BOOST_NO_CXX11_STATIC_ASSERT -#if (BOOST_INTEL_CXX_VERSION >= 1110) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40300)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_STATIC_ASSERT -#endif - -// BOOST_NO_CXX11_VARIADIC_TEMPLATES -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif - -// BOOST_NO_CXX11_VARIADIC_MACROS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40200)) && (!defined(_MSC_VER) || (_MSC_VER >= 1400)) -# undef BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -// BOOST_NO_CXX11_AUTO_DECLARATIONS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_AUTO_DECLARATIONS -#endif - -// BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif - -// BOOST_NO_CXX11_CHAR16_T -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -# undef BOOST_NO_CXX11_CHAR16_T -#endif - -// BOOST_NO_CXX11_CHAR32_T -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -# undef BOOST_NO_CXX11_CHAR32_T -#endif - -// BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#endif - -// BOOST_NO_CXX11_DELETED_FUNCTIONS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_DELETED_FUNCTIONS -#endif - -// BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_VER >= 1700)) -# undef BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -// BOOST_NO_CXX11_SCOPED_ENUMS -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40501)) && (!defined(_MSC_VER) || (_MSC_VER >= 1700)) -// This is available but broken in earlier Intel releases. -# undef BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -// BOOST_NO_SFINAE_EXPR -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -# undef BOOST_NO_SFINAE_EXPR -#endif - -// BOOST_NO_CXX11_SFINAE_EXPR -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40800)) && !defined(_MSC_VER) -# undef BOOST_NO_CXX11_SFINAE_EXPR -#endif - -// BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -// This is available in earlier Intel releases, but breaks Multiprecision: -# undef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif - -// BOOST_NO_CXX11_LAMBDAS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) && (!defined(_MSC_VER) || (_MSC_VER >= 1600)) -# undef BOOST_NO_CXX11_LAMBDAS -#endif - -// BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) -# undef BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif - -// BOOST_NO_CXX11_RANGE_BASED_FOR -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40600)) && (!defined(_MSC_VER) || (_MSC_VER >= 1700)) -# undef BOOST_NO_CXX11_RANGE_BASED_FOR -#endif - -// BOOST_NO_CXX11_RAW_LITERALS -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_RAW_LITERALS -#endif - -// BOOST_NO_CXX11_UNICODE_LITERALS -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40500)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -# undef BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -// BOOST_NO_CXX11_NOEXCEPT -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40600)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -// Available in earlier Intel release, but generates errors when used with -// conditional exception specifications, for example in multiprecision: -# undef BOOST_NO_CXX11_NOEXCEPT -#endif - -// BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40600)) && (!defined(_MSC_VER) || (_MSC_VER >= 9999)) -# undef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -// BOOST_NO_CXX11_USER_DEFINED_LITERALS -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40700)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 190021730)) -# undef BOOST_NO_CXX11_USER_DEFINED_LITERALS -#endif - -// BOOST_NO_CXX11_ALIGNAS -#if (BOOST_INTEL_CXX_VERSION >= 1500) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40800)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 190021730)) -# undef BOOST_NO_CXX11_ALIGNAS -#endif - -// BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#if (BOOST_INTEL_CXX_VERSION >= 1200) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 180020827)) -# undef BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -// BOOST_NO_CXX11_INLINE_NAMESPACES -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40400)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 190021730)) -# undef BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -// BOOST_NO_CXX11_REF_QUALIFIERS -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40800)) && (!defined(_MSC_VER) || (_MSC_FULL_VER >= 190021730)) -# undef BOOST_NO_CXX11_REF_QUALIFIERS -#endif - -// BOOST_NO_CXX11_FINAL -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 40700)) && (!defined(_MSC_VER) || (_MSC_VER >= 1700)) -# undef BOOST_NO_CXX11_FINAL -#endif - -// BOOST_NO_CXX11_UNRESTRICTED_UNION -#if (BOOST_INTEL_CXX_VERSION >= 1400) && (!defined(BOOST_INTEL_GCC_VERSION) || (BOOST_INTEL_GCC_VERSION >= 50100)) && (!defined(_MSC_VER)) -# undef BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif - -#endif // defined(BOOST_INTEL_STDCXX0X) - -// -// Broken in all versions up to 15: -#define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS - -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION <= 1310) -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION == 1400) -// A regression in Intel's compiler means that <tuple> seems to be broken in this release as well as <future> : -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -#if (BOOST_INTEL_CXX_VERSION < 1200) -// -// fenv.h appears not to work with Intel prior to 12.0: -// -# define BOOST_NO_FENV_H -#endif - -// Intel 13.10 fails to access defaulted functions of a base class declared in private or protected sections, -// producing the following errors: -// error #453: protected function "..." (declared at ...") is not accessible through a "..." pointer or object -#if (BOOST_INTEL_CXX_VERSION <= 1310) -# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS -#endif - -#if defined(_MSC_VER) && (_MSC_VER >= 1600) -# define BOOST_HAS_STDINT_H -#endif - -#if defined(__CUDACC__) -# if defined(BOOST_GCC_CXX11) -# define BOOST_NVCC_CXX11 -# else -# define BOOST_NVCC_CXX03 -# endif -#endif - -#if defined(__LP64__) && defined(__GNUC__) && (BOOST_INTEL_CXX_VERSION >= 1310) && !defined(BOOST_NVCC_CXX03) -# define BOOST_HAS_INT128 -#endif - -#endif // defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1500) && (defined(_MSC_VER) || defined(__GNUC__)) -// -// last known and checked version: -#if (BOOST_INTEL_CXX_VERSION > 1700) -# if defined(BOOST_ASSERT_CONFIG) -# error "Boost.Config is older than your compiler - please check for an updated Boost release." -# elif defined(_MSC_VER) -// -// We don't emit this warning any more, since we have so few -// defect macros set anyway (just the one). -// -//# pragma message("boost: Unknown compiler version - please run the configure tests and report the results") -# endif -#endif - diff --git a/ThirdParty/boost/config/compiler/metrowerks.hpp b/ThirdParty/boost/config/compiler/metrowerks.hpp deleted file mode 100644 index 2e6cf70b60fdc3cb495e8f8b9f8c95a140177b3e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/metrowerks.hpp +++ /dev/null @@ -1,196 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright David Abrahams 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Stefan Slapeta 2004. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Metrowerks C++ compiler setup: - -// locale support is disabled when linking with the dynamic runtime -# ifdef _MSL_NO_LOCALE -# define BOOST_NO_STD_LOCALE -# endif - -# if __MWERKS__ <= 0x2301 // 5.3 -# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# define BOOST_NO_POINTER_TO_MEMBER_CONST -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -# endif - -# if __MWERKS__ <= 0x2401 // 6.2 -//# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# endif - -# if(__MWERKS__ <= 0x2407) // 7.x -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -# define BOOST_NO_UNREACHABLE_RETURN_DETECTION -# endif - -# if(__MWERKS__ <= 0x3003) // 8.x -# define BOOST_NO_SFINAE -# endif - -// the "|| !defined(BOOST_STRICT_CONFIG)" part should apply to the last -// tested version *only*: -# if(__MWERKS__ <= 0x3207) || !defined(BOOST_STRICT_CONFIG) // 9.6 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_IS_ABSTRACT -# endif - -#if !__option(wchar_type) -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -#if !__option(exceptions) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if (__INTEL__ && _WIN32) || (__POWERPC__ && macintosh) -# if __MWERKS__ == 0x3000 -# define BOOST_COMPILER_VERSION 8.0 -# elif __MWERKS__ == 0x3001 -# define BOOST_COMPILER_VERSION 8.1 -# elif __MWERKS__ == 0x3002 -# define BOOST_COMPILER_VERSION 8.2 -# elif __MWERKS__ == 0x3003 -# define BOOST_COMPILER_VERSION 8.3 -# elif __MWERKS__ == 0x3200 -# define BOOST_COMPILER_VERSION 9.0 -# elif __MWERKS__ == 0x3201 -# define BOOST_COMPILER_VERSION 9.1 -# elif __MWERKS__ == 0x3202 -# define BOOST_COMPILER_VERSION 9.2 -# elif __MWERKS__ == 0x3204 -# define BOOST_COMPILER_VERSION 9.3 -# elif __MWERKS__ == 0x3205 -# define BOOST_COMPILER_VERSION 9.4 -# elif __MWERKS__ == 0x3206 -# define BOOST_COMPILER_VERSION 9.5 -# elif __MWERKS__ == 0x3207 -# define BOOST_COMPILER_VERSION 9.6 -# else -# define BOOST_COMPILER_VERSION __MWERKS__ -# endif -#else -# define BOOST_COMPILER_VERSION __MWERKS__ -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if __MWERKS__ > 0x3206 && __option(rvalue_refs) -# define BOOST_HAS_RVALUE_REFS -#else -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -#define BOOST_COMPILER "Metrowerks CodeWarrior C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) - -// -// versions check: -// we don't support Metrowerks prior to version 5.3: -#if __MWERKS__ < 0x2301 -# error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version: -#if (__MWERKS__ > 0x3205) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - - - - - - diff --git a/ThirdParty/boost/config/compiler/mpw.hpp b/ThirdParty/boost/config/compiler/mpw.hpp deleted file mode 100644 index 8d7e8c2808e6ae0ca3151cba0cbef93c0dbbf7c8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/mpw.hpp +++ /dev/null @@ -1,138 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// MPW C++ compilers setup: - -# if defined(__SC__) -# define BOOST_COMPILER "MPW SCpp version " BOOST_STRINGIZE(__SC__) -# elif defined(__MRC__) -# define BOOST_COMPILER "MPW MrCpp version " BOOST_STRINGIZE(__MRC__) -# else -# error "Using MPW compiler configuration by mistake. Please update." -# endif - -// -// MPW 8.90: -// -#if (MPW_CPLUS <= 0x890) || !defined(BOOST_STRICT_CONFIG) -# define BOOST_NO_CV_SPECIALIZATIONS -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_INTRINSIC_WCHAR_T -# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# define BOOST_NO_USING_TEMPLATE - -# define BOOST_NO_CWCHAR -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - -# define BOOST_NO_STD_ALLOCATOR /* actually a bug with const reference overloading */ - -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -// -// versions check: -// we don't support MPW prior to version 8.9: -#if MPW_CPLUS < 0x890 -# error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 0x890: -#if (MPW_CPLUS > 0x890) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - diff --git a/ThirdParty/boost/config/compiler/pathscale.hpp b/ThirdParty/boost/config/compiler/pathscale.hpp deleted file mode 100644 index ec6bfd5eee12294ff77d88b515c85adb0eec53cf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/pathscale.hpp +++ /dev/null @@ -1,136 +0,0 @@ -// (C) Copyright Bryce Lelbach 2011 - -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// PathScale EKOPath C++ Compiler - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "PathScale EKOPath C++ Compiler version " __PATHSCALE__ -#endif - -#if __PATHCC__ >= 6 -// PathCC is based on clang, and supports the __has_*() builtins used -// to detect features in clang.hpp. Since the clang toolset is much -// better maintained, it is more convenient to reuse its definitions. -# include "boost/config/compiler/clang.hpp" -#elif __PATHCC__ >= 4 -# define BOOST_MSVC6_MEMBER_TEMPLATES -# define BOOST_HAS_UNISTD_H -# define BOOST_HAS_STDINT_H -# define BOOST_HAS_SIGACTION -# define BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_THREADS -# define BOOST_HAS_PTHREADS -# define BOOST_HAS_PTHREAD_YIELD -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -# define BOOST_HAS_NRVO -# define BOOST_HAS_NL_TYPES_H -# define BOOST_HAS_NANOSLEEP -# define BOOST_HAS_LONG_LONG -# define BOOST_HAS_LOG1P -# define BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_EXPM1 -# define BOOST_HAS_DIRENT_H -# define BOOST_HAS_CLOCK_GETTIME -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_UNICODE_LITERALS -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_SFINAE_EXPR -# define BOOST_NO_CXX11_SFINAE_EXPR -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE_N3276 -# define BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES -# define BOOST_NO_CXX11_REF_QUALIFIERS -# define BOOST_NO_CXX11_FINAL -# define BOOST_NO_CXX11_THREAD_LOCAL -# define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif -#endif diff --git a/ThirdParty/boost/config/compiler/sunpro_cc.hpp b/ThirdParty/boost/config/compiler/sunpro_cc.hpp deleted file mode 100644 index 7d838fc99edd04c94585eb05169cabacb824c677..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/sunpro_cc.hpp +++ /dev/null @@ -1,214 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Peter Dimov 2002. -// (C) Copyright Aleksey Gurtovoy 2002 - 2003. -// (C) Copyright David Abrahams 2002. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Sun C++ compiler setup: - -# if __SUNPRO_CC <= 0x500 -# define BOOST_NO_MEMBER_TEMPLATES -# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# endif - -# if (__SUNPRO_CC <= 0x520) - // - // Sunpro 5.2 and earler: - // - // although sunpro 5.2 supports the syntax for - // inline initialization it often gets the value - // wrong, especially where the value is computed - // from other constants (J Maddock 6th May 2001) -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION - - // Although sunpro 5.2 supports the syntax for - // partial specialization, it often seems to - // bind to the wrong specialization. Better - // to disable it until suppport becomes more stable - // (J Maddock 6th May 2001). -# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# endif - -# if (__SUNPRO_CC <= 0x530) - // Requesting debug info (-g) with Boost.Python results - // in an internal compiler error for "static const" - // initialized in-class. - // >> Assertion: (../links/dbg_cstabs.cc, line 611) - // while processing ../test.cpp at line 0. - // (Jens Maurer according to Gottfried Ganssauge 04 Mar 2002) -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION - - // SunPro 5.3 has better support for partial specialization, - // but breaks when compiling std::less<shared_ptr<T> > - // (Jens Maurer 4 Nov 2001). - - // std::less specialization fixed as reported by George - // Heintzelman; partial specialization re-enabled - // (Peter Dimov 17 Jan 2002) - -//# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // integral constant expressions with 64 bit numbers fail -# define BOOST_NO_INTEGRAL_INT64_T -# endif - -# if (__SUNPRO_CC < 0x570) -# define BOOST_NO_TEMPLATE_TEMPLATES - // see http://lists.boost.org/MailArchives/boost/msg47184.php - // and http://lists.boost.org/MailArchives/boost/msg47220.php -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_SFINAE -# define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS -# endif -# if (__SUNPRO_CC <= 0x580) -# define BOOST_NO_IS_ABSTRACT -# endif - -# if (__SUNPRO_CC <= 0x5100) - // Sun 5.10 may not correctly value-initialize objects of - // some user defined types, as was reported in April 2010 - // (CR 6947016), and confirmed by Steve Clamage. - // (Niels Dekker, LKEB, May 2010). -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# endif - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if __SUNPRO_CC > 0x500 -# define BOOST_SYMBOL_EXPORT __global -# define BOOST_SYMBOL_IMPORT __global -# define BOOST_SYMBOL_VISIBLE __global -#endif - -#if (__SUNPRO_CC < 0x5130) -// C++03 features in 12.4: -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_ADL_BARRIER -#define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#if (__SUNPRO_CC < 0x5130) || (__cplusplus < 201100) -// C++11 only featuires in 12.4: -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif - -#if (__SUNPRO_CC < 0x5140) || (__cplusplus < 201103) -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -// -// C++0x features -// -# define BOOST_HAS_LONG_LONG - -#define BOOST_NO_CXX11_SFINAE_EXPR - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) || (__cplusplus < 201402L) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -// Turn on threading support for Solaris 12. -// Ticket #11972 -#if (__SUNPRO_CC >= 0x5140) && defined(__SunOS_5_12) && !defined(BOOST_HAS_THREADS) -# define BOOST_HAS_THREADS -#endif - -// -// Version -// - -#define BOOST_COMPILER "Sun compiler version " BOOST_STRINGIZE(__SUNPRO_CC) - -// -// versions check: -// we don't support sunpro prior to version 4: -#if __SUNPRO_CC < 0x400 -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version: -#if (__SUNPRO_CC > 0x5150) -# if defined(BOOST_ASSERT_CONFIG) -# error "Boost.Config is older than your compiler - please check for an updated Boost release." -# endif -#endif diff --git a/ThirdParty/boost/config/compiler/vacpp.hpp b/ThirdParty/boost/config/compiler/vacpp.hpp deleted file mode 100644 index 2c4e2c9609b5d9b5b3174ec54b03926ee7b457f0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/vacpp.hpp +++ /dev/null @@ -1,184 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Toon Knapen 2001 - 2003. -// (C) Copyright Lie-Quan Lee 2001. -// (C) Copyright Markus Schoepflin 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Visual Age (IBM) C++ compiler setup: - -#if __IBMCPP__ <= 501 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -#endif - -#if (__IBMCPP__ <= 502) -// Actually the compiler supports inclass member initialization but it -// requires a definition for the class member and it doesn't recognize -// it as an integral constant expression when used as a template argument. -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -#endif - -#if (__IBMCPP__ <= 600) || !defined(BOOST_STRICT_CONFIG) -# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS -#endif - -#if (__IBMCPP__ <= 1110) -// XL C++ V11.1 and earlier versions may not always value-initialize -// a temporary object T(), when T is a non-POD aggregate class type. -// Michael Wong (IBM Canada Ltd) has confirmed this issue and gave it -// high priority. -- Niels Dekker (LKEB), May 2010. -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#endif - -// -// On AIX thread support seems to be indicated by _THREAD_SAFE: -// -#ifdef _THREAD_SAFE -# define BOOST_HAS_THREADS -#endif - -#define BOOST_COMPILER "IBM Visual Age version " BOOST_STRINGIZE(__IBMCPP__) - -// -// versions check: -// we don't support Visual age prior to version 5: -#if __IBMCPP__ < 500 -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 1210: -#if (__IBMCPP__ > 1210) -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - -// Some versions of the compiler have issues with default arguments on partial specializations -#if __IBMCPP__ <= 1010 -#define BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS -#endif - -// Type aliasing hint. Supported since XL C++ 13.1 -#if (__IBMCPP__ >= 1310) -# define BOOST_MAY_ALIAS __attribute__((__may_alias__)) -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if ! __IBMCPP_AUTO_TYPEDEDUCTION -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif -#if ! __IBMCPP_UTF_LITERAL__ -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -#endif -#if ! __IBMCPP_CONSTEXPR -# define BOOST_NO_CXX11_CONSTEXPR -#endif -#if ! __IBMCPP_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE -#else -# define BOOST_HAS_DECLTYPE -#endif -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#if ! __IBMCPP_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif -#if ! __IBMCPP_EXTERN_TEMPLATE -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if ! __IBMCPP_VARIADIC_TEMPLATES -// not enabled separately at this time -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#if ! __IBMCPP_RVALUE_REFERENCES -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif -#if ! __IBMCPP_SCOPED_ENUM -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#if ! __IBMCPP_STATIC_ASSERT -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#if ! __IBMCPP_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif -#if ! __C99_MACRO_WITH_VA_ARGS -# define BOOST_NO_CXX11_VARIADIC_MACROS -#endif -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_UNRESTRICTED_UNION - -// C++ 14: -#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif -#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif -#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304) -# define BOOST_NO_CXX14_CONSTEXPR -#endif -#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif -#if (__cplusplus < 201304) // There's no SD6 check for this.... -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif -#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif -#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif -#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif -#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -// C++17 -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif -#if !defined(__cpp_inline_variables) || (__cpp_inline_variables < 201606) -# define BOOST_NO_CXX17_INLINE_VARIABLES -#endif -#if !defined(__cpp_fold_expressions) || (__cpp_fold_expressions < 201603) -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif diff --git a/ThirdParty/boost/config/compiler/visualc.hpp b/ThirdParty/boost/config/compiler/visualc.hpp deleted file mode 100644 index 4c47b1209b9b68bbb2ba0ee72541ffa0793d08c8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/visualc.hpp +++ /dev/null @@ -1,366 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. -// -// Microsoft Visual C++ compiler setup: -// -// We need to be careful with the checks in this file, as contrary -// to popular belief there are versions with _MSC_VER with the final -// digit non-zero (mainly the MIPS cross compiler). -// -// So we either test _MSC_VER >= XXXX or else _MSC_VER < XXXX. -// No other comparisons (==, >, or <=) are safe. -// - -#define BOOST_MSVC _MSC_VER - -// -// Helper macro BOOST_MSVC_FULL_VER for use in Boost code: -// -#if _MSC_FULL_VER > 100000000 -# define BOOST_MSVC_FULL_VER _MSC_FULL_VER -#else -# define BOOST_MSVC_FULL_VER (_MSC_FULL_VER * 10) -#endif - -// Attempt to suppress VC6 warnings about the length of decorated names (obsolete): -#pragma warning( disable : 4503 ) // warning: decorated name length exceeded - -#define BOOST_HAS_PRAGMA_ONCE - -// -// versions check: -// we don't support Visual C++ prior to version 7.1: -#if _MSC_VER < 1310 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// VS2005 (VC8) docs: __assume has been in Visual C++ for multiple releases -#define BOOST_UNREACHABLE_RETURN(x) __assume(0); - -#if _MSC_FULL_VER < 180020827 -# define BOOST_NO_FENV_H -#endif - -#if _MSC_VER < 1400 -// although a conforming signature for swprint exists in VC7.1 -// it appears not to actually work: -# define BOOST_NO_SWPRINTF -// Our extern template tests also fail for this compiler: -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -// Variadic macros do not exist for VC7.1 and lower -# define BOOST_NO_CXX11_VARIADIC_MACROS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif - -#if _MSC_VER < 1500 // 140X == VC++ 8.0 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#endif - -#if _MSC_VER < 1600 // 150X == VC++ 9.0 - // A bug in VC9: -# define BOOST_NO_ADL_BARRIER -#endif - - -#ifndef _NATIVE_WCHAR_T_DEFINED -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -// -// check for exception handling support: -#if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -// -// __int64 support: -// -#define BOOST_HAS_MS_INT64 -#if defined(_MSC_EXTENSIONS) || (_MSC_VER >= 1400) -# define BOOST_HAS_LONG_LONG -#else -# define BOOST_NO_LONG_LONG -#endif -#if (_MSC_VER >= 1400) && !defined(_DEBUG) -# define BOOST_HAS_NRVO -#endif -#if _MSC_VER >= 1600 // 160X == VC++ 10.0 -# define BOOST_HAS_PRAGMA_DETECT_MISMATCH -#endif -// -// disable Win32 API's if compiler extensions are -// turned off: -// -#if !defined(_MSC_EXTENSIONS) && !defined(BOOST_DISABLE_WIN32) -# define BOOST_DISABLE_WIN32 -#endif -#if !defined(_CPPRTTI) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -// -// TR1 features: -// -#if (_MSC_VER >= 1700) && defined(_HAS_CXX17) && (_HAS_CXX17 > 0) -// # define BOOST_HAS_TR1_HASH // don't know if this is true yet. -// # define BOOST_HAS_TR1_TYPE_TRAITS // don't know if this is true yet. -# define BOOST_HAS_TR1_UNORDERED_MAP -# define BOOST_HAS_TR1_UNORDERED_SET -#endif - -// -// C++0x features -// -// See above for BOOST_NO_LONG_LONG - -// C++ features supported by VC++ 10 (aka 2010) -// -#if _MSC_VER < 1600 -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_DECLTYPE -#endif // _MSC_VER < 1600 - -#if _MSC_VER >= 1600 -# define BOOST_HAS_STDINT_H -#endif - -// C++11 features supported by VC++ 11 (aka 2012) -// -#if _MSC_VER < 1700 -# define BOOST_NO_CXX11_FINAL -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif // _MSC_VER < 1700 - -// C++11 features supported by VC++ 12 (aka 2013). -// -#if _MSC_FULL_VER < 180020827 -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -# define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -#if _MSC_FULL_VER >= 180020827 -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_LOG1P -#endif - -// C++11 features supported by VC++ 14 (aka 2015) -// -#if (_MSC_FULL_VER < 190023026) -# define BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NO_CXX11_DEFAULTED_MOVES -# define BOOST_NO_CXX11_REF_QUALIFIERS -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_INLINE_NAMESPACES -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_UNICODE_LITERALS -# define BOOST_NO_CXX14_DECLTYPE_AUTO -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -# define BOOST_NO_CXX14_BINARY_LITERALS -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -# define BOOST_NO_CXX11_THREAD_LOCAL -# define BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif -// C++11 features supported by VC++ 14 update 3 (aka 2015) -// -#if (_MSC_FULL_VER < 190024210) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -# define BOOST_NO_SFINAE_EXPR -# define BOOST_NO_CXX11_CONSTEXPR -#endif - -// C++14 features supported by VC++ 14.1 (Visual Studio 2017) -// -#if (_MSC_VER < 1910) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif - -// C++17 features supported by VC++ 14.1 (Visual Studio 2017) Update 3 -// -#if (_MSC_VER < 1911) || (_MSVC_LANG < 201703) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -# define BOOST_NO_CXX17_IF_CONSTEXPR -// Let the defaults handle these now: -//# define BOOST_NO_CXX17_HDR_OPTIONAL -//# define BOOST_NO_CXX17_HDR_STRING_VIEW -#endif - -// MSVC including version 14 has not yet completely -// implemented value-initialization, as is reported: -// "VC++ does not value-initialize members of derived classes without -// user-declared constructor", reported in 2009 by Sylvester Hesp: -// https://connect.microsoft.com/VisualStudio/feedback/details/484295 -// "Presence of copy constructor breaks member class initialization", -// reported in 2009 by Alex Vakulenko: -// https://connect.microsoft.com/VisualStudio/feedback/details/499606 -// "Value-initialization in new-expression", reported in 2005 by -// Pavel Kuznetsov (MetaCommunications Engineering): -// https://connect.microsoft.com/VisualStudio/feedback/details/100744 -// Reported again by John Maddock in 2015 for VC14: -// https://connect.microsoft.com/VisualStudio/feedback/details/1582233/c-subobjects-still-not-value-initialized-correctly -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, May 2010) -// Still present in VC15.5, Dec 2017. -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -// -// C++ 11: -// -// This is supported with /permissive- for 15.5 onwards, unfortunately we appear to have no way to tell -// if this is in effect or not, in any case nothing in Boost is currently using this, so we'll just go -// on defining it for now: -// -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP - -#if (_MSC_VER < 1912) || (_MSVC_LANG < 201402) -// Supported from msvc-15.5 onwards: -#define BOOST_NO_CXX11_SFINAE_EXPR -#endif -#if (_MSC_VER < 1915) || (_MSVC_LANG < 201402) -// C++ 14: -// Still gives internal compiler error for msvc-15.5: -# define BOOST_NO_CXX14_CONSTEXPR -#endif -// C++ 17: -#if (_MSC_VER < 1912) || (_MSVC_LANG < 201703) -#define BOOST_NO_CXX17_INLINE_VARIABLES -#define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif - -// -// Things that don't work in clr mode: -// -#ifdef _M_CEE -#ifndef BOOST_NO_CXX11_THREAD_LOCAL -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif -#ifndef BOOST_NO_SFINAE_EXPR -# define BOOST_NO_SFINAE_EXPR -#endif -#ifndef BOOST_NO_CXX11_REF_QUALIFIERS -# define BOOST_NO_CXX11_REF_QUALIFIERS -#endif -#endif -#ifdef _M_CEE_PURE -#ifndef BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_CXX11_CONSTEXPR -#endif -#endif - -// -// prefix and suffix headers: -// -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/msvc_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/msvc_suffix.hpp" -#endif - -#ifndef BOOST_COMPILER -// TODO: -// these things are mostly bogus. 1200 means version 12.0 of the compiler. The -// artificial versions assigned to them only refer to the versions of some IDE -// these compilers have been shipped with, and even that is not all of it. Some -// were shipped with freely downloadable SDKs, others as crosscompilers in eVC. -// IOW, you can't use these 'versions' in any sensible way. Sorry. -# if defined(UNDER_CE) -# if _MSC_VER < 1400 - // Note: I'm not aware of any CE compiler with version 13xx -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown EVC++ compiler version - please run the configure tests and report the results" -# else -# pragma message("boost: Unknown EVC++ compiler version - please run the configure tests and report the results") -# endif -# elif _MSC_VER < 1500 -# define BOOST_COMPILER_VERSION evc8 -# elif _MSC_VER < 1600 -# define BOOST_COMPILER_VERSION evc9 -# elif _MSC_VER < 1700 -# define BOOST_COMPILER_VERSION evc10 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION evc11 -# elif _MSC_VER < 1900 -# define BOOST_COMPILER_VERSION evc12 -# elif _MSC_VER < 2000 -# define BOOST_COMPILER_VERSION evc14 -# else -# if defined(BOOST_ASSERT_CONFIG) -# error "boost: Unknown EVC++ compiler version - please run the configure tests and report the results" -# else -# pragma message("boost: Unknown EVC++ compiler version - please run the configure tests and report the results") -# endif -# endif -# else -# if _MSC_VER < 1200 - // Note: Versions up to 10.0 aren't supported. -# define BOOST_COMPILER_VERSION 5.0 -# elif _MSC_VER < 1300 -# define BOOST_COMPILER_VERSION 6.0 -# elif _MSC_VER < 1310 -# define BOOST_COMPILER_VERSION 7.0 -# elif _MSC_VER < 1400 -# define BOOST_COMPILER_VERSION 7.1 -# elif _MSC_VER < 1500 -# define BOOST_COMPILER_VERSION 8.0 -# elif _MSC_VER < 1600 -# define BOOST_COMPILER_VERSION 9.0 -# elif _MSC_VER < 1700 -# define BOOST_COMPILER_VERSION 10.0 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION 11.0 -# elif _MSC_VER < 1900 -# define BOOST_COMPILER_VERSION 12.0 -# elif _MSC_VER < 1910 -# define BOOST_COMPILER_VERSION 14.0 -# elif _MSC_VER < 1920 -# define BOOST_COMPILER_VERSION 14.1 -# elif _MSC_VER < 1930 -# define BOOST_COMPILER_VERSION 14.2 -# else -# define BOOST_COMPILER_VERSION _MSC_VER -# endif -# endif - -# define BOOST_COMPILER "Microsoft Visual C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) -#endif - -#include <boost/config/pragma_message.hpp> - -// -// last known and checked version is 19.20.27508 (VC++ 2019 RC3): -#if (_MSC_VER > 1920) -# if defined(BOOST_ASSERT_CONFIG) -# error "Boost.Config is older than your current compiler version." -# elif !defined(BOOST_CONFIG_SUPPRESS_OUTDATED_MESSAGE) - // - // Disabled as of March 2018 - the pace of VS releases is hard to keep up with - // and in any case, we have relatively few defect macros defined now. - // BOOST_PRAGMA_MESSAGE("Info: Boost.Config is older than your compiler version - probably nothing bad will happen - but you may wish to look for an updated Boost version. Define BOOST_CONFIG_SUPPRESS_OUTDATED_MESSAGE to suppress this message.") -# endif -#endif diff --git a/ThirdParty/boost/config/compiler/xlcpp.hpp b/ThirdParty/boost/config/compiler/xlcpp.hpp deleted file mode 100644 index 95f5e1d943e014113e72eaf9cd5aa3c5c96d6b11..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/xlcpp.hpp +++ /dev/null @@ -1,289 +0,0 @@ -// (C) Copyright Douglas Gregor 2010 -// -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// compiler setup for IBM XL C/C++ for Linux (Little Endian) based on clang. - -#define BOOST_HAS_PRAGMA_ONCE - -// Detecting `-fms-extension` compiler flag assuming that _MSC_VER defined when that flag is used. -#if defined (_MSC_VER) && (__clang_major__ > 3 || (__clang_major__ == 3 && __clang_minor__ >= 4)) -# define BOOST_HAS_PRAGMA_DETECT_MISMATCH -#endif - -// When compiling with clang before __has_extension was defined, -// even if one writes 'defined(__has_extension) && __has_extension(xxx)', -// clang reports a compiler error. So the only workaround found is: - -#ifndef __has_extension -#define __has_extension __has_feature -#endif - -#ifndef __has_cpp_attribute -#define __has_cpp_attribute(x) 0 -#endif - -#if !__has_feature(cxx_exceptions) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_TYPEID) -# define BOOST_NO_TYPEID -#endif - -#if defined(__int64) && !defined(__GNUC__) -# define BOOST_HAS_MS_INT64 -#endif - -#define BOOST_HAS_NRVO - -// Branch prediction hints -#if defined(__has_builtin) -#if __has_builtin(__builtin_expect) -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) -#endif -#endif - -// Clang supports "long long" in all compilation modes. -#define BOOST_HAS_LONG_LONG - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if !defined(_WIN32) && !defined(__WIN32__) && !defined(WIN32) -# define BOOST_SYMBOL_EXPORT __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) -#endif - -// -// The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through -// between switch labels. -// -#if __cplusplus >= 201103L && defined(__has_warning) -# if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") -# define BOOST_FALLTHROUGH [[clang::fallthrough]] -# endif -#endif - -#if !__has_feature(cxx_auto_type) -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif - -// -// Currently clang on Windows using VC++ RTL does not support C++11's char16_t or char32_t -// -#if defined(_MSC_VER) || !(defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L) -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -#endif - -#if !__has_feature(cxx_constexpr) -# define BOOST_NO_CXX11_CONSTEXPR -#endif - -#if !__has_feature(cxx_decltype) -# define BOOST_NO_CXX11_DECLTYPE -#endif - -#if !__has_feature(cxx_decltype_incomplete_return_types) -# define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -#if !__has_feature(cxx_defaulted_functions) -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#endif - -#if !__has_feature(cxx_deleted_functions) -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -#endif - -#if !__has_feature(cxx_explicit_conversions) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif - -#if !__has_feature(cxx_default_function_template_args) -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#if !__has_feature(cxx_lambdas) -# define BOOST_NO_CXX11_LAMBDAS -#endif - -#if !__has_feature(cxx_local_type_template_args) -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif - -#if !__has_feature(cxx_noexcept) -# define BOOST_NO_CXX11_NOEXCEPT -#endif - -#if !__has_feature(cxx_nullptr) -# define BOOST_NO_CXX11_NULLPTR -#endif - -#if !__has_feature(cxx_range_for) -# define BOOST_NO_CXX11_RANGE_BASED_FOR -#endif - -#if !__has_feature(cxx_raw_string_literals) -# define BOOST_NO_CXX11_RAW_LITERALS -#endif - -#if !__has_feature(cxx_reference_qualified_functions) -# define BOOST_NO_CXX11_REF_QUALIFIERS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -#if !__has_feature(cxx_rvalue_references) -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif - -#if !__has_feature(cxx_strong_enums) -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -#if !__has_feature(cxx_static_assert) -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif - -#if !__has_feature(cxx_alias_templates) -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -#endif - -#if !__has_feature(cxx_unicode_literals) -# define BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -#if !__has_feature(cxx_variadic_templates) -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif - -#if !__has_feature(cxx_user_literals) -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#endif - -#if !__has_feature(cxx_alignas) -# define BOOST_NO_CXX11_ALIGNAS -#endif - -#if !__has_feature(cxx_trailing_return) -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -#if !__has_feature(cxx_inline_namespaces) -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -#if !__has_feature(cxx_override_control) -# define BOOST_NO_CXX11_FINAL -#endif - -#if !__has_feature(cxx_unrestricted_unions) -# define BOOST_NO_CXX11_UNRESTRICTED_UNION -#endif - -#if !(__has_feature(__cxx_binary_literals__) || __has_extension(__cxx_binary_literals__)) -# define BOOST_NO_CXX14_BINARY_LITERALS -#endif - -#if !__has_feature(__cxx_decltype_auto__) -# define BOOST_NO_CXX14_DECLTYPE_AUTO -#endif - -#if !__has_feature(__cxx_aggregate_nsdmi__) -# define BOOST_NO_CXX14_AGGREGATE_NSDMI -#endif - -#if !__has_feature(__cxx_init_captures__) -# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#endif - -#if !__has_feature(__cxx_generic_lambdas__) -# define BOOST_NO_CXX14_GENERIC_LAMBDAS -#endif - -// clang < 3.5 has a defect with dependent type, like following. -// -// template <class T> -// constexpr typename enable_if<pred<T> >::type foo(T &) -// { } // error: no return statement in constexpr function -// -// This issue also affects C++11 mode, but C++11 constexpr requires return stmt. -// Therefore we don't care such case. -// -// Note that we can't check Clang version directly as the numbering system changes depending who's -// creating the Clang release (see https://github.com/boostorg/config/pull/39#issuecomment-59927873) -// so instead verify that we have a feature that was introduced at the same time as working C++14 -// constexpr (generic lambda's in this case): -// -#if !__has_feature(__cxx_generic_lambdas__) || !__has_feature(__cxx_relaxed_constexpr__) -# define BOOST_NO_CXX14_CONSTEXPR -#endif - -#if !__has_feature(__cxx_return_type_deduction__) -# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#endif - -#if !__has_feature(__cxx_variable_templates__) -# define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#endif - -#if !defined(__cpp_structured_bindings) || (__cpp_structured_bindings < 201606) -# define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#endif - -#if !defined(__cpp_if_constexpr) || (__cpp_if_constexpr < 201606) -# define BOOST_NO_CXX17_IF_CONSTEXPR -#endif - -// Clang 3.9+ in c++1z -#if !__has_cpp_attribute(fallthrough) || __cplusplus < 201406L -# define BOOST_NO_CXX17_INLINE_VARIABLES -# define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#endif - -#if !__has_feature(cxx_thread_local) -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -#if __cplusplus < 201400 -// All versions with __cplusplus above this value seem to support this: -# define BOOST_NO_CXX14_DIGIT_SEPARATORS -#endif - - -// Unused attribute: -#if defined(__GNUC__) && (__GNUC__ >= 4) -# define BOOST_ATTRIBUTE_UNUSED __attribute__((unused)) -#endif - -// Type aliasing hint. -#if __has_attribute(__may_alias__) -# define BOOST_MAY_ALIAS __attribute__((__may_alias__)) -#endif - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "Clang version " __clang_version__ -#endif - -// Macro used to identify the Clang compiler. -#define BOOST_CLANG 1 - diff --git a/ThirdParty/boost/config/compiler/xlcpp_zos.hpp b/ThirdParty/boost/config/compiler/xlcpp_zos.hpp deleted file mode 100644 index b62bd9a7658a5e0bdb09739834f2d31619b15f6e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/compiler/xlcpp_zos.hpp +++ /dev/null @@ -1,171 +0,0 @@ -// Copyright (c) 2017 Dynatrace -// -// 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 - -// See http://www.boost.org for most recent version. - -// Compiler setup for IBM z/OS XL C/C++ compiler. - -// Oldest compiler version currently supported is 2.1 (V2R1) -#if !defined(__IBMCPP__) || !defined(__COMPILER_VER__) || __COMPILER_VER__ < 0x42010000 -# error "Compiler not supported or configured - please reconfigure" -#endif - -#if __COMPILER_VER__ > 0x42010000 -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - -#define BOOST_COMPILER "IBM z/OS XL C/C++ version " BOOST_STRINGIZE(__COMPILER_VER__) -#define BOOST_XLCPP_ZOS __COMPILER_VER__ - -// ------------------------------------- - -#include <features.h> // For __UU, __C99, __TR1, ... - -#if !defined(__IBMCPP_DEFAULTED_AND_DELETED_FUNCTIONS) -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS -#endif - -// ------------------------------------- - -#if defined(__UU) || defined(__C99) || defined(__TR1) -# define BOOST_HAS_LOG1P -# define BOOST_HAS_EXPM1 -#endif - -#if defined(__C99) || defined(__TR1) -# define BOOST_HAS_STDINT_H -#else -# define BOOST_NO_FENV_H -#endif - -// ------------------------------------- - -#define BOOST_HAS_NRVO - -#if !defined(__RTTI_ALL__) -# define BOOST_NO_RTTI -#endif - -#if !defined(_CPPUNWIND) && !defined(__EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if defined(_LONG_LONG) || defined(__IBMCPP_C99_LONG_LONG) || defined(__LL) -# define BOOST_HAS_LONG_LONG -#else -# define BOOST_NO_LONG_LONG -#endif - -#if defined(_LONG_LONG) || defined(__IBMCPP_C99_LONG_LONG) || defined(__LL) || defined(_LP64) -# define BOOST_HAS_MS_INT64 -#endif - -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SFINAE_EXPR - -#if defined(__IBMCPP_VARIADIC_TEMPLATES) -# define BOOST_HAS_VARIADIC_TMPL -#else -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif - -#if defined(__IBMCPP_STATIC_ASSERT) -# define BOOST_HAS_STATIC_ASSERT -#else -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif - -#if defined(__IBMCPP_RVALUE_REFERENCES) -# define BOOST_HAS_RVALUE_REFS -#else -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif - -#if !defined(__IBMCPP_SCOPED_ENUM) -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -#define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS - -#if !defined(__IBMCPP_EXPLICIT_CONVERSION_OPERATORS) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif - -#if !defined(__IBMCPP_DECLTYPE) -# define BOOST_NO_CXX11_DECLTYPE -#else -# define BOOST_HAS_DECLTYPE -#endif -#define BOOST_NO_CXX11_DECLTYPE_N3276 - -#if !defined(__IBMCPP_INLINE_NAMESPACE) -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -#if !defined(__IBMCPP_AUTO_TYPEDEDUCTION) -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -#if !defined(__IBM_CHAR32_T__) -# define BOOST_NO_CXX11_CHAR32_T -#endif -#if !defined(__IBM_CHAR16_T__) -# define BOOST_NO_CXX11_CHAR16_T -#endif - -#if !defined(__IBMCPP_CONSTEXPR) -# define BOOST_NO_CXX11_CONSTEXPR -#endif - -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_THREAD_LOCAL -#define BOOST_NO_CXX11_REF_QUALIFIERS -#define BOOST_NO_CXX11_FINAL -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_UNRESTRICTED_UNION -#define BOOST_NO_CXX14_VARIABLE_TEMPLATES -#define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION -#define BOOST_NO_CXX14_AGGREGATE_NSDMI -#define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES -#define BOOST_NO_CXX14_GENERIC_LAMBDAS -#define BOOST_NO_CXX14_DIGIT_SEPARATORS -#define BOOST_NO_CXX14_DECLTYPE_AUTO -#define BOOST_NO_CXX14_CONSTEXPR -#define BOOST_NO_CXX14_BINARY_LITERALS -#define BOOST_NO_CXX17_STRUCTURED_BINDINGS -#define BOOST_NO_CXX17_INLINE_VARIABLES -#define BOOST_NO_CXX17_FOLD_EXPRESSIONS -#define BOOST_NO_CXX17_IF_CONSTEXPR - -// ------------------------------------- - -#if defined(__IBM_ATTRIBUTES) -# define BOOST_FORCEINLINE inline __attribute__ ((__always_inline__)) -# define BOOST_NOINLINE __attribute__ ((__noinline__)) -# define BOOST_MAY_ALIAS __attribute__((__may_alias__)) -// No BOOST_ALIGNMENT - explicit alignment support is broken (V2R1). -#endif - -extern "builtin" long __builtin_expect(long, long); - -#define BOOST_LIKELY(x) __builtin_expect((x) && true, 1) -#define BOOST_UNLIKELY(x) __builtin_expect((x) && true, 0) diff --git a/ThirdParty/boost/config/detail/select_stdlib_config.hpp b/ThirdParty/boost/config/detail/select_stdlib_config.hpp deleted file mode 100644 index 1a09dda1261d973d0d50aff89e30ea1dccd22214..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/detail/select_stdlib_config.hpp +++ /dev/null @@ -1,121 +0,0 @@ -// Boost compiler configuration selection header file - -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2002. -// Use, modification and distribution are subject to 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) - - -// See http://www.boost.org for most recent version. - -// locate which std lib we are using and define BOOST_STDLIB_CONFIG as needed: - -// First, check if __has_include is available and <version> include can be located, -// otherwise include <cstddef> to determine if some version of STLport is in use as the std lib -// (do not rely on this header being included since users can short-circuit this header -// if they know whose std lib they are using.) -#if defined(__cplusplus) && defined(__has_include) -# if __has_include(<version>) -// It should be safe to include `<version>` when it is present without checking -// the actual C++ language version as it consists solely of macro definitions. -// [version.syn] p1: The header <version> supplies implementation-dependent -// information about the C++ standard library (e.g., version number and release date). -# include <version> -# else -# include <cstddef> -# endif -#elif defined(__cplusplus) -# include <cstddef> -#else -# include <stddef.h> -#endif - -#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -// STLPort library; this _must_ come first, otherwise since -// STLport typically sits on top of some other library, we -// can end up detecting that first rather than STLport: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/stlport.hpp" - -#else - -// If our std lib was not some version of STLport, and has not otherwise -// been detected, then include <utility> as it is about -// the smallest of the std lib headers that includes real C++ stuff. -// Some std libs do not include their C++-related macros in <cstddef> -// so this additional include makes sure we get those definitions. -// Note: do not rely on this header being included since users can short-circuit this -// #include if they know whose std lib they are using. -#if !defined(__LIBCOMO__) && !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER)\ - && !defined(_LIBCPP_VERSION) && !defined(__GLIBCPP__) && !defined(__GLIBCXX__)\ - && !defined(__STL_CONFIG_H) && !defined(__MSL_CPP__) && !defined(__IBMCPP__)\ - && !defined(MSIPL_COMPILE_H) && !defined(_YVALS) && !defined(_CPPLIB_VER) -#include <utility> -#endif - -#if defined(__LIBCOMO__) -// Comeau STL: -#define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcomo.hpp" - -#elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) -// Rogue Wave library: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/roguewave.hpp" - -#elif defined(_LIBCPP_VERSION) -// libc++ -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcpp.hpp" - -#elif defined(__GLIBCPP__) || defined(__GLIBCXX__) -// GNU libstdc++ 3 -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libstdcpp3.hpp" - -#elif defined(__STL_CONFIG_H) -// generic SGI STL -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/sgi.hpp" - -#elif defined(__MSL_CPP__) -// MSL standard lib: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/msl.hpp" - -#elif defined(__IBMCPP__) && defined(__COMPILER_VER__) && defined(__MVS__) -// IBM z/OS XL C/C++ -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/xlcpp_zos.hpp" - -#elif defined(__IBMCPP__) -// take the default VACPP std lib -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/vacpp.hpp" - -#elif defined(MSIPL_COMPILE_H) -// Modena C++ standard library -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/modena.hpp" - -#elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER) -// Dinkumware Library (this has to appear after any possible replacement libraries): -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/dinkumware.hpp" - -#elif defined (BOOST_ASSERT_CONFIG) -// this must come last - generate an error if we don't -// recognise the library: -# error "Unknown standard library - please configure and report the results to boost.org" - -#endif - -#endif - -#if 0 -// -// This section allows dependency scanners to find all the files we *might* include: -// -# include "boost/config/stdlib/stlport.hpp" -# include "boost/config/stdlib/libcomo.hpp" -# include "boost/config/stdlib/roguewave.hpp" -# include "boost/config/stdlib/libcpp.hpp" -# include "boost/config/stdlib/libstdcpp3.hpp" -# include "boost/config/stdlib/sgi.hpp" -# include "boost/config/stdlib/msl.hpp" -# include "boost/config/stdlib/xlcpp_zos.hpp" -# include "boost/config/stdlib/vacpp.hpp" -# include "boost/config/stdlib/modena.hpp" -# include "boost/config/stdlib/dinkumware.hpp" -#endif - diff --git a/ThirdParty/boost/config/detail/suffix.hpp b/ThirdParty/boost/config/detail/suffix.hpp deleted file mode 100644 index d3c4e083c5aed4beb88cc869dfd22ae74a51b461..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/detail/suffix.hpp +++ /dev/null @@ -1,1107 +0,0 @@ -// Boost config.hpp configuration header file ------------------------------// -// boostinspect:ndprecated_macros -- tell the inspect tool to ignore this file - -// Copyright (c) 2001-2003 John Maddock -// Copyright (c) 2001 Darin Adler -// Copyright (c) 2001 Peter Dimov -// Copyright (c) 2002 Bill Kempf -// Copyright (c) 2002 Jens Maurer -// Copyright (c) 2002-2003 David Abrahams -// Copyright (c) 2003 Gennaro Prota -// Copyright (c) 2003 Eric Friedman -// Copyright (c) 2010 Eric Jourdanneau, Joel Falcou -// 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) - -// See http://www.boost.org/ for most recent version. - -// Boost config.hpp policy and rationale documentation has been moved to -// http://www.boost.org/libs/config/ -// -// This file is intended to be stable, and relatively unchanging. -// It should contain boilerplate code only - no compiler specific -// code unless it is unavoidable - no changes unless unavoidable. - -#ifndef BOOST_CONFIG_SUFFIX_HPP -#define BOOST_CONFIG_SUFFIX_HPP - -#if defined(__GNUC__) && (__GNUC__ >= 4) -// -// Some GCC-4.x versions issue warnings even when __extension__ is used, -// so use this as a workaround: -// -#pragma GCC system_header -#endif - -// -// ensure that visibility macros are always defined, thus symplifying use -// -#ifndef BOOST_SYMBOL_EXPORT -# define BOOST_SYMBOL_EXPORT -#endif -#ifndef BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_IMPORT -#endif -#ifndef BOOST_SYMBOL_VISIBLE -# define BOOST_SYMBOL_VISIBLE -#endif - -// -// look for long long by looking for the appropriate macros in <limits.h>. -// Note that we use limits.h rather than climits for maximal portability, -// remember that since these just declare a bunch of macros, there should be -// no namespace issues from this. -// -#if !defined(BOOST_HAS_LONG_LONG) && !defined(BOOST_NO_LONG_LONG) \ - && !defined(BOOST_MSVC) && !defined(__BORLANDC__) -# include <limits.h> -# if (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX)) -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif -#endif - -// GCC 3.x will clean up all of those nasty macro definitions that -// BOOST_NO_CTYPE_FUNCTIONS is intended to help work around, so undefine -// it under GCC 3.x. -#if defined(__GNUC__) && (__GNUC__ >= 3) && defined(BOOST_NO_CTYPE_FUNCTIONS) -# undef BOOST_NO_CTYPE_FUNCTIONS -#endif - -// -// Assume any extensions are in namespace std:: unless stated otherwise: -// -# ifndef BOOST_STD_EXTENSION_NAMESPACE -# define BOOST_STD_EXTENSION_NAMESPACE std -# endif - -// -// If cv-qualified specializations are not allowed, then neither are cv-void ones: -// -# if defined(BOOST_NO_CV_SPECIALIZATIONS) \ - && !defined(BOOST_NO_CV_VOID_SPECIALIZATIONS) -# define BOOST_NO_CV_VOID_SPECIALIZATIONS -# endif - -// -// If there is no numeric_limits template, then it can't have any compile time -// constants either! -// -# if defined(BOOST_NO_LIMITS) \ - && !defined(BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS) -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -# endif - -// -// if there is no long long then there is no specialisation -// for numeric_limits<long long> either: -// -#if !defined(BOOST_HAS_LONG_LONG) && !defined(BOOST_NO_LONG_LONG_NUMERIC_LIMITS) -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -#endif - -// -// if there is no __int64 then there is no specialisation -// for numeric_limits<__int64> either: -// -#if !defined(BOOST_HAS_MS_INT64) && !defined(BOOST_NO_MS_INT64_NUMERIC_LIMITS) -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -#endif - -// -// if member templates are supported then so is the -// VC6 subset of member templates: -// -# if !defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) -# define BOOST_MSVC6_MEMBER_TEMPLATES -# endif - -// -// Without partial specialization, can't test for partial specialisation bugs: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_BCB_PARTIAL_SPECIALIZATION_BUG) -# define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -# endif - -// -// Without partial specialization, we can't have array-type partial specialisations: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS) -# define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS -# endif - -// -// Without partial specialization, std::iterator_traits can't work: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_STD_ITERATOR_TRAITS) -# define BOOST_NO_STD_ITERATOR_TRAITS -# endif - -// -// Without partial specialization, partial -// specialization with default args won't work either: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS) -# define BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS -# endif - -// -// Without member template support, we can't have template constructors -// in the standard library either: -// -# if defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) \ - && !defined(BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# endif - -// -// Without member template support, we can't have a conforming -// std::allocator template either: -// -# if defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) \ - && !defined(BOOST_NO_STD_ALLOCATOR) -# define BOOST_NO_STD_ALLOCATOR -# endif - -// -// without ADL support then using declarations will break ADL as well: -// -#if defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// -// Without typeid support we have no dynamic RTTI either: -// -#if defined(BOOST_NO_TYPEID) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -// -// If we have a standard allocator, then we have a partial one as well: -// -#if !defined(BOOST_NO_STD_ALLOCATOR) -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -#endif - -// -// We can't have a working std::use_facet if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_USE_FACET) -# define BOOST_NO_STD_USE_FACET -# endif - -// -// We can't have a std::messages facet if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_MESSAGES) -# define BOOST_NO_STD_MESSAGES -# endif - -// -// We can't have a working std::wstreambuf if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_WSTREAMBUF) -# define BOOST_NO_STD_WSTREAMBUF -# endif - -// -// We can't have a <cwctype> if there is no <cwchar>: -// -# if defined(BOOST_NO_CWCHAR) && !defined(BOOST_NO_CWCTYPE) -# define BOOST_NO_CWCTYPE -# endif - -// -// We can't have a swprintf if there is no <cwchar>: -// -# if defined(BOOST_NO_CWCHAR) && !defined(BOOST_NO_SWPRINTF) -# define BOOST_NO_SWPRINTF -# endif - -// -// If Win32 support is turned off, then we must turn off -// threading support also, unless there is some other -// thread API enabled: -// -#if defined(BOOST_DISABLE_WIN32) && defined(_WIN32) \ - && !defined(BOOST_DISABLE_THREADS) && !defined(BOOST_HAS_PTHREADS) -# define BOOST_DISABLE_THREADS -#endif - -// -// Turn on threading support if the compiler thinks that it's in -// multithreaded mode. We put this here because there are only a -// limited number of macros that identify this (if there's any missing -// from here then add to the appropriate compiler section): -// -#if (defined(__MT__) || defined(_MT) || defined(_REENTRANT) \ - || defined(_PTHREADS) || defined(__APPLE__) || defined(__DragonFly__)) \ - && !defined(BOOST_HAS_THREADS) -# define BOOST_HAS_THREADS -#endif - -// -// Turn threading support off if BOOST_DISABLE_THREADS is defined: -// -#if defined(BOOST_DISABLE_THREADS) && defined(BOOST_HAS_THREADS) -# undef BOOST_HAS_THREADS -#endif - -// -// Turn threading support off if we don't recognise the threading API: -// -#if defined(BOOST_HAS_THREADS) && !defined(BOOST_HAS_PTHREADS)\ - && !defined(BOOST_HAS_WINTHREADS) && !defined(BOOST_HAS_BETHREADS)\ - && !defined(BOOST_HAS_MPTASKS) -# undef BOOST_HAS_THREADS -#endif - -// -// Turn threading detail macros off if we don't (want to) use threading -// -#ifndef BOOST_HAS_THREADS -# undef BOOST_HAS_PTHREADS -# undef BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# undef BOOST_HAS_PTHREAD_YIELD -# undef BOOST_HAS_PTHREAD_DELAY_NP -# undef BOOST_HAS_WINTHREADS -# undef BOOST_HAS_BETHREADS -# undef BOOST_HAS_MPTASKS -#endif - -// -// If the compiler claims to be C99 conformant, then it had better -// have a <stdint.h>: -// -# if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901) -# define BOOST_HAS_STDINT_H -# ifndef BOOST_HAS_LOG1P -# define BOOST_HAS_LOG1P -# endif -# ifndef BOOST_HAS_EXPM1 -# define BOOST_HAS_EXPM1 -# endif -# endif - -// -// Define BOOST_NO_SLIST and BOOST_NO_HASH if required. -// Note that this is for backwards compatibility only. -// -# if !defined(BOOST_HAS_SLIST) && !defined(BOOST_NO_SLIST) -# define BOOST_NO_SLIST -# endif - -# if !defined(BOOST_HAS_HASH) && !defined(BOOST_NO_HASH) -# define BOOST_NO_HASH -# endif - -// -// Set BOOST_SLIST_HEADER if not set already: -// -#if defined(BOOST_HAS_SLIST) && !defined(BOOST_SLIST_HEADER) -# define BOOST_SLIST_HEADER <slist> -#endif - -// -// Set BOOST_HASH_SET_HEADER if not set already: -// -#if defined(BOOST_HAS_HASH) && !defined(BOOST_HASH_SET_HEADER) -# define BOOST_HASH_SET_HEADER <hash_set> -#endif - -// -// Set BOOST_HASH_MAP_HEADER if not set already: -// -#if defined(BOOST_HAS_HASH) && !defined(BOOST_HASH_MAP_HEADER) -# define BOOST_HASH_MAP_HEADER <hash_map> -#endif - -// BOOST_HAS_ABI_HEADERS -// This macro gets set if we have headers that fix the ABI, -// and prevent ODR violations when linking to external libraries: -#if defined(BOOST_ABI_PREFIX) && defined(BOOST_ABI_SUFFIX) && !defined(BOOST_HAS_ABI_HEADERS) -# define BOOST_HAS_ABI_HEADERS -#endif - -#if defined(BOOST_HAS_ABI_HEADERS) && defined(BOOST_DISABLE_ABI_HEADERS) -# undef BOOST_HAS_ABI_HEADERS -#endif - -// BOOST_NO_STDC_NAMESPACE workaround --------------------------------------// -// Because std::size_t usage is so common, even in boost headers which do not -// otherwise use the C library, the <cstddef> workaround is included here so -// that ugly workaround code need not appear in many other boost headers. -// NOTE WELL: This is a workaround for non-conforming compilers; <cstddef> -// must still be #included in the usual places so that <cstddef> inclusion -// works as expected with standard conforming compilers. The resulting -// double inclusion of <cstddef> is harmless. - -# if defined(BOOST_NO_STDC_NAMESPACE) && defined(__cplusplus) -# include <cstddef> - namespace std { using ::ptrdiff_t; using ::size_t; } -# endif - -// Workaround for the unfortunate min/max macros defined by some platform headers - -#define BOOST_PREVENT_MACRO_SUBSTITUTION - -#ifndef BOOST_USING_STD_MIN -# define BOOST_USING_STD_MIN() using std::min -#endif - -#ifndef BOOST_USING_STD_MAX -# define BOOST_USING_STD_MAX() using std::max -#endif - -// BOOST_NO_STD_MIN_MAX workaround -----------------------------------------// - -# if defined(BOOST_NO_STD_MIN_MAX) && defined(__cplusplus) - -namespace std { - template <class _Tp> - inline const _Tp& min BOOST_PREVENT_MACRO_SUBSTITUTION (const _Tp& __a, const _Tp& __b) { - return __b < __a ? __b : __a; - } - template <class _Tp> - inline const _Tp& max BOOST_PREVENT_MACRO_SUBSTITUTION (const _Tp& __a, const _Tp& __b) { - return __a < __b ? __b : __a; - } -} - -# endif - -// BOOST_STATIC_CONSTANT workaround --------------------------------------- // -// On compilers which don't allow in-class initialization of static integral -// constant members, we must use enums as a workaround if we want the constants -// to be available at compile-time. This macro gives us a convenient way to -// declare such constants. - -# ifdef BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_STATIC_CONSTANT(type, assignment) enum { assignment } -# else -# define BOOST_STATIC_CONSTANT(type, assignment) static const type assignment -# endif - -// BOOST_USE_FACET / HAS_FACET workaround ----------------------------------// -// When the standard library does not have a conforming std::use_facet there -// are various workarounds available, but they differ from library to library. -// The same problem occurs with has_facet. -// These macros provide a consistent way to access a locale's facets. -// Usage: -// replace -// std::use_facet<Type>(loc); -// with -// BOOST_USE_FACET(Type, loc); -// Note do not add a std:: prefix to the front of BOOST_USE_FACET! -// Use for BOOST_HAS_FACET is analogous. - -#if defined(BOOST_NO_STD_USE_FACET) -# ifdef BOOST_HAS_TWO_ARG_USE_FACET -# define BOOST_USE_FACET(Type, loc) std::use_facet(loc, static_cast<Type*>(0)) -# define BOOST_HAS_FACET(Type, loc) std::has_facet(loc, static_cast<Type*>(0)) -# elif defined(BOOST_HAS_MACRO_USE_FACET) -# define BOOST_USE_FACET(Type, loc) std::_USE(loc, Type) -# define BOOST_HAS_FACET(Type, loc) std::_HAS(loc, Type) -# elif defined(BOOST_HAS_STLP_USE_FACET) -# define BOOST_USE_FACET(Type, loc) (*std::_Use_facet<Type >(loc)) -# define BOOST_HAS_FACET(Type, loc) std::has_facet< Type >(loc) -# endif -#else -# define BOOST_USE_FACET(Type, loc) std::use_facet< Type >(loc) -# define BOOST_HAS_FACET(Type, loc) std::has_facet< Type >(loc) -#endif - -// BOOST_NESTED_TEMPLATE workaround ------------------------------------------// -// Member templates are supported by some compilers even though they can't use -// the A::template member<U> syntax, as a workaround replace: -// -// typedef typename A::template rebind<U> binder; -// -// with: -// -// typedef typename A::BOOST_NESTED_TEMPLATE rebind<U> binder; - -#ifndef BOOST_NO_MEMBER_TEMPLATE_KEYWORD -# define BOOST_NESTED_TEMPLATE template -#else -# define BOOST_NESTED_TEMPLATE -#endif - -// BOOST_UNREACHABLE_RETURN(x) workaround -------------------------------------// -// Normally evaluates to nothing, unless BOOST_NO_UNREACHABLE_RETURN_DETECTION -// is defined, in which case it evaluates to return x; Use when you have a return -// statement that can never be reached. - -#ifndef BOOST_UNREACHABLE_RETURN -# ifdef BOOST_NO_UNREACHABLE_RETURN_DETECTION -# define BOOST_UNREACHABLE_RETURN(x) return x; -# else -# define BOOST_UNREACHABLE_RETURN(x) -# endif -#endif - -// BOOST_DEDUCED_TYPENAME workaround ------------------------------------------// -// -// Some compilers don't support the use of `typename' for dependent -// types in deduced contexts, e.g. -// -// template <class T> void f(T, typename T::type); -// ^^^^^^^^ -// Replace these declarations with: -// -// template <class T> void f(T, BOOST_DEDUCED_TYPENAME T::type); - -#ifndef BOOST_NO_DEDUCED_TYPENAME -# define BOOST_DEDUCED_TYPENAME typename -#else -# define BOOST_DEDUCED_TYPENAME -#endif - -#ifndef BOOST_NO_TYPENAME_WITH_CTOR -# define BOOST_CTOR_TYPENAME typename -#else -# define BOOST_CTOR_TYPENAME -#endif - -// long long workaround ------------------------------------------// -// On gcc (and maybe other compilers?) long long is alway supported -// but it's use may generate either warnings (with -ansi), or errors -// (with -pedantic -ansi) unless it's use is prefixed by __extension__ -// -#if defined(BOOST_HAS_LONG_LONG) && defined(__cplusplus) -namespace boost{ -# ifdef __GNUC__ - __extension__ typedef long long long_long_type; - __extension__ typedef unsigned long long ulong_long_type; -# else - typedef long long long_long_type; - typedef unsigned long long ulong_long_type; -# endif -} -#endif -// same again for __int128: -#if defined(BOOST_HAS_INT128) && defined(__cplusplus) -namespace boost{ -# ifdef __GNUC__ - __extension__ typedef __int128 int128_type; - __extension__ typedef unsigned __int128 uint128_type; -# else - typedef __int128 int128_type; - typedef unsigned __int128 uint128_type; -# endif -} -#endif -// same again for __float128: -#if defined(BOOST_HAS_FLOAT128) && defined(__cplusplus) -namespace boost { -# ifdef __GNUC__ - __extension__ typedef __float128 float128_type; -# else - typedef __float128 float128_type; -# endif -} -#endif - -// BOOST_[APPEND_]EXPLICIT_TEMPLATE_[NON_]TYPE macros --------------------------// - -// These macros are obsolete. Port away and remove. - -# define BOOST_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -# define BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -// When BOOST_NO_STD_TYPEINFO is defined, we can just import -// the global definition into std namespace: -#if defined(BOOST_NO_STD_TYPEINFO) && defined(__cplusplus) -#include <typeinfo> -namespace std{ using ::type_info; } -#endif - -// ---------------------------------------------------------------------------// - -// Helper macro BOOST_STRINGIZE: -// Helper macro BOOST_JOIN: - -#include <boost/config/helper_macros.hpp> - -// -// Set some default values for compiler/library/platform names. -// These are for debugging config setup only: -// -# ifndef BOOST_COMPILER -# define BOOST_COMPILER "Unknown ISO C++ Compiler" -# endif -# ifndef BOOST_STDLIB -# define BOOST_STDLIB "Unknown ISO standard library" -# endif -# ifndef BOOST_PLATFORM -# if defined(unix) || defined(__unix) || defined(_XOPEN_SOURCE) \ - || defined(_POSIX_SOURCE) -# define BOOST_PLATFORM "Generic Unix" -# else -# define BOOST_PLATFORM "Unknown" -# endif -# endif - -// -// Set some default values GPU support -// -# ifndef BOOST_GPU_ENABLED -# define BOOST_GPU_ENABLED -# endif - -// BOOST_RESTRICT ---------------------------------------------// -// Macro to use in place of 'restrict' keyword variants -#if !defined(BOOST_RESTRICT) -# if defined(_MSC_VER) -# define BOOST_RESTRICT __restrict -# if !defined(BOOST_NO_RESTRICT_REFERENCES) && (_MSC_FULL_VER < 190023026) -# define BOOST_NO_RESTRICT_REFERENCES -# endif -# elif defined(__GNUC__) && __GNUC__ > 3 - // Clang also defines __GNUC__ (as 4) -# define BOOST_RESTRICT __restrict__ -# else -# define BOOST_RESTRICT -# if !defined(BOOST_NO_RESTRICT_REFERENCES) -# define BOOST_NO_RESTRICT_REFERENCES -# endif -# endif -#endif - -// BOOST_MAY_ALIAS -----------------------------------------------// -// The macro expands to an attribute to mark a type that is allowed to alias other types. -// The macro is defined in the compiler-specific headers. -#if !defined(BOOST_MAY_ALIAS) -# define BOOST_NO_MAY_ALIAS -# define BOOST_MAY_ALIAS -#endif - -// BOOST_FORCEINLINE ---------------------------------------------// -// Macro to use in place of 'inline' to force a function to be inline -#if !defined(BOOST_FORCEINLINE) -# if defined(_MSC_VER) -# define BOOST_FORCEINLINE __forceinline -# elif defined(__GNUC__) && __GNUC__ > 3 - // Clang also defines __GNUC__ (as 4) -# define BOOST_FORCEINLINE inline __attribute__ ((__always_inline__)) -# else -# define BOOST_FORCEINLINE inline -# endif -#endif - -// BOOST_NOINLINE ---------------------------------------------// -// Macro to use in place of 'inline' to prevent a function to be inlined -#if !defined(BOOST_NOINLINE) -# if defined(_MSC_VER) -# define BOOST_NOINLINE __declspec(noinline) -# elif defined(__GNUC__) && __GNUC__ > 3 - // Clang also defines __GNUC__ (as 4) -# if defined(__CUDACC__) - // nvcc doesn't always parse __noinline__, - // see: https://svn.boost.org/trac/boost/ticket/9392 -# define BOOST_NOINLINE __attribute__ ((noinline)) -# else -# define BOOST_NOINLINE __attribute__ ((__noinline__)) -# endif -# else -# define BOOST_NOINLINE -# endif -#endif - -// BOOST_NORETURN ---------------------------------------------// -// Macro to use before a function declaration/definition to designate -// the function as not returning normally (i.e. with a return statement -// or by leaving the function scope, if the function return type is void). -#if !defined(BOOST_NORETURN) -# if defined(_MSC_VER) -# define BOOST_NORETURN __declspec(noreturn) -# elif defined(__GNUC__) -# define BOOST_NORETURN __attribute__ ((__noreturn__)) -# elif defined(__has_attribute) && defined(__SUNPRO_CC) && (__SUNPRO_CC > 0x5130) -# if __has_attribute(noreturn) -# define BOOST_NORETURN [[noreturn]] -# endif -# elif defined(__has_cpp_attribute) -# if __has_cpp_attribute(noreturn) -# define BOOST_NORETURN [[noreturn]] -# endif -# endif -#endif - -#if !defined(BOOST_NORETURN) -# define BOOST_NO_NORETURN -# define BOOST_NORETURN -#endif - -// Branch prediction hints -// These macros are intended to wrap conditional expressions that yield true or false -// -// if (BOOST_LIKELY(var == 10)) -// { -// // the most probable code here -// } -// -#if !defined(BOOST_LIKELY) -# define BOOST_LIKELY(x) x -#endif -#if !defined(BOOST_UNLIKELY) -# define BOOST_UNLIKELY(x) x -#endif - -// Type and data alignment specification -// -#if !defined(BOOST_ALIGNMENT) -# if !defined(BOOST_NO_CXX11_ALIGNAS) -# define BOOST_ALIGNMENT(x) alignas(x) -# elif defined(_MSC_VER) -# define BOOST_ALIGNMENT(x) __declspec(align(x)) -# elif defined(__GNUC__) -# define BOOST_ALIGNMENT(x) __attribute__ ((__aligned__(x))) -# else -# define BOOST_NO_ALIGNMENT -# define BOOST_ALIGNMENT(x) -# endif -#endif - -// Lack of non-public defaulted functions is implied by the lack of any defaulted functions -#if !defined(BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS) && defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) -# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS -#endif - -// Lack of defaulted moves is implied by the lack of either rvalue references or any defaulted functions -#if !defined(BOOST_NO_CXX11_DEFAULTED_MOVES) && (defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) || defined(BOOST_NO_CXX11_RVALUE_REFERENCES)) -# define BOOST_NO_CXX11_DEFAULTED_MOVES -#endif - -// Defaulted and deleted function declaration helpers -// These macros are intended to be inside a class definition. -// BOOST_DEFAULTED_FUNCTION accepts the function declaration and its -// body, which will be used if the compiler doesn't support defaulted functions. -// BOOST_DELETED_FUNCTION only accepts the function declaration. It -// will expand to a private function declaration, if the compiler doesn't support -// deleted functions. Because of this it is recommended to use BOOST_DELETED_FUNCTION -// in the end of the class definition. -// -// class my_class -// { -// public: -// // Default-constructible -// BOOST_DEFAULTED_FUNCTION(my_class(), {}) -// // Copying prohibited -// BOOST_DELETED_FUNCTION(my_class(my_class const&)) -// BOOST_DELETED_FUNCTION(my_class& operator= (my_class const&)) -// }; -// -#if !(defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) || defined(BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS)) -# define BOOST_DEFAULTED_FUNCTION(fun, body) fun = default; -#else -# define BOOST_DEFAULTED_FUNCTION(fun, body) fun body -#endif - -#if !defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) -# define BOOST_DELETED_FUNCTION(fun) fun = delete; -#else -# define BOOST_DELETED_FUNCTION(fun) private: fun; -#endif - -// -// Set BOOST_NO_DECLTYPE_N3276 when BOOST_NO_DECLTYPE is defined -// -#if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_CXX11_DECLTYPE_N3276) -#define BOOST_NO_CXX11_DECLTYPE_N3276 BOOST_NO_CXX11_DECLTYPE -#endif - -// -------------------- Deprecated macros for 1.50 --------------------------- -// These will go away in a future release - -// Use BOOST_NO_CXX11_HDR_UNORDERED_SET or BOOST_NO_CXX11_HDR_UNORDERED_MAP -// instead of BOOST_NO_STD_UNORDERED -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_MAP) || defined (BOOST_NO_CXX11_HDR_UNORDERED_SET) -# ifndef BOOST_NO_CXX11_STD_UNORDERED -# define BOOST_NO_CXX11_STD_UNORDERED -# endif -#endif - -// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST instead of BOOST_NO_INITIALIZER_LISTS -#if defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) && !defined(BOOST_NO_INITIALIZER_LISTS) -# define BOOST_NO_INITIALIZER_LISTS -#endif - -// Use BOOST_NO_CXX11_HDR_ARRAY instead of BOOST_NO_0X_HDR_ARRAY -#if defined(BOOST_NO_CXX11_HDR_ARRAY) && !defined(BOOST_NO_0X_HDR_ARRAY) -# define BOOST_NO_0X_HDR_ARRAY -#endif -// Use BOOST_NO_CXX11_HDR_CHRONO instead of BOOST_NO_0X_HDR_CHRONO -#if defined(BOOST_NO_CXX11_HDR_CHRONO) && !defined(BOOST_NO_0X_HDR_CHRONO) -# define BOOST_NO_0X_HDR_CHRONO -#endif -// Use BOOST_NO_CXX11_HDR_CODECVT instead of BOOST_NO_0X_HDR_CODECVT -#if defined(BOOST_NO_CXX11_HDR_CODECVT) && !defined(BOOST_NO_0X_HDR_CODECVT) -# define BOOST_NO_0X_HDR_CODECVT -#endif -// Use BOOST_NO_CXX11_HDR_CONDITION_VARIABLE instead of BOOST_NO_0X_HDR_CONDITION_VARIABLE -#if defined(BOOST_NO_CXX11_HDR_CONDITION_VARIABLE) && !defined(BOOST_NO_0X_HDR_CONDITION_VARIABLE) -# define BOOST_NO_0X_HDR_CONDITION_VARIABLE -#endif -// Use BOOST_NO_CXX11_HDR_FORWARD_LIST instead of BOOST_NO_0X_HDR_FORWARD_LIST -#if defined(BOOST_NO_CXX11_HDR_FORWARD_LIST) && !defined(BOOST_NO_0X_HDR_FORWARD_LIST) -# define BOOST_NO_0X_HDR_FORWARD_LIST -#endif -// Use BOOST_NO_CXX11_HDR_FUTURE instead of BOOST_NO_0X_HDR_FUTURE -#if defined(BOOST_NO_CXX11_HDR_FUTURE) && !defined(BOOST_NO_0X_HDR_FUTURE) -# define BOOST_NO_0X_HDR_FUTURE -#endif - -// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST -// instead of BOOST_NO_0X_HDR_INITIALIZER_LIST or BOOST_NO_INITIALIZER_LISTS -#ifdef BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST -# define BOOST_NO_0X_HDR_INITIALIZER_LIST -# endif -# ifndef BOOST_NO_INITIALIZER_LISTS -# define BOOST_NO_INITIALIZER_LISTS -# endif -#endif - -// Use BOOST_NO_CXX11_HDR_MUTEX instead of BOOST_NO_0X_HDR_MUTEX -#if defined(BOOST_NO_CXX11_HDR_MUTEX) && !defined(BOOST_NO_0X_HDR_MUTEX) -# define BOOST_NO_0X_HDR_MUTEX -#endif -// Use BOOST_NO_CXX11_HDR_RANDOM instead of BOOST_NO_0X_HDR_RANDOM -#if defined(BOOST_NO_CXX11_HDR_RANDOM) && !defined(BOOST_NO_0X_HDR_RANDOM) -# define BOOST_NO_0X_HDR_RANDOM -#endif -// Use BOOST_NO_CXX11_HDR_RATIO instead of BOOST_NO_0X_HDR_RATIO -#if defined(BOOST_NO_CXX11_HDR_RATIO) && !defined(BOOST_NO_0X_HDR_RATIO) -# define BOOST_NO_0X_HDR_RATIO -#endif -// Use BOOST_NO_CXX11_HDR_REGEX instead of BOOST_NO_0X_HDR_REGEX -#if defined(BOOST_NO_CXX11_HDR_REGEX) && !defined(BOOST_NO_0X_HDR_REGEX) -# define BOOST_NO_0X_HDR_REGEX -#endif -// Use BOOST_NO_CXX11_HDR_SYSTEM_ERROR instead of BOOST_NO_0X_HDR_SYSTEM_ERROR -#if defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) && !defined(BOOST_NO_0X_HDR_SYSTEM_ERROR) -# define BOOST_NO_0X_HDR_SYSTEM_ERROR -#endif -// Use BOOST_NO_CXX11_HDR_THREAD instead of BOOST_NO_0X_HDR_THREAD -#if defined(BOOST_NO_CXX11_HDR_THREAD) && !defined(BOOST_NO_0X_HDR_THREAD) -# define BOOST_NO_0X_HDR_THREAD -#endif -// Use BOOST_NO_CXX11_HDR_TUPLE instead of BOOST_NO_0X_HDR_TUPLE -#if defined(BOOST_NO_CXX11_HDR_TUPLE) && !defined(BOOST_NO_0X_HDR_TUPLE) -# define BOOST_NO_0X_HDR_TUPLE -#endif -// Use BOOST_NO_CXX11_HDR_TYPE_TRAITS instead of BOOST_NO_0X_HDR_TYPE_TRAITS -#if defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS) && !defined(BOOST_NO_0X_HDR_TYPE_TRAITS) -# define BOOST_NO_0X_HDR_TYPE_TRAITS -#endif -// Use BOOST_NO_CXX11_HDR_TYPEINDEX instead of BOOST_NO_0X_HDR_TYPEINDEX -#if defined(BOOST_NO_CXX11_HDR_TYPEINDEX) && !defined(BOOST_NO_0X_HDR_TYPEINDEX) -# define BOOST_NO_0X_HDR_TYPEINDEX -#endif -// Use BOOST_NO_CXX11_HDR_UNORDERED_MAP instead of BOOST_NO_0X_HDR_UNORDERED_MAP -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_MAP) && !defined(BOOST_NO_0X_HDR_UNORDERED_MAP) -# define BOOST_NO_0X_HDR_UNORDERED_MAP -#endif -// Use BOOST_NO_CXX11_HDR_UNORDERED_SET instead of BOOST_NO_0X_HDR_UNORDERED_SET -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_SET) && !defined(BOOST_NO_0X_HDR_UNORDERED_SET) -# define BOOST_NO_0X_HDR_UNORDERED_SET -#endif - -// ------------------ End of deprecated macros for 1.50 --------------------------- - -// -------------------- Deprecated macros for 1.51 --------------------------- -// These will go away in a future release - -// Use BOOST_NO_CXX11_AUTO_DECLARATIONS instead of BOOST_NO_AUTO_DECLARATIONS -#if defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && !defined(BOOST_NO_AUTO_DECLARATIONS) -# define BOOST_NO_AUTO_DECLARATIONS -#endif -// Use BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS instead of BOOST_NO_AUTO_MULTIDECLARATIONS -#if defined(BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS) && !defined(BOOST_NO_AUTO_MULTIDECLARATIONS) -# define BOOST_NO_AUTO_MULTIDECLARATIONS -#endif -// Use BOOST_NO_CXX11_CHAR16_T instead of BOOST_NO_CHAR16_T -#if defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CHAR16_T) -# define BOOST_NO_CHAR16_T -#endif -// Use BOOST_NO_CXX11_CHAR32_T instead of BOOST_NO_CHAR32_T -#if defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CHAR32_T) -# define BOOST_NO_CHAR32_T -#endif -// Use BOOST_NO_CXX11_TEMPLATE_ALIASES instead of BOOST_NO_TEMPLATE_ALIASES -#if defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) && !defined(BOOST_NO_TEMPLATE_ALIASES) -# define BOOST_NO_TEMPLATE_ALIASES -#endif -// Use BOOST_NO_CXX11_CONSTEXPR instead of BOOST_NO_CONSTEXPR -#if defined(BOOST_NO_CXX11_CONSTEXPR) && !defined(BOOST_NO_CONSTEXPR) -# define BOOST_NO_CONSTEXPR -#endif -// Use BOOST_NO_CXX11_DECLTYPE_N3276 instead of BOOST_NO_DECLTYPE_N3276 -#if defined(BOOST_NO_CXX11_DECLTYPE_N3276) && !defined(BOOST_NO_DECLTYPE_N3276) -# define BOOST_NO_DECLTYPE_N3276 -#endif -// Use BOOST_NO_CXX11_DECLTYPE instead of BOOST_NO_DECLTYPE -#if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_DECLTYPE) -# define BOOST_NO_DECLTYPE -#endif -// Use BOOST_NO_CXX11_DEFAULTED_FUNCTIONS instead of BOOST_NO_DEFAULTED_FUNCTIONS -#if defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) && !defined(BOOST_NO_DEFAULTED_FUNCTIONS) -# define BOOST_NO_DEFAULTED_FUNCTIONS -#endif -// Use BOOST_NO_CXX11_DELETED_FUNCTIONS instead of BOOST_NO_DELETED_FUNCTIONS -#if defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) && !defined(BOOST_NO_DELETED_FUNCTIONS) -# define BOOST_NO_DELETED_FUNCTIONS -#endif -// Use BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS instead of BOOST_NO_EXPLICIT_CONVERSION_OPERATORS -#if defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) && !defined(BOOST_NO_EXPLICIT_CONVERSION_OPERATORS) -# define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS -#endif -// Use BOOST_NO_CXX11_EXTERN_TEMPLATE instead of BOOST_NO_EXTERN_TEMPLATE -#if defined(BOOST_NO_CXX11_EXTERN_TEMPLATE) && !defined(BOOST_NO_EXTERN_TEMPLATE) -# define BOOST_NO_EXTERN_TEMPLATE -#endif -// Use BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS instead of BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS -#if defined(BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS) && !defined(BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS) -# define BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif -// Use BOOST_NO_CXX11_LAMBDAS instead of BOOST_NO_LAMBDAS -#if defined(BOOST_NO_CXX11_LAMBDAS) && !defined(BOOST_NO_LAMBDAS) -# define BOOST_NO_LAMBDAS -#endif -// Use BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS instead of BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS -#if defined(BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS) && !defined(BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS) -# define BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif -// Use BOOST_NO_CXX11_NOEXCEPT instead of BOOST_NO_NOEXCEPT -#if defined(BOOST_NO_CXX11_NOEXCEPT) && !defined(BOOST_NO_NOEXCEPT) -# define BOOST_NO_NOEXCEPT -#endif -// Use BOOST_NO_CXX11_NULLPTR instead of BOOST_NO_NULLPTR -#if defined(BOOST_NO_CXX11_NULLPTR) && !defined(BOOST_NO_NULLPTR) -# define BOOST_NO_NULLPTR -#endif -// Use BOOST_NO_CXX11_RAW_LITERALS instead of BOOST_NO_RAW_LITERALS -#if defined(BOOST_NO_CXX11_RAW_LITERALS) && !defined(BOOST_NO_RAW_LITERALS) -# define BOOST_NO_RAW_LITERALS -#endif -// Use BOOST_NO_CXX11_RVALUE_REFERENCES instead of BOOST_NO_RVALUE_REFERENCES -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_RVALUE_REFERENCES) -# define BOOST_NO_RVALUE_REFERENCES -#endif -// Use BOOST_NO_CXX11_SCOPED_ENUMS instead of BOOST_NO_SCOPED_ENUMS -#if defined(BOOST_NO_CXX11_SCOPED_ENUMS) && !defined(BOOST_NO_SCOPED_ENUMS) -# define BOOST_NO_SCOPED_ENUMS -#endif -// Use BOOST_NO_CXX11_STATIC_ASSERT instead of BOOST_NO_STATIC_ASSERT -#if defined(BOOST_NO_CXX11_STATIC_ASSERT) && !defined(BOOST_NO_STATIC_ASSERT) -# define BOOST_NO_STATIC_ASSERT -#endif -// Use BOOST_NO_CXX11_STD_UNORDERED instead of BOOST_NO_STD_UNORDERED -#if defined(BOOST_NO_CXX11_STD_UNORDERED) && !defined(BOOST_NO_STD_UNORDERED) -# define BOOST_NO_STD_UNORDERED -#endif -// Use BOOST_NO_CXX11_UNICODE_LITERALS instead of BOOST_NO_UNICODE_LITERALS -#if defined(BOOST_NO_CXX11_UNICODE_LITERALS) && !defined(BOOST_NO_UNICODE_LITERALS) -# define BOOST_NO_UNICODE_LITERALS -#endif -// Use BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX instead of BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX -#if defined(BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX) && !defined(BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX) -# define BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX -#endif -// Use BOOST_NO_CXX11_VARIADIC_TEMPLATES instead of BOOST_NO_VARIADIC_TEMPLATES -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_VARIADIC_TEMPLATES) -# define BOOST_NO_VARIADIC_TEMPLATES -#endif -// Use BOOST_NO_CXX11_VARIADIC_MACROS instead of BOOST_NO_VARIADIC_MACROS -#if defined(BOOST_NO_CXX11_VARIADIC_MACROS) && !defined(BOOST_NO_VARIADIC_MACROS) -# define BOOST_NO_VARIADIC_MACROS -#endif -// Use BOOST_NO_CXX11_NUMERIC_LIMITS instead of BOOST_NO_NUMERIC_LIMITS_LOWEST -#if defined(BOOST_NO_CXX11_NUMERIC_LIMITS) && !defined(BOOST_NO_NUMERIC_LIMITS_LOWEST) -# define BOOST_NO_NUMERIC_LIMITS_LOWEST -#endif -// ------------------ End of deprecated macros for 1.51 --------------------------- - - -// -// Helper macro for marking types and methods final -// -#if !defined(BOOST_NO_CXX11_FINAL) -# define BOOST_FINAL final -#else -# define BOOST_FINAL -#endif - -// -// Helper macros BOOST_NOEXCEPT, BOOST_NOEXCEPT_IF, BOOST_NOEXCEPT_EXPR -// These aid the transition to C++11 while still supporting C++03 compilers -// -#ifdef BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NOEXCEPT -# define BOOST_NOEXCEPT_OR_NOTHROW throw() -# define BOOST_NOEXCEPT_IF(Predicate) -# define BOOST_NOEXCEPT_EXPR(Expression) false -#else -# define BOOST_NOEXCEPT noexcept -# define BOOST_NOEXCEPT_OR_NOTHROW noexcept -# define BOOST_NOEXCEPT_IF(Predicate) noexcept((Predicate)) -# define BOOST_NOEXCEPT_EXPR(Expression) noexcept((Expression)) -#endif -// -// Helper macro BOOST_FALLTHROUGH -// Fallback definition of BOOST_FALLTHROUGH macro used to mark intended -// fall-through between case labels in a switch statement. We use a definition -// that requires a semicolon after it to avoid at least one type of misuse even -// on unsupported compilers. -// -#ifndef BOOST_FALLTHROUGH -# define BOOST_FALLTHROUGH ((void)0) -#endif - -// -// constexpr workarounds -// -#if defined(BOOST_NO_CXX11_CONSTEXPR) -#define BOOST_CONSTEXPR -#define BOOST_CONSTEXPR_OR_CONST const -#else -#define BOOST_CONSTEXPR constexpr -#define BOOST_CONSTEXPR_OR_CONST constexpr -#endif -#if defined(BOOST_NO_CXX14_CONSTEXPR) -#define BOOST_CXX14_CONSTEXPR -#else -#define BOOST_CXX14_CONSTEXPR constexpr -#endif - -// -// C++17 inline variables -// -#if !defined(BOOST_NO_CXX17_INLINE_VARIABLES) -#define BOOST_INLINE_VARIABLE inline -#else -#define BOOST_INLINE_VARIABLE -#endif -// -// C++17 if constexpr -// -#if !defined(BOOST_NO_CXX17_IF_CONSTEXPR) -# define BOOST_IF_CONSTEXPR if constexpr -#else -# define BOOST_IF_CONSTEXPR if -#endif - -#define BOOST_INLINE_CONSTEXPR BOOST_INLINE_VARIABLE BOOST_CONSTEXPR_OR_CONST - -// -// Unused variable/typedef workarounds: -// -#ifndef BOOST_ATTRIBUTE_UNUSED -# define BOOST_ATTRIBUTE_UNUSED -#endif -// -// [[nodiscard]]: -// -#if defined(__has_attribute) && defined(__SUNPRO_CC) && (__SUNPRO_CC > 0x5130) -#if __has_attribute(nodiscard) -# define BOOST_ATTRIBUTE_NODISCARD [[nodiscard]] -#endif -#if __has_attribute(no_unique_address) -# define BOOST_ATTRIBUTE_NO_UNIQUE_ADDRESS [[no_unique_address]] -#endif -#elif defined(__has_cpp_attribute) -// clang-6 accepts [[nodiscard]] with -std=c++14, but warns about it -pedantic -#if __has_cpp_attribute(nodiscard) && !(defined(__clang__) && (__cplusplus < 201703L)) -# define BOOST_ATTRIBUTE_NODISCARD [[nodiscard]] -#endif -#if __has_cpp_attribute(no_unique_address) && !(defined(__GNUC__) && (__cplusplus < 201100)) -# define BOOST_ATTRIBUTE_NO_UNIQUE_ADDRESS [[no_unique_address]] -#endif -#endif -#ifndef BOOST_ATTRIBUTE_NODISCARD -# define BOOST_ATTRIBUTE_NODISCARD -#endif -#ifndef BOOST_ATTRIBUTE_NO_UNIQUE_ADDRESS -# define BOOST_ATTRIBUTE_NO_UNIQUE_ADDRESS -#endif - -#define BOOST_STATIC_CONSTEXPR static BOOST_CONSTEXPR_OR_CONST - -// -// Set BOOST_HAS_STATIC_ASSERT when BOOST_NO_CXX11_STATIC_ASSERT is not defined -// -#if !defined(BOOST_NO_CXX11_STATIC_ASSERT) && !defined(BOOST_HAS_STATIC_ASSERT) -# define BOOST_HAS_STATIC_ASSERT -#endif - -// -// Set BOOST_HAS_RVALUE_REFS when BOOST_NO_CXX11_RVALUE_REFERENCES is not defined -// -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_HAS_RVALUE_REFS) -#define BOOST_HAS_RVALUE_REFS -#endif - -// -// Set BOOST_HAS_VARIADIC_TMPL when BOOST_NO_CXX11_VARIADIC_TEMPLATES is not defined -// -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_HAS_VARIADIC_TMPL) -#define BOOST_HAS_VARIADIC_TMPL -#endif -// -// Set BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS when -// BOOST_NO_CXX11_VARIADIC_TEMPLATES is set: -// -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS) -# define BOOST_NO_CXX11_FIXED_LENGTH_VARIADIC_TEMPLATE_EXPANSION_PACKS -#endif - -// This is a catch all case for obsolete compilers / std libs: -#if !defined(_YVALS) && !defined(_CPPLIB_VER) // msvc std lib already configured -#if (!defined(__has_include) || (__cplusplus < 201700)) -# define BOOST_NO_CXX17_HDR_OPTIONAL -# define BOOST_NO_CXX17_HDR_STRING_VIEW -# define BOOST_NO_CXX17_HDR_VARIANT -#else -#if !__has_include(<optional>) -# define BOOST_NO_CXX17_HDR_OPTIONAL -#endif -#if !__has_include(<string_view>) -# define BOOST_NO_CXX17_HDR_STRING_VIEW -#endif -#if !__has_include(<variant>) -# define BOOST_NO_CXX17_HDR_VARIANT -#endif -#endif -#endif - -// -// Finish off with checks for macros that are depricated / no longer supported, -// if any of these are set then it's very likely that much of Boost will no -// longer work. So stop with a #error for now, but give the user a chance -// to continue at their own risk if they really want to: -// -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_CONFIG_ALLOW_DEPRECATED) -# error "You are using a compiler which lacks features which are now a minimum requirement in order to use Boost, define BOOST_CONFIG_ALLOW_DEPRECATED if you want to continue at your own risk!!!" -#endif - -#endif diff --git a/ThirdParty/boost/config/platform/vxworks.hpp b/ThirdParty/boost/config/platform/vxworks.hpp deleted file mode 100644 index 0564b9443f84ad710271ae0f1c4ab718b7ce1470..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/platform/vxworks.hpp +++ /dev/null @@ -1,422 +0,0 @@ -// (C) Copyright Dustin Spicuzza 2009. -// Adapted to vxWorks 6.9 by Peter Brockamp 2012. -// Updated for VxWorks 7 by Brian Kuhl 2016 -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Old versions of vxWorks (namely everything below 6.x) are -// absolutely unable to use boost. Old STLs and compilers -// like (GCC 2.96) . Do not even think of getting this to work, -// a miserable failure will be guaranteed! -// -// VxWorks supports C++ linkage in the kernel with -// DKMs (Downloadable Kernel Modules). But, until recently -// the kernel used a C89 library with no -// wide character support and no guarantee of ANSI C. -// Regardless of the C library the same Dinkum -// STL library is used in both contexts. -// -// Similarly the Dinkum abridged STL that supports the loosely specified -// embedded C++ standard has not been tested and is unlikely to work -// on anything but the simplest library. -// ==================================================================== -// -// Some important information regarding the usage of POSIX semaphores: -// ------------------------------------------------------------------- -// -// VxWorks as a real time operating system handles threads somewhat -// different from what "normal" OSes do, regarding their scheduling! -// This could lead to a scenario called "priority inversion" when using -// semaphores, see http://en.wikipedia.org/wiki/Priority_inversion. -// -// Now, VxWorks POSIX-semaphores for DKM's default to the usage of -// priority inverting semaphores, which is fine. On the other hand, -// for RTP's it defaults to using non priority inverting semaphores, -// which could easily pose a serious problem for a real time process. -// -// To change the default properties for POSIX-semaphores in VxWorks 7 -// enable core > CORE_USER Menu > DEFAULT_PTHREAD_PRIO_INHERIT -// -// In VxWorks 6.x so as to integrate with boost. -// - Edit the file -// installDir/vxworks-6.x/target/usr/src/posix/pthreadLib.c -// - Around line 917 there should be the definition of the default -// mutex attributes: -// -// LOCAL pthread_mutexattr_t defaultMutexAttr = -// { -// PTHREAD_INITIALIZED_OBJ, PTHREAD_PRIO_NONE, 0, -// PTHREAD_MUTEX_DEFAULT -// }; -// -// Here, replace PTHREAD_PRIO_NONE by PTHREAD_PRIO_INHERIT. -// - Around line 1236 there should be a definition for the function -// pthread_mutexattr_init(). A couple of lines below you should -// find a block of code like this: -// -// pAttr->mutexAttrStatus = PTHREAD_INITIALIZED_OBJ; -// pAttr->mutexAttrProtocol = PTHREAD_PRIO_NONE; -// pAttr->mutexAttrPrioceiling = 0; -// pAttr->mutexAttrType = PTHREAD_MUTEX_DEFAULT; -// -// Here again, replace PTHREAD_PRIO_NONE by PTHREAD_PRIO_INHERIT. -// - Finally, rebuild your VSB. This will rebuild the libraries -// with the changed properties. That's it! Now, using boost should -// no longer cause any problems with task deadlocks! -// -// ==================================================================== - -// Block out all versions before vxWorks 6.x, as these don't work: -// Include header with the vxWorks version information and query them -#include <version.h> -#if !defined(_WRS_VXWORKS_MAJOR) || (_WRS_VXWORKS_MAJOR < 6) -# error "The vxWorks version you're using is so badly outdated,\ - it doesn't work at all with boost, sorry, no chance!" -#endif - -// Handle versions above 5.X but below 6.9 -#if (_WRS_VXWORKS_MAJOR == 6) && (_WRS_VXWORKS_MINOR < 9) -// TODO: Starting from what version does vxWorks work with boost? -// We can't reasonably insert a #warning "" as a user hint here, -// as this will show up with every file including some boost header, -// badly bugging the user... So for the time being we just leave it. -#endif - -// vxWorks specific config options: -// -------------------------------- -#define BOOST_PLATFORM "vxWorks" - - -// Generally available headers: -#define BOOST_HAS_UNISTD_H -#define BOOST_HAS_STDINT_H -#define BOOST_HAS_DIRENT_H -//#define BOOST_HAS_SLIST - -// vxWorks does not have installed an iconv-library by default, -// so unfortunately no Unicode support from scratch is available! -// Thus, instead it is suggested to switch to ICU, as this seems -// to be the most complete and portable option... -#ifndef BOOST_LOCALE_WITH_ICU - #define BOOST_LOCALE_WITH_ICU -#endif - -// Generally available functionality: -#define BOOST_HAS_THREADS -#define BOOST_HAS_NANOSLEEP -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_CLOCK_GETTIME -#define BOOST_HAS_MACRO_USE_FACET - -// Generally available threading API's: -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_SCHED_YIELD -#define BOOST_HAS_SIGACTION - -// Functionality available for RTPs only: -#ifdef __RTP__ -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_LOG1P -# define BOOST_HAS_EXPM1 -#endif - -// Functionality available for DKMs only: -#ifdef _WRS_KERNEL - // Luckily, at the moment there seems to be none! -#endif - -// These #defines allow detail/posix_features to work, since vxWorks doesn't -// #define them itself for DKMs (for RTPs on the contrary it does): -#ifdef _WRS_KERNEL -# ifndef _POSIX_TIMERS -# define _POSIX_TIMERS 1 -# endif -# ifndef _POSIX_THREADS -# define _POSIX_THREADS 1 -# endif -// no sysconf( _SC_PAGESIZE) in kernel -# define BOOST_THREAD_USES_GETPAGESIZE -#endif - -#if (_WRS_VXWORKS_MAJOR < 7) -// vxWorks-around: <time.h> #defines CLOCKS_PER_SEC as sysClkRateGet() but -// miserably fails to #include the required <sysLib.h> to make -// sysClkRateGet() available! So we manually include it here. -# ifdef __RTP__ -# include <time.h> -# include <sysLib.h> -# endif - -// vxWorks-around: In <stdint.h> the macros INT32_C(), UINT32_C(), INT64_C() and -// UINT64_C() are defined erroneously, yielding not a signed/ -// unsigned long/long long type, but a signed/unsigned int/long -// type. Eventually this leads to compile errors in ratio_fwd.hpp, -// when trying to define several constants which do not fit into a -// long type! We correct them here by redefining. - -# include <cstdint> - -// Special behaviour for DKMs: - -// Some macro-magic to do the job -# define VX_JOIN(X, Y) VX_DO_JOIN(X, Y) -# define VX_DO_JOIN(X, Y) VX_DO_JOIN2(X, Y) -# define VX_DO_JOIN2(X, Y) X##Y - -// Correctly setup the macros -# undef INT32_C -# undef UINT32_C -# undef INT64_C -# undef UINT64_C -# define INT32_C(x) VX_JOIN(x, L) -# define UINT32_C(x) VX_JOIN(x, UL) -# define INT64_C(x) VX_JOIN(x, LL) -# define UINT64_C(x) VX_JOIN(x, ULL) - -// #include Libraries required for the following function adaption -# include <sys/time.h> -#endif // _WRS_VXWORKS_MAJOR < 7 - -#include <ioLib.h> -#include <tickLib.h> - -#if defined(_WRS_KERNEL) && (_CPPLIB_VER < 700) - // recent kernels use Dinkum clib v7.00+ - // with widechar but older kernels - // do not have the <cwchar>-header, - // but apparently they do have an intrinsic wchar_t meanwhile! -# define BOOST_NO_CWCHAR - - // Lots of wide-functions and -headers are unavailable for DKMs as well: -# define BOOST_NO_CWCTYPE -# define BOOST_NO_SWPRINTF -# define BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTREAMBUF -#endif - - -// Use C-linkage for the following helper functions -#ifdef __cplusplus -extern "C" { -#endif - -// vxWorks-around: The required functions getrlimit() and getrlimit() are missing. -// But we have the similar functions getprlimit() and setprlimit(), -// which may serve the purpose. -// Problem: The vxWorks-documentation regarding these functions -// doesn't deserve its name! It isn't documented what the first two -// parameters idtype and id mean, so we must fall back to an educated -// guess - null, argh... :-/ - -// TODO: getprlimit() and setprlimit() do exist for RTPs only, for whatever reason. -// Thus for DKMs there would have to be another implementation. -#if defined ( __RTP__) && (_WRS_VXWORKS_MAJOR < 7) - inline int getrlimit(int resource, struct rlimit *rlp){ - return getprlimit(0, 0, resource, rlp); - } - - inline int setrlimit(int resource, const struct rlimit *rlp){ - return setprlimit(0, 0, resource, const_cast<struct rlimit*>(rlp)); - } -#endif - -// vxWorks has ftruncate() only, so we do simulate truncate(): -inline int truncate(const char *p, off_t l){ - int fd = open(p, O_WRONLY); - if (fd == -1){ - errno = EACCES; - return -1; - } - if (ftruncate(fd, l) == -1){ - close(fd); - errno = EACCES; - return -1; - } - return close(fd); -} - -#ifdef __GNUC__ -# define ___unused __attribute__((unused)) -#else -# define ___unused -#endif - -// Fake symlink handling by dummy functions: -inline int symlink(const char* path1 ___unused, const char* path2 ___unused){ - // vxWorks has no symlinks -> always return an error! - errno = EACCES; - return -1; -} - -inline ssize_t readlink(const char* path1 ___unused, char* path2 ___unused, size_t size ___unused){ - // vxWorks has no symlinks -> always return an error! - errno = EACCES; - return -1; -} - -#if (_WRS_VXWORKS_MAJOR < 7) - -inline int gettimeofday(struct timeval *tv, void * /*tzv*/) { - struct timespec ts; - clock_gettime(CLOCK_MONOTONIC, &ts); - tv->tv_sec = ts.tv_sec; - tv->tv_usec = ts.tv_nsec / 1000; - return 0; -} -#endif - -#ifdef __cplusplus -} // extern "C" -#endif - -/* - * moved to os/utils/unix/freind_h/times.h in VxWorks 7 - * to avoid conflict with MPL operator times - */ -#if (_WRS_VXWORKS_MAJOR < 7) -# ifdef __cplusplus - -// vxWorks provides neither struct tms nor function times()! -// We implement an empty dummy-function, simply setting the user -// and system time to the half of thew actual system ticks-value -// and the child user and system time to 0. -// Rather ugly but at least it suppresses compiler errors... -// Unfortunately, this of course *does* have an severe impact on -// dependant libraries, actually this is chrono only! Here it will -// not be possible to correctly use user and system times! But -// as vxWorks is lacking the ability to calculate user and system -// process times there seems to be no other possible solution. -struct tms{ - clock_t tms_utime; // User CPU time - clock_t tms_stime; // System CPU time - clock_t tms_cutime; // User CPU time of terminated child processes - clock_t tms_cstime; // System CPU time of terminated child processes -}; - - - inline clock_t times(struct tms *t){ - struct timespec ts; - clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts); - clock_t ticks(static_cast<clock_t>(static_cast<double>(ts.tv_sec) * CLOCKS_PER_SEC + - static_cast<double>(ts.tv_nsec) * CLOCKS_PER_SEC / 1000000.0)); - t->tms_utime = ticks/2U; - t->tms_stime = ticks/2U; - t->tms_cutime = 0; // vxWorks is lacking the concept of a child process! - t->tms_cstime = 0; // -> Set the wait times for childs to 0 - return ticks; -} - - -namespace std { - using ::times; -} -# endif // __cplusplus -#endif // _WRS_VXWORKS_MAJOR < 7 - - -#ifdef __cplusplus -extern "C" void bzero (void *, size_t); // FD_ZERO uses bzero() but doesn't include strings.h - -// Put the selfmade functions into the std-namespace, just in case -namespace std { -# ifdef __RTP__ - using ::getrlimit; - using ::setrlimit; -# endif - using ::truncate; - using ::symlink; - using ::readlink; -# if (_WRS_VXWORKS_MAJOR < 7) - using ::gettimeofday; -# endif -} -#endif // __cplusplus - -// Some more macro-magic: -// vxWorks-around: Some functions are not present or broken in vxWorks -// but may be patched to life via helper macros... - -// Include signal.h which might contain a typo to be corrected here -#include <signal.h> - -#if (_WRS_VXWORKS_MAJOR < 7) -# define getpagesize() sysconf(_SC_PAGESIZE) // getpagesize is deprecated anyway! -inline int lstat(p, b) { return stat(p, b); } // lstat() == stat(), as vxWorks has no symlinks! -#endif - -#ifndef S_ISSOCK -# define S_ISSOCK(mode) ((mode & S_IFMT) == S_IFSOCK) // Is file a socket? -#endif -#ifndef FPE_FLTINV -# define FPE_FLTINV (FPE_FLTSUB+1) // vxWorks has no FPE_FLTINV, so define one as a dummy -#endif -#if !defined(BUS_ADRALN) && defined(BUS_ADRALNR) -# define BUS_ADRALN BUS_ADRALNR // Correct a supposed typo in vxWorks' <signal.h> -#endif -typedef int locale_t; // locale_t is a POSIX-extension, currently not present in vxWorks! - -// #include boilerplate code: -#include <boost/config/detail/posix_features.hpp> - -// vxWorks lies about XSI conformance, there is no nl_types.h: -#undef BOOST_HAS_NL_TYPES_H - -// vxWorks 7 adds C++11 support -// however it is optional, and does not match exactly the support determined -// by examining the Dinkum STL version and GCC version (or ICC and DCC) -#if !( defined( _WRS_CONFIG_LANG_LIB_CPLUS_CPLUS_USER_2011) || defined(_WRS_CONFIG_LIBCPLUS_STD)) -# define BOOST_NO_CXX11_ADDRESSOF // C11 addressof operator on memory location -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_NUMERIC_LIMITS // max_digits10 in test/../print_helper.hpp -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_STD_ALIGN - - -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST //serialization/test/test_list.cpp -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM //math/../test_data.hpp -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -#else -# ifndef BOOST_SYSTEM_NO_DEPRECATED -# define BOOST_SYSTEM_NO_DEPRECATED // workaround link error in spirit -# endif -#endif - - -// NONE is used in enums in lamda and other libraries -#undef NONE -// restrict is an iostreams class -#undef restrict -// affects some typeof tests -#undef V7 - -// use fake poll() from Unix layer in ASIO to get full functionality -// most libraries will use select() but this define allows 'iostream' functionality -// which is based on poll() only -#if (_WRS_VXWORKS_MAJOR > 6) -# ifndef BOOST_ASIO_HAS_POSIX_STREAM_DESCRIPTOR -# define BOOST_ASIO_HAS_POSIX_STREAM_DESCRIPTOR -# endif -#else -# define BOOST_ASIO_DISABLE_SERIAL_PORT -#endif - diff --git a/ThirdParty/boost/config/stdlib/dinkumware.hpp b/ThirdParty/boost/config/stdlib/dinkumware.hpp deleted file mode 100644 index 109804204704f706fe256c56a4bcfb7730bc6afa..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/dinkumware.hpp +++ /dev/null @@ -1,264 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Guillaume Melquiond 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Dinkumware standard library config: - -#if !defined(_YVALS) && !defined(_CPPLIB_VER) -#include <boost/config/no_tr1/utility.hpp> -#if !defined(_YVALS) && !defined(_CPPLIB_VER) -#error This is not the Dinkumware lib! -#endif -#endif - - -#if defined(_CPPLIB_VER) && (_CPPLIB_VER >= 306) - // full dinkumware 3.06 and above - // fully conforming provided the compiler supports it: -# if !(defined(_GLOBAL_USING) && (_GLOBAL_USING+0 > 0)) && !defined(__BORLANDC__) && !defined(_STD) && !(defined(__ICC) && (__ICC >= 700)) // can be defined in yvals.h -# define BOOST_NO_STDC_NAMESPACE -# endif -# if !(defined(_HAS_MEMBER_TEMPLATES_REBIND) && (_HAS_MEMBER_TEMPLATES_REBIND+0 > 0)) && !(defined(_MSC_VER) && (_MSC_VER > 1300)) && defined(BOOST_MSVC) -# define BOOST_NO_STD_ALLOCATOR -# endif -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -# if defined(BOOST_MSVC) && (BOOST_MSVC < 1300) - // if this lib version is set up for vc6 then there is no std::use_facet: -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET - // C lib functions aren't in namespace std either: -# define BOOST_NO_STDC_NAMESPACE - // and nor is <exception> -# define BOOST_NO_EXCEPTION_STD_NAMESPACE -# endif -// There's no numeric_limits<long long> support unless _LONGLONG is defined: -# if !defined(_LONGLONG) && (_CPPLIB_VER <= 310) -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# endif -// 3.06 appears to have (non-sgi versions of) <hash_set> & <hash_map>, -// and no <slist> at all -#else -# define BOOST_MSVC_STD_ITERATOR 1 -# define BOOST_NO_STD_ITERATOR -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -# define BOOST_NO_STDC_NAMESPACE -# define BOOST_NO_STD_USE_FACET -# define BOOST_NO_STD_OUTPUT_ITERATOR_ASSIGN -# define BOOST_HAS_MACRO_USE_FACET -# ifndef _CPPLIB_VER - // Updated Dinkum library defines this, and provides - // its own min and max definitions, as does MTA version. -# ifndef __MTA__ -# define BOOST_NO_STD_MIN_MAX -# endif -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# endif -#endif - -// -// std extension namespace is stdext for vc7.1 and later, -// the same applies to other compilers that sit on top -// of vc7.1 (Intel and Comeau): -// -#if defined(_MSC_VER) && (_MSC_VER >= 1310) && !defined(__BORLANDC__) -# define BOOST_STD_EXTENSION_NAMESPACE stdext -#endif - - -#if (defined(_MSC_VER) && (_MSC_VER <= 1300) && !defined(__BORLANDC__)) || !defined(_CPPLIB_VER) || (_CPPLIB_VER < 306) - // if we're using a dinkum lib that's - // been configured for VC6/7 then there is - // no iterator traits (true even for icl) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -#if defined(__ICL) && (__ICL < 800) && defined(_CPPLIB_VER) && (_CPPLIB_VER <= 310) -// Intel C++ chokes over any non-trivial use of <locale> -// this may be an overly restrictive define, but regex fails without it: -# define BOOST_NO_STD_LOCALE -#endif - -#if BOOST_MSVC < 1800 -// Fix for VC++ 8.0 on up ( I do not have a previous version to test ) -// or clang-cl. If exceptions are off you must manually include the -// <exception> header before including the <typeinfo> header. Admittedly -// trying to use Boost libraries or the standard C++ libraries without -// exception support is not suggested but currently clang-cl ( v 3.4 ) -// does not support exceptions and must be compiled with exceptions off. -#if !_HAS_EXCEPTIONS && ((defined(BOOST_MSVC) && BOOST_MSVC >= 1400) || (defined(__clang__) && defined(_MSC_VER))) -#include <exception> -#endif -#include <typeinfo> -#if ( (!_HAS_EXCEPTIONS && !defined(__ghs__)) || (defined(__ghs__) && !_HAS_NAMESPACE) ) && !defined(__TI_COMPILER_VERSION__) && !defined(__VISUALDSPVERSION__) \ - && !defined(__VXWORKS__) -# define BOOST_NO_STD_TYPEINFO -#endif -#endif - -// C++0x headers implemented in 520 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 520 -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_SMART_PTR -#endif - -#if ((!defined(_HAS_TR1_IMPORTS) || (_HAS_TR1_IMPORTS+0 == 0)) && !defined(BOOST_NO_CXX11_HDR_TUPLE)) \ - && (!defined(_CPPLIB_VER) || _CPPLIB_VER < 610) -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -// C++0x headers implemented in 540 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 540 -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_HDR_EXCEPTION -#endif - -// C++0x headers implemented in 610 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 610 -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_ALLOCATOR -// 540 has std::align but it is not a conforming implementation -# define BOOST_NO_CXX11_STD_ALIGN -#endif - -// Before 650 std::pointer_traits has a broken rebind template -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 650 -# define BOOST_NO_CXX11_POINTER_TRAITS -#elif defined(BOOST_MSVC) && BOOST_MSVC < 1910 -# define BOOST_NO_CXX11_POINTER_TRAITS -#endif - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif (__cplusplus < 201402) && !defined(_MSC_VER) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#elif !defined(_CPPLIB_VER) || (_CPPLIB_VER < 650) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -#if !defined(_CPPLIB_VER) || (_CPPLIB_VER < 650) -# define BOOST_NO_CXX14_STD_EXCHANGE -#endif - -// C++17 features -#if !defined(_CPPLIB_VER) || (_CPPLIB_VER < 650) || !defined(BOOST_MSVC) || (BOOST_MSVC < 1910) || !defined(_HAS_CXX17) || (_HAS_CXX17 == 0) -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_ITERATOR_TRAITS -# define BOOST_NO_CXX17_HDR_STRING_VIEW -# define BOOST_NO_CXX17_HDR_OPTIONAL -# define BOOST_NO_CXX17_HDR_VARIANT -#endif -#if !defined(_CPPLIB_VER) || (_CPPLIB_VER < 650) || !defined(_HAS_CXX17) || (_HAS_CXX17 == 0) || !defined(_MSVC_STL_UPDATE) || (_MSVC_STL_UPDATE < 201709) -# define BOOST_NO_CXX17_STD_INVOKE -#endif - -#if !(!defined(_CPPLIB_VER) || (_CPPLIB_VER < 650) || !defined(BOOST_MSVC) || (BOOST_MSVC < 1912) || !defined(_HAS_CXX17) || (_HAS_CXX17 == 0)) -// Deprecated std::iterator: -# define BOOST_NO_STD_ITERATOR -#endif - -#if defined(BOOST_INTEL) && (BOOST_INTEL <= 1400) -// Intel's compiler can't handle this header yet: -# define BOOST_NO_CXX11_HDR_ATOMIC -#endif - - -// 520..610 have std::addressof, but it doesn't support functions -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 650 -# define BOOST_NO_CXX11_ADDRESSOF -#endif - -// Bug specific to VC14, -// See https://connect.microsoft.com/VisualStudio/feedback/details/1348277/link-error-when-using-std-codecvt-utf8-utf16-char16-t -// and discussion here: http://blogs.msdn.com/b/vcblog/archive/2014/11/12/visual-studio-2015-preview-now-available.aspx?PageIndex=2 -#if defined(_CPPLIB_VER) && (_CPPLIB_VER == 650) -# define BOOST_NO_CXX11_HDR_CODECVT -#endif - -#if defined(_CPPLIB_VER) && (_CPPLIB_VER >= 650) -// If _HAS_AUTO_PTR_ETC is defined to 0, std::auto_ptr and std::random_shuffle are not available. -// See https://www.visualstudio.com/en-us/news/vs2015-vs.aspx#C++ -// and http://blogs.msdn.com/b/vcblog/archive/2015/06/19/c-11-14-17-features-in-vs-2015-rtm.aspx -# if defined(_HAS_AUTO_PTR_ETC) && (_HAS_AUTO_PTR_ETC == 0) -# define BOOST_NO_AUTO_PTR -# define BOOST_NO_CXX98_RANDOM_SHUFFLE -# define BOOST_NO_CXX98_FUNCTION_BASE -# define BOOST_NO_CXX98_BINDERS -# endif -#endif - - -// -// Things not supported by the CLR: -#ifdef _M_CEE -#ifndef BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_MUTEX -#endif -#ifndef BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_HDR_ATOMIC -#endif -#ifndef BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_FUTURE -#endif -#ifndef BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -#endif -#ifndef BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_THREAD -#endif -#ifndef BOOST_NO_CXX14_HDR_SHARED_MUTEX -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#ifndef BOOST_NO_CXX14_STD_EXCHANGE -# define BOOST_NO_CXX14_STD_EXCHANGE -#endif -#ifndef BOOST_NO_FENV_H -# define BOOST_NO_FENV_H -#endif -#endif - -#ifdef _CPPLIB_VER -# define BOOST_DINKUMWARE_STDLIB _CPPLIB_VER -#else -# define BOOST_DINKUMWARE_STDLIB 1 -#endif - -#ifdef _CPPLIB_VER -# define BOOST_STDLIB "Dinkumware standard library version " BOOST_STRINGIZE(_CPPLIB_VER) -#else -# define BOOST_STDLIB "Dinkumware standard library version 1.x" -#endif diff --git a/ThirdParty/boost/config/stdlib/libcomo.hpp b/ThirdParty/boost/config/stdlib/libcomo.hpp deleted file mode 100644 index 6a8a1619625453b0ef6018b2b06ad70cc32f7053..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/libcomo.hpp +++ /dev/null @@ -1,93 +0,0 @@ -// (C) Copyright John Maddock 2002 - 2003. -// (C) Copyright Jens Maurer 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Comeau STL: - -#if !defined(__LIBCOMO__) -# include <boost/config/no_tr1/utility.hpp> -# if !defined(__LIBCOMO__) -# error "This is not the Comeau STL!" -# endif -#endif - -// -// std::streambuf<wchar_t> is non-standard -// NOTE: versions of libcomo prior to beta28 have octal version numbering, -// e.g. version 25 is 21 (dec) -#if __LIBCOMO_VERSION__ <= 22 -# define BOOST_NO_STD_WSTREAMBUF -#endif - -#if (__LIBCOMO_VERSION__ <= 31) && defined(_WIN32) -#define BOOST_NO_SWPRINTF -#endif - -#if __LIBCOMO_VERSION__ >= 31 -# define BOOST_HAS_HASH -# define BOOST_HAS_SLIST -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_EXCEPTION -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -// -// Intrinsic type_traits support. -// The SGI STL has it's own __type_traits class, which -// has intrinsic compiler support with SGI's compilers. -// Whatever map SGI style type traits to boost equivalents: -// -#define BOOST_HAS_SGI_TYPE_TRAITS - -#define BOOST_STDLIB "Comeau standard library " BOOST_STRINGIZE(__LIBCOMO_VERSION__) diff --git a/ThirdParty/boost/config/stdlib/libcpp.hpp b/ThirdParty/boost/config/stdlib/libcpp.hpp deleted file mode 100644 index e8eea9117c1062280c21173cda3142958ac55d18..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/libcpp.hpp +++ /dev/null @@ -1,145 +0,0 @@ -// (C) Copyright Christopher Jefferson 2011. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// config for libc++ -// Might need more in here later. - -#if !defined(_LIBCPP_VERSION) -# include <ciso646> -# if !defined(_LIBCPP_VERSION) -# error "This is not libc++!" -# endif -#endif - -#define BOOST_STDLIB "libc++ version " BOOST_STRINGIZE(_LIBCPP_VERSION) - -#define BOOST_HAS_THREADS - -#ifdef _LIBCPP_HAS_NO_VARIADICS -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -// BOOST_NO_CXX11_ALLOCATOR should imply no support for the C++11 -// allocator model. The C++11 allocator model requires a conforming -// std::allocator_traits which is only possible with C++11 template -// aliases since members rebind_alloc and rebind_traits require it. -#if defined(_LIBCPP_HAS_NO_TEMPLATE_ALIASES) -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -#endif - -#if __cplusplus < 201103 -// -// These two appear to be somewhat useable in C++03 mode, there may be others... -// -//# define BOOST_NO_CXX11_HDR_ARRAY -//# define BOOST_NO_CXX11_HDR_FORWARD_LIST - -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_EXCEPTION -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_FUTURE -#elif _LIBCPP_VERSION < 3700 -// -// These appear to be unusable/incomplete so far: -// -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_FUTURE -#endif - - -#if _LIBCPP_VERSION < 3700 -// libc++ uses a non-standard messages_base -#define BOOST_NO_STD_MESSAGES -#endif - -// C++14 features -#if (_LIBCPP_VERSION < 3700) || (__cplusplus <= 201402L) -# define BOOST_NO_CXX14_STD_EXCHANGE -#endif - -// C++17 features -#if (_LIBCPP_VERSION < 4000) || (__cplusplus <= 201402L) -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_HDR_OPTIONAL -# define BOOST_NO_CXX17_HDR_STRING_VIEW -# define BOOST_NO_CXX17_HDR_VARIANT -#endif -#if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_AUTO_PTR) -# define BOOST_NO_AUTO_PTR -#endif -#if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_RANDOM_SHUFFLE) -# define BOOST_NO_CXX98_RANDOM_SHUFFLE -#endif -#if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_BINDERS) -# define BOOST_NO_CXX98_BINDERS -#endif - -#define BOOST_NO_CXX17_ITERATOR_TRAITS -#define BOOST_NO_CXX17_STD_INVOKE // Invoke support is incomplete (no invoke_result) - -#if (_LIBCPP_VERSION <= 1101) && !defined(BOOST_NO_CXX11_THREAD_LOCAL) -// This is a bit of a sledgehammer, because really it's just libc++abi that has no -// support for thread_local, leading to linker errors such as -// "undefined reference to `__cxa_thread_atexit'". It is fixed in the -// most recent releases of libc++abi though... -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -#if defined(__linux__) && (_LIBCPP_VERSION < 6000) && !defined(BOOST_NO_CXX11_THREAD_LOCAL) -// After libc++-dev is installed on Trusty, clang++-libc++ almost works, -// except uses of `thread_local` fail with undefined reference to -// `__cxa_thread_atexit`. -// -// clang's libc++abi provides an implementation by deferring to the glibc -// implementation, which may or may not be available (it is not on Trusty). -// clang 4's libc++abi will provide an implementation if one is not in glibc -// though, so thread local support should work with clang 4 and above as long -// as libc++abi is linked in. -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus <= 201103 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -#if !defined(BOOST_NO_CXX14_HDR_SHARED_MUTEX) && (_LIBCPP_VERSION < 5000) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// --- end --- diff --git a/ThirdParty/boost/config/stdlib/libstdcpp3.hpp b/ThirdParty/boost/config/stdlib/libstdcpp3.hpp deleted file mode 100644 index c4c999602659082f0700cf2f44b7b77cb809febe..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/libstdcpp3.hpp +++ /dev/null @@ -1,357 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// config for libstdc++ v3 -// not much to go in here: - -#define BOOST_GNU_STDLIB 1 - -#ifdef __GLIBCXX__ -#define BOOST_STDLIB "GNU libstdc++ version " BOOST_STRINGIZE(__GLIBCXX__) -#else -#define BOOST_STDLIB "GNU libstdc++ version " BOOST_STRINGIZE(__GLIBCPP__) -#endif - -#if !defined(_GLIBCPP_USE_WCHAR_T) && !defined(_GLIBCXX_USE_WCHAR_T) -# define BOOST_NO_CWCHAR -# define BOOST_NO_CWCTYPE -# define BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTREAMBUF -#endif - -#if defined(__osf__) && !defined(_REENTRANT) \ - && ( defined(_GLIBCXX_HAVE_GTHR_DEFAULT) || defined(_GLIBCPP_HAVE_GTHR_DEFAULT) ) -// GCC 3 on Tru64 forces the definition of _REENTRANT when any std lib header -// file is included, therefore for consistency we define it here as well. -# define _REENTRANT -#endif - -#ifdef __GLIBCXX__ // gcc 3.4 and greater: -# if defined(_GLIBCXX_HAVE_GTHR_DEFAULT) \ - || defined(_GLIBCXX__PTHREADS) \ - || defined(_GLIBCXX_HAS_GTHREADS) \ - || defined(_WIN32) \ - || defined(_AIX) \ - || defined(__HAIKU__) - // - // If the std lib has thread support turned on, then turn it on in Boost - // as well. We do this because some gcc-3.4 std lib headers define _REENTANT - // while others do not... - // -# define BOOST_HAS_THREADS -# else -# define BOOST_DISABLE_THREADS -# endif -#elif defined(__GLIBCPP__) \ - && !defined(_GLIBCPP_HAVE_GTHR_DEFAULT) \ - && !defined(_GLIBCPP__PTHREADS) - // disable thread support if the std lib was built single threaded: -# define BOOST_DISABLE_THREADS -#endif - -#if (defined(linux) || defined(__linux) || defined(__linux__)) && defined(__arm__) && defined(_GLIBCPP_HAVE_GTHR_DEFAULT) -// linux on arm apparently doesn't define _REENTRANT -// so just turn on threading support whenever the std lib is thread safe: -# define BOOST_HAS_THREADS -#endif - -#if !defined(_GLIBCPP_USE_LONG_LONG) \ - && !defined(_GLIBCXX_USE_LONG_LONG)\ - && defined(BOOST_HAS_LONG_LONG) -// May have been set by compiler/*.hpp, but "long long" without library -// support is useless. -# undef BOOST_HAS_LONG_LONG -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include <unistd.h> -#endif - -#ifndef __VXWORKS__ // VxWorks uses Dinkum, not GNU STL with GCC -#if defined(__GLIBCXX__) || (defined(__GLIBCPP__) && __GLIBCPP__>=20020514) // GCC >= 3.1.0 -# define BOOST_STD_EXTENSION_NAMESPACE __gnu_cxx -# define BOOST_HAS_SLIST -# define BOOST_HAS_HASH -# define BOOST_SLIST_HEADER <ext/slist> -# if !defined(__GNUC__) || __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 3) -# define BOOST_HASH_SET_HEADER <ext/hash_set> -# define BOOST_HASH_MAP_HEADER <ext/hash_map> -# else -# define BOOST_HASH_SET_HEADER <backward/hash_set> -# define BOOST_HASH_MAP_HEADER <backward/hash_map> -# endif -#endif -#endif - -// -// Decide whether we have C++11 support turned on: -// -#if defined(__GXX_EXPERIMENTAL_CXX0X__) || (__cplusplus >= 201103) -# define BOOST_LIBSTDCXX11 -#endif - -// -// Decide which version of libstdc++ we have, normally -// libstdc++ C++0x support is detected via __GNUC__, __GNUC_MINOR__, and possibly -// __GNUC_PATCHLEVEL__ at the suggestion of Jonathan Wakely, one of the libstdc++ -// developers. He also commented: -// -// "I'm not sure how useful __GLIBCXX__ is for your purposes, for instance in -// GCC 4.2.4 it is set to 20080519 but in GCC 4.3.0 it is set to 20080305. -// Although 4.3.0 was released earlier than 4.2.4, it has better C++0x support -// than any release in the 4.2 series." -// -// Another resource for understanding libstdc++ features is: -// http://gcc.gnu.org/onlinedocs/libstdc++/manual/status.html#manual.intro.status.standard.200x -// -// However, using the GCC version number fails when the compiler is clang since this -// only ever claims to emulate GCC-4.2, see https://svn.boost.org/trac/boost/ticket/7473 -// for a long discussion on this issue. What we can do though is use clang's __has_include -// to detect the presence of a C++11 header that was introduced with a specific GCC release. -// We still have to be careful though as many such headers were buggy and/or incomplete when -// first introduced, so we only check for headers that were fully featured from day 1, and then -// use that to infer the underlying GCC version: -// -#ifdef __clang__ - -#if __has_include(<memory_resource>) -# define BOOST_LIBSTDCXX_VERSION 90100 -#elif __has_include(<charconv>) -# define BOOST_LIBSTDCXX_VERSION 80100 -#elif __has_include(<variant>) -# define BOOST_LIBSTDCXX_VERSION 70100 -#elif __has_include(<experimental/memory_resource>) -# define BOOST_LIBSTDCXX_VERSION 60100 -#elif __has_include(<experimental/any>) -# define BOOST_LIBSTDCXX_VERSION 50100 -#elif __has_include(<shared_mutex>) -# define BOOST_LIBSTDCXX_VERSION 40900 -#elif __has_include(<ext/cmath>) -# define BOOST_LIBSTDCXX_VERSION 40800 -#elif __has_include(<scoped_allocator>) -# define BOOST_LIBSTDCXX_VERSION 40700 -#elif __has_include(<typeindex>) -# define BOOST_LIBSTDCXX_VERSION 40600 -#elif __has_include(<future>) -# define BOOST_LIBSTDCXX_VERSION 40500 -#elif __has_include(<ratio>) -# define BOOST_LIBSTDCXX_VERSION 40400 -#elif __has_include(<array>) -# define BOOST_LIBSTDCXX_VERSION 40300 -#endif - -#if (BOOST_LIBSTDCXX_VERSION < 50100) -// libstdc++ does not define this function as it's deprecated in C++11, but clang still looks for it, -// defining it here is a terrible cludge, but should get things working: -extern "C" char *gets (char *__s); -#endif -// -// clang is unable to parse some GCC headers, add those workarounds here: -// -#if BOOST_LIBSTDCXX_VERSION < 50000 -# define BOOST_NO_CXX11_HDR_REGEX -#endif -// -// GCC 4.7.x has no __cxa_thread_atexit which -// thread_local objects require for cleanup: -// -#if BOOST_LIBSTDCXX_VERSION < 40800 -# define BOOST_NO_CXX11_THREAD_LOCAL -#endif -// -// Early clang versions can handle <chrono>, not exactly sure which versions -// but certainly up to clang-3.8 and gcc-4.6: -// -#if (__clang_major__ < 5) -# if BOOST_LIBSTDCXX_VERSION < 40800 -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_CHRONO -# endif -#endif - -// -// GCC 4.8 and 9 add working versions of <atomic> and <regex> respectively. -// However, we have no test for these as the headers were present but broken -// in early GCC versions. -// -#endif - -#if defined(__SUNPRO_CC) && (__SUNPRO_CC >= 0x5130) && (__cplusplus >= 201103L) -// -// Oracle Solaris compiler uses it's own verison of libstdc++ but doesn't -// set __GNUC__ -// -#if __SUNPRO_CC >= 0x5140 -#define BOOST_LIBSTDCXX_VERSION 50100 -#else -#define BOOST_LIBSTDCXX_VERSION 40800 -#endif -#endif - -#if !defined(BOOST_LIBSTDCXX_VERSION) -# define BOOST_LIBSTDCXX_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#endif - -// std::auto_ptr isn't provided with _GLIBCXX_DEPRECATED=0 (GCC 4.5 and earlier) -// or _GLIBCXX_USE_DEPRECATED=0 (GCC 4.6 and later). -#if defined(BOOST_LIBSTDCXX11) -# if BOOST_LIBSTDCXX_VERSION < 40600 -# if !_GLIBCXX_DEPRECATED -# define BOOST_NO_AUTO_PTR -# endif -# elif !_GLIBCXX_USE_DEPRECATED -# define BOOST_NO_AUTO_PTR -# endif -#endif - -// C++0x headers in GCC 4.3.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40300) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -#endif - -// C++0x headers in GCC 4.4.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40400) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_EXCEPTION -#else -# define BOOST_HAS_TR1_COMPLEX_INVERSE_TRIG -# define BOOST_HAS_TR1_COMPLEX_OVERLOADS -#endif - -// C++0x features in GCC 4.5.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40500) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_RANDOM -#endif - -// C++0x features in GCC 4.6.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40600) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX17_ITERATOR_TRAITS -#endif - -// C++0x features in GCC 4.7.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40700) || !defined(BOOST_LIBSTDCXX11) -// Note that although <chrono> existed prior to 4.7, "steady_clock" is spelled "monotonic_clock" -// so 4.7.0 is the first truly conforming one. -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -#endif -// C++0x features in GCC 4.8.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40800) || !defined(BOOST_LIBSTDCXX11) -// Note that although <atomic> existed prior to gcc 4.8 it was largely unimplemented for many types: -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_HDR_THREAD -#endif -// C++0x features in GCC 4.9.0 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 40900) || !defined(BOOST_LIBSTDCXX11) -// Although <regex> is present and compilable against, the actual implementation is not functional -// even for the simplest patterns such as "\d" or "[0-9]". This is the case at least in gcc up to 4.8, inclusively. -# define BOOST_NO_CXX11_HDR_REGEX -#endif -#if (BOOST_LIBSTDCXX_VERSION < 40900) || (__cplusplus <= 201103) -# define BOOST_NO_CXX14_STD_EXCHANGE -#endif - -#if defined(__clang_major__) && ((__clang_major__ < 3) || ((__clang_major__ == 3) && (__clang_minor__ < 7))) -// As of clang-3.6, libstdc++ header <atomic> throws up errors with clang: -# define BOOST_NO_CXX11_HDR_ATOMIC -#endif -// -// C++0x features in GCC 5.1 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 50100) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_STD_ALIGN -#endif - -// -// C++17 features in GCC 7.1 and later -// -#if (BOOST_LIBSTDCXX_VERSION < 70100) || (__cplusplus <= 201402L) -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_HDR_OPTIONAL -# define BOOST_NO_CXX17_HDR_STRING_VIEW -# define BOOST_NO_CXX17_HDR_VARIANT -#endif - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus <= 201103 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#elif __cplusplus < 201402 || (BOOST_LIBSTDCXX_VERSION < 40900) || !defined(BOOST_LIBSTDCXX11) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// -// Headers not present on Solaris with the Oracle compiler: -#if defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x5140) -#define BOOST_NO_CXX11_HDR_FUTURE -#define BOOST_NO_CXX11_HDR_FORWARD_LIST -#define BOOST_NO_CXX11_HDR_ATOMIC -// shared_ptr is present, but is not convertible to bool -// which causes all kinds of problems especially in Boost.Thread -// but probably elsewhere as well. -#define BOOST_NO_CXX11_SMART_PTR -#endif - -#if (!defined(_GLIBCXX_HAS_GTHREADS) || !defined(_GLIBCXX_USE_C99_STDINT_TR1)) - // Headers not always available: -# ifndef BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# endif -# ifndef BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_MUTEX -# endif -# ifndef BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_THREAD -# endif -# ifndef BOOST_NO_CXX14_HDR_SHARED_MUTEX -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -# endif -#endif - -#if (!defined(_GTHREAD_USE_MUTEX_TIMEDLOCK) || (_GTHREAD_USE_MUTEX_TIMEDLOCK == 0)) && !defined(BOOST_NO_CXX11_HDR_MUTEX) -// Timed mutexes are not always available: -# define BOOST_NO_CXX11_HDR_MUTEX -#endif - -// --- end --- diff --git a/ThirdParty/boost/config/stdlib/modena.hpp b/ThirdParty/boost/config/stdlib/modena.hpp deleted file mode 100644 index 31a26c856a2cf93cc32ee7bc6bbf4acd160ce372..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/modena.hpp +++ /dev/null @@ -1,79 +0,0 @@ -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Modena C++ standard library (comes with KAI C++) - -#if !defined(MSIPL_COMPILE_H) -# include <boost/config/no_tr1/utility.hpp> -# if !defined(__MSIPL_COMPILE_H) -# error "This is not the Modena C++ library!" -# endif -#endif - -#ifndef MSIPL_NL_TYPES -#define BOOST_NO_STD_MESSAGES -#endif - -#ifndef MSIPL_WCHART -#define BOOST_NO_STD_WSTRING -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -#define BOOST_STDLIB "Modena C++ standard library" - - - - - diff --git a/ThirdParty/boost/config/stdlib/msl.hpp b/ThirdParty/boost/config/stdlib/msl.hpp deleted file mode 100644 index f2f825983be0282d2b578c35e2125bb614d58548..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/msl.hpp +++ /dev/null @@ -1,98 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Darin Adler 2001. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Metrowerks standard library: - -#ifndef __MSL_CPP__ -# include <boost/config/no_tr1/utility.hpp> -# ifndef __MSL_CPP__ -# error This is not the MSL standard library! -# endif -#endif - -#if __MSL_CPP__ >= 0x6000 // Pro 6 -# define BOOST_HAS_HASH -# define BOOST_STD_EXTENSION_NAMESPACE Metrowerks -#endif -#define BOOST_HAS_SLIST - -#if __MSL_CPP__ < 0x6209 -# define BOOST_NO_STD_MESSAGES -#endif - -// check C lib version for <stdint.h> -#include <cstddef> - -#if defined(__MSL__) && (__MSL__ >= 0x5000) -# define BOOST_HAS_STDINT_H -# if !defined(__PALMOS_TRAPS__) -# define BOOST_HAS_UNISTD_H -# endif - // boilerplate code: -# include <boost/config/detail/posix_features.hpp> -#endif - -#if defined(_MWMT) || _MSL_THREADSAFE -# define BOOST_HAS_THREADS -#endif - -#ifdef _MSL_NO_EXPLICIT_FUNC_TEMPLATE_ARG -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -#define BOOST_STDLIB "Metrowerks Standard Library version " BOOST_STRINGIZE(__MSL_CPP__) diff --git a/ThirdParty/boost/config/stdlib/roguewave.hpp b/ThirdParty/boost/config/stdlib/roguewave.hpp deleted file mode 100644 index 0c5c113ea3a71b0656bf1679ca81acd9fca11336..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/roguewave.hpp +++ /dev/null @@ -1,208 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2003. -// (C) Copyright Boris Gubenko 2007. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// Rogue Wave std lib: - -#define BOOST_RW_STDLIB 1 - -#if !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER) -# include <boost/config/no_tr1/utility.hpp> -# if !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER) -# error This is not the Rogue Wave standard library -# endif -#endif -// -// figure out a consistent version number: -// -#ifndef _RWSTD_VER -# define BOOST_RWSTD_VER 0x010000 -#elif _RWSTD_VER < 0x010000 -# define BOOST_RWSTD_VER (_RWSTD_VER << 8) -#else -# define BOOST_RWSTD_VER _RWSTD_VER -#endif - -#ifndef _RWSTD_VER -# define BOOST_STDLIB "Rogue Wave standard library version (Unknown version)" -#elif _RWSTD_VER < 0x04010200 - # define BOOST_STDLIB "Rogue Wave standard library version " BOOST_STRINGIZE(_RWSTD_VER) -#else -# ifdef _RWSTD_VER_STR -# define BOOST_STDLIB "Apache STDCXX standard library version " _RWSTD_VER_STR -# else -# define BOOST_STDLIB "Apache STDCXX standard library version " BOOST_STRINGIZE(_RWSTD_VER) -# endif -#endif - -// -// Prior to version 2.2.0 the primary template for std::numeric_limits -// does not have compile time constants, even though specializations of that -// template do: -// -#if BOOST_RWSTD_VER < 0x020200 -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -#endif - -// Sun CC 5.5 patch 113817-07 adds long long specialization, but does not change the -// library version number (http://sunsolve6.sun.com/search/document.do?assetkey=1-21-113817): -#if BOOST_RWSTD_VER <= 0x020101 && (!defined(__SUNPRO_CC) || (__SUNPRO_CC < 0x550)) -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -# endif - -// -// Borland version of numeric_limits lacks __int64 specialisation: -// -#ifdef __BORLANDC__ -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -#endif - -// -// No std::iterator if it can't figure out default template args: -// -#if defined(_RWSTD_NO_SIMPLE_DEFAULT_TEMPLATES) || defined(RWSTD_NO_SIMPLE_DEFAULT_TEMPLATES) || (BOOST_RWSTD_VER < 0x020000) -# define BOOST_NO_STD_ITERATOR -#endif - -// -// No iterator traits without partial specialization: -// -#if defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) || defined(RWSTD_NO_CLASS_PARTIAL_SPEC) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// Prior to version 2.0, std::auto_ptr was buggy, and there were no -// new-style iostreams, and no conformant std::allocator: -// -#if (BOOST_RWSTD_VER < 0x020000) -# define BOOST_NO_AUTO_PTR -# define BOOST_NO_STRINGSTREAM -# define BOOST_NO_STD_ALLOCATOR -# define BOOST_NO_STD_LOCALE -#endif - -// -// No template iterator constructors without member template support: -// -#if defined(RWSTD_NO_MEMBER_TEMPLATES) || defined(_RWSTD_NO_MEMBER_TEMPLATES) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -#endif - -// -// RW defines _RWSTD_ALLOCATOR if the allocator is conformant and in use -// (the or _HPACC_ part is a hack - the library seems to define _RWSTD_ALLOCATOR -// on HP aCC systems even though the allocator is in fact broken): -// -#if !defined(_RWSTD_ALLOCATOR) || (defined(__HP_aCC) && __HP_aCC <= 33100) -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// If we have a std::locale, we still may not have std::use_facet: -// -#if defined(_RWSTD_NO_TEMPLATE_ON_RETURN_TYPE) && !defined(BOOST_NO_STD_LOCALE) -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET -#endif - -// -// There's no std::distance prior to version 2, or without -// partial specialization support: -// -#if (BOOST_RWSTD_VER < 0x020000) || defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) - #define BOOST_NO_STD_DISTANCE -#endif - -// -// Some versions of the rogue wave library don't have assignable -// OutputIterators: -// -#if BOOST_RWSTD_VER < 0x020100 -# define BOOST_NO_STD_OUTPUT_ITERATOR_ASSIGN -#endif - -// -// Disable BOOST_HAS_LONG_LONG when the library has no support for it. -// -#if !defined(_RWSTD_LONG_LONG) && defined(BOOST_HAS_LONG_LONG) -# undef BOOST_HAS_LONG_LONG -#endif - -// -// check that on HP-UX, the proper RW library is used -// -#if defined(__HP_aCC) && !defined(_HP_NAMESPACE_STD) -# error "Boost requires Standard RW library. Please compile and link with -AA" -#endif - -// -// Define macros specific to RW V2.2 on HP-UX -// -#if defined(__HP_aCC) && (BOOST_RWSTD_VER == 0x02020100) -# ifndef __HP_TC1_MAKE_PAIR -# define __HP_TC1_MAKE_PAIR -# endif -# ifndef _HP_INSTANTIATE_STD2_VL -# define _HP_INSTANTIATE_STD2_VL -# endif -#endif - -#if _RWSTD_VER < 0x05000000 -# define BOOST_NO_CXX11_HDR_ARRAY -#endif -// type_traits header is incomplete: -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -// -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS diff --git a/ThirdParty/boost/config/stdlib/sgi.hpp b/ThirdParty/boost/config/stdlib/sgi.hpp deleted file mode 100644 index c49957cef8b02a7f7bbbe9cef7c815dd82d35dff..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/sgi.hpp +++ /dev/null @@ -1,168 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Jens Maurer 2001 - 2003. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// generic SGI STL: - -#if !defined(__STL_CONFIG_H) -# include <boost/config/no_tr1/utility.hpp> -# if !defined(__STL_CONFIG_H) -# error "This is not the SGI STL!" -# endif -#endif - -// -// No std::iterator traits without partial specialisation: -// -#if !defined(__STL_CLASS_PARTIAL_SPECIALIZATION) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// No std::stringstream with gcc < 3 -// -#if defined(__GNUC__) && (__GNUC__ < 3) && \ - ((__GNUC_MINOR__ < 95) || (__GNUC_MINOR__ == 96)) && \ - !defined(__STL_USE_NEW_IOSTREAMS) || \ - defined(__APPLE_CC__) - // Note that we only set this for GNU C++ prior to 2.95 since the - // latest patches for that release do contain a minimal <sstream> - // If you are running a 2.95 release prior to 2.95.3 then this will need - // setting, but there is no way to detect that automatically (other - // than by running the configure script). - // Also, the unofficial GNU C++ 2.96 included in RedHat 7.1 doesn't - // have <sstream>. -# define BOOST_NO_STRINGSTREAM -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include <unistd.h> -#endif - - -// -// Assume no std::locale without own iostreams (this may be an -// incorrect assumption in some cases): -// -#if !defined(__SGI_STL_OWN_IOSTREAMS) && !defined(__STL_USE_NEW_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -#endif - -// -// Original native SGI streams have non-standard std::messages facet: -// -#if defined(__sgi) && (_COMPILER_VERSION <= 650) && !defined(__SGI_STL_OWN_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -#endif - -// -// SGI's new iostreams have missing "const" in messages<>::open -// -#if defined(__sgi) && (_COMPILER_VERSION <= 740) && defined(__STL_USE_NEW_IOSTREAMS) -# define BOOST_NO_STD_MESSAGES -#endif - -// -// No template iterator constructors, or std::allocator -// without member templates: -// -#if !defined(__STL_MEMBER_TEMPLATES) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// We always have SGI style hash_set, hash_map, and slist: -// -#define BOOST_HAS_HASH -#define BOOST_HAS_SLIST - -// -// If this is GNU libstdc++2, then no <limits> and no std::wstring: -// -#if (defined(__GNUC__) && (__GNUC__ < 3)) -# include <string> -# if defined(__BASTRING__) -# define BOOST_NO_LIMITS -// Note: <boost/limits.hpp> will provide compile-time constants -# undef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_STD_WSTRING -# endif -#endif - -// -// There is no standard iterator unless we have namespace support: -// -#if !defined(__STL_USE_NAMESPACES) -# define BOOST_NO_STD_ITERATOR -#endif - -// -// Intrinsic type_traits support. -// The SGI STL has it's own __type_traits class, which -// has intrinsic compiler support with SGI's compilers. -// Whatever map SGI style type traits to boost equivalents: -// -#define BOOST_HAS_SGI_TYPE_TRAITS - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -#define BOOST_STDLIB "SGI standard library" diff --git a/ThirdParty/boost/config/stdlib/stlport.hpp b/ThirdParty/boost/config/stdlib/stlport.hpp deleted file mode 100644 index 094e27bb74459755727237f12f33834c8e78ee1f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/stlport.hpp +++ /dev/null @@ -1,258 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -// STLPort standard library config: - -#if !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -# include <cstddef> -# if !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -# error "This is not STLPort!" -# endif -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include <unistd.h> -#endif - -// -// __STL_STATIC_CONST_INIT_BUG implies BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -// for versions prior to 4.1(beta) -// -#if (defined(__STL_STATIC_CONST_INIT_BUG) || defined(_STLP_STATIC_CONST_INIT_BUG)) && (__SGI_STL_PORT <= 0x400) -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -#endif - -// -// If STLport thinks that there is no partial specialisation, then there is no -// std::iterator traits: -// -#if !(defined(_STLP_CLASS_PARTIAL_SPECIALIZATION) || defined(__STL_CLASS_PARTIAL_SPECIALIZATION)) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// No new style iostreams on GCC without STLport's iostreams enabled: -// -#if (defined(__GNUC__) && (__GNUC__ < 3)) && !(defined(__SGI_STL_OWN_IOSTREAMS) || defined(_STLP_OWN_IOSTREAMS)) -# define BOOST_NO_STRINGSTREAM -#endif - -// -// No new iostreams implies no std::locale, and no std::stringstream: -// -#if defined(__STL_NO_IOSTREAMS) || defined(__STL_NO_NEW_IOSTREAMS) || defined(_STLP_NO_IOSTREAMS) || defined(_STLP_NO_NEW_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -# define BOOST_NO_STRINGSTREAM -#endif - -// -// If the streams are not native, and we have a "using ::x" compiler bug -// then the io stream facets are not available in namespace std:: -// -#ifdef _STLPORT_VERSION -# if !(_STLPORT_VERSION >= 0x500) && !defined(_STLP_OWN_IOSTREAMS) && defined(_STLP_USE_NAMESPACES) && defined(BOOST_NO_USING_TEMPLATE) && !defined(__BORLANDC__) -# define BOOST_NO_STD_LOCALE -# endif -#else -# if !defined(__SGI_STL_OWN_IOSTREAMS) && defined(__STL_USE_NAMESPACES) && defined(BOOST_NO_USING_TEMPLATE) && !defined(__BORLANDC__) -# define BOOST_NO_STD_LOCALE -# endif -#endif - -#if defined(_STLPORT_VERSION) && (_STLPORT_VERSION >= 0x520) -# define BOOST_HAS_TR1_UNORDERED_SET -# define BOOST_HAS_TR1_UNORDERED_MAP -#endif -// -// Without member template support enabled, their are no template -// iterate constructors, and no std::allocator: -// -#if !(defined(__STL_MEMBER_TEMPLATES) || defined(_STLP_MEMBER_TEMPLATES)) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -#endif -// -// however we always have at least a partial allocator: -// -#define BOOST_HAS_PARTIAL_STD_ALLOCATOR - -#if !defined(_STLP_MEMBER_TEMPLATE_CLASSES) || defined(_STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE) -# define BOOST_NO_STD_ALLOCATOR -#endif - -#if defined(_STLP_NO_MEMBER_TEMPLATE_KEYWORD) && defined(BOOST_MSVC) && (BOOST_MSVC <= 1300) -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// If STLport thinks there is no wchar_t at all, then we have to disable -// the support for the relevant specilazations of std:: templates. -// -#if !defined(_STLP_HAS_WCHAR_T) && !defined(_STLP_WCHAR_T_IS_USHORT) -# ifndef BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTRING -# endif -# ifndef BOOST_NO_STD_WSTREAMBUF -# define BOOST_NO_STD_WSTREAMBUF -# endif -#endif - -// -// We always have SGI style hash_set, hash_map, and slist: -// -#ifndef _STLP_NO_EXTENSIONS -#define BOOST_HAS_HASH -#define BOOST_HAS_SLIST -#endif - -// -// STLport does a good job of importing names into namespace std::, -// but doesn't always get them all, define BOOST_NO_STDC_NAMESPACE, since our -// workaround does not conflict with STLports: -// -// -// Harold Howe says: -// Borland switched to STLport in BCB6. Defining BOOST_NO_STDC_NAMESPACE with -// BCB6 does cause problems. If we detect C++ Builder, then don't define -// BOOST_NO_STDC_NAMESPACE -// -#if !defined(__BORLANDC__) && !defined(__DMC__) -// -// If STLport is using it's own namespace, and the real names are in -// the global namespace, then we duplicate STLport's using declarations -// (by defining BOOST_NO_STDC_NAMESPACE), we do this because STLport doesn't -// necessarily import all the names we need into namespace std:: -// -# if (defined(__STL_IMPORT_VENDOR_CSTD) \ - || defined(__STL_USE_OWN_NAMESPACE) \ - || defined(_STLP_IMPORT_VENDOR_CSTD) \ - || defined(_STLP_USE_OWN_NAMESPACE)) \ - && (defined(__STL_VENDOR_GLOBAL_CSTD) || defined (_STLP_VENDOR_GLOBAL_CSTD)) -# define BOOST_NO_STDC_NAMESPACE -# define BOOST_NO_EXCEPTION_STD_NAMESPACE -# endif -#elif defined(__BORLANDC__) && __BORLANDC__ < 0x560 -// STLport doesn't import std::abs correctly: -#include <stdlib.h> -namespace std { using ::abs; } -// and strcmp/strcpy don't get imported either ('cos they are macros) -#include <string.h> -#ifdef strcpy -# undef strcpy -#endif -#ifdef strcmp -# undef strcmp -#endif -#ifdef _STLP_VENDOR_CSTD -namespace std{ using _STLP_VENDOR_CSTD::strcmp; using _STLP_VENDOR_CSTD::strcpy; } -#endif -#endif - -// -// std::use_facet may be non-standard, uses a class instead: -// -#if defined(__STL_NO_EXPLICIT_FUNCTION_TMPL_ARGS) || defined(_STLP_NO_EXPLICIT_FUNCTION_TMPL_ARGS) -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_STLP_USE_FACET -#endif - -// -// If STLport thinks there are no wide functions, <cwchar> etc. is not working; but -// only if BOOST_NO_STDC_NAMESPACE is not defined (if it is then we do the import -// into std:: ourselves). -// -#if defined(_STLP_NO_NATIVE_WIDE_FUNCTIONS) && !defined(BOOST_NO_STDC_NAMESPACE) -# define BOOST_NO_CWCHAR -# define BOOST_NO_CWCTYPE -#endif - -// -// If STLport for some reason was configured so that it thinks that wchar_t -// is not an intrinsic type, then we have to disable the support for it as -// well (we would be missing required specializations otherwise). -// -#if !defined( _STLP_HAS_WCHAR_T) || defined(_STLP_WCHAR_T_IS_USHORT) -# undef BOOST_NO_INTRINSIC_WCHAR_T -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -// -// Borland ships a version of STLport with C++ Builder 6 that lacks -// hashtables and the like: -// -#if defined(__BORLANDC__) && (__BORLANDC__ == 0x560) -# undef BOOST_HAS_HASH -#endif - -// -// gcc-2.95.3/STLPort does not like the using declarations we use to get ADL with std::min/max -// -#if defined(__GNUC__) && (__GNUC__ < 3) -# include <algorithm> // for std::min and std::max -# define BOOST_USING_STD_MIN() ((void)0) -# define BOOST_USING_STD_MAX() ((void)0) -namespace boost { using std::min; using std::max; } -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -#define BOOST_STDLIB "STLPort standard library version " BOOST_STRINGIZE(__SGI_STL_PORT) diff --git a/ThirdParty/boost/config/stdlib/vacpp.hpp b/ThirdParty/boost/config/stdlib/vacpp.hpp deleted file mode 100644 index b14dd65576ea312f7b08231bffb20a07cf707c74..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/vacpp.hpp +++ /dev/null @@ -1,74 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// Use, modification and distribution are subject to 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) - -// See http://www.boost.org for most recent version. - -#if __IBMCPP__ <= 501 -# define BOOST_NO_STD_ALLOCATOR -#endif - -#define BOOST_HAS_MACRO_USE_FACET -#define BOOST_NO_STD_MESSAGES - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include <unistd.h> -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_POINTER_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_HDR_ATOMIC -# define BOOST_NO_CXX11_STD_ALIGN -# define BOOST_NO_CXX11_ADDRESSOF -# define BOOST_NO_CXX11_HDR_EXCEPTION - -#if defined(__has_include) -#if !__has_include(<shared_mutex>) -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#elif __cplusplus < 201402 -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif -#else -# define BOOST_NO_CXX14_HDR_SHARED_MUTEX -#endif - -// C++14 features -# define BOOST_NO_CXX14_STD_EXCHANGE - -// C++17 features -# define BOOST_NO_CXX17_STD_APPLY -# define BOOST_NO_CXX17_STD_INVOKE -# define BOOST_NO_CXX17_ITERATOR_TRAITS - -#define BOOST_STDLIB "Visual Age default standard library" diff --git a/ThirdParty/boost/config/stdlib/xlcpp_zos.hpp b/ThirdParty/boost/config/stdlib/xlcpp_zos.hpp deleted file mode 100644 index a5e02fd8b83be8a89b1993d919629d5bcda3252c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/stdlib/xlcpp_zos.hpp +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright (c) 2017 Dynatrace -// -// 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 - -// See http://www.boost.org for most recent version. - -// Standard library setup for IBM z/OS XL C/C++ compiler. - -// Oldest library version currently supported is 2.1 (V2R1) -#if __TARGET_LIB__ < 0x42010000 -# error "Library version not supported or configured - please reconfigure" -#endif - -#if __TARGET_LIB__ > 0x42010000 -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown library version - please run the configure tests and report the results" -# endif -#endif - -#define BOOST_STDLIB "IBM z/OS XL C/C++ standard library" - -#define BOOST_HAS_MACRO_USE_FACET - -#define BOOST_NO_CXX11_HDR_TYPE_TRAITS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST - -#define BOOST_NO_CXX11_ADDRESSOF -#define BOOST_NO_CXX11_SMART_PTR -#define BOOST_NO_CXX11_ATOMIC_SMART_PTR -#define BOOST_NO_CXX11_NUMERIC_LIMITS -#define BOOST_NO_CXX11_ALLOCATOR -#define BOOST_NO_CXX11_POINTER_TRAITS -#define BOOST_NO_CXX11_HDR_FUNCTIONAL -#define BOOST_NO_CXX11_HDR_UNORDERED_SET -#define BOOST_NO_CXX11_HDR_UNORDERED_MAP -#define BOOST_NO_CXX11_HDR_TYPEINDEX -#define BOOST_NO_CXX11_HDR_TUPLE -#define BOOST_NO_CXX11_HDR_THREAD -#define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -#define BOOST_NO_CXX11_HDR_REGEX -#define BOOST_NO_CXX11_HDR_RATIO -#define BOOST_NO_CXX11_HDR_RANDOM -#define BOOST_NO_CXX11_HDR_MUTEX -#define BOOST_NO_CXX11_HDR_FUTURE -#define BOOST_NO_CXX11_HDR_FORWARD_LIST -#define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -#define BOOST_NO_CXX11_HDR_CODECVT -#define BOOST_NO_CXX11_HDR_CHRONO -#define BOOST_NO_CXX11_HDR_ATOMIC -#define BOOST_NO_CXX11_HDR_ARRAY -#define BOOST_NO_CXX11_HDR_EXCEPTION -#define BOOST_NO_CXX11_STD_ALIGN - -#define BOOST_NO_CXX14_STD_EXCHANGE -#define BOOST_NO_CXX14_HDR_SHARED_MUTEX - -#define BOOST_NO_CXX17_STD_INVOKE -#define BOOST_NO_CXX17_STD_APPLY -#define BOOST_NO_CXX17_ITERATOR_TRAITS diff --git a/ThirdParty/boost/config/user.hpp b/ThirdParty/boost/config/user.hpp deleted file mode 100644 index 8160fcae25c777ad86c5e6df90236f0376e29bff..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/config/user.hpp +++ /dev/null @@ -1,133 +0,0 @@ -// boost/config/user.hpp ---------------------------------------------------// - -// (C) Copyright John Maddock 2001. -// Use, modification and distribution are subject to 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) - -// Do not check in modified versions of this file, -// This file may be customized by the end user, but not by boost. - -// -// Use this file to define a site and compiler specific -// configuration policy: -// - -// define this to locate a compiler config file: -// #define BOOST_COMPILER_CONFIG <myheader> - -// define this to locate a stdlib config file: -// #define BOOST_STDLIB_CONFIG <myheader> - -// define this to locate a platform config file: -// #define BOOST_PLATFORM_CONFIG <myheader> - -// define this to disable compiler config, -// use if your compiler config has nothing to set: -// #define BOOST_NO_COMPILER_CONFIG - -// define this to disable stdlib config, -// use if your stdlib config has nothing to set: -// #define BOOST_NO_STDLIB_CONFIG - -// define this to disable platform config, -// use if your platform config has nothing to set: -// #define BOOST_NO_PLATFORM_CONFIG - -// define this to disable all config options, -// excluding the user config. Use if your -// setup is fully ISO compliant, and has no -// useful extensions, or for autoconf generated -// setups: -// #define BOOST_NO_CONFIG - -// define this to make the config "optimistic" -// about unknown compiler versions. Normally -// unknown compiler versions are assumed to have -// all the defects of the last known version, however -// setting this flag, causes the config to assume -// that unknown compiler versions are fully conformant -// with the standard: -// #define BOOST_STRICT_CONFIG - -// define this to cause the config to halt compilation -// with an #error if it encounters anything unknown -- -// either an unknown compiler version or an unknown -// compiler/platform/library: -// #define BOOST_ASSERT_CONFIG - - -// define if you want to disable threading support, even -// when available: -// #define BOOST_DISABLE_THREADS - -// define when you want to disable Win32 specific features -// even when available: -// #define BOOST_DISABLE_WIN32 - -// BOOST_DISABLE_ABI_HEADERS: Stops boost headers from including any -// prefix/suffix headers that normally control things like struct -// packing and alignment. -// #define BOOST_DISABLE_ABI_HEADERS - -// BOOST_ABI_PREFIX: A prefix header to include in place of whatever -// boost.config would normally select, any replacement should set up -// struct packing and alignment options as required. -// #define BOOST_ABI_PREFIX my-header-name - -// BOOST_ABI_SUFFIX: A suffix header to include in place of whatever -// boost.config would normally select, any replacement should undo -// the effects of the prefix header. -// #define BOOST_ABI_SUFFIX my-header-name - -// BOOST_ALL_DYN_LINK: Forces all libraries that have separate source, -// to be linked as dll's rather than static libraries on Microsoft Windows -// (this macro is used to turn on __declspec(dllimport) modifiers, so that -// the compiler knows which symbols to look for in a dll rather than in a -// static library). Note that there may be some libraries that can only -// be linked in one way (statically or dynamically), in these cases this -// macro has no effect. -// #define BOOST_ALL_DYN_LINK - -// BOOST_WHATEVER_DYN_LINK: Forces library "whatever" to be linked as a dll -// rather than a static library on Microsoft Windows: replace the WHATEVER -// part of the macro name with the name of the library that you want to -// dynamically link to, for example use BOOST_DATE_TIME_DYN_LINK or -// BOOST_REGEX_DYN_LINK etc (this macro is used to turn on __declspec(dllimport) -// modifiers, so that the compiler knows which symbols to look for in a dll -// rather than in a static library). -// Note that there may be some libraries that can only -// be linked in one way (statically or dynamically), -// in these cases this macro is unsupported. -// #define BOOST_WHATEVER_DYN_LINK - -// BOOST_ALL_NO_LIB: Tells the config system not to automatically select -// which libraries to link against. -// Normally if a compiler supports #pragma lib, then the correct library -// build variant will be automatically selected and linked against, -// simply by the act of including one of that library's headers. -// This macro turns that feature off. -// #define BOOST_ALL_NO_LIB - -// BOOST_WHATEVER_NO_LIB: Tells the config system not to automatically -// select which library to link against for library "whatever", -// replace WHATEVER in the macro name with the name of the library; -// for example BOOST_DATE_TIME_NO_LIB or BOOST_REGEX_NO_LIB. -// Normally if a compiler supports #pragma lib, then the correct library -// build variant will be automatically selected and linked against, simply -// by the act of including one of that library's headers. This macro turns -// that feature off. -// #define BOOST_WHATEVER_NO_LIB - -// BOOST_LIB_BUILDID: Set to the same value as the value passed to Boost.Build's -// --buildid command line option. For example if you built using: -// -// bjam address-model=64 --buildid=amd64 -// -// then compile your code with: -// -// -DBOOST_LIB_BUILDID = amd64 -// -// to ensure the correct libraries are selected at link time. -// #define BOOST_LIB_BUILDID amd64 - diff --git a/ThirdParty/boost/container/allocator_traits.hpp b/ThirdParty/boost/container/allocator_traits.hpp deleted file mode 100644 index 72d90d1b435bac1338c8b9a149be1212ff828bd5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/allocator_traits.hpp +++ /dev/null @@ -1,493 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Pablo Halpern 2009. 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) -// -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2013. 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#ifndef BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP -#define BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/container/detail/config_begin.hpp> -#include <boost/container/detail/workaround.hpp> - -// container -#include <boost/container/container_fwd.hpp> -#include <boost/container/detail/mpl.hpp> -#include <boost/container/detail/type_traits.hpp> //is_empty -#include <boost/container/detail/placement_new.hpp> -#ifndef BOOST_CONTAINER_DETAIL_STD_FWD_HPP -#include <boost/container/detail/std_fwd.hpp> -#endif -// intrusive -#include <boost/intrusive/pointer_traits.hpp> -#include <boost/intrusive/detail/mpl.hpp> -// move -#include <boost/move/utility_core.hpp> -// move/detail -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -#include <boost/move/detail/fwd_macros.hpp> -#endif -// other boost -#include <boost/static_assert.hpp> - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME allocate -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEG namespace boost { namespace container { namespace dtl { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MIN 2 -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MAX 2 -#include <boost/intrusive/detail/has_member_function_callable_with.hpp> - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME destroy -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEG namespace boost { namespace container { namespace dtl { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MIN 1 -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MAX 1 -#include <boost/intrusive/detail/has_member_function_callable_with.hpp> - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME construct -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEG namespace boost { namespace container { namespace dtl { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MIN 1 -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_MAX 9 -#include <boost/intrusive/detail/has_member_function_callable_with.hpp> - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -namespace boost { -namespace container { - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -template<class T, class VoidAllocator, class Options> -class small_vector_allocator; - -namespace allocator_traits_detail { - -BOOST_INTRUSIVE_HAS_STATIC_MEMBER_FUNC_SIGNATURE(has_max_size, max_size) -BOOST_INTRUSIVE_HAS_STATIC_MEMBER_FUNC_SIGNATURE(has_select_on_container_copy_construction, select_on_container_copy_construction) - -} //namespace allocator_traits_detail { - -namespace dtl { - -//workaround needed for C++03 compilers with no construct() -//supporting rvalue references -template<class Allocator> -struct is_std_allocator -{ static const bool value = false; }; - -template<class T> -struct is_std_allocator< std::allocator<T> > -{ static const bool value = true; }; - -template<class T, class Options> -struct is_std_allocator< small_vector_allocator<T, std::allocator<T>, Options > > -{ static const bool value = true; }; - -template<class Allocator> -struct is_not_std_allocator -{ static const bool value = !is_std_allocator<Allocator>::value; }; - -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(pointer) -BOOST_INTRUSIVE_INSTANTIATE_EVAL_DEFAULT_TYPE_TMPLT(const_pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(reference) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(const_reference) -BOOST_INTRUSIVE_INSTANTIATE_EVAL_DEFAULT_TYPE_TMPLT(void_pointer) -BOOST_INTRUSIVE_INSTANTIATE_EVAL_DEFAULT_TYPE_TMPLT(const_void_pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(size_type) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_copy_assignment) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_move_assignment) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_swap) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(is_always_equal) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(difference_type) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(is_partially_propagable) - -} //namespace dtl { - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -//! The class template allocator_traits supplies a uniform interface to all allocator types. -//! This class is a C++03-compatible implementation of std::allocator_traits -template <typename Allocator> -struct allocator_traits -{ - //allocator_type - typedef Allocator allocator_type; - //value_type - typedef typename allocator_type::value_type value_type; - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! Allocator::pointer if such a type exists; otherwise, value_type* - //! - typedef unspecified pointer; - //! Allocator::const_pointer if such a type exists ; otherwise, pointer_traits<pointer>::rebind<const - //! - typedef see_documentation const_pointer; - //! Non-standard extension - //! Allocator::reference if such a type exists; otherwise, value_type& - typedef see_documentation reference; - //! Non-standard extension - //! Allocator::const_reference if such a type exists ; otherwise, const value_type& - typedef see_documentation const_reference; - //! Allocator::void_pointer if such a type exists ; otherwise, pointer_traits<pointer>::rebind<void>. - //! - typedef see_documentation void_pointer; - //! Allocator::const_void_pointer if such a type exists ; otherwise, pointer_traits<pointer>::rebind<const - //! - typedef see_documentation const_void_pointer; - //! Allocator::difference_type if such a type exists ; otherwise, pointer_traits<pointer>::difference_type. - //! - typedef see_documentation difference_type; - //! Allocator::size_type if such a type exists ; otherwise, make_unsigned<difference_type>::type - //! - typedef see_documentation size_type; - //! Allocator::propagate_on_container_copy_assignment if such a type exists, otherwise a type - //! with an internal constant static boolean member <code>value</code> == false. - typedef see_documentation propagate_on_container_copy_assignment; - //! Allocator::propagate_on_container_move_assignment if such a type exists, otherwise a type - //! with an internal constant static boolean member <code>value</code> == false. - typedef see_documentation propagate_on_container_move_assignment; - //! Allocator::propagate_on_container_swap if such a type exists, otherwise a type - //! with an internal constant static boolean member <code>value</code> == false. - typedef see_documentation propagate_on_container_swap; - //! Allocator::is_always_equal if such a type exists, otherwise a type - //! with an internal constant static boolean member <code>value</code> == is_empty<Allocator>::value - typedef see_documentation is_always_equal; - //! Allocator::is_partially_propagable if such a type exists, otherwise a type - //! with an internal constant static boolean member <code>value</code> == false - //! <b>Note</b>: Non-standard extension used to implement `small_vector_allocator`. - typedef see_documentation is_partially_propagable; - //! Defines an allocator: Allocator::rebind<T>::other if such a type exists; otherwise, Allocator<T, Args> - //! if Allocator is a class template instantiation of the form Allocator<U, Args>, where Args is zero or - //! more type arguments ; otherwise, the instantiation of rebind_alloc is ill-formed. - //! - //! In C++03 compilers <code>rebind_alloc</code> is a struct derived from an allocator - //! deduced by previously detailed rules. - template <class T> using rebind_alloc = see_documentation; - - //! In C++03 compilers <code>rebind_traits</code> is a struct derived from - //! <code>allocator_traits<OtherAlloc></code>, where <code>OtherAlloc</code> is - //! the allocator deduced by rules explained in <code>rebind_alloc</code>. - template <class T> using rebind_traits = allocator_traits<rebind_alloc<T> >; - - //! Non-standard extension: Portable allocator rebind for C++03 and C++11 compilers. - //! <code>type</code> is an allocator related to Allocator deduced deduced by rules explained in <code>rebind_alloc</code>. - template <class T> - struct portable_rebind_alloc - { typedef see_documentation type; }; - #else - //pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - pointer, value_type*) - pointer; - //const_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::dtl::, Allocator, - const_pointer, typename boost::intrusive::pointer_traits<pointer>::template - rebind_pointer<const value_type>) - const_pointer; - //reference - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - reference, typename dtl::unvoid_ref<value_type>::type) - reference; - //const_reference - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - const_reference, typename dtl::unvoid_ref<const value_type>::type) - const_reference; - //void_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::dtl::, Allocator, - void_pointer, typename boost::intrusive::pointer_traits<pointer>::template - rebind_pointer<void>) - void_pointer; - //const_void_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::dtl::, Allocator, - const_void_pointer, typename boost::intrusive::pointer_traits<pointer>::template - rebind_pointer<const void>) - const_void_pointer; - //difference_type - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - difference_type, std::ptrdiff_t) - difference_type; - //size_type - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - size_type, std::size_t) - size_type; - //propagate_on_container_copy_assignment - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - propagate_on_container_copy_assignment, dtl::false_type) - propagate_on_container_copy_assignment; - //propagate_on_container_move_assignment - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - propagate_on_container_move_assignment, dtl::false_type) - propagate_on_container_move_assignment; - //propagate_on_container_swap - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - propagate_on_container_swap, dtl::false_type) - propagate_on_container_swap; - //is_always_equal - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - is_always_equal, dtl::is_empty<Allocator>) - is_always_equal; - //is_partially_propagable - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::dtl::, Allocator, - is_partially_propagable, dtl::false_type) - is_partially_propagable; - - //rebind_alloc & rebind_traits - #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - //C++11 - template <typename T> using rebind_alloc = typename boost::intrusive::pointer_rebind<Allocator, T>::type; - template <typename T> using rebind_traits = allocator_traits< rebind_alloc<T> >; - #else // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - //Some workaround for C++03 or C++11 compilers with no template aliases - template <typename T> - struct rebind_alloc : boost::intrusive::pointer_rebind<Allocator,T>::type - { - typedef typename boost::intrusive::pointer_rebind<Allocator,T>::type Base; - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template <typename... Args> - rebind_alloc(BOOST_FWD_REF(Args)... args) : Base(boost::forward<Args>(args)...) {} - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - #define BOOST_CONTAINER_ALLOCATOR_TRAITS_REBIND_ALLOC(N) \ - BOOST_MOVE_TMPL_LT##N BOOST_MOVE_CLASS##N BOOST_MOVE_GT##N\ - explicit rebind_alloc(BOOST_MOVE_UREF##N) : Base(BOOST_MOVE_FWD##N){}\ - // - BOOST_MOVE_ITERATE_0TO9(BOOST_CONTAINER_ALLOCATOR_TRAITS_REBIND_ALLOC) - #undef BOOST_CONTAINER_ALLOCATOR_TRAITS_REBIND_ALLOC - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - }; - - template <typename T> - struct rebind_traits - : allocator_traits<typename boost::intrusive::pointer_rebind<Allocator, T>::type> - {}; - #endif // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - - //portable_rebind_alloc - template <class T> - struct portable_rebind_alloc - { typedef typename boost::intrusive::pointer_rebind<Allocator, T>::type type; }; - #endif //BOOST_CONTAINER_DOXYGEN_INVOKED - - //! <b>Returns</b>: <code>a.allocate(n)</code> - //! - BOOST_CONTAINER_FORCEINLINE static pointer allocate(Allocator &a, size_type n) - { return a.allocate(n); } - - //! <b>Returns</b>: <code>a.deallocate(p, n)</code> - //! - //! <b>Throws</b>: Nothing - BOOST_CONTAINER_FORCEINLINE static void deallocate(Allocator &a, pointer p, size_type n) - { a.deallocate(p, n); } - - //! <b>Effects</b>: calls <code>a.allocate(n, p)</code> if that call is well-formed; - //! otherwise, invokes <code>a.allocate(n)</code> - BOOST_CONTAINER_FORCEINLINE static pointer allocate(Allocator &a, size_type n, const_void_pointer p) - { - const bool value = boost::container::dtl:: - has_member_function_callable_with_allocate - <Allocator, const size_type, const const_void_pointer>::value; - dtl::bool_<value> flag; - return allocator_traits::priv_allocate(flag, a, n, p); - } - - //! <b>Effects</b>: calls <code>a.destroy(p)</code> if that call is well-formed; - //! otherwise, invokes <code>p->~T()</code>. - template<class T> - BOOST_CONTAINER_FORCEINLINE static void destroy(Allocator &a, T*p) BOOST_NOEXCEPT_OR_NOTHROW - { - typedef T* destroy_pointer; - const bool value = boost::container::dtl:: - has_member_function_callable_with_destroy - <Allocator, const destroy_pointer>::value; - dtl::bool_<value> flag; - allocator_traits::priv_destroy(flag, a, p); - } - - //! <b>Returns</b>: <code>a.max_size()</code> if that expression is well-formed; otherwise, - //! <code>numeric_limits<size_type>::max()</code>. - BOOST_CONTAINER_FORCEINLINE static size_type max_size(const Allocator &a) BOOST_NOEXCEPT_OR_NOTHROW - { - const bool value = allocator_traits_detail::has_max_size<Allocator, size_type (Allocator::*)() const>::value; - dtl::bool_<value> flag; - return allocator_traits::priv_max_size(flag, a); - } - - //! <b>Returns</b>: <code>a.select_on_container_copy_construction()</code> if that expression is well-formed; - //! otherwise, a. - BOOST_CONTAINER_FORCEINLINE static BOOST_CONTAINER_DOC1ST(Allocator, - typename dtl::if_c - < allocator_traits_detail::has_select_on_container_copy_construction<Allocator BOOST_MOVE_I Allocator (Allocator::*)() const>::value - BOOST_MOVE_I Allocator BOOST_MOVE_I const Allocator & >::type) - select_on_container_copy_construction(const Allocator &a) - { - const bool value = allocator_traits_detail::has_select_on_container_copy_construction - <Allocator, Allocator (Allocator::*)() const>::value; - dtl::bool_<value> flag; - return allocator_traits::priv_select_on_container_copy_construction(flag, a); - } - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! <b>Effects</b>: calls <code>a.construct(p, std::forward<Args>(args)...)</code> if that call is well-formed; - //! otherwise, invokes <code>`placement new` (static_cast<void*>(p)) T(std::forward<Args>(args)...)</code> - template <class T, class ...Args> - BOOST_CONTAINER_FORCEINLINE static void construct(Allocator & a, T* p, BOOST_FWD_REF(Args)... args) - { - static const bool value = ::boost::move_detail::and_ - < dtl::is_not_std_allocator<Allocator> - , boost::container::dtl::has_member_function_callable_with_construct - < Allocator, T*, Args... > - >::value; - dtl::bool_<value> flag; - allocator_traits::priv_construct(flag, a, p, ::boost::forward<Args>(args)...); - } - #endif - - //! <b>Returns</b>: <code>a.storage_is_unpropagable(p)</code> if is_partially_propagable::value is true; otherwise, - //! <code>false</code>. - BOOST_CONTAINER_FORCEINLINE static bool storage_is_unpropagable(const Allocator &a, pointer p) BOOST_NOEXCEPT_OR_NOTHROW - { - dtl::bool_<is_partially_propagable::value> flag; - return allocator_traits::priv_storage_is_unpropagable(flag, a, p); - } - - //! <b>Returns</b>: <code>true</code> if <code>is_always_equal::value == true</code>, otherwise, - //! <code>a == b</code>. - BOOST_CONTAINER_FORCEINLINE static bool equal(const Allocator &a, const Allocator &b) BOOST_NOEXCEPT_OR_NOTHROW - { - dtl::bool_<is_always_equal::value> flag; - return allocator_traits::priv_equal(flag, a, b); - } - - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - private: - BOOST_CONTAINER_FORCEINLINE static pointer priv_allocate(dtl::true_type, Allocator &a, size_type n, const_void_pointer p) - { return a.allocate(n, p); } - - BOOST_CONTAINER_FORCEINLINE static pointer priv_allocate(dtl::false_type, Allocator &a, size_type n, const_void_pointer) - { return a.allocate(n); } - - template<class T> - BOOST_CONTAINER_FORCEINLINE static void priv_destroy(dtl::true_type, Allocator &a, T* p) BOOST_NOEXCEPT_OR_NOTHROW - { a.destroy(p); } - - template<class T> - BOOST_CONTAINER_FORCEINLINE static void priv_destroy(dtl::false_type, Allocator &, T* p) BOOST_NOEXCEPT_OR_NOTHROW - { p->~T(); (void)p; } - - BOOST_CONTAINER_FORCEINLINE static size_type priv_max_size(dtl::true_type, const Allocator &a) BOOST_NOEXCEPT_OR_NOTHROW - { return a.max_size(); } - - BOOST_CONTAINER_FORCEINLINE static size_type priv_max_size(dtl::false_type, const Allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { return size_type(-1)/sizeof(value_type); } - - BOOST_CONTAINER_FORCEINLINE static Allocator priv_select_on_container_copy_construction(dtl::true_type, const Allocator &a) - { return a.select_on_container_copy_construction(); } - - BOOST_CONTAINER_FORCEINLINE static const Allocator &priv_select_on_container_copy_construction(dtl::false_type, const Allocator &a) BOOST_NOEXCEPT_OR_NOTHROW - { return a; } - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template<class T, class ...Args> - BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::true_type, Allocator &a, T *p, BOOST_FWD_REF(Args) ...args) - { a.construct( p, ::boost::forward<Args>(args)...); } - - template<class T, class ...Args> - BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::false_type, Allocator &, T *p, BOOST_FWD_REF(Args) ...args) - { ::new((void*)p, boost_container_new_t()) T(::boost::forward<Args>(args)...); } - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - public: - - #define BOOST_CONTAINER_ALLOCATOR_TRAITS_CONSTRUCT_IMPL(N) \ - template<class T BOOST_MOVE_I##N BOOST_MOVE_CLASS##N >\ - BOOST_CONTAINER_FORCEINLINE static void construct(Allocator &a, T *p BOOST_MOVE_I##N BOOST_MOVE_UREF##N)\ - {\ - static const bool value = ::boost::move_detail::and_ \ - < dtl::is_not_std_allocator<Allocator> \ - , boost::container::dtl::has_member_function_callable_with_construct \ - < Allocator, T* BOOST_MOVE_I##N BOOST_MOVE_FWD_T##N > \ - >::value; \ - dtl::bool_<value> flag;\ - (priv_construct)(flag, a, p BOOST_MOVE_I##N BOOST_MOVE_FWD##N);\ - }\ - // - BOOST_MOVE_ITERATE_0TO8(BOOST_CONTAINER_ALLOCATOR_TRAITS_CONSTRUCT_IMPL) - #undef BOOST_CONTAINER_ALLOCATOR_TRAITS_CONSTRUCT_IMPL - - private: - ///////////////////////////////// - // priv_construct - ///////////////////////////////// - #define BOOST_CONTAINER_ALLOCATOR_TRAITS_PRIV_CONSTRUCT_IMPL(N) \ - template<class T BOOST_MOVE_I##N BOOST_MOVE_CLASS##N >\ - BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::true_type, Allocator &a, T *p BOOST_MOVE_I##N BOOST_MOVE_UREF##N)\ - { a.construct( p BOOST_MOVE_I##N BOOST_MOVE_FWD##N ); }\ - \ - template<class T BOOST_MOVE_I##N BOOST_MOVE_CLASS##N >\ - BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::false_type, Allocator &, T *p BOOST_MOVE_I##N BOOST_MOVE_UREF##N)\ - { ::new((void*)p, boost_container_new_t()) T(BOOST_MOVE_FWD##N); }\ - // - BOOST_MOVE_ITERATE_0TO8(BOOST_CONTAINER_ALLOCATOR_TRAITS_PRIV_CONSTRUCT_IMPL) - #undef BOOST_CONTAINER_ALLOCATOR_TRAITS_PRIV_CONSTRUCT_IMPL - - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template<class T> - BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::false_type, Allocator &, T *p, const ::boost::container::default_init_t&) - { ::new((void*)p, boost_container_new_t()) T; } - - BOOST_CONTAINER_FORCEINLINE static bool priv_storage_is_unpropagable(dtl::true_type, const Allocator &a, pointer p) - { return a.storage_is_unpropagable(p); } - - BOOST_CONTAINER_FORCEINLINE static bool priv_storage_is_unpropagable(dtl::false_type, const Allocator &, pointer) - { return false; } - - BOOST_CONTAINER_FORCEINLINE static bool priv_equal(dtl::true_type, const Allocator &, const Allocator &) - { return true; } - - BOOST_CONTAINER_FORCEINLINE static bool priv_equal(dtl::false_type, const Allocator &a, const Allocator &b) - { return a == b; } - - #endif //#if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) -}; - -#if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - -template<class T, class AllocatorOrVoid> -struct real_allocator -{ - typedef AllocatorOrVoid type; -}; - -template<class T> -struct real_allocator<T, void> -{ - typedef new_allocator<T> type; -}; - -#endif //#if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - -} //namespace container { -} //namespace boost { - -#include <boost/container/detail/config_end.hpp> - -#endif // ! defined(BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP) diff --git a/ThirdParty/boost/container/container_fwd.hpp b/ThirdParty/boost/container/container_fwd.hpp deleted file mode 100644 index 2cfb20a540eae634758bfab1bd7f4a1fec2cf797..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/container_fwd.hpp +++ /dev/null @@ -1,301 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2014. 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_FWD_HPP -#define BOOST_CONTAINER_CONTAINER_FWD_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -//! \file -//! This header file forward declares the following containers: -//! - boost::container::vector -//! - boost::container::stable_vector -//! - boost::container::static_vector -//! - boost::container::small_vector_base -//! - boost::container::small_vector -//! - boost::container::slist -//! - boost::container::list -//! - boost::container::set -//! - boost::container::multiset -//! - boost::container::map -//! - boost::container::multimap -//! - boost::container::flat_set -//! - boost::container::flat_multiset -//! - boost::container::flat_map -//! - boost::container::flat_multimap -//! - boost::container::basic_string -//! - boost::container::string -//! - boost::container::wstring -//! -//! Forward declares the following allocators: -//! - boost::container::allocator -//! - boost::container::node_allocator -//! - boost::container::adaptive_pool -//! -//! Forward declares the following polymorphic resource classes: -//! - boost::container::pmr::memory_resource -//! - boost::container::pmr::polymorphic_allocator -//! - boost::container::pmr::monotonic_buffer_resource -//! - boost::container::pmr::pool_options -//! - boost::container::pmr::unsynchronized_pool_resource -//! - boost::container::pmr::synchronized_pool_resource -//! -//! And finally it defines the following types - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -//Std forward declarations -#ifndef BOOST_CONTAINER_DETAIL_STD_FWD_HPP - #include <boost/container/detail/std_fwd.hpp> -#endif - -namespace boost{ -namespace intrusive{ -namespace detail{ - //Create namespace to avoid compilation errors -}}} - -namespace boost{ namespace container{ namespace dtl{ - namespace bi = boost::intrusive; - namespace bid = boost::intrusive::detail; -}}} - -namespace boost{ namespace container{ namespace pmr{ - namespace bi = boost::intrusive; - namespace bid = boost::intrusive::detail; -}}} - -#include <cstddef> - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -////////////////////////////////////////////////////////////////////////////// -// Containers -////////////////////////////////////////////////////////////////////////////// - -namespace boost { -namespace container { - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -template<class T1, class T2> -struct pair; - -template<class T> -class new_allocator; - -template <class T - ,class Allocator = void - ,class Options = void> -class vector; - -template <class T - ,class Allocator = void > -class stable_vector; - -template < class T - , std::size_t Capacity - , class Options = void> -class static_vector; - -template < class T - , class Allocator = void - , class Options = void > -class small_vector_base; - -template < class T - , std::size_t N - , class Allocator = void - , class Options = void > -class small_vector; - -template <class T - ,class Allocator = void - ,class Options = void> -class deque; - -template <class T - ,class Allocator = void > -class list; - -template <class T - ,class Allocator = void > -class slist; - -template <class Key - ,class Compare = std::less<Key> - ,class Allocator = void - ,class Options = void> -class set; - -template <class Key - ,class Compare = std::less<Key> - ,class Allocator = void - ,class Options = void > -class multiset; - -template <class Key - ,class T - ,class Compare = std::less<Key> - ,class Allocator = void - ,class Options = void > -class map; - -template <class Key - ,class T - ,class Compare = std::less<Key> - ,class Allocator = void - ,class Options = void > -class multimap; - -template <class Key - ,class Compare = std::less<Key> - ,class Allocator = void > -class flat_set; - -template <class Key - ,class Compare = std::less<Key> - ,class Allocator = void > -class flat_multiset; - -template <class Key - ,class T - ,class Compare = std::less<Key> - ,class Allocator = void > -class flat_map; - -template <class Key - ,class T - ,class Compare = std::less<Key> - ,class Allocator = void > -class flat_multimap; - -template <class CharT - ,class Traits = std::char_traits<CharT> - ,class Allocator = void > -class basic_string; - -typedef basic_string <char> string; -typedef basic_string<wchar_t> wstring; - -static const std::size_t ADP_nodes_per_block = 256u; -static const std::size_t ADP_max_free_blocks = 2u; -static const std::size_t ADP_overhead_percent = 1u; -static const std::size_t ADP_only_alignment = 0u; - -template < class T - , std::size_t NodesPerBlock = ADP_nodes_per_block - , std::size_t MaxFreeBlocks = ADP_max_free_blocks - , std::size_t OverheadPercent = ADP_overhead_percent - , unsigned Version = 2 - > -class adaptive_pool; - -template < class T - , unsigned Version = 2 - , unsigned int AllocationDisableMask = 0> -class allocator; - -static const std::size_t NodeAlloc_nodes_per_block = 256u; - -template - < class T - , std::size_t NodesPerBlock = NodeAlloc_nodes_per_block - , std::size_t Version = 2> -class node_allocator; - -namespace pmr { - -class memory_resource; - -template<class T> -class polymorphic_allocator; - -class monotonic_buffer_resource; - -struct pool_options; - -template <class Allocator> -class resource_adaptor_imp; - -class unsynchronized_pool_resource; - -class synchronized_pool_resource; - -} //namespace pmr { - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -//! Type used to tag that the input range is -//! guaranteed to be ordered -struct ordered_range_t -{}; - -//! Value used to tag that the input range is -//! guaranteed to be ordered -static const ordered_range_t ordered_range = ordered_range_t(); - -//! Type used to tag that the input range is -//! guaranteed to be ordered and unique -struct ordered_unique_range_t - : public ordered_range_t -{}; - -//! Value used to tag that the input range is -//! guaranteed to be ordered and unique -static const ordered_unique_range_t ordered_unique_range = ordered_unique_range_t(); - -//! Type used to tag that the inserted values -//! should be default initialized -struct default_init_t -{}; - -//! Value used to tag that the inserted values -//! should be default initialized -static const default_init_t default_init = default_init_t(); -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -//! Type used to tag that the inserted values -//! should be value initialized -struct value_init_t -{}; - -//! Value used to tag that the inserted values -//! should be value initialized -static const value_init_t value_init = value_init_t(); - -namespace container_detail_really_deep_namespace { - -//Otherwise, gcc issues a warning of previously defined -//anonymous_instance and unique_instance -struct dummy -{ - dummy() - { - (void)ordered_range; - (void)ordered_unique_range; - (void)default_init; - } -}; - -} //detail_really_deep_namespace { - - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -}} //namespace boost { namespace container { - -#endif //#ifndef BOOST_CONTAINER_CONTAINER_FWD_HPP diff --git a/ThirdParty/boost/container/detail/mpl.hpp b/ThirdParty/boost/container/detail/mpl.hpp deleted file mode 100644 index ffae180c859a001637384d6af15543c0e0b22987..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/detail/mpl.hpp +++ /dev/null @@ -1,144 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2013. -// -// 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP -#define BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/container/detail/config_begin.hpp> -#include <boost/container/detail/workaround.hpp> -#include <boost/move/detail/type_traits.hpp> -#include <boost/intrusive/detail/mpl.hpp> - -#include <cstddef> - -namespace boost { -namespace container { -namespace dtl { - -using boost::move_detail::integral_constant; -using boost::move_detail::true_type; -using boost::move_detail::false_type; -using boost::move_detail::enable_if_c; -using boost::move_detail::enable_if; -using boost::move_detail::enable_if_convertible; -using boost::move_detail::disable_if_c; -using boost::move_detail::disable_if; -using boost::move_detail::disable_if_convertible; -using boost::move_detail::is_convertible; -using boost::move_detail::if_c; -using boost::move_detail::if_; -using boost::move_detail::identity; -using boost::move_detail::bool_; -using boost::move_detail::true_; -using boost::move_detail::false_; -using boost::move_detail::yes_type; -using boost::move_detail::no_type; -using boost::move_detail::bool_; -using boost::move_detail::true_; -using boost::move_detail::false_; -using boost::move_detail::unvoid_ref; -using boost::move_detail::and_; -using boost::move_detail::or_; -using boost::move_detail::not_; -using boost::move_detail::enable_if_and; -using boost::move_detail::disable_if_and; -using boost::move_detail::enable_if_or; -using boost::move_detail::disable_if_or; -using boost::move_detail::remove_const; - -template <class FirstType> -struct select1st -{ - typedef FirstType type; - - template<class T> - BOOST_CONTAINER_FORCEINLINE const type& operator()(const T& x) const - { return x.first; } - - template<class T> - BOOST_CONTAINER_FORCEINLINE type& operator()(T& x) - { return const_cast<type&>(x.first); } -}; - - -template<typename T> -struct void_t { typedef void type; }; - -template <class T, class=void> -struct is_transparent_base -{ - static const bool value = false; -}; - -template <class T> -struct is_transparent_base<T, typename void_t<typename T::is_transparent>::type> -{ - static const bool value = true; -}; - -template <class T> -struct is_transparent - : is_transparent_base<T> -{}; - -template <typename C, class /*Dummy*/, typename R> -struct enable_if_transparent - : boost::move_detail::enable_if_c<dtl::is_transparent<C>::value, R> -{}; - -#ifndef BOOST_CONTAINER_NO_CXX17_CTAD - -// void_t (void_t for C++11) -template<typename...> using variadic_void_t = void; - -// Trait to detect Allocator-like types. -template<typename Allocator, typename = void> -struct is_allocator -{ - static const bool value = false; -}; - -template <typename T> -T&& ctad_declval(); - -template<typename Allocator> -struct is_allocator < Allocator, - variadic_void_t< typename Allocator::value_type - , decltype(ctad_declval<Allocator&>().allocate(size_t{})) >> -{ - static const bool value = true; -}; - -template<class T> -using require_allocator_t = typename enable_if_c<is_allocator<T>::value, T>::type; - -template<class T> -using require_nonallocator_t = typename enable_if_c<!is_allocator<T>::value, T>::type; - -#endif - -} //namespace dtl { -} //namespace container { -} //namespace boost { - -#include <boost/container/detail/config_end.hpp> - -#endif //#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP - diff --git a/ThirdParty/boost/container/detail/version_type.hpp b/ThirdParty/boost/container/detail/version_type.hpp deleted file mode 100644 index 389606a56706aff7b7de633502cd226ee1e8b7c3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/detail/version_type.hpp +++ /dev/null @@ -1,101 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2013. 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// This code comes from N1953 document by Howard E. Hinnant -// -////////////////////////////////////////////////////////////////////////////// - - -#ifndef BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP -#define BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/container/detail/config_begin.hpp> -#include <boost/container/detail/workaround.hpp> - -#include <boost/container/detail/mpl.hpp> -#include <boost/container/detail/type_traits.hpp> - -namespace boost{ -namespace container { -namespace dtl { - -template <class T, unsigned V> -struct version_type - : public dtl::integral_constant<unsigned, V> -{ - typedef T type; -}; - -namespace impl{ - -template <class T> -struct extract_version -{ - typedef typename T::version type; -}; - -template <class T> -struct has_version -{ - private: - struct two {char _[2];}; - template <class U> static two test(...); - template <class U> static char test(const typename U::version*); - public: - static const bool value = sizeof(test<T>(0)) == 1; - void dummy(){} -}; - -template <class T, bool = has_version<T>::value> -struct version -{ - static const unsigned value = 1; -}; - -template <class T> -struct version<T, true> -{ - static const unsigned value = extract_version<T>::type::value; -}; - -} //namespace impl - -template <class T> -struct version - : public dtl::integral_constant<unsigned, impl::version<T>::value> -{}; - -template<class T, unsigned N> -struct is_version -{ - static const bool value = - is_same< typename version<T>::type, integral_constant<unsigned, N> >::value; -}; - -} //namespace dtl { - -typedef dtl::integral_constant<unsigned, 0> version_0; -typedef dtl::integral_constant<unsigned, 1> version_1; -typedef dtl::integral_constant<unsigned, 2> version_2; - -} //namespace container { -} //namespace boost{ - -#include <boost/container/detail/config_end.hpp> - -#endif //#define BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP diff --git a/ThirdParty/boost/container/new_allocator.hpp b/ThirdParty/boost/container/new_allocator.hpp deleted file mode 100644 index 4801f708262dc4b0ca347a7df0e28b58f2cd549d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/new_allocator.hpp +++ /dev/null @@ -1,194 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2014-2015. 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_NEW_ALLOCATOR_HPP -#define BOOST_CONTAINER_NEW_ALLOCATOR_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/container/detail/config_begin.hpp> -#include <boost/container/detail/workaround.hpp> -#include <boost/container/throw_exception.hpp> -#include <cstddef> - -//!\file - -namespace boost { -namespace container { - -/// @cond - -template<bool Value> -struct new_allocator_bool -{ static const bool value = Value; }; - -template<class T> -class new_allocator; - -/// @endcond - -//! Specialization of new_allocator for void types -template<> -class new_allocator<void> -{ - public: - typedef void value_type; - typedef void * pointer; - typedef const void* const_pointer; - //!A integral constant of type bool with value true - typedef BOOST_CONTAINER_IMPDEF(new_allocator_bool<true>) propagate_on_container_move_assignment; - //!A integral constant of type bool with value true - typedef BOOST_CONTAINER_IMPDEF(new_allocator_bool<true>) is_always_equal; - // reference-to-void members are impossible - - //!Obtains an new_allocator that allocates - //!objects of type T2 - template<class T2> - struct rebind - { - typedef new_allocator< T2> other; - }; - - //!Default constructor - //!Never throws - new_allocator() BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Constructor from other new_allocator. - //!Never throws - new_allocator(const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Copy assignment operator from other new_allocator. - //!Never throws - new_allocator& operator=(const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { - return *this; - } - - //!Constructor from related new_allocator. - //!Never throws - template<class T2> - new_allocator(const new_allocator<T2> &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Swaps two allocators, does nothing - //!because this new_allocator is stateless - friend void swap(new_allocator &, new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!An new_allocator always compares to true, as memory allocated with one - //!instance can be deallocated by another instance - friend bool operator==(const new_allocator &, const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { return true; } - - //!An new_allocator always compares to false, as memory allocated with one - //!instance can be deallocated by another instance - friend bool operator!=(const new_allocator &, const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { return false; } -}; - - -//! This class is a reduced STL-compatible allocator that allocates memory using operator new -template<class T> -class new_allocator -{ - public: - typedef T value_type; - typedef T * pointer; - typedef const T * const_pointer; - typedef T & reference; - typedef const T & const_reference; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - //!A integral constant of type bool with value true - typedef BOOST_CONTAINER_IMPDEF(new_allocator_bool<true>) propagate_on_container_move_assignment; - //!A integral constant of type bool with value true - typedef BOOST_CONTAINER_IMPDEF(new_allocator_bool<true>) is_always_equal; - - //!Obtains an new_allocator that allocates - //!objects of type T2 - template<class T2> - struct rebind - { - typedef new_allocator<T2> other; - }; - - //!Default constructor - //!Never throws - new_allocator() BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Constructor from other new_allocator. - //!Never throws - new_allocator(const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Copy assignment operator from other new_allocator. - //!Never throws - new_allocator& operator=(const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { - return *this; - } - - //!Constructor from related new_allocator. - //!Never throws - template<class T2> - new_allocator(const new_allocator<T2> &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!Allocates memory for an array of count elements. - //!Throws std::bad_alloc if there is no enough memory - pointer allocate(size_type count) - { - const std::size_t max_count = std::size_t(-1)/(2*sizeof(T)); - if(BOOST_UNLIKELY(count > max_count)) - throw_bad_alloc(); - return static_cast<T*>(::operator new(count*sizeof(T))); - } - - //!Deallocates previously allocated memory. - //!Never throws - void deallocate(pointer ptr, size_type) BOOST_NOEXCEPT_OR_NOTHROW - { ::operator delete((void*)ptr); } - - //!Returns the maximum number of elements that could be allocated. - //!Never throws - size_type max_size() const BOOST_NOEXCEPT_OR_NOTHROW - { return std::size_t(-1)/(2*sizeof(T)); } - - //!Swaps two allocators, does nothing - //!because this new_allocator is stateless - friend void swap(new_allocator &, new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - {} - - //!An new_allocator always compares to true, as memory allocated with one - //!instance can be deallocated by another instance - friend bool operator==(const new_allocator &, const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { return true; } - - //!An new_allocator always compares to false, as memory allocated with one - //!instance can be deallocated by another instance - friend bool operator!=(const new_allocator &, const new_allocator &) BOOST_NOEXCEPT_OR_NOTHROW - { return false; } -}; - -} //namespace container { -} //namespace boost { - -#include <boost/container/detail/config_end.hpp> - -#endif //BOOST_CONTAINER_NEW_ALLOCATOR_HPP diff --git a/ThirdParty/boost/container/slist.hpp b/ThirdParty/boost/container/slist.hpp deleted file mode 100644 index d10cf5748f2781724d8ff6a9631abbd5b91be12a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container/slist.hpp +++ /dev/null @@ -1,1756 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2004-2015. 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) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_SLIST_HPP -#define BOOST_CONTAINER_SLIST_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/container/detail/config_begin.hpp> -#include <boost/container/detail/workaround.hpp> - -// container -#include <boost/container/container_fwd.hpp> -#include <boost/container/new_allocator.hpp> //new_allocator -#include <boost/container/throw_exception.hpp> -// container/detail -#include <boost/container/detail/algorithm.hpp> //algo_equal(), algo_lexicographical_compare -#include <boost/container/detail/compare_functors.hpp> -#include <boost/container/detail/iterator.hpp> -#include <boost/container/detail/iterators.hpp> -#include <boost/container/detail/mpl.hpp> -#include <boost/container/detail/node_alloc_holder.hpp> -#include <boost/container/detail/type_traits.hpp> -#include <boost/container/detail/value_functors.hpp> -// intrusive -#include <boost/intrusive/pointer_traits.hpp> -#include <boost/intrusive/slist.hpp> -// move -#include <boost/move/iterator.hpp> -#include <boost/move/traits.hpp> -#include <boost/move/utility_core.hpp> -// move/detail -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -#include <boost/move/detail/fwd_macros.hpp> -#endif -#include <boost/move/detail/move_helpers.hpp> -// other -#include <boost/core/no_exceptions_support.hpp> -// std -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) -#include <initializer_list> -#endif - -namespace boost { -namespace container { - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -template <class T, class Allocator> -class slist; - -namespace dtl { - -template<class VoidPointer> -struct slist_hook -{ - typedef typename dtl::bi::make_slist_base_hook - <dtl::bi::void_pointer<VoidPointer>, dtl::bi::link_mode<dtl::bi::normal_link> >::type type; -}; - - -template <class T, class VoidPointer> -struct slist_node - : public slist_hook<VoidPointer>::type -{ - public: - typedef T value_type; - typedef T internal_type; - typedef typename slist_hook<VoidPointer>::type hook_type; - - typedef typename dtl::aligned_storage<sizeof(T), dtl::alignment_of<T>::value>::type storage_t; - storage_t m_storage; - - #if defined(BOOST_GCC) && (BOOST_GCC >= 40600) && (BOOST_GCC < 80000) - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" - #define BOOST_CONTAINER_DISABLE_ALIASING_WARNING - # endif - - BOOST_CONTAINER_FORCEINLINE T &get_data() - { return *reinterpret_cast<T*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE const T &get_data() const - { return *reinterpret_cast<const T*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE T *get_data_ptr() - { return reinterpret_cast<T*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE const T *get_data_ptr() const - { return reinterpret_cast<T*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE internal_type &get_real_data() - { return *reinterpret_cast<internal_type*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE const internal_type &get_real_data() const - { return *reinterpret_cast<const internal_type*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE internal_type *get_real_data_ptr() - { return reinterpret_cast<internal_type*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE const internal_type *get_real_data_ptr() const - { return reinterpret_cast<internal_type*>(this->m_storage.data); } - - BOOST_CONTAINER_FORCEINLINE ~slist_node() - { reinterpret_cast<T*>(this->m_storage.data)->~T(); } - - #if defined(BOOST_CONTAINER_DISABLE_ALIASING_WARNING) - #pragma GCC diagnostic pop - #undef BOOST_CONTAINER_DISABLE_ALIASING_WARNING - # endif - - BOOST_CONTAINER_FORCEINLINE void destroy_header() - { static_cast<hook_type*>(this)->~hook_type(); } -}; - - -template <class T, class VoidPointer> -struct iiterator_node_value_type< slist_node<T,VoidPointer> > { - typedef T type; -}; - -template<class Allocator> -struct intrusive_slist_type -{ - typedef boost::container::allocator_traits<Allocator> allocator_traits_type; - typedef typename allocator_traits_type::value_type value_type; - typedef typename boost::intrusive::pointer_traits - <typename allocator_traits_type::pointer>::template - rebind_pointer<void>::type - void_pointer; - typedef typename dtl::slist_node - <value_type, void_pointer> node_type; - - typedef typename dtl::bi::make_slist - <node_type - ,dtl::bi::base_hook<typename slist_hook<void_pointer>::type> - ,dtl::bi::constant_time_size<true> - , dtl::bi::size_type - <typename allocator_traits_type::size_type> - >::type container_type; - typedef container_type type ; -}; - -} //namespace dtl { - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -//! An slist is a singly linked list: a list where each element is linked to the next -//! element, but not to the previous element. That is, it is a Sequence that -//! supports forward but not backward traversal, and (amortized) constant time -//! insertion and removal of elements. Slists, like lists, have the important -//! property that insertion and splicing do not invalidate iterators to list elements, -//! and that even removal invalidates only the iterators that point to the elements -//! that are removed. The ordering of iterators may be changed (that is, -//! slist<T>::iterator might have a different predecessor or successor after a list -//! operation than it did before), but the iterators themselves will not be invalidated -//! or made to point to different elements unless that invalidation or mutation is explicit. -//! -//! The main difference between slist and list is that list's iterators are bidirectional -//! iterators, while slist's iterators are forward iterators. This means that slist is -//! less versatile than list; frequently, however, bidirectional iterators are -//! unnecessary. You should usually use slist unless you actually need the extra -//! functionality of list, because singly linked lists are smaller and faster than double -//! linked lists. -//! -//! Important performance note: like every other Sequence, slist defines the member -//! functions insert and erase. Using these member functions carelessly, however, can -//! result in disastrously slow programs. The problem is that insert's first argument is -//! an iterator p, and that it inserts the new element(s) before p. This means that -//! insert must find the iterator just before p; this is a constant-time operation -//! for list, since list has bidirectional iterators, but for slist it must find that -//! iterator by traversing the list from the beginning up to p. In other words: -//! insert and erase are slow operations anywhere but near the beginning of the slist. -//! -//! Slist provides the member functions insert_after and erase_after, which are constant -//! time operations: you should always use insert_after and erase_after whenever -//! possible. If you find that insert_after and erase_after aren't adequate for your -//! needs, and that you often need to use insert and erase in the middle of the list, -//! then you should probably use list instead of slist. -//! -//! \tparam T The type of object that is stored in the list -//! \tparam Allocator The allocator used for all internal memory management, use void -//! for the default allocator -#ifdef BOOST_CONTAINER_DOXYGEN_INVOKED -template <class T, class Allocator = void > -#else -template <class T, class Allocator> -#endif -class slist - : protected dtl::node_alloc_holder - < typename real_allocator<T, Allocator>::type - , typename dtl::intrusive_slist_type<typename real_allocator<T, Allocator>::type>::type> -{ - #ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - typedef typename real_allocator<T, Allocator>::type ValueAllocator; - typedef typename - dtl::intrusive_slist_type<ValueAllocator>::type Icont; - typedef dtl::node_alloc_holder<ValueAllocator, Icont> AllocHolder; - typedef typename AllocHolder::NodePtr NodePtr; - typedef typename AllocHolder::NodeAlloc NodeAlloc; - typedef typename AllocHolder::ValAlloc ValAlloc; - typedef typename AllocHolder::Node Node; - typedef dtl::allocator_destroyer<NodeAlloc> Destroyer; - typedef typename AllocHolder::alloc_version alloc_version; - typedef boost::container:: - allocator_traits<ValueAllocator> allocator_traits_type; - typedef boost::container::equal_to_value - <typename allocator_traits_type::value_type> equal_to_value_type; - - BOOST_COPYABLE_AND_MOVABLE(slist) - typedef dtl::iterator_from_iiterator<typename Icont::iterator, false> iterator_impl; - typedef dtl::iterator_from_iiterator<typename Icont::iterator, true > const_iterator_impl; - #endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - - public: - ////////////////////////////////////////////// - // - // types - // - ////////////////////////////////////////////// - - typedef T value_type; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::pointer pointer; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::const_pointer const_pointer; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::reference reference; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::const_reference const_reference; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::size_type size_type; - typedef typename ::boost::container::allocator_traits<ValueAllocator>::difference_type difference_type; - typedef ValueAllocator allocator_type; - typedef BOOST_CONTAINER_IMPDEF(NodeAlloc) stored_allocator_type; - typedef BOOST_CONTAINER_IMPDEF(iterator_impl) iterator; - typedef BOOST_CONTAINER_IMPDEF(const_iterator_impl) const_iterator; - - public: - - ////////////////////////////////////////////// - // - // construct/copy/destroy - // - ////////////////////////////////////////////// - - //! <b>Effects</b>: Constructs a list taking the allocator as parameter. - //! - //! <b>Throws</b>: If allocator_type's copy constructor throws. - //! - //! <b>Complexity</b>: Constant. - slist() BOOST_NOEXCEPT_IF(dtl::is_nothrow_default_constructible<ValueAllocator>::value) - : AllocHolder() - {} - - //! <b>Effects</b>: Constructs a list taking the allocator as parameter. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - explicit slist(const allocator_type& a) BOOST_NOEXCEPT_OR_NOTHROW - : AllocHolder(a) - {} - - //! <b>Effects</b>: Constructs a list - //! and inserts n value-initialized value_types. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! throws or T's default or copy constructor throws. - //! - //! <b>Complexity</b>: Linear to n. - explicit slist(size_type n) - : AllocHolder(allocator_type()) - { this->resize(n); } - - //! <b>Effects</b>: Constructs a list that will use a copy of allocator a - //! and inserts n copies of value. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! throws or T's default or copy constructor throws. - //! - //! <b>Complexity</b>: Linear to n. - slist(size_type n, const allocator_type &a) - : AllocHolder(a) - { this->resize(n); } - - //! <b>Effects</b>: Constructs a list that will use a copy of allocator a - //! and inserts n copies of value. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! throws or T's default or copy constructor throws. - //! - //! <b>Complexity</b>: Linear to n. - explicit slist(size_type n, const value_type& x, const allocator_type& a = allocator_type()) - : AllocHolder(a) - { this->insert_after(this->cbefore_begin(), n, x); } - - //! <b>Effects</b>: Constructs a list that will use a copy of allocator a - //! and inserts a copy of the range [first, last) in the list. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! throws or T's constructor taking a dereferenced InIt throws. - //! - //! <b>Complexity</b>: Linear to the range [first, last). - template <class InpIt> - slist(InpIt first, InpIt last, const allocator_type& a = allocator_type()) - : AllocHolder(a) - { this->insert_after(this->cbefore_begin(), first, last); } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - //! <b>Effects</b>: Constructs a list that will use a copy of allocator a - //! and inserts a copy of the range [il.begin(), il.end()) in the list. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! throws or T's constructor taking a dereferenced std::initializer_list iterator throws. - //! - //! <b>Complexity</b>: Linear to the range [il.begin(), il.end()). - slist(std::initializer_list<value_type> il, const allocator_type& a = allocator_type()) - : AllocHolder(a) - { this->insert_after(this->cbefore_begin(), il.begin(), il.end()); } -#endif - - //! <b>Effects</b>: Copy constructs a list. - //! - //! <b>Postcondition</b>: x == *this. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! - //! <b>Complexity</b>: Linear to the elements x contains. - slist(const slist& x) - : AllocHolder(x) - { this->insert_after(this->cbefore_begin(), x.begin(), x.end()); } - - //! <b>Effects</b>: Move constructor. Moves x's resources to *this. - //! - //! <b>Throws</b>: If allocator_type's copy constructor throws. - //! - //! <b>Complexity</b>: Constant. - slist(BOOST_RV_REF(slist) x) BOOST_NOEXCEPT_OR_NOTHROW - : AllocHolder(BOOST_MOVE_BASE(AllocHolder, x)) - {} - - //! <b>Effects</b>: Copy constructs a list using the specified allocator. - //! - //! <b>Postcondition</b>: x == *this. - //! - //! <b>Throws</b>: If allocator_type's default constructor - //! - //! <b>Complexity</b>: Linear to the elements x contains. - slist(const slist& x, const allocator_type &a) - : AllocHolder(a) - { this->insert_after(this->cbefore_begin(), x.begin(), x.end()); } - - //! <b>Effects</b>: Move constructor using the specified allocator. - //! Moves x's resources to *this. - //! - //! <b>Throws</b>: If allocation or value_type's copy constructor throws. - //! - //! <b>Complexity</b>: Constant if a == x.get_allocator(), linear otherwise. - slist(BOOST_RV_REF(slist) x, const allocator_type &a) - : AllocHolder(a) - { - if(this->node_alloc() == x.node_alloc()){ - this->icont().swap(x.icont()); - } - else{ - this->insert_after(this->cbefore_begin(), boost::make_move_iterator(x.begin()), boost::make_move_iterator(x.end())); - } - } - - //! <b>Effects</b>: Destroys the list. All stored values are destroyed - //! and used memory is deallocated. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements. - ~slist() BOOST_NOEXCEPT_OR_NOTHROW - {} //AllocHolder clears the slist - - //! <b>Effects</b>: Makes *this contain the same elements as x. - //! - //! <b>Postcondition</b>: this->size() == x.size(). *this contains a copy - //! of each of x's elements. - //! - //! <b>Throws</b>: If memory allocation throws or T's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to the number of elements in x. - slist& operator= (BOOST_COPY_ASSIGN_REF(slist) x) - { - if (BOOST_LIKELY(this != &x)) { - NodeAlloc &this_alloc = this->node_alloc(); - const NodeAlloc &x_alloc = x.node_alloc(); - dtl::bool_<allocator_traits_type:: - propagate_on_container_copy_assignment::value> flag; - if(flag && this_alloc != x_alloc){ - this->clear(); - } - this->AllocHolder::copy_assign_alloc(x); - this->assign(x.begin(), x.end()); - } - return *this; - } - - //! <b>Effects</b>: Makes *this contain the same elements as x. - //! - //! <b>Postcondition</b>: this->size() == x.size(). *this contains a copy - //! of each of x's elements. - //! - //! <b>Throws</b>: If allocator_traits_type::propagate_on_container_move_assignment - //! is false and (allocation throws or value_type's move constructor throws) - //! - //! <b>Complexity</b>: Constant if allocator_traits_type:: - //! propagate_on_container_move_assignment is true or - //! this->get>allocator() == x.get_allocator(). Linear otherwise. - slist& operator=(BOOST_RV_REF(slist) x) - BOOST_NOEXCEPT_IF(allocator_traits_type::propagate_on_container_move_assignment::value - || allocator_traits_type::is_always_equal::value) - { - if (BOOST_LIKELY(this != &x)) { - NodeAlloc &this_alloc = this->node_alloc(); - NodeAlloc &x_alloc = x.node_alloc(); - const bool propagate_alloc = allocator_traits_type:: - propagate_on_container_move_assignment::value; - const bool allocators_equal = this_alloc == x_alloc; (void)allocators_equal; - //Resources can be transferred if both allocators are - //going to be equal after this function (either propagated or already equal) - if(propagate_alloc || allocators_equal){ - //Destroy - this->clear(); - //Move allocator if needed - this->AllocHolder::move_assign_alloc(x); - //Obtain resources - this->icont() = boost::move(x.icont()); - } - //Else do a one by one move - else{ - this->assign( boost::make_move_iterator(x.begin()) - , boost::make_move_iterator(x.end())); - } - } - return *this; - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - //! <b>Effects</b>: Makes *this contain the same elements as in il. - //! - //! <b>Postcondition</b>: this->size() == il.size(). *this contains a copy - //! of each of il's elements. - //! - //! <b>Throws</b>: If allocator_traits_type::propagate_on_container_move_assignment - //! is false and (allocation throws or value_type's move constructor throws) - slist& operator=(std::initializer_list<value_type> il) - { - assign(il.begin(), il.end()); - return *this; - } -#endif - - //! <b>Effects</b>: Assigns the n copies of val to *this. - //! - //! <b>Throws</b>: If memory allocation throws or T's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to n. - void assign(size_type n, const T& val) - { - typedef constant_iterator<value_type, difference_type> cvalue_iterator; - return this->assign(cvalue_iterator(val, n), cvalue_iterator()); - } - - //! <b>Effects</b>: Assigns the range [first, last) to *this. - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's constructor from dereferencing InpIt throws. - //! - //! <b>Complexity</b>: Linear to n. - template <class InpIt> - void assign(InpIt first, InpIt last - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename dtl::disable_if_convertible<InpIt, size_type>::type * = 0 - #endif - ) - { - iterator end_n(this->end()); - iterator prev(this->before_begin()); - iterator node(this->begin()); - while (node != end_n && first != last){ - *node = *first; - prev = node; - ++node; - ++first; - } - if (first != last) - this->insert_after(prev, first, last); - else - this->erase_after(prev, end_n); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - //! <b>Effects</b>: Assigns the range [il.begin(), il.end()) to *this. - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's constructor from dereferencing std::initializer_list iterator throws. - //! - //! <b>Complexity</b>: Linear to range [il.begin(), il.end()). - - void assign(std::initializer_list<value_type> il) - { - assign(il.begin(), il.end()); - } -#endif - //! <b>Effects</b>: Returns a copy of the internal allocator. - //! - //! <b>Throws</b>: If allocator's copy constructor throws. - //! - //! <b>Complexity</b>: Constant. - allocator_type get_allocator() const BOOST_NOEXCEPT_OR_NOTHROW - { return allocator_type(this->node_alloc()); } - - //! <b>Effects</b>: Returns a reference to the internal allocator. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Non-standard extension. - stored_allocator_type &get_stored_allocator() BOOST_NOEXCEPT_OR_NOTHROW - { return this->node_alloc(); } - - //! <b>Effects</b>: Returns a reference to the internal allocator. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Non-standard extension. - const stored_allocator_type &get_stored_allocator() const BOOST_NOEXCEPT_OR_NOTHROW - { return this->node_alloc(); } - - ////////////////////////////////////////////// - // - // iterators - // - ////////////////////////////////////////////// - - //! <b>Effects</b>: Returns a non-dereferenceable iterator that, - //! when incremented, yields begin(). This iterator may be used - //! as the argument to insert_after, erase_after, etc. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - iterator before_begin() BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(end()); } - - //! <b>Effects</b>: Returns a non-dereferenceable const_iterator - //! that, when incremented, yields begin(). This iterator may be used - //! as the argument to insert_after, erase_after, etc. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator before_begin() const BOOST_NOEXCEPT_OR_NOTHROW - { return this->cbefore_begin(); } - - //! <b>Effects</b>: Returns an iterator to the first element contained in the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - iterator begin() BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(this->icont().begin()); } - - //! <b>Effects</b>: Returns a const_iterator to the first element contained in the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator begin() const BOOST_NOEXCEPT_OR_NOTHROW - { return this->cbegin(); } - - //! <b>Effects</b>: Returns an iterator to the end of the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - iterator end() BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(this->icont().end()); } - - //! <b>Effects</b>: Returns a const_iterator to the end of the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator end() const BOOST_NOEXCEPT_OR_NOTHROW - { return this->cend(); } - - //! <b>Effects</b>: Returns a non-dereferenceable const_iterator - //! that, when incremented, yields begin(). This iterator may be used - //! as the argument to insert_after, erase_after, etc. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator cbefore_begin() const BOOST_NOEXCEPT_OR_NOTHROW - { return const_iterator(end()); } - - //! <b>Effects</b>: Returns a const_iterator to the first element contained in the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator cbegin() const BOOST_NOEXCEPT_OR_NOTHROW - { return const_iterator(this->non_const_icont().begin()); } - - //! <b>Effects</b>: Returns a const_iterator to the end of the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_iterator cend() const BOOST_NOEXCEPT_OR_NOTHROW - { return const_iterator(this->non_const_icont().end()); } - - //! <b>Returns</b>: The iterator to the element before i in the sequence. - //! Returns the end-iterator, if either i is the begin-iterator or the - //! sequence is empty. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements before i. - //! - //! <b>Note</b>: Non-standard extension. - iterator previous(iterator p) BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(this->icont().previous(p.get())); } - - //! <b>Returns</b>: The const_iterator to the element before i in the sequence. - //! Returns the end-const_iterator, if either i is the begin-const_iterator or - //! the sequence is empty. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements before i. - //! - //! <b>Note</b>: Non-standard extension. - const_iterator previous(const_iterator p) - { return const_iterator(this->icont().previous(p.get())); } - - ////////////////////////////////////////////// - // - // capacity - // - ////////////////////////////////////////////// - - //! <b>Effects</b>: Returns true if the list contains no elements. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - bool empty() const - { return !this->size(); } - - //! <b>Effects</b>: Returns the number of the elements contained in the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - size_type size() const - { return this->icont().size(); } - - //! <b>Effects</b>: Returns the largest possible size of the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - size_type max_size() const - { return AllocHolder::max_size(); } - - //! <b>Effects</b>: Inserts or erases elements at the end such that - //! the size becomes n. New elements are value initialized. - //! - //! <b>Throws</b>: If memory allocation throws, or T's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to the difference between size() and new_size. - void resize(size_type new_size) - { - const_iterator last_pos; - if(!priv_try_shrink(new_size, last_pos)){ - typedef value_init_construct_iterator<value_type, difference_type> value_init_iterator; - this->insert_after(last_pos, value_init_iterator(new_size - this->size()), value_init_iterator()); - } - } - - //! <b>Effects</b>: Inserts or erases elements at the end such that - //! the size becomes n. New elements are copy constructed from x. - //! - //! <b>Throws</b>: If memory allocation throws, or T's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to the difference between size() and new_size. - void resize(size_type new_size, const T& x) - { - const_iterator last_pos; - if(!priv_try_shrink(new_size, last_pos)){ - this->insert_after(last_pos, new_size, x); - } - } - - ////////////////////////////////////////////// - // - // element access - // - ////////////////////////////////////////////// - - //! <b>Requires</b>: !empty() - //! - //! <b>Effects</b>: Returns a reference to the first element - //! from the beginning of the container. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - reference front() - { - BOOST_ASSERT(!this->empty()); - return *this->begin(); - } - - //! <b>Requires</b>: !empty() - //! - //! <b>Effects</b>: Returns a const reference to the first element - //! from the beginning of the container. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - const_reference front() const - { - BOOST_ASSERT(!this->empty()); - return *this->begin(); - } - - ////////////////////////////////////////////// - // - // modifiers - // - ////////////////////////////////////////////// - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! <b>Effects</b>: Inserts an object of type T constructed with - //! std::forward<Args>(args)... in the front of the list - //! - //! <b>Returns</b>: A reference to the created object. - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's copy constructor throws. - //! - //! <b>Complexity</b>: Amortized constant time. - template <class... Args> - reference emplace_front(BOOST_FWD_REF(Args)... args) - { return *this->emplace_after(this->cbefore_begin(), boost::forward<Args>(args)...); } - - //! <b>Effects</b>: Inserts an object of type T constructed with - //! std::forward<Args>(args)... after prev - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's in-place constructor throws. - //! - //! <b>Complexity</b>: Constant - template <class... Args> - iterator emplace_after(const_iterator prev, BOOST_FWD_REF(Args)... args) - { - NodePtr pnode(AllocHolder::create_node(boost::forward<Args>(args)...)); - return iterator(this->icont().insert_after(prev.get(), *pnode)); - } - - #else // !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - #define BOOST_CONTAINER_SLIST_EMPLACE_CODE(N) \ - BOOST_MOVE_TMPL_LT##N BOOST_MOVE_CLASS##N BOOST_MOVE_GT##N \ - reference emplace_front(BOOST_MOVE_UREF##N)\ - { return *this->emplace_after(this->cbefore_begin() BOOST_MOVE_I##N BOOST_MOVE_FWD##N);}\ - \ - BOOST_MOVE_TMPL_LT##N BOOST_MOVE_CLASS##N BOOST_MOVE_GT##N \ - iterator emplace_after(const_iterator p BOOST_MOVE_I##N BOOST_MOVE_UREF##N)\ - {\ - NodePtr pnode (AllocHolder::create_node(BOOST_MOVE_FWD##N));\ - return iterator(this->icont().insert_after(p.get(), *pnode));\ - }\ - // - BOOST_MOVE_ITERATE_0TO9(BOOST_CONTAINER_SLIST_EMPLACE_CODE) - #undef BOOST_CONTAINER_SLIST_EMPLACE_CODE - - #endif // !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! <b>Effects</b>: Inserts a copy of x at the beginning of the list. - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's copy constructor throws. - //! - //! <b>Complexity</b>: Amortized constant time. - void push_front(const T &x); - - //! <b>Effects</b>: Constructs a new element in the beginning of the list - //! and moves the resources of x to this new element. - //! - //! <b>Throws</b>: If memory allocation throws. - //! - //! <b>Complexity</b>: Amortized constant time. - void push_front(T &&x); - #else - BOOST_MOVE_CONVERSION_AWARE_CATCH(push_front, T, void, priv_push_front) - #endif - - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts a copy of the value after prev_p. - //! - //! <b>Returns</b>: An iterator to the inserted element. - //! - //! <b>Throws</b>: If memory allocation throws or T's copy constructor throws. - //! - //! <b>Complexity</b>: Amortized constant time. - //! - //! <b>Note</b>: Does not affect the validity of iterators and references of - //! previous values. - iterator insert_after(const_iterator prev_p, const T &x); - - //! <b>Requires</b>: prev_p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts a move constructed copy object from the value after the - //! element pointed by prev_p. - //! - //! <b>Returns</b>: An iterator to the inserted element. - //! - //! <b>Throws</b>: If memory allocation throws. - //! - //! <b>Complexity</b>: Amortized constant time. - //! - //! <b>Note</b>: Does not affect the validity of iterators and references of - //! previous values. - iterator insert_after(const_iterator prev_p, T &&x); - #else - BOOST_MOVE_CONVERSION_AWARE_CATCH_1ARG(insert_after, T, iterator, priv_insert_after, const_iterator, const_iterator) - #endif - - //! <b>Requires</b>: prev_p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts n copies of x after prev_p. - //! - //! <b>Returns</b>: an iterator to the last inserted element or prev_p if n is 0. - //! - //! <b>Throws</b>: If memory allocation throws or T's copy constructor throws. - //! - //! - //! <b>Complexity</b>: Linear to n. - //! - //! <b>Note</b>: Does not affect the validity of iterators and references of - //! previous values. - iterator insert_after(const_iterator prev_p, size_type n, const value_type& x) - { - typedef constant_iterator<value_type, difference_type> cvalue_iterator; - return this->insert_after(prev_p, cvalue_iterator(x, n), cvalue_iterator()); - } - - //! <b>Requires</b>: prev_p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts the range pointed by [first, last) after prev_p. - //! - //! <b>Returns</b>: an iterator to the last inserted element or prev_p if first == last. - //! - //! <b>Throws</b>: If memory allocation throws, T's constructor from a - //! dereferenced InpIt throws. - //! - //! <b>Complexity</b>: Linear to the number of elements inserted. - //! - //! <b>Note</b>: Does not affect the validity of iterators and references of - //! previous values. - template <class InpIt> - iterator insert_after(const_iterator prev_p, InpIt first, InpIt last - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename dtl::enable_if_c - < !dtl::is_convertible<InpIt, size_type>::value - && (dtl::is_input_iterator<InpIt>::value - || dtl::is_same<alloc_version, version_1>::value - ) - >::type * = 0 - #endif - ) - { - iterator ret_it(prev_p.get()); - for (; first != last; ++first){ - ret_it = iterator(this->icont().insert_after(ret_it.get(), *this->create_node_from_it(first))); - } - return ret_it; - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - //! <b>Requires</b>: prev_p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts the range pointed by [il.begin(), il.end()) after prev_p. - //! - //! <b>Returns</b>: an iterator to the last inserted element or prev_p if il.begin() == il.end(). - //! - //! <b>Throws</b>: If memory allocation throws, T's constructor from a - //! dereferenced std::initializer_list iterator throws. - //! - //! <b>Complexity</b>: Linear to the number of elements inserted. - //! - //! <b>Note</b>: Does not affect the validity of iterators and references of - //! previous values. - iterator insert_after(const_iterator prev_p, std::initializer_list<value_type> il) - { - return insert_after(prev_p, il.begin(), il.end()); - } -#endif - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - template <class FwdIt> - iterator insert_after(const_iterator prev, FwdIt first, FwdIt last - , typename dtl::enable_if_c - < !dtl::is_convertible<FwdIt, size_type>::value - && !(dtl::is_input_iterator<FwdIt>::value - || dtl::is_same<alloc_version, version_1>::value - ) - >::type * = 0 - ) - { - //Optimized allocation and construction - insertion_functor func(this->icont(), prev.get()); - this->allocate_many_and_construct(first, boost::container::iterator_distance(first, last), func); - return iterator(func.inserted_first()); - } - #endif - - //! <b>Effects</b>: Removes the first element from the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Amortized constant time. - void pop_front() - { - BOOST_ASSERT(!this->empty()); - this->icont().pop_front_and_dispose(Destroyer(this->node_alloc())); - } - - //! <b>Effects</b>: Erases the element after the element pointed by prev_p - //! of the list. - //! - //! <b>Returns</b>: the first element remaining beyond the removed elements, - //! or end() if no such element exists. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Does not invalidate iterators or references to non erased elements. - iterator erase_after(const_iterator prev_p) - { - return iterator(this->icont().erase_after_and_dispose(prev_p.get(), Destroyer(this->node_alloc()))); - } - - //! <b>Effects</b>: Erases the range (before_first, last) from - //! the list. - //! - //! <b>Returns</b>: the first element remaining beyond the removed elements, - //! or end() if no such element exists. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of erased elements. - //! - //! <b>Note</b>: Does not invalidate iterators or references to non erased elements. - iterator erase_after(const_iterator before_first, const_iterator last) - { - return iterator(this->icont().erase_after_and_dispose(before_first.get(), last.get(), Destroyer(this->node_alloc()))); - } - - //! <b>Effects</b>: Swaps the contents of *this and x. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements on *this and x. - void swap(slist& x) - BOOST_NOEXCEPT_IF( allocator_traits_type::propagate_on_container_swap::value - || allocator_traits_type::is_always_equal::value) - { - BOOST_ASSERT(allocator_traits_type::propagate_on_container_swap::value || - allocator_traits_type::is_always_equal::value || - this->get_stored_allocator() == x.get_stored_allocator()); - AllocHolder::swap(x); - } - - //! <b>Effects</b>: Erases all the elements of the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements in the list. - void clear() - { this->icont().clear_and_dispose(Destroyer(this->node_alloc())); } - - ////////////////////////////////////////////// - // - // slist operations - // - ////////////////////////////////////////////// - - //! <b>Requires</b>: p must point to an element contained - //! by the list. x != *this - //! - //! <b>Effects</b>: Transfers all the elements of list x to this list, after the - //! the element pointed by p. No destructors or copy constructors are called. - //! - //! <b>Throws</b>: std::runtime_error if this' allocator and x's allocator - //! are not equal. - //! - //! <b>Complexity</b>: Linear to the elements in x. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of - //! this list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, slist& x) BOOST_NOEXCEPT_OR_NOTHROW - { - BOOST_ASSERT(this != &x); - BOOST_ASSERT(this->node_alloc() == x.node_alloc()); - this->icont().splice_after(prev_p.get(), x.icont()); - } - - //! <b>Requires</b>: p must point to an element contained - //! by the list. x != *this - //! - //! <b>Effects</b>: Transfers all the elements of list x to this list, after the - //! the element pointed by p. No destructors or copy constructors are called. - //! - //! <b>Throws</b>: std::runtime_error if this' allocator and x's allocator - //! are not equal. - //! - //! <b>Complexity</b>: Linear to the elements in x. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of - //! this list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, BOOST_RV_REF(slist) x) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(prev_p, static_cast<slist&>(x)); } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! i must point to an element contained in list x. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the value pointed by i, from list x to this list, - //! after the element pointed by prev_p. - //! If prev_p == prev or prev_p == ++prev, this function is a null operation. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, slist& x, const_iterator prev) BOOST_NOEXCEPT_OR_NOTHROW - { - BOOST_ASSERT(this->node_alloc() == x.node_alloc()); - this->icont().splice_after(prev_p.get(), x.icont(), prev.get()); - } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! i must point to an element contained in list x. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the value pointed by i, from list x to this list, - //! after the element pointed by prev_p. - //! If prev_p == prev or prev_p == ++prev, this function is a null operation. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, BOOST_RV_REF(slist) x, const_iterator prev) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(prev_p, static_cast<slist&>(x), prev); } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! before_first and before_last must be valid iterators of x. - //! prev_p must not be contained in [before_first, before_last) range. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the range [before_first + 1, before_last + 1) - //! from list x to this list, after the element pointed by prev_p. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear to the number of transferred elements. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, slist& x, - const_iterator before_first, const_iterator before_last) BOOST_NOEXCEPT_OR_NOTHROW - { - BOOST_ASSERT(this->node_alloc() == x.node_alloc()); - this->icont().splice_after - (prev_p.get(), x.icont(), before_first.get(), before_last.get()); - } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! before_first and before_last must be valid iterators of x. - //! prev_p must not be contained in [before_first, before_last) range. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the range [before_first + 1, before_last + 1) - //! from list x to this list, after the element pointed by prev_p. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear to the number of transferred elements. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, BOOST_RV_REF(slist) x, - const_iterator before_first, const_iterator before_last) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(prev_p, static_cast<slist&>(x), before_first, before_last); } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! before_first and before_last must be valid iterators of x. - //! prev_p must not be contained in [before_first, before_last) range. - //! n == distance(before_first, before_last). - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the range [before_first + 1, before_last + 1) - //! from list x to this list, after the element pointed by prev_p. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, slist& x, - const_iterator before_first, const_iterator before_last, - size_type n) BOOST_NOEXCEPT_OR_NOTHROW - { - BOOST_ASSERT(this->node_alloc() == x.node_alloc()); - this->icont().splice_after - (prev_p.get(), x.icont(), before_first.get(), before_last.get(), n); - } - - //! <b>Requires</b>: prev_p must be a valid iterator of this. - //! before_first and before_last must be valid iterators of x. - //! prev_p must not be contained in [before_first, before_last) range. - //! n == distance(before_first, before_last). - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the range [before_first + 1, before_last + 1) - //! from list x to this list, after the element pointed by prev_p. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Constant. - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice_after(const_iterator prev_p, BOOST_RV_REF(slist) x, - const_iterator before_first, const_iterator before_last, - size_type n) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(prev_p, static_cast<slist&>(x), before_first, before_last, n); } - - //! <b>Effects</b>: Removes all the elements that compare equal to value. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear time. It performs exactly size() comparisons for equality. - //! - //! <b>Note</b>: The relative order of elements that are not removed is unchanged, - //! and iterators to elements that are not removed remain valid. - void remove(const T& value) - { this->remove_if(equal_to_value_type(value)); } - - //! <b>Effects</b>: Removes all the elements for which a specified - //! predicate is satisfied. - //! - //! <b>Throws</b>: If pred throws. - //! - //! <b>Complexity</b>: Linear time. It performs exactly size() calls to the predicate. - //! - //! <b>Note</b>: The relative order of elements that are not removed is unchanged, - //! and iterators to elements that are not removed remain valid. - template <class Pred> - void remove_if(Pred pred) - { - typedef value_to_node_compare<Node, Pred> value_to_node_compare_type; - this->icont().remove_and_dispose_if(value_to_node_compare_type(pred), Destroyer(this->node_alloc())); - } - - //! <b>Effects</b>: Removes adjacent duplicate elements or adjacent - //! elements that are equal from the list. - //! - //! <b>Throws</b>: If comparison throws. - //! - //! <b>Complexity</b>: Linear time (size()-1 comparisons equality comparisons). - //! - //! <b>Note</b>: The relative order of elements that are not removed is unchanged, - //! and iterators to elements that are not removed remain valid. - void unique() - { this->unique(value_equal_t()); } - - //! <b>Effects</b>: Removes adjacent duplicate elements or adjacent - //! elements that satisfy some binary predicate from the list. - //! - //! <b>Throws</b>: If pred throws. - //! - //! <b>Complexity</b>: Linear time (size()-1 comparisons calls to pred()). - //! - //! <b>Note</b>: The relative order of elements that are not removed is unchanged, - //! and iterators to elements that are not removed remain valid. - template <class Pred> - void unique(Pred pred) - { - typedef value_to_node_compare<Node, Pred> value_to_node_compare_type; - this->icont().unique_and_dispose(value_to_node_compare_type(pred), Destroyer(this->node_alloc())); - } - - //! <b>Requires</b>: The lists x and *this must be distinct. - //! - //! <b>Effects</b>: This function removes all of x's elements and inserts them - //! in order into *this according to std::less<value_type>. The merge is stable; - //! that is, if an element from *this is equivalent to one from x, then the element - //! from *this will precede the one from x. - //! - //! <b>Throws</b>: If comparison throws. - //! - //! <b>Complexity</b>: This function is linear time: it performs at most - //! size() + x.size() - 1 comparisons. - void merge(slist & x) - { this->merge(x, value_less_t()); } - - //! <b>Requires</b>: The lists x and *this must be distinct. - //! - //! <b>Effects</b>: This function removes all of x's elements and inserts them - //! in order into *this according to std::less<value_type>. The merge is stable; - //! that is, if an element from *this is equivalent to one from x, then the element - //! from *this will precede the one from x. - //! - //! <b>Throws</b>: If comparison throws. - //! - //! <b>Complexity</b>: This function is linear time: it performs at most - //! size() + x.size() - 1 comparisons. - void merge(BOOST_RV_REF(slist) x) - { this->merge(static_cast<slist&>(x)); } - - //! <b>Requires</b>: p must be a comparison function that induces a strict weak - //! ordering and both *this and x must be sorted according to that ordering - //! The lists x and *this must be distinct. - //! - //! <b>Effects</b>: This function removes all of x's elements and inserts them - //! in order into *this. The merge is stable; that is, if an element from *this is - //! equivalent to one from x, then the element from *this will precede the one from x. - //! - //! <b>Throws</b>: If comp throws. - //! - //! <b>Complexity</b>: This function is linear time: it performs at most - //! size() + x.size() - 1 comparisons. - //! - //! <b>Note</b>: Iterators and references to *this are not invalidated. - template <class StrictWeakOrdering> - void merge(slist& x, StrictWeakOrdering comp) - { - typedef value_to_node_compare<Node, StrictWeakOrdering> value_to_node_compare_type; - BOOST_ASSERT(this->node_alloc() == x.node_alloc()); - this->icont().merge(x.icont(), value_to_node_compare_type(comp)); - } - - //! <b>Requires</b>: p must be a comparison function that induces a strict weak - //! ordering and both *this and x must be sorted according to that ordering - //! The lists x and *this must be distinct. - //! - //! <b>Effects</b>: This function removes all of x's elements and inserts them - //! in order into *this. The merge is stable; that is, if an element from *this is - //! equivalent to one from x, then the element from *this will precede the one from x. - //! - //! <b>Throws</b>: If comp throws. - //! - //! <b>Complexity</b>: This function is linear time: it performs at most - //! size() + x.size() - 1 comparisons. - //! - //! <b>Note</b>: Iterators and references to *this are not invalidated. - template <class StrictWeakOrdering> - void merge(BOOST_RV_REF(slist) x, StrictWeakOrdering comp) - { this->merge(static_cast<slist&>(x), comp); } - - //! <b>Effects</b>: This function sorts the list *this according to std::less<value_type>. - //! The sort is stable, that is, the relative order of equivalent elements is preserved. - //! - //! <b>Throws</b>: If comparison throws. - //! - //! <b>Notes</b>: Iterators and references are not invalidated. - //! - //! <b>Complexity</b>: The number of comparisons is approximately N log N, where N - //! is the list's size. - void sort() - { this->sort(value_less_t()); } - - //! <b>Effects</b>: This function sorts the list *this according to std::less<value_type>. - //! The sort is stable, that is, the relative order of equivalent elements is preserved. - //! - //! <b>Throws</b>: If comp throws. - //! - //! <b>Notes</b>: Iterators and references are not invalidated. - //! - //! <b>Complexity</b>: The number of comparisons is approximately N log N, where N - //! is the list's size. - template <class StrictWeakOrdering> - void sort(StrictWeakOrdering comp) - { - typedef value_to_node_compare<Node, StrictWeakOrdering> value_to_node_compare_type; - // nothing if the slist has length 0 or 1. - if (this->size() < 2) - return; - this->icont().sort(value_to_node_compare_type(comp)); - } - - //! <b>Effects</b>: Reverses the order of elements in the list. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: This function is linear time. - //! - //! <b>Note</b>: Iterators and references are not invalidated - void reverse() BOOST_NOEXCEPT_OR_NOTHROW - { this->icont().reverse(); } - - ////////////////////////////////////////////// - // - // list compatibility interface - // - ////////////////////////////////////////////// - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! <b>Effects</b>: Inserts an object of type T constructed with - //! std::forward<Args>(args)... before p - //! - //! <b>Throws</b>: If memory allocation throws or - //! T's in-place constructor throws. - //! - //! <b>Complexity</b>: Linear to the elements before p - template <class... Args> - iterator emplace(const_iterator p, BOOST_FWD_REF(Args)... args) - { return this->emplace_after(this->previous(p), boost::forward<Args>(args)...); } - - #else - - #define BOOST_CONTAINER_SLIST_EMPLACE_CODE(N) \ - BOOST_MOVE_TMPL_LT##N BOOST_MOVE_CLASS##N BOOST_MOVE_GT##N \ - iterator emplace(const_iterator p BOOST_MOVE_I##N BOOST_MOVE_UREF##N)\ - {\ - return this->emplace_after(this->previous(p) BOOST_MOVE_I##N BOOST_MOVE_FWD##N);\ - }\ - // - BOOST_MOVE_ITERATE_0TO9(BOOST_CONTAINER_SLIST_EMPLACE_CODE) - #undef BOOST_CONTAINER_SLIST_EMPLACE_CODE - - #endif // !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Insert a copy of x before p. - //! - //! <b>Returns</b>: an iterator to the inserted element. - //! - //! <b>Throws</b>: If memory allocation throws or x's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to the elements before p. - iterator insert(const_iterator p, const T &x); - - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Insert a new element before p with x's resources. - //! - //! <b>Returns</b>: an iterator to the inserted element. - //! - //! <b>Throws</b>: If memory allocation throws. - //! - //! <b>Complexity</b>: Linear to the elements before p. - iterator insert(const_iterator prev_p, T &&x); - #else - BOOST_MOVE_CONVERSION_AWARE_CATCH_1ARG(insert, T, iterator, priv_insert, const_iterator, const_iterator) - #endif - - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Inserts n copies of x before p. - //! - //! <b>Returns</b>: an iterator to the first inserted element or p if n == 0. - //! - //! <b>Throws</b>: If memory allocation throws or T's copy constructor throws. - //! - //! <b>Complexity</b>: Linear to n plus linear to the elements before p. - iterator insert(const_iterator p, size_type n, const value_type& x) - { - const_iterator prev(this->previous(p)); - this->insert_after(prev, n, x); - return ++iterator(prev.get()); - } - - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Insert a copy of the [first, last) range before p. - //! - //! <b>Returns</b>: an iterator to the first inserted element or p if first == last. - //! - //! <b>Throws</b>: If memory allocation throws, T's constructor from a - //! dereferenced InpIt throws. - //! - //! <b>Complexity</b>: Linear to distance [first, last) plus - //! linear to the elements before p. - template <class InIter> - iterator insert(const_iterator p, InIter first, InIter last) - { - const_iterator prev(this->previous(p)); - this->insert_after(prev, first, last); - return ++iterator(prev.get()); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Insert a copy of the [il.begin(), il.end()) range before p. - //! - //! <b>Returns</b>: an iterator to the first inserted element or p if il.begin() == il.end(). - //! - //! <b>Throws</b>: If memory allocation throws, T's constructor from a - //! dereferenced std::initializer_list iterator throws. - //! - //! <b>Complexity</b>: Linear to the range [il.begin(), il.end()) plus - //! linear to the elements before p. - iterator insert(const_iterator p, std::initializer_list<value_type> il) - { - return insert(p, il.begin(), il.end()); - } -#endif - - //! <b>Requires</b>: p must be a valid iterator of *this. - //! - //! <b>Effects</b>: Erases the element at p. - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the number of elements before p. - iterator erase(const_iterator p) BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(this->erase_after(previous(p))); } - - //! <b>Requires</b>: first and last must be valid iterator to elements in *this. - //! - //! <b>Effects</b>: Erases the elements pointed by [first, last). - //! - //! <b>Throws</b>: Nothing. - //! - //! <b>Complexity</b>: Linear to the distance between first and last plus - //! linear to the elements before first. - iterator erase(const_iterator first, const_iterator last) BOOST_NOEXCEPT_OR_NOTHROW - { return iterator(this->erase_after(previous(first), last)); } - - //! <b>Requires</b>: p must point to an element contained - //! by the list. x != *this. this' allocator and x's allocator shall compare equal - //! - //! <b>Effects</b>: Transfers all the elements of list x to this list, before the - //! the element pointed by p. No destructors or copy constructors are called. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), and linear in x.size(). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of - //! this list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, slist& x) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(this->previous(p), x); } - - //! <b>Requires</b>: p must point to an element contained - //! by the list. x != *this. this' allocator and x's allocator shall compare equal - //! - //! <b>Effects</b>: Transfers all the elements of list x to this list, before the - //! the element pointed by p. No destructors or copy constructors are called. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), and linear in x.size(). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of - //! this list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, BOOST_RV_REF(slist) x) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice(p, static_cast<slist&>(x)); } - - //! <b>Requires</b>: p must point to an element contained - //! by this list. i must point to an element contained in list x. - //! this' allocator and x's allocator shall compare equal - //! - //! <b>Effects</b>: Transfers the value pointed by i, from list x to this list, - //! before the element pointed by p. No destructors or copy constructors are called. - //! If p == i or p == ++i, this function is a null operation. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), and in distance(x.begin(), i). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, slist& x, const_iterator i) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(this->previous(p), x, x.previous(i)); } - - //! <b>Requires</b>: p must point to an element contained - //! by this list. i must point to an element contained in list x. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Effects</b>: Transfers the value pointed by i, from list x to this list, - //! before the element pointed by p. No destructors or copy constructors are called. - //! If p == i or p == ++i, this function is a null operation. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), and in distance(x.begin(), i). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, BOOST_RV_REF(slist) x, const_iterator i) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice(p, static_cast<slist&>(x), i); } - - //! <b>Requires</b>: p must point to an element contained - //! by this list. first and last must point to elements contained in list x. - //! - //! <b>Effects</b>: Transfers the range pointed by first and last from list x to this list, - //! before the element pointed by p. No destructors or copy constructors are called. - //! this' allocator and x's allocator shall compare equal. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), in distance(x.begin(), first), - //! and in distance(first, last). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, slist& x, const_iterator first, const_iterator last) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice_after(this->previous(p), x, x.previous(first), x.previous(last)); } - - //! <b>Requires</b>: p must point to an element contained - //! by this list. first and last must point to elements contained in list x. - //! this' allocator and x's allocator shall compare equal - //! - //! <b>Effects</b>: Transfers the range pointed by first and last from list x to this list, - //! before the element pointed by p. No destructors or copy constructors are called. - //! - //! <b>Throws</b>: Nothing - //! - //! <b>Complexity</b>: Linear in distance(begin(), p), in distance(x.begin(), first), - //! and in distance(first, last). - //! - //! <b>Note</b>: Iterators of values obtained from list x now point to elements of this - //! list. Iterators of this list and all the references are not invalidated. - void splice(const_iterator p, BOOST_RV_REF(slist) x, const_iterator first, const_iterator last) BOOST_NOEXCEPT_OR_NOTHROW - { this->splice(p, static_cast<slist&>(x), first, last); } - - //! <b>Effects</b>: Returns true if x and y are equal - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator==(const slist& x, const slist& y) - { return x.size() == y.size() && ::boost::container::algo_equal(x.begin(), x.end(), y.begin()); } - - //! <b>Effects</b>: Returns true if x and y are unequal - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator!=(const slist& x, const slist& y) - { return !(x == y); } - - //! <b>Effects</b>: Returns true if x is less than y - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator<(const slist& x, const slist& y) - { return ::boost::container::algo_lexicographical_compare(x.begin(), x.end(), y.begin(), y.end()); } - - //! <b>Effects</b>: Returns true if x is greater than y - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator>(const slist& x, const slist& y) - { return y < x; } - - //! <b>Effects</b>: Returns true if x is equal or less than y - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator<=(const slist& x, const slist& y) - { return !(y < x); } - - //! <b>Effects</b>: Returns true if x is equal or greater than y - //! - //! <b>Complexity</b>: Linear to the number of elements in the container. - friend bool operator>=(const slist& x, const slist& y) - { return !(x < y); } - - //! <b>Effects</b>: x.swap(y) - //! - //! <b>Complexity</b>: Constant. - friend void swap(slist& x, slist& y) - { x.swap(y); } - - #ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - private: - - void priv_push_front (const T &x) - { this->insert_after(this->cbefore_begin(), x); } - - void priv_push_front (BOOST_RV_REF(T) x) - { this->insert_after(this->cbefore_begin(), ::boost::move(x)); } - - bool priv_try_shrink(size_type new_size, const_iterator &last_pos) - { - typename Icont::iterator end_n(this->icont().end()), cur(this->icont().before_begin()), cur_next; - while (++(cur_next = cur) != end_n && new_size > 0){ - --new_size; - cur = cur_next; - } - last_pos = const_iterator(cur); - if (cur_next != end_n){ - this->erase_after(last_pos, const_iterator(end_n)); - return true; - } - else{ - return false; - } - } - - template<class U> - iterator priv_insert(const_iterator p, BOOST_FWD_REF(U) x) - { return this->insert_after(previous(p), ::boost::forward<U>(x)); } - - template<class U> - iterator priv_insert_after(const_iterator prev_p, BOOST_FWD_REF(U) x) - { return iterator(this->icont().insert_after(prev_p.get(), *this->create_node(::boost::forward<U>(x)))); } - - class insertion_functor; - friend class insertion_functor; - - class insertion_functor - { - Icont &icont_; - typedef typename Icont::iterator iiterator; - typedef typename Icont::const_iterator iconst_iterator; - const iconst_iterator prev_; - iiterator ret_; - - public: - insertion_functor(Icont &icont, typename Icont::const_iterator prev) - : icont_(icont), prev_(prev), ret_(prev.unconst()) - {} - - void operator()(Node &n) - { - ret_ = this->icont_.insert_after(prev_, n); - } - - iiterator inserted_first() const - { return ret_; } - }; - - //Functors for member algorithm defaults - typedef value_less<value_type> value_less_t; - typedef value_equal<value_type> value_equal_t; - - #endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED -}; - -#ifndef BOOST_CONTAINER_NO_CXX17_CTAD - -template <typename InpIt> -slist(InpIt, InpIt) -> - slist<typename iterator_traits<InpIt>::value_type>; - -template <typename InpIt, typename Allocator> -slist(InpIt, InpIt, Allocator const&) -> - slist<typename iterator_traits<InpIt>::value_type, Allocator>; - -#endif - -}} - -#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -namespace boost { - -//!has_trivial_destructor_after_move<> == true_type -//!specialization for optimizations -template <class T, class Allocator> -struct has_trivial_destructor_after_move<boost::container::slist<T, Allocator> > -{ - typedef typename boost::container::slist<T, Allocator>::allocator_type allocator_type; - typedef typename ::boost::container::allocator_traits<allocator_type>::pointer pointer; - static const bool value = ::boost::has_trivial_destructor_after_move<allocator_type>::value && - ::boost::has_trivial_destructor_after_move<pointer>::value; -}; - -namespace container { - -}} //namespace boost{ namespace container { - -#endif //#ifndef BOOST_CONTAINER_DOXYGEN_INVOKED - -// Specialization of insert_iterator so that insertions will be constant -// time rather than linear time. - -#include <boost/move/detail/std_ns_begin.hpp> -BOOST_CONTAINER_DOC1ST(namespace std {, BOOST_MOVE_STD_NS_BEG) - -//! A specialization of insert_iterator -//! that works with slist -template <class T, class ValueAllocator> -class insert_iterator<boost::container::slist<T, ValueAllocator> > -{ - private: - typedef boost::container::slist<T, ValueAllocator> Container; - Container* container; - typename Container::iterator iter; - - public: - typedef Container container_type; - typedef output_iterator_tag iterator_category; - typedef void value_type; - typedef void difference_type; - typedef void pointer; - typedef void reference; - - insert_iterator(Container& x, - typename Container::iterator i, - bool is_previous = false) - : container(&x), iter(is_previous ? i : x.previous(i)){ } - - insert_iterator<Container>& - operator=(const typename Container::value_type& value) - { - iter = container->insert_after(iter, value); - return *this; - } - insert_iterator<Container>& operator*(){ return *this; } - insert_iterator<Container>& operator++(){ return *this; } - insert_iterator<Container>& operator++(int){ return *this; } -}; - -BOOST_CONTAINER_DOC1ST( }, BOOST_MOVE_STD_NS_END) -#include <boost/move/detail/std_ns_end.hpp> - -#include <boost/container/detail/config_end.hpp> - -#endif // BOOST_CONTAINER_SLIST_HPP diff --git a/ThirdParty/boost/container_hash/extensions.hpp b/ThirdParty/boost/container_hash/extensions.hpp deleted file mode 100644 index 393b7020ef7ec8ea78a8fb1f64b6eba85e538779..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container_hash/extensions.hpp +++ /dev/null @@ -1,363 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// 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) - -// Based on Peter Dimov's proposal -// http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf -// issue 6.18. - -// This implements the extensions to the standard. -// It's undocumented, so you shouldn't use it.... - -#if !defined(BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP) -#define BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP - -#include <boost/config.hpp> -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -#include <boost/container_hash/hash.hpp> -#include <boost/detail/container_fwd.hpp> -#include <boost/core/enable_if.hpp> -#include <boost/static_assert.hpp> - -#if !defined(BOOST_NO_CXX11_HDR_ARRAY) -# include <array> -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) -# include <tuple> -#endif - -#if !defined(BOOST_NO_CXX11_HDR_MEMORY) -# include <memory> -#endif - -#if defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) -#include <boost/type_traits/is_array.hpp> -#endif - -namespace boost -{ - template <class A, class B> - std::size_t hash_value(std::pair<A, B> const&); - template <class T, class A> - std::size_t hash_value(std::vector<T, A> const&); - template <class T, class A> - std::size_t hash_value(std::list<T, A> const& v); - template <class T, class A> - std::size_t hash_value(std::deque<T, A> const& v); - template <class K, class C, class A> - std::size_t hash_value(std::set<K, C, A> const& v); - template <class K, class C, class A> - std::size_t hash_value(std::multiset<K, C, A> const& v); - template <class K, class T, class C, class A> - std::size_t hash_value(std::map<K, T, C, A> const& v); - template <class K, class T, class C, class A> - std::size_t hash_value(std::multimap<K, T, C, A> const& v); - - template <class T> - std::size_t hash_value(std::complex<T> const&); - - template <class A, class B> - std::size_t hash_value(std::pair<A, B> const& v) - { - std::size_t seed = 0; - boost::hash_combine(seed, v.first); - boost::hash_combine(seed, v.second); - return seed; - } - - template <class T, class A> - std::size_t hash_value(std::vector<T, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class T, class A> - std::size_t hash_value(std::list<T, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class T, class A> - std::size_t hash_value(std::deque<T, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class K, class C, class A> - std::size_t hash_value(std::set<K, C, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class K, class C, class A> - std::size_t hash_value(std::multiset<K, C, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class K, class T, class C, class A> - std::size_t hash_value(std::map<K, T, C, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class K, class T, class C, class A> - std::size_t hash_value(std::multimap<K, T, C, A> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template <class T> - std::size_t hash_value(std::complex<T> const& v) - { - boost::hash<T> hasher; - std::size_t seed = hasher(v.imag()); - seed ^= hasher(v.real()) + (seed<<6) + (seed>>2); - return seed; - } - -#if !defined(BOOST_NO_CXX11_HDR_ARRAY) - template <class T, std::size_t N> - std::size_t hash_value(std::array<T, N> const& v) - { - return boost::hash_range(v.begin(), v.end()); - } -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) - namespace hash_detail { - template <std::size_t I, typename T> - inline typename boost::enable_if_c<(I == std::tuple_size<T>::value), - void>::type - hash_combine_tuple(std::size_t&, T const&) - { - } - - template <std::size_t I, typename T> - inline typename boost::enable_if_c<(I < std::tuple_size<T>::value), - void>::type - hash_combine_tuple(std::size_t& seed, T const& v) - { - boost::hash_combine(seed, std::get<I>(v)); - boost::hash_detail::hash_combine_tuple<I + 1>(seed, v); - } - - template <typename T> - inline std::size_t hash_tuple(T const& v) - { - std::size_t seed = 0; - boost::hash_detail::hash_combine_tuple<0>(seed, v); - return seed; - } - } - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template <typename... T> - inline std::size_t hash_value(std::tuple<T...> const& v) - { - return boost::hash_detail::hash_tuple(v); - } -#else - - inline std::size_t hash_value(std::tuple<> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0> - inline std::size_t hash_value(std::tuple<A0> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1> - inline std::size_t hash_value(std::tuple<A0, A1> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2> - inline std::size_t hash_value(std::tuple<A0, A1, A2> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4, typename A5> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4, A5> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4, A5, A6> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4, A5, A6, A7> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4, A5, A6, A7, A8> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - - template<typename A0, typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> - inline std::size_t hash_value(std::tuple<A0, A1, A2, A3, A4, A5, A6, A7, A8, A9> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - -#endif - -#endif - -#if !defined(BOOST_NO_CXX11_SMART_PTR) - template <typename T> - inline std::size_t hash_value(std::shared_ptr<T> const& x) { - return boost::hash_value(x.get()); - } - - template <typename T, typename Deleter> - inline std::size_t hash_value(std::unique_ptr<T, Deleter> const& x) { - return boost::hash_value(x.get()); - } -#endif - - // - // call_hash_impl - // - - // On compilers without function template ordering, this deals with arrays. - -#if defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - namespace hash_detail - { - template <bool IsArray> - struct call_hash_impl - { - template <class T> - struct inner - { - static std::size_t call(T const& v) - { - using namespace boost; - return hash_value(v); - } - }; - }; - - template <> - struct call_hash_impl<true> - { - template <class Array> - struct inner - { - static std::size_t call(Array const& v) - { - const int size = sizeof(v) / sizeof(*v); - return boost::hash_range(v, v + size); - } - }; - }; - - template <class T> - struct call_hash - : public call_hash_impl<boost::is_array<T>::value> - ::BOOST_NESTED_TEMPLATE inner<T> - { - }; - } -#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - // - // boost::hash - // - - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - - template <class T> struct hash - : boost::hash_detail::hash_base<T> - { -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - std::size_t operator()(T const& val) const - { - return hash_value(val); - } -#else - std::size_t operator()(T const& val) const - { - return hash_detail::call_hash<T>::call(val); - } -#endif - }; - -#if BOOST_WORKAROUND(__DMC__, <= 0x848) - template <class T, unsigned int n> struct hash<T[n]> - : boost::hash_detail::hash_base<T[n]> - { - std::size_t operator()(const T* val) const - { - return boost::hash_range(val, val+n); - } - }; -#endif - -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // On compilers without partial specialization, boost::hash<T> - // has already been declared to deal with pointers, so just - // need to supply the non-pointer version of hash_impl. - - namespace hash_detail - { - template <bool IsPointer> - struct hash_impl; - - template <> - struct hash_impl<false> - { - template <class T> - struct inner - : boost::hash_detail::hash_base<T> - { -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - std::size_t operator()(T const& val) const - { - return hash_value(val); - } -#else - std::size_t operator()(T const& val) const - { - return hash_detail::call_hash<T>::call(val); - } -#endif - }; - }; - } -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -} - -#endif diff --git a/ThirdParty/boost/container_hash/hash.hpp b/ThirdParty/boost/container_hash/hash.hpp deleted file mode 100644 index 7aac2fab67eaacab9987840c0e2f630d6659e1bb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/container_hash/hash.hpp +++ /dev/null @@ -1,762 +0,0 @@ - -// Copyright 2005-2014 Daniel James. -// 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) - -// Based on Peter Dimov's proposal -// http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf -// issue 6.18. -// -// This also contains public domain code from MurmurHash. From the -// MurmurHash header: - -// MurmurHash3 was written by Austin Appleby, and is placed in the public -// domain. The author hereby disclaims copyright to this source code. - -#if !defined(BOOST_FUNCTIONAL_HASH_HASH_HPP) -#define BOOST_FUNCTIONAL_HASH_HASH_HPP - -#include <boost/container_hash/hash_fwd.hpp> -#include <functional> -#include <iterator> -#include <boost/container_hash/detail/hash_float.hpp> -#include <string> -#include <boost/limits.hpp> -#include <boost/type_traits/is_enum.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <boost/core/enable_if.hpp> -#include <boost/cstdint.hpp> - -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -#include <boost/type_traits/is_pointer.hpp> -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) -#include <typeindex> -#endif - -#if !defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) -#include <system_error> -#endif - -#if defined(BOOST_MSVC) -#pragma warning(push) - -#if BOOST_MSVC >= 1400 -#pragma warning(disable:6295) // Ill-defined for-loop : 'unsigned int' values - // are always of range '0' to '4294967295'. - // Loop executes infinitely. -#endif - -#endif - -#if BOOST_WORKAROUND(__GNUC__, < 3) \ - && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -#define BOOST_HASH_CHAR_TRAITS string_char_traits -#else -#define BOOST_HASH_CHAR_TRAITS char_traits -#endif - -#if defined(_MSC_VER) -# define BOOST_FUNCTIONAL_HASH_ROTL32(x, r) _rotl(x,r) -#else -# define BOOST_FUNCTIONAL_HASH_ROTL32(x, r) (x << r) | (x >> (32 - r)) -#endif - -// Detect whether standard library has C++17 headers - -#if !defined(BOOST_HASH_CXX17) -# if defined(BOOST_MSVC) -# if defined(_HAS_CXX17) && _HAS_CXX17 -# define BOOST_HASH_CXX17 1 -# endif -# elif defined(__cplusplus) && __cplusplus >= 201703 -# define BOOST_HASH_CXX17 1 -# endif -#endif - -#if !defined(BOOST_HASH_CXX17) -# define BOOST_HASH_CXX17 0 -#endif - -#if BOOST_HASH_CXX17 && defined(__has_include) -# if !defined(BOOST_HASH_HAS_STRING_VIEW) && __has_include(<string_view>) -# define BOOST_HASH_HAS_STRING_VIEW 1 -# endif -# if !defined(BOOST_HASH_HAS_OPTIONAL) && __has_include(<optional>) -# define BOOST_HASH_HAS_OPTIONAL 1 -# endif -# if !defined(BOOST_HASH_HAS_VARIANT) && __has_include(<variant>) -# define BOOST_HASH_HAS_VARIANT 1 -# endif -#endif - -#if !defined(BOOST_HASH_HAS_STRING_VIEW) -# define BOOST_HASH_HAS_STRING_VIEW 0 -#endif - -#if !defined(BOOST_HASH_HAS_OPTIONAL) -# define BOOST_HASH_HAS_OPTIONAL 0 -#endif - -#if !defined(BOOST_HASH_HAS_VARIANT) -# define BOOST_HASH_HAS_VARIANT 0 -#endif - -#if BOOST_HASH_HAS_STRING_VIEW -# include <string_view> -#endif - -#if BOOST_HASH_HAS_OPTIONAL -# include <optional> -#endif - -#if BOOST_HASH_HAS_VARIANT -# include <variant> -#endif - -namespace boost -{ - namespace hash_detail - { -#if defined(BOOST_NO_CXX98_FUNCTION_BASE) - template <typename T> - struct hash_base - { - typedef T argument_type; - typedef std::size_t result_type; - }; -#else - template <typename T> - struct hash_base : std::unary_function<T, std::size_t> {}; -#endif - - struct enable_hash_value { typedef std::size_t type; }; - - template <typename T> struct basic_numbers {}; - template <typename T> struct long_numbers; - template <typename T> struct ulong_numbers; - template <typename T> struct float_numbers {}; - - template <> struct basic_numbers<bool> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<char> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<unsigned char> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<signed char> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<short> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<unsigned short> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<int> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<unsigned int> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<long> : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers<unsigned long> : - boost::hash_detail::enable_hash_value {}; - -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) - template <> struct basic_numbers<wchar_t> : - boost::hash_detail::enable_hash_value {}; -#endif - -#if !defined(BOOST_NO_CXX11_CHAR16_T) - template <> struct basic_numbers<char16_t> : - boost::hash_detail::enable_hash_value {}; -#endif - -#if !defined(BOOST_NO_CXX11_CHAR32_T) - template <> struct basic_numbers<char32_t> : - boost::hash_detail::enable_hash_value {}; -#endif - - // long_numbers is defined like this to allow for separate - // specialization for long_long and int128_type, in case - // they conflict. - template <typename T> struct long_numbers2 {}; - template <typename T> struct ulong_numbers2 {}; - template <typename T> struct long_numbers : long_numbers2<T> {}; - template <typename T> struct ulong_numbers : ulong_numbers2<T> {}; - -#if !defined(BOOST_NO_LONG_LONG) - template <> struct long_numbers<boost::long_long_type> : - boost::hash_detail::enable_hash_value {}; - template <> struct ulong_numbers<boost::ulong_long_type> : - boost::hash_detail::enable_hash_value {}; -#endif - -#if defined(BOOST_HAS_INT128) - template <> struct long_numbers2<boost::int128_type> : - boost::hash_detail::enable_hash_value {}; - template <> struct ulong_numbers2<boost::uint128_type> : - boost::hash_detail::enable_hash_value {}; -#endif - - template <> struct float_numbers<float> : - boost::hash_detail::enable_hash_value {}; - template <> struct float_numbers<double> : - boost::hash_detail::enable_hash_value {}; - template <> struct float_numbers<long double> : - boost::hash_detail::enable_hash_value {}; - } - - template <typename T> - typename boost::hash_detail::basic_numbers<T>::type hash_value(T); - template <typename T> - typename boost::hash_detail::long_numbers<T>::type hash_value(T); - template <typename T> - typename boost::hash_detail::ulong_numbers<T>::type hash_value(T); - - template <typename T> - typename boost::enable_if<boost::is_enum<T>, std::size_t>::type - hash_value(T); - -#if !BOOST_WORKAROUND(__DMC__, <= 0x848) - template <class T> std::size_t hash_value(T* const&); -#else - template <class T> std::size_t hash_value(T*); -#endif - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - template< class T, unsigned N > - std::size_t hash_value(const T (&x)[N]); - - template< class T, unsigned N > - std::size_t hash_value(T (&x)[N]); -#endif - - template <class Ch, class A> - std::size_t hash_value( - std::basic_string<Ch, std::BOOST_HASH_CHAR_TRAITS<Ch>, A> const&); - -#if BOOST_HASH_HAS_STRING_VIEW - template <class Ch> - std::size_t hash_value( - std::basic_string_view<Ch, std::BOOST_HASH_CHAR_TRAITS<Ch> > const&); -#endif - - template <typename T> - typename boost::hash_detail::float_numbers<T>::type hash_value(T); - -#if BOOST_HASH_HAS_OPTIONAL - template <typename T> - std::size_t hash_value(std::optional<T> const&); -#endif - -#if BOOST_HASH_HAS_VARIANT - std::size_t hash_value(std::monostate); - template <typename... Types> - std::size_t hash_value(std::variant<Types...> const&); -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - std::size_t hash_value(std::type_index); -#endif - -#if !defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) - std::size_t hash_value(std::error_code const&); - std::size_t hash_value(std::error_condition const&); -#endif - - // Implementation - - namespace hash_detail - { - template <class T> - inline std::size_t hash_value_signed(T val) - { - const unsigned int size_t_bits = std::numeric_limits<std::size_t>::digits; - // ceiling(std::numeric_limits<T>::digits / size_t_bits) - 1 - const int length = (std::numeric_limits<T>::digits - 1) - / static_cast<int>(size_t_bits); - - std::size_t seed = 0; - T positive = val < 0 ? -1 - val : val; - - // Hopefully, this loop can be unrolled. - for(unsigned int i = length * size_t_bits; i > 0; i -= size_t_bits) - { - seed ^= (std::size_t) (positive >> i) + (seed<<6) + (seed>>2); - } - seed ^= (std::size_t) val + (seed<<6) + (seed>>2); - - return seed; - } - - template <class T> - inline std::size_t hash_value_unsigned(T val) - { - const unsigned int size_t_bits = std::numeric_limits<std::size_t>::digits; - // ceiling(std::numeric_limits<T>::digits / size_t_bits) - 1 - const int length = (std::numeric_limits<T>::digits - 1) - / static_cast<int>(size_t_bits); - - std::size_t seed = 0; - - // Hopefully, this loop can be unrolled. - for(unsigned int i = length * size_t_bits; i > 0; i -= size_t_bits) - { - seed ^= (std::size_t) (val >> i) + (seed<<6) + (seed>>2); - } - seed ^= (std::size_t) val + (seed<<6) + (seed>>2); - - return seed; - } - - template <typename SizeT> - inline void hash_combine_impl(SizeT& seed, SizeT value) - { - seed ^= value + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - - inline void hash_combine_impl(boost::uint32_t& h1, - boost::uint32_t k1) - { - const uint32_t c1 = 0xcc9e2d51; - const uint32_t c2 = 0x1b873593; - - k1 *= c1; - k1 = BOOST_FUNCTIONAL_HASH_ROTL32(k1,15); - k1 *= c2; - - h1 ^= k1; - h1 = BOOST_FUNCTIONAL_HASH_ROTL32(h1,13); - h1 = h1*5+0xe6546b64; - } - - -// Don't define 64-bit hash combine on platforms without 64 bit integers, -// and also not for 32-bit gcc as it warns about the 64-bit constant. -#if !defined(BOOST_NO_INT64_T) && \ - !(defined(__GNUC__) && ULONG_MAX == 0xffffffff) - - inline void hash_combine_impl(boost::uint64_t& h, - boost::uint64_t k) - { - const boost::uint64_t m = UINT64_C(0xc6a4a7935bd1e995); - const int r = 47; - - k *= m; - k ^= k >> r; - k *= m; - - h ^= k; - h *= m; - - // Completely arbitrary number, to prevent 0's - // from hashing to 0. - h += 0xe6546b64; - } - -#endif // BOOST_NO_INT64_T - } - - template <typename T> - typename boost::hash_detail::basic_numbers<T>::type hash_value(T v) - { - return static_cast<std::size_t>(v); - } - - template <typename T> - typename boost::hash_detail::long_numbers<T>::type hash_value(T v) - { - return hash_detail::hash_value_signed(v); - } - - template <typename T> - typename boost::hash_detail::ulong_numbers<T>::type hash_value(T v) - { - return hash_detail::hash_value_unsigned(v); - } - - template <typename T> - typename boost::enable_if<boost::is_enum<T>, std::size_t>::type - hash_value(T v) - { - return static_cast<std::size_t>(v); - } - - // Implementation by Alberto Barbati and Dave Harris. -#if !BOOST_WORKAROUND(__DMC__, <= 0x848) - template <class T> std::size_t hash_value(T* const& v) -#else - template <class T> std::size_t hash_value(T* v) -#endif - { -#if defined(__VMS) && __INITIAL_POINTER_SIZE == 64 - // for some reason ptrdiff_t on OpenVMS compiler with - // 64 bit is not 64 bit !!! - std::size_t x = static_cast<std::size_t>( - reinterpret_cast<long long int>(v)); -#else - std::size_t x = static_cast<std::size_t>( - reinterpret_cast<std::ptrdiff_t>(v)); -#endif - return x + (x >> 3); - } - -#if defined(BOOST_MSVC) -#pragma warning(push) -#if BOOST_MSVC <= 1400 -#pragma warning(disable:4267) // 'argument' : conversion from 'size_t' to - // 'unsigned int', possible loss of data - // A misguided attempt to detect 64-bit - // incompatability. -#endif -#endif - - template <class T> - inline void hash_combine(std::size_t& seed, T const& v) - { - boost::hash<T> hasher; - return boost::hash_detail::hash_combine_impl(seed, hasher(v)); - } - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - - template <class It> - inline std::size_t hash_range(It first, It last) - { - std::size_t seed = 0; - - for(; first != last; ++first) - { - hash_combine<typename std::iterator_traits<It>::value_type>(seed, *first); - } - - return seed; - } - - template <class It> - inline void hash_range(std::size_t& seed, It first, It last) - { - for(; first != last; ++first) - { - hash_combine<typename std::iterator_traits<It>::value_type>(seed, *first); - } - } - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x551)) - template <class T> - inline std::size_t hash_range(T* first, T* last) - { - std::size_t seed = 0; - - for(; first != last; ++first) - { - boost::hash<T> hasher; - seed ^= hasher(*first) + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - - return seed; - } - - template <class T> - inline void hash_range(std::size_t& seed, T* first, T* last) - { - for(; first != last; ++first) - { - boost::hash<T> hasher; - seed ^= hasher(*first) + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - } -#endif - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - template< class T, unsigned N > - inline std::size_t hash_value(const T (&x)[N]) - { - return hash_range(x, x + N); - } - - template< class T, unsigned N > - inline std::size_t hash_value(T (&x)[N]) - { - return hash_range(x, x + N); - } -#endif - - template <class Ch, class A> - inline std::size_t hash_value( - std::basic_string<Ch, std::BOOST_HASH_CHAR_TRAITS<Ch>, A> const& v) - { - return hash_range(v.begin(), v.end()); - } - -#if BOOST_HASH_HAS_STRING_VIEW - template <class Ch> - inline std::size_t hash_value( - std::basic_string_view<Ch, std::BOOST_HASH_CHAR_TRAITS<Ch> > const& v) - { - return hash_range(v.begin(), v.end()); - } -#endif - - template <typename T> - typename boost::hash_detail::float_numbers<T>::type hash_value(T v) - { - return boost::hash_detail::float_hash_value(v); - } - -#if BOOST_HASH_HAS_OPTIONAL - template <typename T> - inline std::size_t hash_value(std::optional<T> const& v) { - if (!v) { - // Arbitray value for empty optional. - return 0x12345678; - } else { - boost::hash<T> hf; - return hf(*v); - } - } -#endif - -#if BOOST_HASH_HAS_VARIANT - inline std::size_t hash_value(std::monostate) { - return 0x87654321; - } - - template <typename... Types> - inline std::size_t hash_value(std::variant<Types...> const& v) { - std::size_t seed = 0; - hash_combine(seed, v.index()); - std::visit([&seed](auto&& x) { hash_combine(seed, x); }, v); - return seed; - } -#endif - - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - inline std::size_t hash_value(std::type_index v) - { - return v.hash_code(); - } -#endif - -#if !defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) - inline std::size_t hash_value(std::error_code const& v) { - std::size_t seed = 0; - hash_combine(seed, v.value()); - hash_combine(seed, &v.category()); - return seed; - } - - inline std::size_t hash_value(std::error_condition const& v) { - std::size_t seed = 0; - hash_combine(seed, v.value()); - hash_combine(seed, &v.category()); - return seed; - } -#endif - - // - // boost::hash - // - - // Define the specializations required by the standard. The general purpose - // boost::hash is defined later in extensions.hpp if - // BOOST_HASH_NO_EXTENSIONS is not defined. - - // BOOST_HASH_SPECIALIZE - define a specialization for a type which is - // passed by copy. - // - // BOOST_HASH_SPECIALIZE_REF - define a specialization for a type which is - // passed by const reference. - // - // These are undefined later. - -#define BOOST_HASH_SPECIALIZE(type) \ - template <> struct hash<type> \ - : public boost::hash_detail::hash_base<type> \ - { \ - std::size_t operator()(type v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; - -#define BOOST_HASH_SPECIALIZE_REF(type) \ - template <> struct hash<type> \ - : public boost::hash_detail::hash_base<type> \ - { \ - std::size_t operator()(type const& v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; - -#define BOOST_HASH_SPECIALIZE_TEMPLATE_REF(type) \ - struct hash<type> \ - : public boost::hash_detail::hash_base<type> \ - { \ - std::size_t operator()(type const& v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; - - BOOST_HASH_SPECIALIZE(bool) - BOOST_HASH_SPECIALIZE(char) - BOOST_HASH_SPECIALIZE(signed char) - BOOST_HASH_SPECIALIZE(unsigned char) -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) - BOOST_HASH_SPECIALIZE(wchar_t) -#endif -#if !defined(BOOST_NO_CXX11_CHAR16_T) - BOOST_HASH_SPECIALIZE(char16_t) -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) - BOOST_HASH_SPECIALIZE(char32_t) -#endif - BOOST_HASH_SPECIALIZE(short) - BOOST_HASH_SPECIALIZE(unsigned short) - BOOST_HASH_SPECIALIZE(int) - BOOST_HASH_SPECIALIZE(unsigned int) - BOOST_HASH_SPECIALIZE(long) - BOOST_HASH_SPECIALIZE(unsigned long) - - BOOST_HASH_SPECIALIZE(float) - BOOST_HASH_SPECIALIZE(double) - BOOST_HASH_SPECIALIZE(long double) - - BOOST_HASH_SPECIALIZE_REF(std::string) -#if !defined(BOOST_NO_STD_WSTRING) && !defined(BOOST_NO_INTRINSIC_WCHAR_T) - BOOST_HASH_SPECIALIZE_REF(std::wstring) -#endif -#if !defined(BOOST_NO_CXX11_CHAR16_T) - BOOST_HASH_SPECIALIZE_REF(std::basic_string<char16_t>) -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) - BOOST_HASH_SPECIALIZE_REF(std::basic_string<char32_t>) -#endif - -#if BOOST_HASH_HAS_STRING_VIEW - BOOST_HASH_SPECIALIZE_REF(std::string_view) -# if !defined(BOOST_NO_STD_WSTRING) && !defined(BOOST_NO_INTRINSIC_WCHAR_T) - BOOST_HASH_SPECIALIZE_REF(std::wstring_view) -# endif -# if !defined(BOOST_NO_CXX11_CHAR16_T) - BOOST_HASH_SPECIALIZE_REF(std::basic_string_view<char16_t>) -# endif -# if !defined(BOOST_NO_CXX11_CHAR32_T) - BOOST_HASH_SPECIALIZE_REF(std::basic_string_view<char32_t>) -# endif -#endif - -#if !defined(BOOST_NO_LONG_LONG) - BOOST_HASH_SPECIALIZE(boost::long_long_type) - BOOST_HASH_SPECIALIZE(boost::ulong_long_type) -#endif - -#if defined(BOOST_HAS_INT128) - BOOST_HASH_SPECIALIZE(boost::int128_type) - BOOST_HASH_SPECIALIZE(boost::uint128_type) -#endif - -#if BOOST_HASH_HAS_OPTIONAL - template <typename T> - BOOST_HASH_SPECIALIZE_TEMPLATE_REF(std::optional<T>) -#endif - -#if !defined(BOOST_HASH_HAS_VARIANT) - template <typename... T> - BOOST_HASH_SPECIALIZE_TEMPLATE_REF(std::variant<T...>) - BOOST_HASH_SPECIALIZE(std::monostate) -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - BOOST_HASH_SPECIALIZE(std::type_index) -#endif - -#undef BOOST_HASH_SPECIALIZE -#undef BOOST_HASH_SPECIALIZE_REF -#undef BOOST_HASH_SPECIALIZE_TEMPLATE_REF - -// Specializing boost::hash for pointers. - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - - template <class T> - struct hash<T*> - : public boost::hash_detail::hash_base<T*> - { - std::size_t operator()(T* v) const - { -#if !BOOST_WORKAROUND(__SUNPRO_CC, <= 0x590) - return boost::hash_value(v); -#else - std::size_t x = static_cast<std::size_t>( - reinterpret_cast<std::ptrdiff_t>(v)); - - return x + (x >> 3); -#endif - } - }; - -#else - - // For compilers without partial specialization, we define a - // boost::hash for all remaining types. But hash_impl is only defined - // for pointers in 'extensions.hpp' - so when BOOST_HASH_NO_EXTENSIONS - // is defined there will still be a compile error for types not supported - // in the standard. - - namespace hash_detail - { - template <bool IsPointer> - struct hash_impl; - - template <> - struct hash_impl<true> - { - template <class T> - struct inner - : public boost::hash_detail::hash_base<T> - { - std::size_t operator()(T val) const - { -#if !BOOST_WORKAROUND(__SUNPRO_CC, <= 590) - return boost::hash_value(val); -#else - std::size_t x = static_cast<std::size_t>( - reinterpret_cast<std::ptrdiff_t>(val)); - - return x + (x >> 3); -#endif - } - }; - }; - } - - template <class T> struct hash - : public boost::hash_detail::hash_impl<boost::is_pointer<T>::value> - ::BOOST_NESTED_TEMPLATE inner<T> - { - }; - -#endif -} - -#undef BOOST_HASH_CHAR_TRAITS -#undef BOOST_FUNCTIONAL_HASH_ROTL32 - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#endif // BOOST_FUNCTIONAL_HASH_HASH_HPP - -// Include this outside of the include guards in case the file is included -// twice - once with BOOST_HASH_NO_EXTENSIONS defined, and then with it -// undefined. - -#if !defined(BOOST_HASH_NO_EXTENSIONS) \ - && !defined(BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP) -#include <boost/container_hash/extensions.hpp> -#endif diff --git a/ThirdParty/boost/core/alloc_construct.hpp b/ThirdParty/boost/core/alloc_construct.hpp deleted file mode 100644 index 7b87525449c3af2e7d1f119e3759f2cf5c8050cd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/alloc_construct.hpp +++ /dev/null @@ -1,245 +0,0 @@ -/* -Copyright 2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_ALLOC_CONSTRUCT_HPP -#define BOOST_CORE_ALLOC_CONSTRUCT_HPP - -#include <boost/core/noinit_adaptor.hpp> - -namespace boost { - -#if !defined(BOOST_NO_CXX11_ALLOCATOR) -template<class A, class T> -inline void -alloc_destroy(A& a, T* p) -{ - std::allocator_traits<A>::destroy(a, p); -} - -template<class A, class T> -inline void -alloc_destroy_n(A& a, T* p, std::size_t n) -{ - while (n > 0) { - std::allocator_traits<A>::destroy(a, p + --n); - } -} -#else -template<class A, class T> -inline void -alloc_destroy(A&, T* p) -{ - p->~T(); -} - -template<class A, class T> -inline void -alloc_destroy_n(A&, T* p, std::size_t n) -{ - while (n > 0) { - p[--n].~T(); - } -} -#endif - -namespace detail { - -template<class A, class T> -class alloc_destroyer { -public: - alloc_destroyer(A& a, T* p) BOOST_NOEXCEPT - : a_(a), - p_(p), - n_(0) { } - - ~alloc_destroyer() { - boost::alloc_destroy_n(a_, p_, n_); - } - - std::size_t& size() BOOST_NOEXCEPT { - return n_; - } - -private: - alloc_destroyer(const alloc_destroyer&); - alloc_destroyer& operator=(const alloc_destroyer&); - - A& a_; - T* p_; - std::size_t n_; -}; - -} /* detail */ - -#if !defined(BOOST_NO_CXX11_ALLOCATOR) -template<class A, class T> -inline void -alloc_construct(A& a, T* p) -{ - std::allocator_traits<A>::construct(a, p); -} - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -template<class A, class T, class U, class... V> -inline void -alloc_construct(A& a, T* p, U&& u, V&&... v) -{ - std::allocator_traits<A>::construct(a, p, std::forward<U>(u), - std::forward<V>(v)...); -} -#else -template<class A, class T, class U> -inline void -alloc_construct(A& a, T* p, U&& u) -{ - std::allocator_traits<A>::construct(a, p, std::forward<U>(u)); -} -#endif -#else -template<class A, class T, class U> -inline void -alloc_construct(A& a, T* p, const U& u) -{ - std::allocator_traits<A>::construct(a, p, u); -} - -template<class A, class T, class U> -inline void -alloc_construct(A& a, T* p, U& u) -{ - std::allocator_traits<A>::construct(a, p, u); -} -#endif - -template<class A, class T> -inline void -alloc_construct_n(A& a, T* p, std::size_t n) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; ++i) { - std::allocator_traits<A>::construct(a, p + i); - } - hold.size() = 0; -} - -template<class A, class T> -inline void -alloc_construct_n(A& a, T* p, std::size_t n, const T* l, std::size_t m) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; ++i) { - std::allocator_traits<A>::construct(a, p + i, l[i % m]); - } - hold.size() = 0; -} - -template<class A, class T, class I> -inline void -alloc_construct_n(A& a, T* p, std::size_t n, I b) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; void(++i), void(++b)) { - std::allocator_traits<A>::construct(a, p + i, *b); - } - hold.size() = 0; -} -#else -template<class A, class T> -inline void -alloc_construct(A&, T* p) -{ - ::new(static_cast<void*>(p)) T(); -} - -template<class A, class T> -inline void -alloc_construct(noinit_adaptor<A>&, T* p) -{ - ::new(static_cast<void*>(p)) T; -} - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -template<class A, class T, class U, class... V> -inline void -alloc_construct(A&, T* p, U&& u, V&&... v) -{ - ::new(static_cast<void*>(p)) T(std::forward<U>(u), std::forward<V>(v)...); -} -#else -template<class A, class T, class U> -inline void -alloc_construct(A& a, T* p, U&& u) -{ - ::new(static_cast<void*>(p)) T(std::forward<U>(u)); -} -#endif -#else -template<class A, class T, class U> -inline void -alloc_construct(A&, T* p, const U& u) -{ - ::new(static_cast<void*>(p)) T(u); -} - -template<class A, class T, class U> -inline void -alloc_construct(A&, T* p, U& u) -{ - ::new(static_cast<void*>(p)) T(u); -} -#endif - -template<class A, class T> -inline void -alloc_construct_n(A& a, T* p, std::size_t n) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; ++i) { - ::new(static_cast<void*>(p + i)) T(); - } - hold.size() = 0; -} - -template<class A, class T> -inline void -alloc_construct_n(noinit_adaptor<A>& a, T* p, std::size_t n) -{ - detail::alloc_destroyer<noinit_adaptor<A>, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; ++i) { - ::new(static_cast<void*>(p + i)) T; - } - hold.size() = 0; -} - -template<class A, class T> -inline void -alloc_construct_n(A& a, T* p, std::size_t n, const T* l, std::size_t m) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; ++i) { - ::new(static_cast<void*>(p + i)) T(l[i % m]); - } - hold.size() = 0; -} - -template<class A, class T, class I> -inline void -alloc_construct_n(A& a, T* p, std::size_t n, I b) -{ - detail::alloc_destroyer<A, T> hold(a, p); - for (std::size_t& i = hold.size(); i < n; void(++i), void(++b)) { - ::new(static_cast<void*>(p + i)) T(*b); - } - hold.size() = 0; -} -#endif - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/default_allocator.hpp b/ThirdParty/boost/core/default_allocator.hpp deleted file mode 100644 index 9fc3ea2604a5084e0a19105ae65c4171c2c97c5d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/default_allocator.hpp +++ /dev/null @@ -1,158 +0,0 @@ -/* -Copyright 2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_DEFAULT_ALLOCATOR_HPP -#define BOOST_CORE_DEFAULT_ALLOCATOR_HPP - -#include <boost/config.hpp> -#include <new> -#include <climits> - -#if defined(BOOST_LIBSTDCXX_VERSION) && BOOST_LIBSTDCXX_VERSION < 60000 -#define BOOST_CORE_NO_CXX11_ALLOCATOR -#endif - -namespace boost { - -#if defined(BOOST_NO_EXCEPTIONS) -BOOST_NORETURN void throw_exception(const std::exception&); -#endif - -namespace default_ { - -struct true_type { - typedef bool value_type; - typedef true_type type; - - BOOST_STATIC_CONSTANT(bool, value = true); - - BOOST_CONSTEXPR operator bool() const BOOST_NOEXCEPT { - return true; - } - - BOOST_CONSTEXPR bool operator()() const BOOST_NOEXCEPT { - return true; - } -}; - -template<class T> -struct add_reference { - typedef T& type; -}; - -template<> -struct add_reference<void> { - typedef void type; -}; - -template<> -struct add_reference<const void> { - typedef const void type; -}; - -template<class T> -struct default_allocator { - typedef T value_type; - typedef T* pointer; - typedef const T* const_pointer; - typedef typename add_reference<T>::type reference; - typedef typename add_reference<const T>::type const_reference; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - typedef true_type propagate_on_container_move_assignment; - typedef true_type is_always_equal; - - template<class U> - struct rebind { - typedef default_allocator<U> other; - }; - -#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) - default_allocator() = default; -#else - BOOST_CONSTEXPR default_allocator() BOOST_NOEXCEPT { } -#endif - - template<class U> - BOOST_CONSTEXPR default_allocator(const default_allocator<U>&) - BOOST_NOEXCEPT { } - -#if defined(PTRDIFF_MAX) && defined(SIZE_MAX) - BOOST_CONSTEXPR std::size_t max_size() const BOOST_NOEXCEPT { - return PTRDIFF_MAX < SIZE_MAX / sizeof(T) - ? PTRDIFF_MAX : SIZE_MAX / sizeof(T); - } -#else - BOOST_CONSTEXPR std::size_t max_size() const BOOST_NOEXCEPT { - return ~static_cast<std::size_t>(0) / sizeof(T); - } -#endif - -#if !defined(BOOST_NO_EXCEPTIONS) - T* allocate(std::size_t n) { - if (n > max_size()) { - throw std::bad_alloc(); - } - return static_cast<T*>(::operator new(sizeof(T) * n)); - } - - void deallocate(T* p, std::size_t) { - ::operator delete(p); - } -#else - T* allocate(std::size_t n) { - if (n > max_size()) { - boost::throw_exception(std::bad_alloc()); - } - void* p = ::operator new(sizeof(T) * n, std::nothrow); - if (!p) { - boost::throw_exception(std::bad_alloc()); - } - return static_cast<T*>(p); - } - - void deallocate(T* p, std::size_t) { - ::operator delete(p, std::nothrow); - } -#endif - -#if defined(BOOST_NO_CXX11_ALLOCATOR) || defined(BOOST_CORE_NO_CXX11_ALLOCATOR) - template<class U, class V> - void construct(U* p, const V& v) { - ::new(p) U(v); - } - - template<class U> - void destroy(U* p) { - p->~U(); - } -#endif -}; - -template<class T, class U> -BOOST_CONSTEXPR inline bool -operator==(const default_allocator<T>&, - const default_allocator<U>&) BOOST_NOEXCEPT -{ - return true; -} - -template<class T, class U> -BOOST_CONSTEXPR inline bool -operator!=(const default_allocator<T>&, - const default_allocator<U>&) BOOST_NOEXCEPT -{ - return false; -} - -} /* default_ */ - -using default_::default_allocator; - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/empty_value.hpp b/ThirdParty/boost/core/empty_value.hpp deleted file mode 100644 index 289b05bca655652ca4312fd1d54c7e4a300451cd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/empty_value.hpp +++ /dev/null @@ -1,146 +0,0 @@ -/* -Copyright 2018 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_EMPTY_VALUE_HPP -#define BOOST_CORE_EMPTY_VALUE_HPP - -#include <boost/config.hpp> -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#include <utility> -#endif - -#if defined(BOOST_GCC_VERSION) && (BOOST_GCC_VERSION >= 40700) -#define BOOST_DETAIL_EMPTY_VALUE_BASE -#elif defined(BOOST_INTEL) && defined(_MSC_VER) && (_MSC_VER >= 1800) -#define BOOST_DETAIL_EMPTY_VALUE_BASE -#elif defined(BOOST_MSVC) && (BOOST_MSVC >= 1800) -#define BOOST_DETAIL_EMPTY_VALUE_BASE -#elif defined(BOOST_CLANG) && !defined(__CUDACC__) -#if __has_feature(is_empty) && __has_feature(is_final) -#define BOOST_DETAIL_EMPTY_VALUE_BASE -#endif -#endif - -namespace boost { - -template<class T> -struct use_empty_value_base { - enum { -#if defined(BOOST_DETAIL_EMPTY_VALUE_BASE) - value = __is_empty(T) && !__is_final(T) -#else - value = false -#endif - }; -}; - -struct empty_init_t { }; - -namespace empty_ { - -template<class T, unsigned N = 0, - bool E = boost::use_empty_value_base<T>::value> -class empty_value { -public: - typedef T type; - -#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) - empty_value() = default; -#else - empty_value() { } -#endif - - empty_value(boost::empty_init_t) - : value_() { } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template<class... Args> - explicit empty_value(boost::empty_init_t, Args&&... args) - : value_(std::forward<Args>(args)...) { } -#else - template<class U> - empty_value(boost::empty_init_t, U&& value) - : value_(std::forward<U>(value)) { } -#endif -#else - template<class U> - empty_value(boost::empty_init_t, const U& value) - : value_(value) { } - - template<class U> - empty_value(boost::empty_init_t, U& value) - : value_(value) { } -#endif - - const T& get() const BOOST_NOEXCEPT { - return value_; - } - - T& get() BOOST_NOEXCEPT { - return value_; - } - -private: - T value_; -}; - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -template<class T, unsigned N> -class empty_value<T, N, true> - : T { -public: - typedef T type; - -#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) - empty_value() = default; -#else - empty_value() { } -#endif - - empty_value(boost::empty_init_t) - : T() { } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template<class... Args> - explicit empty_value(boost::empty_init_t, Args&&... args) - : T(std::forward<Args>(args)...) { } -#else - template<class U> - empty_value(boost::empty_init_t, U&& value) - : T(std::forward<U>(value)) { } -#endif -#else - template<class U> - empty_value(boost::empty_init_t, const U& value) - : T(value) { } - - template<class U> - empty_value(boost::empty_init_t, U& value) - : T(value) { } -#endif - - const T& get() const BOOST_NOEXCEPT { - return *this; - } - - T& get() BOOST_NOEXCEPT { - return *this; - } -}; -#endif - -} /* empty_ */ - -using empty_::empty_value; - -BOOST_INLINE_CONSTEXPR empty_init_t empty_init = empty_init_t(); - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/first_scalar.hpp b/ThirdParty/boost/core/first_scalar.hpp deleted file mode 100644 index 5373542e028d933aed699c3c37f3978b47613308..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/first_scalar.hpp +++ /dev/null @@ -1,45 +0,0 @@ -/* -Copyright 2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_FIRST_SCALAR_HPP -#define BOOST_CORE_FIRST_SCALAR_HPP - -#include <boost/config.hpp> -#include <cstddef> - -namespace boost { -namespace detail { - -template<class T> -struct make_scalar { - typedef T type; -}; - -template<class T, std::size_t N> -struct make_scalar<T[N]> { - typedef typename make_scalar<T>::type type; -}; - -} /* detail */ - -template<class T> -BOOST_CONSTEXPR inline T* -first_scalar(T* p) BOOST_NOEXCEPT -{ - return p; -} - -template<class T, std::size_t N> -BOOST_CONSTEXPR inline typename detail::make_scalar<T>::type* -first_scalar(T (*p)[N]) BOOST_NOEXCEPT -{ - return boost::first_scalar(&(*p)[0]); -} - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/lightweight_test.hpp b/ThirdParty/boost/core/lightweight_test.hpp deleted file mode 100644 index 49ff6267ed25aacc49bab1fe1e508b0d3dd94574..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/lightweight_test.hpp +++ /dev/null @@ -1,467 +0,0 @@ -#ifndef BOOST_CORE_LIGHTWEIGHT_TEST_HPP -#define BOOST_CORE_LIGHTWEIGHT_TEST_HPP - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) -# pragma once -#endif - -// -// boost/core/lightweight_test.hpp - lightweight test library -// -// Copyright (c) 2002, 2009, 2014 Peter Dimov -// Copyright (2) Beman Dawes 2010, 2011 -// Copyright (3) Ion Gaztanaga 2013 -// -// Copyright 2018 Glen Joseph Fernandes -// (glenjofe@gmail.com) -// -// 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/current_function.hpp> -#include <boost/config.hpp> -#include <iostream> -#include <iterator> -#include <cstdlib> -#include <cstring> -#include <cstddef> - -#if defined(_MSC_VER) && defined(_CPPLIB_VER) && defined(_DEBUG) -# include <crtdbg.h> -#endif - -// IDE's like Visual Studio perform better if output goes to std::cout or -// some other stream, so allow user to configure output stream: -#ifndef BOOST_LIGHTWEIGHT_TEST_OSTREAM -# define BOOST_LIGHTWEIGHT_TEST_OSTREAM std::cerr -#endif - -namespace boost -{ - -namespace detail -{ - -class test_result { -public: - test_result() - : report_(false) - , errors_(0) { -#if defined(_MSC_VER) && (_MSC_VER > 1310) - // disable message boxes on assert(), abort() - ::_set_abort_behavior(0, _WRITE_ABORT_MSG | _CALL_REPORTFAULT); -#endif -#if defined(_MSC_VER) && defined(_CPPLIB_VER) && defined(_DEBUG) - // disable message boxes on iterator debugging violations - _CrtSetReportMode( _CRT_ASSERT, _CRTDBG_MODE_FILE ); - _CrtSetReportFile( _CRT_ASSERT, _CRTDBG_FILE_STDERR ); -#endif - } - - ~test_result() { - if (!report_) { - BOOST_LIGHTWEIGHT_TEST_OSTREAM << "main() should return report_errors()" << std::endl; - std::abort(); - } - } - - int& errors() { - return errors_; - } - - void done() { - report_ = true; - } - -private: - bool report_; - int errors_; -}; - -inline test_result& test_results() -{ - static test_result instance; - return instance; -} - -inline int& test_errors() -{ - return test_results().errors(); -} - -inline bool test_impl(char const * expr, char const * file, int line, char const * function, bool v) -{ - if( v ) - { - test_results(); - return true; - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): test '" << expr << "' failed in function '" - << function << "'" << std::endl; - ++test_results().errors(); - return false; - } -} - -inline void error_impl(char const * msg, char const * file, int line, char const * function) -{ - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): " << msg << " in function '" - << function << "'" << std::endl; - ++test_results().errors(); -} - -inline void throw_failed_impl(char const * excep, char const * file, int line, char const * function) -{ - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): Exception '" << excep << "' not thrown in function '" - << function << "'" << std::endl; - ++test_results().errors(); -} - -// In the comparisons below, it is possible that T and U are signed and unsigned integer types, which generates warnings in some compilers. -// A cleaner fix would require common_type trait or some meta-programming, which would introduce a dependency on Boost.TypeTraits. To avoid -// the dependency we just disable the warnings. -#if defined(__clang__) && defined(__has_warning) -# if __has_warning("-Wsign-compare") -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Wsign-compare" -# endif -#elif defined(_MSC_VER) -# pragma warning(push) -# pragma warning(disable: 4389) -#elif defined(__GNUC__) && !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) && (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 -# pragma GCC diagnostic push -# pragma GCC diagnostic ignored "-Wsign-compare" -#endif - -// specialize test output for char pointers to avoid printing as cstring -template <class T> inline const T& test_output_impl(const T& v) { return v; } -inline const void* test_output_impl(const char* v) { return v; } -inline const void* test_output_impl(const unsigned char* v) { return v; } -inline const void* test_output_impl(const signed char* v) { return v; } -inline const void* test_output_impl(char* v) { return v; } -inline const void* test_output_impl(unsigned char* v) { return v; } -inline const void* test_output_impl(signed char* v) { return v; } -template<class T> inline const void* test_output_impl(T volatile* v) { return const_cast<T*>(v); } - -#if !defined( BOOST_NO_CXX11_NULLPTR ) -inline const void* test_output_impl(std::nullptr_t) { return nullptr; } -#endif - -struct lw_test_eq { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t == u; } - static const char* op() { return "=="; } -}; - -struct lw_test_ne { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t != u; } - static const char* op() { return "!="; } -}; - -struct lw_test_lt { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t < u; } - static const char* op() { return "<"; } -}; - -struct lw_test_le { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t <= u; } - static const char* op() { return "<="; } -}; - -struct lw_test_gt { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t > u; } - static const char* op() { return ">"; } -}; - -struct lw_test_ge { - template <typename T, typename U> - bool operator()(const T& t, const U& u) const { return t >= u; } - static const char* op() { return ">="; } -}; - -template<class BinaryPredicate, class T, class U> -inline bool test_with_impl(BinaryPredicate pred, char const * expr1, char const * expr2, - char const * file, int line, char const * function, - T const & t, U const & u) -{ - if( pred(t, u) ) - { - test_results(); - return true; - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): test '" << expr1 << " " << pred.op() << " " << expr2 - << "' ('" << test_output_impl(t) << "' " << pred.op() << " '" << test_output_impl(u) - << "') failed in function '" << function << "'" << std::endl; - ++test_results().errors(); - return false; - } -} - -inline bool test_cstr_eq_impl( char const * expr1, char const * expr2, - char const * file, int line, char const * function, char const * const t, char const * const u ) -{ - if( std::strcmp(t, u) == 0 ) - { - test_results(); - return true; - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): test '" << expr1 << " == " << expr2 << "' ('" << t - << "' == '" << u << "') failed in function '" << function << "'" << std::endl; - ++test_results().errors(); - return false; - } -} - -inline bool test_cstr_ne_impl( char const * expr1, char const * expr2, - char const * file, int line, char const * function, char const * const t, char const * const u ) -{ - if( std::strcmp(t, u) != 0 ) - { - test_results(); - return true; - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): test '" << expr1 << " != " << expr2 << "' ('" << t - << "' != '" << u << "') failed in function '" << function << "'" << std::endl; - ++test_results().errors(); - return false; - } -} - -template<class FormattedOutputFunction, class InputIterator1, class InputIterator2> -bool test_all_eq_impl(FormattedOutputFunction& output, - char const * file, int line, char const * function, - InputIterator1 first_begin, InputIterator1 first_end, - InputIterator2 second_begin, InputIterator2 second_end) -{ - InputIterator1 first_it = first_begin; - InputIterator2 second_it = second_begin; - typename std::iterator_traits<InputIterator1>::difference_type first_index = 0; - typename std::iterator_traits<InputIterator2>::difference_type second_index = 0; - std::size_t error_count = 0; - const std::size_t max_count = 8; - do - { - while ((first_it != first_end) && (second_it != second_end) && (*first_it == *second_it)) - { - ++first_it; - ++second_it; - ++first_index; - ++second_index; - } - if ((first_it == first_end) || (second_it == second_end)) - { - break; // do-while - } - if (error_count == 0) - { - output << file << "(" << line << "): Container contents differ in function '" << function << "':"; - } - else if (error_count >= max_count) - { - output << " ..."; - break; - } - output << " [" << first_index << "] '" << test_output_impl(*first_it) << "' != '" << test_output_impl(*second_it) << "'"; - ++first_it; - ++second_it; - ++first_index; - ++second_index; - ++error_count; - } while (first_it != first_end); - - first_index += std::distance(first_it, first_end); - second_index += std::distance(second_it, second_end); - if (first_index != second_index) - { - if (error_count == 0) - { - output << file << "(" << line << "): Container sizes differ in function '" << function << "': size(" << first_index << ") != size(" << second_index << ")"; - } - else - { - output << " [*] size(" << first_index << ") != size(" << second_index << ")"; - } - ++error_count; - } - - if (error_count == 0) - { - test_results(); - return true; - } - else - { - output << std::endl; - ++test_results().errors(); - return false; - } -} - -template<class FormattedOutputFunction, class InputIterator1, class InputIterator2, typename BinaryPredicate> -bool test_all_with_impl(FormattedOutputFunction& output, - char const * file, int line, char const * function, - InputIterator1 first_begin, InputIterator1 first_end, - InputIterator2 second_begin, InputIterator2 second_end, - BinaryPredicate predicate) -{ - InputIterator1 first_it = first_begin; - InputIterator2 second_it = second_begin; - typename std::iterator_traits<InputIterator1>::difference_type first_index = 0; - typename std::iterator_traits<InputIterator2>::difference_type second_index = 0; - std::size_t error_count = 0; - const std::size_t max_count = 8; - do - { - while ((first_it != first_end) && (second_it != second_end) && predicate(*first_it, *second_it)) - { - ++first_it; - ++second_it; - ++first_index; - ++second_index; - } - if ((first_it == first_end) || (second_it == second_end)) - { - break; // do-while - } - if (error_count == 0) - { - output << file << "(" << line << "): Container contents differ in function '" << function << "':"; - } - else if (error_count >= max_count) - { - output << " ..."; - break; - } - output << " [" << first_index << "]"; - ++first_it; - ++second_it; - ++first_index; - ++second_index; - ++error_count; - } while (first_it != first_end); - - first_index += std::distance(first_it, first_end); - second_index += std::distance(second_it, second_end); - if (first_index != second_index) - { - if (error_count == 0) - { - output << file << "(" << line << "): Container sizes differ in function '" << function << "': size(" << first_index << ") != size(" << second_index << ")"; - } - else - { - output << " [*] size(" << first_index << ") != size(" << second_index << ")"; - } - ++error_count; - } - - if (error_count == 0) - { - test_results(); - return true; - } - else - { - output << std::endl; - ++test_results().errors(); - return false; - } -} - -#if defined(__clang__) && defined(__has_warning) -# if __has_warning("-Wsign-compare") -# pragma clang diagnostic pop -# endif -#elif defined(_MSC_VER) -# pragma warning(pop) -#elif defined(__GNUC__) && !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) && (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 -# pragma GCC diagnostic pop -#endif - -} // namespace detail - -inline int report_errors() -{ - boost::detail::test_result& result = boost::detail::test_results(); - result.done(); - - int errors = result.errors(); - - if( errors == 0 ) - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << "No errors detected." << std::endl; - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << errors << " error" << (errors == 1? "": "s") << " detected." << std::endl; - } - - // `return report_errors();` from main only supports 8 bit exit codes - return errors < 256? errors: 255; -} - -} // namespace boost - -#define BOOST_TEST(expr) ( ::boost::detail::test_impl(#expr, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, (expr)? true: false) ) -#define BOOST_TEST_NOT(expr) BOOST_TEST(!(expr)) - -#define BOOST_ERROR(msg) ( ::boost::detail::error_impl(msg, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION) ) - -#define BOOST_TEST_EQ(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_eq(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) -#define BOOST_TEST_NE(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_ne(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) - -#define BOOST_TEST_LT(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_lt(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) -#define BOOST_TEST_LE(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_le(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) -#define BOOST_TEST_GT(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_gt(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) -#define BOOST_TEST_GE(expr1,expr2) ( ::boost::detail::test_with_impl(::boost::detail::lw_test_ge(), #expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) - -#define BOOST_TEST_CSTR_EQ(expr1,expr2) ( ::boost::detail::test_cstr_eq_impl(#expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) -#define BOOST_TEST_CSTR_NE(expr1,expr2) ( ::boost::detail::test_cstr_ne_impl(#expr1, #expr2, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, expr1, expr2) ) - -#define BOOST_TEST_ALL_EQ(begin1, end1, begin2, end2) ( ::boost::detail::test_all_eq_impl(BOOST_LIGHTWEIGHT_TEST_OSTREAM, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, begin1, end1, begin2, end2) ) -#define BOOST_TEST_ALL_WITH(begin1, end1, begin2, end2, predicate) ( ::boost::detail::test_all_with_impl(BOOST_LIGHTWEIGHT_TEST_OSTREAM, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION, begin1, end1, begin2, end2, predicate) ) - -#ifndef BOOST_NO_EXCEPTIONS - #define BOOST_TEST_THROWS( EXPR, EXCEP ) \ - try { \ - EXPR; \ - ::boost::detail::throw_failed_impl \ - (#EXCEP, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION); \ - } \ - catch(EXCEP const&) { \ - ::boost::detail::test_results(); \ - } \ - catch(...) { \ - ::boost::detail::throw_failed_impl \ - (#EXCEP, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION); \ - } \ - // -#else - #define BOOST_TEST_THROWS( EXPR, EXCEP ) -#endif - -#endif // #ifndef BOOST_CORE_LIGHTWEIGHT_TEST_HPP diff --git a/ThirdParty/boost/core/lightweight_test_trait.hpp b/ThirdParty/boost/core/lightweight_test_trait.hpp deleted file mode 100644 index 26042c619da4706f4f57a1152de97d11e4aa417a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/lightweight_test_trait.hpp +++ /dev/null @@ -1,131 +0,0 @@ -#ifndef BOOST_CORE_LIGHTWEIGHT_TEST_TRAIT_HPP -#define BOOST_CORE_LIGHTWEIGHT_TEST_TRAIT_HPP - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) -# pragma once -#endif - -// boost/core/lightweight_test_trait.hpp -// -// BOOST_TEST_TRAIT_TRUE, BOOST_TEST_TRAIT_FALSE, BOOST_TEST_TRAIT_SAME -// -// Copyright 2014 Peter Dimov -// -// Copyright 2019 Glen Joseph Fernandes -// (glenjofe@gmail.com) -// -// 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/core/lightweight_test.hpp> -#include <boost/core/typeinfo.hpp> -#include <boost/core/is_same.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -template<class, int = 0> struct test_print { }; - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<T, 2>) -{ - return o << boost::core::demangled_name(BOOST_CORE_TYPEID(T)); -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<T, 1>) -{ - return o << test_print<T, 2>(); -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<const T, 1>) -{ - return o << test_print<T, 2>() << " const"; -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<volatile T, 1>) -{ - return o << test_print<T, 2>() << " volatile"; -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<const volatile T, 1>) -{ - return o << test_print<T, 2>() << " const volatile"; -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<T>) -{ - return o << test_print<T, 1>(); -} - -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<T&>) -{ - return o << test_print<T, 1>() << " &"; -} - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -template<class T> inline std::ostream& operator<<(std::ostream& o, test_print<T&&>) -{ - return o << test_print<T, 1>() << " &&"; -} -#endif - -template< class T > inline void test_trait_impl( char const * trait, void (*)( T ), - bool expected, char const * file, int line, char const * function ) -{ - if( T::value == expected ) - { - test_results(); - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): predicate '" << trait << "' [" - << boost::core::demangled_name( BOOST_CORE_TYPEID(T) ) << "]" - << " test failed in function '" << function - << "' (should have been " << ( expected? "true": "false" ) << ")" - << std::endl; - - ++test_results().errors(); - } -} - -template<class T> inline bool test_trait_same_impl_( T ) -{ - return T::value; -} - -template<class T1, class T2> inline void test_trait_same_impl( char const * types, - boost::core::is_same<T1, T2> same, char const * file, int line, char const * function ) -{ - if( test_trait_same_impl_( same ) ) - { - test_results(); - } - else - { - BOOST_LIGHTWEIGHT_TEST_OSTREAM - << file << "(" << line << "): test 'is_same<" << types << ">'" - << " failed in function '" << function - << "' ('" << test_print<T1>() - << "' != '" << test_print<T2>() << "')" - << std::endl; - - ++test_results().errors(); - } -} - -} // namespace detail - -} // namespace boost - -#define BOOST_TEST_TRAIT_TRUE(type) ( ::boost::detail::test_trait_impl(#type, (void(*)type)0, true, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION) ) -#define BOOST_TEST_TRAIT_FALSE(type) ( ::boost::detail::test_trait_impl(#type, (void(*)type)0, false, __FILE__, __LINE__, BOOST_CURRENT_FUNCTION) ) -#define BOOST_TEST_TRAIT_SAME(...) ( ::boost::detail::test_trait_same_impl(#__VA_ARGS__, ::boost::core::is_same<__VA_ARGS__>(), __FILE__, __LINE__, BOOST_CURRENT_FUNCTION) ) - -#endif // #ifndef BOOST_CORE_LIGHTWEIGHT_TEST_TRAIT_HPP diff --git a/ThirdParty/boost/core/no_exceptions_support.hpp b/ThirdParty/boost/core/no_exceptions_support.hpp deleted file mode 100644 index 6fd76b241a631d35d43df4488b15b858036d31bb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/no_exceptions_support.hpp +++ /dev/null @@ -1,56 +0,0 @@ -#ifndef BOOST_CORE_NO_EXCEPTIONS_SUPPORT_HPP -#define BOOST_CORE_NO_EXCEPTIONS_SUPPORT_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -//---------------------------------------------------------------------- -// (C) Copyright 2004 Pavel Vozenilek. -// Use, modification and distribution is subject to 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) -// -// -// This file contains helper macros used when exception support may be -// disabled (as indicated by macro BOOST_NO_EXCEPTIONS). -// -// Before picking up these macros you may consider using RAII techniques -// to deal with exceptions - their syntax can be always the same with -// or without exception support enabled. -//---------------------------------------------------------------------- - -#include <boost/config.hpp> -#include <boost/config/workaround.hpp> - -#if !(defined BOOST_NO_EXCEPTIONS) -# define BOOST_TRY { try -# define BOOST_CATCH(x) catch(x) -# define BOOST_RETHROW throw; -# define BOOST_CATCH_END } -#else -# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -# define BOOST_TRY { if ("") -# define BOOST_CATCH(x) else if (!"") -# elif !defined(BOOST_MSVC) || BOOST_MSVC >= 1900 -# define BOOST_TRY { if (true) -# define BOOST_CATCH(x) else if (false) -# else - // warning C4127: conditional expression is constant -# define BOOST_TRY { \ - __pragma(warning(push)) \ - __pragma(warning(disable: 4127)) \ - if (true) \ - __pragma(warning(pop)) -# define BOOST_CATCH(x) else \ - __pragma(warning(push)) \ - __pragma(warning(disable: 4127)) \ - if (false) \ - __pragma(warning(pop)) -# endif -# define BOOST_RETHROW -# define BOOST_CATCH_END } -#endif - - -#endif diff --git a/ThirdParty/boost/core/noinit_adaptor.hpp b/ThirdParty/boost/core/noinit_adaptor.hpp deleted file mode 100644 index 22c9aaba4e2ca3f0317af7ae3e175f324efa2013..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/noinit_adaptor.hpp +++ /dev/null @@ -1,112 +0,0 @@ -/* -Copyright 2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_NOINIT_ADAPTOR_HPP -#define BOOST_CORE_NOINIT_ADAPTOR_HPP - -#include <boost/config.hpp> -#if !defined(BOOST_NO_CXX11_ALLOCATOR) -#include <memory> -#endif -#include <new> -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#include <utility> -#endif - -namespace boost { - -template<class A> -struct noinit_adaptor - : A { - template<class U> - struct rebind { -#if !defined(BOOST_NO_CXX11_ALLOCATOR) - typedef noinit_adaptor<typename std::allocator_traits<A>::template - rebind_alloc<U> > other; -#else - typedef noinit_adaptor<typename A::template rebind<U>::other> other; -#endif - }; - - noinit_adaptor() - : A() { } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template<class U> - noinit_adaptor(U&& u) BOOST_NOEXCEPT - : A(std::forward<U>(u)) { } -#else - template<class U> - noinit_adaptor(const U& u) BOOST_NOEXCEPT - : A(u) { } -#endif - - template<class U> - noinit_adaptor(const noinit_adaptor<U>& u) BOOST_NOEXCEPT - : A(static_cast<const U&>(u)) { } - - template<class U> - void construct(U* p) { - ::new((void*)p) U; - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template<class U, class V, class... Args> - void construct(U* p, V&& v, Args&&... args) { - ::new((void*)p) U(std::forward<V>(v), std::forward<Args>(args)...); - } -#else - template<class U, class V> - void construct(U* p, V&& v) { - ::new((void*)p) U(std::forward<V>(v)); - } -#endif -#else - template<class U, class V> - void construct(U* p, const V& v) { - ::new((void*)p) U(v); - } - - template<class U, class V> - void construct(U* p, V& v) { - ::new((void*)p) U(v); - } -#endif - - template<class U> - void destroy(U* p) { - p->~U(); - } -}; - -template<class T, class U> -inline bool -operator==(const noinit_adaptor<T>& lhs, - const noinit_adaptor<U>& rhs) BOOST_NOEXCEPT -{ - return static_cast<const T&>(lhs) == static_cast<const U&>(rhs); -} - -template<class T, class U> -inline bool -operator!=(const noinit_adaptor<T>& lhs, - const noinit_adaptor<U>& rhs) BOOST_NOEXCEPT -{ - return !(lhs == rhs); -} - -template<class A> -inline noinit_adaptor<A> -noinit_adapt(const A& a) BOOST_NOEXCEPT -{ - return noinit_adaptor<A>(a); -} - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/nvp.hpp b/ThirdParty/boost/core/nvp.hpp deleted file mode 100644 index 8826a5929e8d37d1aa10abea8e4b2c41dd83e2d0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/nvp.hpp +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright 2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_NVP_HPP -#define BOOST_CORE_NVP_HPP - -#include <boost/core/addressof.hpp> -#include <boost/config.hpp> - -namespace boost { -namespace serialization { - -template<class T> -class nvp { -public: - nvp(const char* n, T& v) BOOST_NOEXCEPT - : n_(n) - , v_(boost::addressof(v)) { } - - const char* name() const BOOST_NOEXCEPT { - return n_; - } - - T& value() const BOOST_NOEXCEPT { - return *v_; - } - - const T& const_value() const BOOST_NOEXCEPT { - return *v_; - } - -private: - const char* n_; - T* v_; -}; - -template<class T> -inline const nvp<T> -make_nvp(const char* n, T& v) BOOST_NOEXCEPT -{ - return nvp<T>(n, v); -} - -} /* serialization */ - -using serialization::nvp; -using serialization::make_nvp; - -} /* boost */ - -#define BOOST_NVP(v) boost::make_nvp(BOOST_STRINGIZE(v), v) - -#endif diff --git a/ThirdParty/boost/core/pointer_traits.hpp b/ThirdParty/boost/core/pointer_traits.hpp deleted file mode 100644 index e66194d603d598e103a1e223c4fa6bcb27fa3362..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/pointer_traits.hpp +++ /dev/null @@ -1,234 +0,0 @@ -/* -Copyright 2017-2018 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_CORE_POINTER_TRAITS_HPP -#define BOOST_CORE_POINTER_TRAITS_HPP - -#include <boost/config.hpp> -#if !defined(BOOST_NO_CXX11_POINTER_TRAITS) -#include <memory> -#else -#include <boost/core/addressof.hpp> -#include <cstddef> -#endif - -namespace boost { - -#if !defined(BOOST_NO_CXX11_POINTER_TRAITS) -template<class T> -struct pointer_traits - : std::pointer_traits<T> { - template<class U> - struct rebind_to { - typedef typename std::pointer_traits<T>::template rebind<U> type; - }; -}; - -template<class T> -struct pointer_traits<T*> - : std::pointer_traits<T*> { - template<class U> - struct rebind_to { - typedef U* type; - }; -}; -#else -namespace detail { - -template<class> -struct ptr_void { - typedef void type; -}; - -template<class T> -struct ptr_first; - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -template<template<class, class...> class T, class U, class... Args> -struct ptr_first<T<U, Args...> > { - typedef U type; -}; -#else -template<template<class> class T, class U> -struct ptr_first<T<U> > { - typedef U type; -}; - -template<template<class, class> class T, class U1, class U2> -struct ptr_first<T<U1, U2> > { - typedef U1 type; -}; - -template<template<class, class, class> class T, class U1, class U2, class U3> -struct ptr_first<T<U1, U2, U3> > { - typedef U1 type; -}; -#endif - -template<class T, class = void> -struct ptr_element { - typedef typename ptr_first<T>::type type; -}; - -template<class T> -struct ptr_element<T, typename ptr_void<typename T::element_type>::type> { - typedef typename T::element_type type; -}; - -template<class, class = void> -struct ptr_difference { - typedef std::ptrdiff_t type; -}; - -template<class T> -struct ptr_difference<T, - typename ptr_void<typename T::difference_type>::type> { - typedef typename T::difference_type type; -}; - -template<class T, class V> -struct ptr_transform; - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -template<template<class, class...> class T, class U, class... Args, class V> -struct ptr_transform<T<U, Args...>, V> { - typedef T<V, Args...> type; -}; -#else -template<template<class> class T, class U, class V> -struct ptr_transform<T<U>, V> { - typedef T<V> type; -}; - -template<template<class, class> class T, class U1, class U2, class V> -struct ptr_transform<T<U1, U2>, V> { - typedef T<V, U2> type; -}; - -template<template<class, class, class> class T, - class U1, class U2, class U3, class V> -struct ptr_transform<T<U1, U2, U3>, V> { - typedef T<V, U2, U3> type; -}; -#endif - -template<class T, class U, class = void> -struct ptr_rebind { - typedef typename ptr_transform<T, U>::type type; -}; - -#if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) -template<class T, class U> -struct ptr_rebind<T, U, - typename ptr_void<typename T::template rebind<U> >::type> { - typedef typename T::template rebind<U> type; -}; -#endif - -template<class T> -struct ptr_value { - typedef T type; -}; - -template<> -struct ptr_value<void> { - typedef struct { } type; -}; - -} /* detail */ - -template<class T> -struct pointer_traits { - typedef T pointer; - typedef typename detail::ptr_element<T>::type element_type; - typedef typename detail::ptr_difference<T>::type difference_type; - template<class U> - struct rebind_to { - typedef typename detail::ptr_rebind<T, U>::type type; - }; -#if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - template<class U> - using rebind = typename detail::ptr_rebind<T, U>::type; -#endif - static pointer - pointer_to(typename detail::ptr_value<element_type>::type& v) { - return pointer::pointer_to(v); - } -}; - -template<class T> -struct pointer_traits<T*> { - typedef T* pointer; - typedef T element_type; - typedef std::ptrdiff_t difference_type; - template<class U> - struct rebind_to { - typedef U* type; - }; -#if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - template<class U> - using rebind = U*; -#endif - static T* - pointer_to(typename detail::ptr_value<T>::type& v) BOOST_NOEXCEPT { - return boost::addressof(v); - } -}; -#endif - -template<class T> -BOOST_CONSTEXPR inline T* -to_address(T* v) BOOST_NOEXCEPT -{ - return v; -} - -#if !defined(BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION) -namespace detail { - -template<class T> -inline T* -ptr_address(T* v, int) BOOST_NOEXCEPT -{ - return v; -} - -template<class T> -inline auto -ptr_address(const T& v, int) BOOST_NOEXCEPT --> decltype(boost::pointer_traits<T>::to_address(v)) -{ - return boost::pointer_traits<T>::to_address(v); -} - -template<class T> -inline auto -ptr_address(const T& v, long) BOOST_NOEXCEPT -{ - return boost::detail::ptr_address(v.operator->(), 0); -} - -} /* detail */ - -template<class T> -inline auto -to_address(const T& v) BOOST_NOEXCEPT -{ - return boost::detail::ptr_address(v, 0); -} -#else -template<class T> -inline typename pointer_traits<T>::element_type* -to_address(const T& v) BOOST_NOEXCEPT -{ - return boost::to_address(v.operator->()); -} -#endif - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/core/quick_exit.hpp b/ThirdParty/boost/core/quick_exit.hpp deleted file mode 100644 index 40ead1d491b492e8c3def73357f4c4cca4feefa0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/quick_exit.hpp +++ /dev/null @@ -1,59 +0,0 @@ -#ifndef BOOST_CORE_QUICK_EXIT_HPP_INCLUDED -#define BOOST_CORE_QUICK_EXIT_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// boost/core/quick_exit.hpp -// -// Copyright 2018 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> -#include <stdlib.h> - -#if defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) - -extern "C" _CRTIMP __cdecl __MINGW_NOTHROW void _exit (int) __MINGW_ATTRIB_NORETURN; - -#endif - -#if defined(__CYGWIN__) && __cplusplus < 201103L - -extern "C" _Noreturn void quick_exit(int); - -#endif - -namespace boost -{ - -BOOST_NORETURN void quick_exit( int code ) BOOST_NOEXCEPT -{ -#if defined(_MSC_VER) && _MSC_VER < 1900 - - ::_exit( code ); - -#elif defined(__MINGW32__) - - ::_exit( code ); - -#elif defined(__APPLE__) - - ::_Exit( code ); - -#else - - ::quick_exit( code ); - -#endif -} - -} // namespace boost - -#endif // #ifndef BOOST_CORE_QUICK_EXIT_HPP_INCLUDED diff --git a/ThirdParty/boost/core/swap.hpp b/ThirdParty/boost/core/swap.hpp deleted file mode 100644 index 73a454cea9c57f8b7032d3c6fcf381e0f8e937f7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/swap.hpp +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright (C) 2007, 2008 Steven Watanabe, Joseph Gauterin, Niels Dekker -// -// 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) -// For more information, see http://www.boost.org - - -#ifndef BOOST_CORE_SWAP_HPP -#define BOOST_CORE_SWAP_HPP - -// Note: the implementation of this utility contains various workarounds: -// - 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. -// - 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. - -#include <boost/core/enable_if.hpp> -#include <boost/config.hpp> -#if __cplusplus >= 201103L || defined(BOOST_MSVC) -#include <utility> //for std::swap (C++11) -#else -#include <algorithm> //for std::swap (C++98) -#endif -#include <cstddef> //for std::size_t - -namespace boost_swap_impl -{ - // we can't use type_traits here - - template<class T> struct is_const { enum _vt { value = 0 }; }; - template<class T> struct is_const<T const> { enum _vt { value = 1 }; }; - - template<class T> - BOOST_GPU_ENABLED - void swap_impl(T& left, T& right) - { - using namespace std;//use std::swap if argument dependent lookup fails - swap(left,right); - } - - template<class T, std::size_t N> - BOOST_GPU_ENABLED - void swap_impl(T (& left)[N], T (& right)[N]) - { - for (std::size_t i = 0; i < N; ++i) - { - ::boost_swap_impl::swap_impl(left[i], right[i]); - } - } -} - -namespace boost -{ - template<class T1, class T2> - 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_swap_impl::swap_impl(left, right); - } -} - -#endif diff --git a/ThirdParty/boost/core/typeinfo.hpp b/ThirdParty/boost/core/typeinfo.hpp deleted file mode 100644 index d33d29ba6885662ae4644ee580fc277853251ad6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/typeinfo.hpp +++ /dev/null @@ -1,167 +0,0 @@ -#ifndef BOOST_CORE_TYPEINFO_HPP_INCLUDED -#define BOOST_CORE_TYPEINFO_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// core::typeinfo, BOOST_CORE_TYPEID -// -// Copyright 2007, 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_NO_TYPEID ) - -#include <boost/current_function.hpp> -#include <functional> -#include <cstring> - -namespace boost -{ - -namespace core -{ - -class typeinfo -{ -private: - - typeinfo( typeinfo const& ); - typeinfo& operator=( typeinfo const& ); - - char const * name_; - void (*lib_id_)(); - -public: - - typeinfo( char const * name, void (*lib_id)() ): name_( name ), lib_id_( lib_id ) - { - } - - bool operator==( typeinfo const& rhs ) const - { -#if ( defined(_WIN32) || defined(__CYGWIN__) ) && ( defined(__GNUC__) || defined(__clang__) ) && !defined(BOOST_DISABLE_CURRENT_FUNCTION) - - return lib_id_ == rhs.lib_id_? this == &rhs: std::strcmp( name_, rhs.name_ ) == 0; - -#else - - return this == &rhs; - -#endif - } - - bool operator!=( typeinfo const& rhs ) const - { - return !( *this == rhs ); - } - - bool before( typeinfo const& rhs ) const - { -#if ( defined(_WIN32) || defined(__CYGWIN__) ) && ( defined(__GNUC__) || defined(__clang__) ) && !defined(BOOST_DISABLE_CURRENT_FUNCTION) - - return lib_id_ == rhs.lib_id_? std::less< typeinfo const* >()( this, &rhs ): std::strcmp( name_, rhs.name_ ) < 0; - -#else - - return std::less< typeinfo const* >()( this, &rhs ); - -#endif - } - - char const* name() const - { - return name_; - } -}; - -inline char const * demangled_name( core::typeinfo const & ti ) -{ - return ti.name(); -} - -} // namespace core - -namespace detail -{ - -template<class T> struct BOOST_SYMBOL_VISIBLE core_typeid_ -{ - static boost::core::typeinfo ti_; - - static char const * name() - { - return BOOST_CURRENT_FUNCTION; - } -}; - -BOOST_SYMBOL_VISIBLE inline void core_typeid_lib_id() -{ -} - -template<class T> boost::core::typeinfo core_typeid_< T >::ti_( core_typeid_< T >::name(), &core_typeid_lib_id ); - -template<class T> struct core_typeid_< T & >: core_typeid_< T > -{ -}; - -template<class T> struct core_typeid_< T const >: core_typeid_< T > -{ -}; - -template<class T> struct core_typeid_< T volatile >: core_typeid_< T > -{ -}; - -template<class T> struct core_typeid_< T const volatile >: core_typeid_< T > -{ -}; - -} // namespace detail - -} // namespace boost - -#define BOOST_CORE_TYPEID(T) (boost::detail::core_typeid_<T>::ti_) - -#else - -#include <boost/core/demangle.hpp> -#include <typeinfo> - -namespace boost -{ - -namespace core -{ - -#if defined( BOOST_NO_STD_TYPEINFO ) - -typedef ::type_info typeinfo; - -#else - -typedef std::type_info typeinfo; - -#endif - -inline std::string demangled_name( core::typeinfo const & ti ) -{ - return core::demangle( ti.name() ); -} - -} // namespace core - -} // namespace boost - -#define BOOST_CORE_TYPEID(T) typeid(T) - -#endif - -#endif // #ifndef BOOST_CORE_TYPEINFO_HPP_INCLUDED diff --git a/ThirdParty/boost/core/uncaught_exceptions.hpp b/ThirdParty/boost/core/uncaught_exceptions.hpp deleted file mode 100644 index 27e2491bda840e6ed47a74ff9021dd11c1b071c1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/core/uncaught_exceptions.hpp +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright Andrey Semashev 2018. - * Distributed under the Boost Software License, Version 1.0. - * (See accompanying file LICENSE_1_0.txt or copy at - * https://www.boost.org/LICENSE_1_0.txt) - */ -/*! - * \file uncaught_exceptions.hpp - * \author Andrey Semashev - * \date 2018-11-10 - * - * \brief This header provides an `uncaught_exceptions` function implementation, which was introduced in C++17. - * - * The code in this file is based on the implementation by Evgeny Panasyuk: - * - * https://github.com/panaseleus/stack_unwinding/blob/master/boost/exception/uncaught_exception_count.hpp - */ - -#ifndef BOOST_CORE_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED_ -#define BOOST_CORE_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED_ - -#include <exception> -#include <boost/config.hpp> - -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -// Visual Studio 14 supports N4152 std::uncaught_exceptions() -#if (defined(__cpp_lib_uncaught_exceptions) && __cpp_lib_uncaught_exceptions >= 201411) || \ - (defined(_MSC_VER) && _MSC_VER >= 1900) -#define BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS -#endif - -#if !defined(BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS) - -// cxxabi.h availability macro -#if defined(__has_include) && (!defined(BOOST_GCC) || (__GNUC__ >= 5)) -# if __has_include(<cxxabi.h>) -# define BOOST_CORE_HAS_CXXABI_H -# endif -#elif defined(__GLIBCXX__) || defined(__GLIBCPP__) -# define BOOST_CORE_HAS_CXXABI_H -#endif - -#if defined(BOOST_CORE_HAS_CXXABI_H) -// MinGW GCC 4.4 seem to not work the same way the newer GCC versions do. As a result, __cxa_get_globals based implementation will always return 0. -// Just disable it for now and fall back to std::uncaught_exception(). -#if !(defined(__MINGW32__) && (defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) < 405)) -#include <cxxabi.h> -#include <cstring> -#define BOOST_CORE_HAS_CXA_GET_GLOBALS -// At least on MinGW and Linux, only GCC since 4.7 declares __cxa_get_globals() in cxxabi.h. Older versions of GCC do not expose this function but it's there. -// On OpenBSD, it seems, the declaration is also missing. -// Note that at least on FreeBSD 11, cxxabi.h declares __cxa_get_globals with a different exception specification, so we can't declare the function unconditionally. -// On Linux with clang and libc++ and on OS X, there is a version of cxxabi.h from libc++abi that doesn't declare __cxa_get_globals, but provides __cxa_uncaught_exceptions. -// The function only appeared in version _LIBCPPABI_VERSION >= 1002 of the library. Unfortunately, there are linking errors about undefined reference to __cxa_uncaught_exceptions -// on Ubuntu Trusty and OS X, so we avoid using it and forward-declare __cxa_get_globals instead. -// On QNX SDP 7.0 (QCC 5.4.0), there are multiple cxxabi.h, one from glibcxx from gcc and another from libc++abi from LLVM. Which one is included will be determined by the qcc -// command line arguments (-V and/or -Y; http://www.qnx.com/developers/docs/7.0.0/#com.qnx.doc.neutrino.utilities/topic/q/qcc.html). The LLVM libc++abi is missing the declaration -// of __cxa_get_globals but it is also patched by QNX developers to not define _LIBCPPABI_VERSION. Older QNX SDP versions, up to and including 6.6, don't provide LLVM and libc++abi. -// See https://github.com/boostorg/core/issues/59. -#if !defined(__FreeBSD__) && \ - ( \ - (defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) < 407) || \ - defined(__OpenBSD__) || \ - (defined(__QNXNTO__) && !defined(__GLIBCXX__) && !defined(__GLIBCPP__)) || \ - defined(_LIBCPPABI_VERSION) \ - ) -namespace __cxxabiv1 { -struct __cxa_eh_globals; -#if defined(__OpenBSD__) -extern "C" __cxa_eh_globals* __cxa_get_globals(); -#else -extern "C" __cxa_eh_globals* __cxa_get_globals() BOOST_NOEXCEPT_OR_NOTHROW __attribute__((__const__)); -#endif -} // namespace __cxxabiv1 -#endif -#endif // !(defined(__MINGW32__) && (defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) < 405)) -#endif // defined(BOOST_CORE_HAS_CXXABI_H) - -#if defined(_MSC_VER) && _MSC_VER >= 1400 -#include <cstring> -#define BOOST_CORE_HAS_GETPTD -namespace boost { -namespace core { -namespace detail { -extern "C" void* _getptd(); -} // namespace detail -} // namespace core -} // namespace boost -#endif // defined(_MSC_VER) && _MSC_VER >= 1400 - -#endif // !defined(BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS) - -#if !defined(BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS) && !defined(BOOST_CORE_HAS_CXA_GET_GLOBALS) && !defined(BOOST_CORE_HAS_GETPTD) -//! This macro is defined when `uncaught_exceptions` is not guaranteed to return values greater than 1 if multiple exceptions are pending -#define BOOST_CORE_UNCAUGHT_EXCEPTIONS_EMULATED -#endif - -namespace boost { - -namespace core { - -//! Returns the number of currently pending exceptions -inline unsigned int uncaught_exceptions() BOOST_NOEXCEPT -{ -#if defined(BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS) - // C++17 implementation - return static_cast< unsigned int >(std::uncaught_exceptions()); -#elif defined(BOOST_CORE_HAS_CXA_GET_GLOBALS) - // Tested on {clang 3.2,GCC 3.5.6,GCC 4.1.2,GCC 4.4.6,GCC 4.4.7}x{x32,x64} - unsigned int count; - std::memcpy(&count, reinterpret_cast< const unsigned char* >(::abi::__cxa_get_globals()) + sizeof(void*), sizeof(count)); // __cxa_eh_globals::uncaughtExceptions, x32 offset - 0x4, x64 - 0x8 - return count; -#elif defined(BOOST_CORE_HAS_GETPTD) - // MSVC specific. Tested on {MSVC2005SP1,MSVC2008SP1,MSVC2010SP1,MSVC2012}x{x32,x64}. - unsigned int count; - std::memcpy(&count, static_cast< const unsigned char* >(boost::core::detail::_getptd()) + (sizeof(void*) == 8u ? 0x100 : 0x90), sizeof(count)); // _tiddata::_ProcessingThrow, x32 offset - 0x90, x64 - 0x100 - return count; -#else - // Portable C++03 implementation. Does not allow to detect multiple nested exceptions. - return static_cast< unsigned int >(std::uncaught_exception()); -#endif -} - -} // namespace core - -} // namespace boost - -#undef BOOST_CORE_HAS_CXXABI_H -#undef BOOST_CORE_HAS_CXA_GET_GLOBALS -#undef BOOST_CORE_HAS_UNCAUGHT_EXCEPTIONS -#undef BOOST_CORE_HAS_GETPTD - -#endif // BOOST_CORE_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED_ diff --git a/ThirdParty/boost/cstdint.hpp b/ThirdParty/boost/cstdint.hpp deleted file mode 100644 index 9c88d13b84ff2d3decabd6f730acc1c2196ba60c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/cstdint.hpp +++ /dev/null @@ -1,556 +0,0 @@ -// boost cstdint.hpp header file ------------------------------------------// - -// (C) Copyright Beman Dawes 1999. -// (C) Copyright Jens Mauer 2001 -// (C) Copyright John Maddock 2001 -// 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) - -// See http://www.boost.org/libs/integer for documentation. - -// Revision History -// 31 Oct 01 use BOOST_HAS_LONG_LONG to check for "long long" (Jens M.) -// 16 Apr 01 check LONGLONG_MAX when looking for "long long" (Jens Maurer) -// 23 Jan 01 prefer "long" over "int" for int32_t and intmax_t (Jens Maurer) -// 12 Nov 00 Merged <boost/stdint.h> (Jens Maurer) -// 23 Sep 00 Added INTXX_C macro support (John Maddock). -// 22 Sep 00 Better 64-bit support (John Maddock) -// 29 Jun 00 Reimplement to avoid including stdint.h within namespace boost -// 8 Aug 99 Initial version (Beman Dawes) - - -#ifndef BOOST_CSTDINT_HPP -#define BOOST_CSTDINT_HPP - -// -// Since we always define the INT#_C macros as per C++0x, -// define __STDC_CONSTANT_MACROS so that <stdint.h> does the right -// thing if possible, and so that the user knows that the macros -// are actually defined as per C99. -// -#ifndef __STDC_CONSTANT_MACROS -# define __STDC_CONSTANT_MACROS -#endif - -#include <boost/config.hpp> -// -// For the following code we get several warnings along the lines of: -// -// boost/cstdint.hpp:428:35: error: use of C99 long long integer constant -// -// So we declare this a system header to suppress these warnings. -// See also https://github.com/boostorg/config/issues/190 -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -#pragma GCC system_header -#endif - -// -// Note that GLIBC is a bit inconsistent about whether int64_t is defined or not -// depending upon what headers happen to have been included first... -// so we disable use of stdint.h when GLIBC does not define __GLIBC_HAVE_LONG_LONG. -// See https://svn.boost.org/trac/boost/ticket/3548 and http://sources.redhat.com/bugzilla/show_bug.cgi?id=10990 -// -#if defined(BOOST_HAS_STDINT_H) \ - && (!defined(__GLIBC__) \ - || defined(__GLIBC_HAVE_LONG_LONG) \ - || (defined(__GLIBC__) && ((__GLIBC__ > 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ >= 17))))) - -// The following #include is an implementation artifact; not part of interface. -# ifdef __hpux -// HP-UX has a vaguely nice <stdint.h> in a non-standard location -# include <inttypes.h> -# ifdef __STDC_32_MODE__ - // this is triggered with GCC, because it defines __cplusplus < 199707L -# define BOOST_NO_INT64_T -# endif -# elif defined(__FreeBSD__) || defined(__IBMCPP__) || defined(_AIX) -# include <inttypes.h> -# else -# include <stdint.h> - -// There is a bug in Cygwin two _C macros -# if defined(INTMAX_C) && defined(__CYGWIN__) -# undef INTMAX_C -# undef UINTMAX_C -# define INTMAX_C(c) c##LL -# define UINTMAX_C(c) c##ULL -# endif - -# endif - -#if defined(__QNX__) && defined(__EXT_QNX) - -// QNX (Dinkumware stdlib) defines these as non-standard names. -// Reflect to the standard names. - -typedef ::intleast8_t int_least8_t; -typedef ::intfast8_t int_fast8_t; -typedef ::uintleast8_t uint_least8_t; -typedef ::uintfast8_t uint_fast8_t; - -typedef ::intleast16_t int_least16_t; -typedef ::intfast16_t int_fast16_t; -typedef ::uintleast16_t uint_least16_t; -typedef ::uintfast16_t uint_fast16_t; - -typedef ::intleast32_t int_least32_t; -typedef ::intfast32_t int_fast32_t; -typedef ::uintleast32_t uint_least32_t; -typedef ::uintfast32_t uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - -typedef ::intleast64_t int_least64_t; -typedef ::intfast64_t int_fast64_t; -typedef ::uintleast64_t uint_least64_t; -typedef ::uintfast64_t uint_fast64_t; - -# endif - -#endif - -namespace boost -{ - - using ::int8_t; - using ::int_least8_t; - using ::int_fast8_t; - using ::uint8_t; - using ::uint_least8_t; - using ::uint_fast8_t; - - using ::int16_t; - using ::int_least16_t; - using ::int_fast16_t; - using ::uint16_t; - using ::uint_least16_t; - using ::uint_fast16_t; - - using ::int32_t; - using ::int_least32_t; - using ::int_fast32_t; - using ::uint32_t; - using ::uint_least32_t; - using ::uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - - using ::int64_t; - using ::int_least64_t; - using ::int_fast64_t; - using ::uint64_t; - using ::uint_least64_t; - using ::uint_fast64_t; - -# endif - - using ::intmax_t; - using ::uintmax_t; - -} // namespace boost - -#elif defined(__FreeBSD__) && (__FreeBSD__ <= 4) || defined(__osf__) || defined(__VMS) || defined(__SOLARIS9__) || defined(__NetBSD__) -// FreeBSD and Tru64 have an <inttypes.h> that contains much of what we need. -# include <inttypes.h> - -namespace boost { - - using ::int8_t; - typedef int8_t int_least8_t; - typedef int8_t int_fast8_t; - using ::uint8_t; - typedef uint8_t uint_least8_t; - typedef uint8_t uint_fast8_t; - - using ::int16_t; - typedef int16_t int_least16_t; - typedef int16_t int_fast16_t; - using ::uint16_t; - typedef uint16_t uint_least16_t; - typedef uint16_t uint_fast16_t; - - using ::int32_t; - typedef int32_t int_least32_t; - typedef int32_t int_fast32_t; - using ::uint32_t; - typedef uint32_t uint_least32_t; - typedef uint32_t uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - - using ::int64_t; - typedef int64_t int_least64_t; - typedef int64_t int_fast64_t; - using ::uint64_t; - typedef uint64_t uint_least64_t; - typedef uint64_t uint_fast64_t; - - typedef int64_t intmax_t; - typedef uint64_t uintmax_t; - -# else - - typedef int32_t intmax_t; - typedef uint32_t uintmax_t; - -# endif - -} // namespace boost - -#else // BOOST_HAS_STDINT_H - -# include <boost/limits.hpp> // implementation artifact; not part of interface -# include <limits.h> // needed for limits macros - - -namespace boost -{ - -// These are fairly safe guesses for some 16-bit, and most 32-bit and 64-bit -// platforms. For other systems, they will have to be hand tailored. -// -// Because the fast types are assumed to be the same as the undecorated types, -// it may be possible to hand tailor a more efficient implementation. Such -// an optimization may be illusionary; on the Intel x86-family 386 on, for -// example, byte arithmetic and load/stores are as fast as "int" sized ones. - -// 8-bit types ------------------------------------------------------------// - -# if UCHAR_MAX == 0xff - typedef signed char int8_t; - typedef signed char int_least8_t; - typedef signed char int_fast8_t; - typedef unsigned char uint8_t; - typedef unsigned char uint_least8_t; - typedef unsigned char uint_fast8_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 16-bit types -----------------------------------------------------------// - -# if USHRT_MAX == 0xffff -# if defined(__crayx1) - // The Cray X1 has a 16-bit short, however it is not recommend - // for use in performance critical code. - typedef short int16_t; - typedef short int_least16_t; - typedef int int_fast16_t; - typedef unsigned short uint16_t; - typedef unsigned short uint_least16_t; - typedef unsigned int uint_fast16_t; -# else - typedef short int16_t; - typedef short int_least16_t; - typedef short int_fast16_t; - typedef unsigned short uint16_t; - typedef unsigned short uint_least16_t; - typedef unsigned short uint_fast16_t; -# endif -# elif (USHRT_MAX == 0xffffffff) && defined(__MTA__) - // On MTA / XMT short is 32 bits unless the -short16 compiler flag is specified - // MTA / XMT does support the following non-standard integer types - typedef __short16 int16_t; - typedef __short16 int_least16_t; - typedef __short16 int_fast16_t; - typedef unsigned __short16 uint16_t; - typedef unsigned __short16 uint_least16_t; - typedef unsigned __short16 uint_fast16_t; -# elif (USHRT_MAX == 0xffffffff) && defined(CRAY) - // no 16-bit types on Cray: - typedef short int_least16_t; - typedef short int_fast16_t; - typedef unsigned short uint_least16_t; - typedef unsigned short uint_fast16_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 32-bit types -----------------------------------------------------------// - -# if UINT_MAX == 0xffffffff - typedef int int32_t; - typedef int int_least32_t; - typedef int int_fast32_t; - typedef unsigned int uint32_t; - typedef unsigned int uint_least32_t; - typedef unsigned int uint_fast32_t; -# elif (USHRT_MAX == 0xffffffff) - typedef short int32_t; - typedef short int_least32_t; - typedef short int_fast32_t; - typedef unsigned short uint32_t; - typedef unsigned short uint_least32_t; - typedef unsigned short uint_fast32_t; -# elif ULONG_MAX == 0xffffffff - typedef long int32_t; - typedef long int_least32_t; - typedef long int_fast32_t; - typedef unsigned long uint32_t; - typedef unsigned long uint_least32_t; - typedef unsigned long uint_fast32_t; -# elif (UINT_MAX == 0xffffffffffffffff) && defined(__MTA__) - // Integers are 64 bits on the MTA / XMT - typedef __int32 int32_t; - typedef __int32 int_least32_t; - typedef __int32 int_fast32_t; - typedef unsigned __int32 uint32_t; - typedef unsigned __int32 uint_least32_t; - typedef unsigned __int32 uint_fast32_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 64-bit types + intmax_t and uintmax_t ----------------------------------// - -# if defined(BOOST_HAS_LONG_LONG) && \ - !defined(BOOST_MSVC) && !defined(__BORLANDC__) && \ - (!defined(__GLIBCPP__) || defined(_GLIBCPP_USE_LONG_LONG)) && \ - (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX)) -# if defined(__hpux) - // HP-UX's value of ULONG_LONG_MAX is unusable in preprocessor expressions -# elif (defined(ULLONG_MAX) && ULLONG_MAX == 18446744073709551615ULL) || (defined(ULONG_LONG_MAX) && ULONG_LONG_MAX == 18446744073709551615ULL) || (defined(ULONGLONG_MAX) && ULONGLONG_MAX == 18446744073709551615ULL) - // 2**64 - 1 -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - - typedef ::boost::long_long_type intmax_t; - typedef ::boost::ulong_long_type uintmax_t; - typedef ::boost::long_long_type int64_t; - typedef ::boost::long_long_type int_least64_t; - typedef ::boost::long_long_type int_fast64_t; - typedef ::boost::ulong_long_type uint64_t; - typedef ::boost::ulong_long_type uint_least64_t; - typedef ::boost::ulong_long_type uint_fast64_t; - -# elif ULONG_MAX != 0xffffffff - -# if ULONG_MAX == 18446744073709551615 // 2**64 - 1 - typedef long intmax_t; - typedef unsigned long uintmax_t; - typedef long int64_t; - typedef long int_least64_t; - typedef long int_fast64_t; - typedef unsigned long uint64_t; - typedef unsigned long uint_least64_t; - typedef unsigned long uint_fast64_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif defined(__GNUC__) && defined(BOOST_HAS_LONG_LONG) - __extension__ typedef long long intmax_t; - __extension__ typedef unsigned long long uintmax_t; - __extension__ typedef long long int64_t; - __extension__ typedef long long int_least64_t; - __extension__ typedef long long int_fast64_t; - __extension__ typedef unsigned long long uint64_t; - __extension__ typedef unsigned long long uint_least64_t; - __extension__ typedef unsigned long long uint_fast64_t; -# elif defined(BOOST_HAS_MS_INT64) - // - // we have Borland/Intel/Microsoft __int64: - // - typedef __int64 intmax_t; - typedef unsigned __int64 uintmax_t; - typedef __int64 int64_t; - typedef __int64 int_least64_t; - typedef __int64 int_fast64_t; - typedef unsigned __int64 uint64_t; - typedef unsigned __int64 uint_least64_t; - typedef unsigned __int64 uint_fast64_t; -# else // assume no 64-bit integers -# define BOOST_NO_INT64_T - typedef int32_t intmax_t; - typedef uint32_t uintmax_t; -# endif - -} // namespace boost - - -#endif // BOOST_HAS_STDINT_H - -// intptr_t/uintptr_t are defined separately because they are optional and not universally available -#if defined(BOOST_WINDOWS) && !defined(_WIN32_WCE) && !defined(BOOST_HAS_STDINT_H) -// Older MSVC don't have stdint.h and have intptr_t/uintptr_t defined in stddef.h -#include <stddef.h> -#endif - -#if (defined(BOOST_WINDOWS) && !defined(_WIN32_WCE)) \ - || (defined(_XOPEN_UNIX) && (_XOPEN_UNIX+0 > 0) && !defined(__UCLIBC__)) \ - || defined(__CYGWIN__) || defined(__VXWORKS__) \ - || defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__) \ - || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) || (defined(sun) && !defined(BOOST_HAS_STDINT_H)) || defined(INTPTR_MAX) - -namespace boost { - using ::intptr_t; - using ::uintptr_t; -} -#define BOOST_HAS_INTPTR_T - -// Clang pretends to be GCC, so it'll match this condition -#elif defined(__GNUC__) && defined(__INTPTR_TYPE__) && defined(__UINTPTR_TYPE__) - -namespace boost { - typedef __INTPTR_TYPE__ intptr_t; - typedef __UINTPTR_TYPE__ uintptr_t; -} -#define BOOST_HAS_INTPTR_T - -#endif - -#endif // BOOST_CSTDINT_HPP - - -/**************************************************** - -Macro definition section: - -Added 23rd September 2000 (John Maddock). -Modified 11th September 2001 to be excluded when -BOOST_HAS_STDINT_H is defined (John Maddock). -Modified 11th Dec 2009 to always define the -INT#_C macros if they're not already defined (John Maddock). - -******************************************************/ - -#if !defined(BOOST__STDC_CONSTANT_MACROS_DEFINED) && \ - (!defined(INT8_C) || !defined(INT16_C) || !defined(INT32_C) || !defined(INT64_C)) -// -// Undef the macros as a precaution, since we may get here if <stdint.h> has failed -// to define them all, see https://svn.boost.org/trac/boost/ticket/12786 -// -#undef INT8_C -#undef INT16_C -#undef INT32_C -#undef INT64_C -#undef INTMAX_C -#undef UINT8_C -#undef UINT16_C -#undef UINT32_C -#undef UINT64_C -#undef UINTMAX_C - -#include <limits.h> -# define BOOST__STDC_CONSTANT_MACROS_DEFINED -# if defined(BOOST_HAS_MS_INT64) -// -// Borland/Intel/Microsoft compilers have width specific suffixes: -// -#ifndef INT8_C -# define INT8_C(value) value##i8 -#endif -#ifndef INT16_C -# define INT16_C(value) value##i16 -#endif -#ifndef INT32_C -# define INT32_C(value) value##i32 -#endif -#ifndef INT64_C -# define INT64_C(value) value##i64 -#endif -# ifdef __BORLANDC__ - // Borland bug: appending ui8 makes the type a signed char -# define UINT8_C(value) static_cast<unsigned char>(value##u) -# else -# define UINT8_C(value) value##ui8 -# endif -#ifndef UINT16_C -# define UINT16_C(value) value##ui16 -#endif -#ifndef UINT32_C -# define UINT32_C(value) value##ui32 -#endif -#ifndef UINT64_C -# define UINT64_C(value) value##ui64 -#endif -#ifndef INTMAX_C -# define INTMAX_C(value) value##i64 -# define UINTMAX_C(value) value##ui64 -#endif - -# else -// do it the old fashioned way: - -// 8-bit types ------------------------------------------------------------// - -# if (UCHAR_MAX == 0xff) && !defined(INT8_C) -# define INT8_C(value) static_cast<boost::int8_t>(value) -# define UINT8_C(value) static_cast<boost::uint8_t>(value##u) -# endif - -// 16-bit types -----------------------------------------------------------// - -# if (USHRT_MAX == 0xffff) && !defined(INT16_C) -# define INT16_C(value) static_cast<boost::int16_t>(value) -# define UINT16_C(value) static_cast<boost::uint16_t>(value##u) -# endif - -// 32-bit types -----------------------------------------------------------// -#ifndef INT32_C -# if (UINT_MAX == 0xffffffff) -# define INT32_C(value) value -# define UINT32_C(value) value##u -# elif ULONG_MAX == 0xffffffff -# define INT32_C(value) value##L -# define UINT32_C(value) value##uL -# endif -#endif - -// 64-bit types + intmax_t and uintmax_t ----------------------------------// -#ifndef INT64_C -# if defined(BOOST_HAS_LONG_LONG) && \ - (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX) || defined(_ULLONG_MAX) || defined(_LLONG_MAX)) - -# if defined(__hpux) - // HP-UX's value of ULONG_LONG_MAX is unusable in preprocessor expressions -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# elif (defined(ULLONG_MAX) && ULLONG_MAX == 18446744073709551615ULL) || \ - (defined(ULONG_LONG_MAX) && ULONG_LONG_MAX == 18446744073709551615ULL) || \ - (defined(ULONGLONG_MAX) && ULONGLONG_MAX == 18446744073709551615ULL) || \ - (defined(_ULLONG_MAX) && _ULLONG_MAX == 18446744073709551615ULL) || \ - (defined(_LLONG_MAX) && _LLONG_MAX == 9223372036854775807LL) - -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif ULONG_MAX != 0xffffffff - -# if ULONG_MAX == 18446744073709551615U // 2**64 - 1 -# define INT64_C(value) value##L -# define UINT64_C(value) value##uL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif defined(BOOST_HAS_LONG_LONG) - // Usual macros not defined, work things out for ourselves: -# if(~0uLL == 18446744073709551615ULL) -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -# ifdef BOOST_NO_INT64_T -# define INTMAX_C(value) INT32_C(value) -# define UINTMAX_C(value) UINT32_C(value) -# else -# define INTMAX_C(value) INT64_C(value) -# define UINTMAX_C(value) UINT64_C(value) -# endif -#endif -# endif // Borland/Microsoft specific width suffixes - -#endif // INT#_C macros. - - - - diff --git a/ThirdParty/boost/detail/sp_typeinfo.hpp b/ThirdParty/boost/detail/sp_typeinfo.hpp deleted file mode 100644 index bec228f57d0e3097bbd0afbb7fd73caa793abb2c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/detail/sp_typeinfo.hpp +++ /dev/null @@ -1,39 +0,0 @@ -#ifndef BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED -#define BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_typeinfo.hpp -// -// Deprecated, please use boost/core/typeinfo.hpp -// -// Copyright 2007 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/core/typeinfo.hpp> -#include <boost/config/header_deprecated.hpp> - -BOOST_HEADER_DEPRECATED( "<boost/core/typeinfo.hpp>" ) - -namespace boost -{ - -namespace detail -{ - -typedef boost::core::typeinfo sp_typeinfo; - -} // namespace detail - -} // namespace boost - -#define BOOST_SP_TYPEID(T) BOOST_CORE_TYPEID(T) - -#endif // #ifndef BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED diff --git a/ThirdParty/boost/exception/current_exception_cast.hpp b/ThirdParty/boost/exception/current_exception_cast.hpp deleted file mode 100644 index 950eeff17198ba99f8b1d8062f02a7eafb2fb3f8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/current_exception_cast.hpp +++ /dev/null @@ -1,49 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_7E83C166200811DE885E826156D89593 -#define BOOST_EXCEPTION_7E83C166200811DE885E826156D89593 - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - template <class E> - inline - E * - current_exception_cast() - { - try - { - throw; - } - catch( - E & e ) - { - return &e; - } - catch( - ...) - { - return 0; - } - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/detail/error_info_impl.hpp b/ThirdParty/boost/exception/detail/error_info_impl.hpp deleted file mode 100644 index 30ccffd1481d0b13ed3617491a6097173de3ed73..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/detail/error_info_impl.hpp +++ /dev/null @@ -1,107 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_CE6983AC753411DDA764247956D89593 -#define BOOST_EXCEPTION_CE6983AC753411DDA764247956D89593 - -#include <boost/config.hpp> -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES -#include <boost/type_traits/is_nothrow_move_constructible.hpp> -#endif -#include <utility> -#include <string> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - namespace - exception_detail - { - class - error_info_base - { - public: - - virtual std::string name_value_string() const = 0; - virtual error_info_base * clone() const = 0; - - virtual - ~error_info_base() BOOST_NOEXCEPT_OR_NOTHROW - { - } - }; - } - - template <class Tag,class T> - class - error_info: - public exception_detail::error_info_base - { - exception_detail::error_info_base * - clone() const - { - return new error_info<Tag,T>(*this); - } - public: - typedef T value_type; - error_info( value_type const & v ): - v_(v) - { - } -#if (__GNUC__*100+__GNUC_MINOR__!=406) //workaround for g++ bug -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - error_info( error_info const & x ): - v_(x.v_) - { - } - error_info( T && v ) BOOST_NOEXCEPT_IF(boost::is_nothrow_move_constructible<T>::value): - v_(std::move(v)) - { - } - error_info( error_info && x ) BOOST_NOEXCEPT_IF(boost::is_nothrow_move_constructible<T>::value): - v_(std::move(x.v_)) - { - } -#endif -#endif - ~error_info() BOOST_NOEXCEPT_OR_NOTHROW - { - } - value_type const & - value() const - { - return v_; - } - value_type & - value() - { - return v_; - } - private: - error_info & operator=( error_info const & ); -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - error_info & operator=( error_info && x ); -#endif - std::string name_value_string() const; - value_type v_; - }; - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/detail/is_output_streamable.hpp b/ThirdParty/boost/exception/detail/is_output_streamable.hpp deleted file mode 100644 index a61f986bc9fed978f59cd361771dae8b5bec8d67..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/detail/is_output_streamable.hpp +++ /dev/null @@ -1,66 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_898984B4076411DD973EDFA055D89593 -#define BOOST_EXCEPTION_898984B4076411DD973EDFA055D89593 - -#include <ostream> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - namespace - to_string_detail - { - struct - partial_ordering_helper1 - { - template <class CharT,class Traits> - partial_ordering_helper1( std::basic_ostream<CharT,Traits> & ); - }; - - struct - partial_ordering_helper2 - { - template <class T> - partial_ordering_helper2( T const & ); - }; - - char operator<<( partial_ordering_helper1, partial_ordering_helper2 ); - - template <class T,class CharT,class Traits> - struct - is_output_streamable_impl - { - static std::basic_ostream<CharT,Traits> & f(); - static T const & g(); - enum e { value=1!=(sizeof(f()<<g())) }; - }; - } - - template <class T, class CharT=char, class Traits=std::char_traits<CharT> > - struct - is_output_streamable - { - enum e { value=to_string_detail::is_output_streamable_impl<T,CharT,Traits>::value }; - }; - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/detail/object_hex_dump.hpp b/ThirdParty/boost/exception/detail/object_hex_dump.hpp deleted file mode 100644 index c195de50d91fe6403532b1664174e406f5fa47ee..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/detail/object_hex_dump.hpp +++ /dev/null @@ -1,56 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_6F463AC838DF11DDA3E6909F56D89593 -#define BOOST_EXCEPTION_6F463AC838DF11DDA3E6909F56D89593 - -#include <boost/exception/detail/type_info.hpp> -#include <iomanip> -#include <ios> -#include <string> -#include <sstream> -#include <cstdlib> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - namespace - exception_detail - { - template <class T> - inline - std::string - object_hex_dump( T const & x, std::size_t max_size=16 ) - { - std::ostringstream s; - s << "type: " << type_name<T>() << ", size: " << sizeof(T) << ", dump: "; - std::size_t n=sizeof(T)>max_size?max_size:sizeof(T); - s.fill('0'); - s.width(2); - unsigned char const * b=reinterpret_cast<unsigned char const *>(&x); - s << std::setw(2) << std::hex << (unsigned int)*b; - for( unsigned char const * e=b+n; ++b!=e; ) - s << " " << std::setw(2) << std::hex << (unsigned int)*b; - return s.str(); - } - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/detail/shared_ptr.hpp b/ThirdParty/boost/exception/detail/shared_ptr.hpp deleted file mode 100644 index 24dd16d7b1b8b3c235b936897a557e48af3e62f2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/detail/shared_ptr.hpp +++ /dev/null @@ -1,17 +0,0 @@ -//Copyright (c) 2006-2008 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_837060E885AF11E68DA91D15E31AC075 -#define BOOST_EXCEPTION_837060E885AF11E68DA91D15E31AC075 - -#ifdef BOOST_EXCEPTION_MINI_BOOST -#include <memory> -namespace boost { namespace exception_detail { using std::shared_ptr; } } -#else -#include <boost/shared_ptr.hpp> -namespace boost { namespace exception_detail { using boost::shared_ptr; } } -#endif - -#endif diff --git a/ThirdParty/boost/exception/detail/type_info.hpp b/ThirdParty/boost/exception/detail/type_info.hpp deleted file mode 100644 index 94cca7f0f782b662e71528f983d4b4bb7b12ba06..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/detail/type_info.hpp +++ /dev/null @@ -1,87 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_C3E1741C754311DDB2834CCA55D89593 -#define BOOST_EXCEPTION_C3E1741C754311DDB2834CCA55D89593 - -#include <boost/config.hpp> -#include <boost/core/typeinfo.hpp> -#include <boost/core/demangle.hpp> -#include <boost/current_function.hpp> -#include <string> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - template <class T> - inline - std::string - tag_type_name() - { -#ifdef BOOST_NO_TYPEID - return BOOST_CURRENT_FUNCTION; -#else - return core::demangle(typeid(T*).name()); -#endif - } - - template <class T> - inline - std::string - type_name() - { -#ifdef BOOST_NO_TYPEID - return BOOST_CURRENT_FUNCTION; -#else - return core::demangle(typeid(T).name()); -#endif - } - - namespace - exception_detail - { - struct - type_info_ - { - core::typeinfo const * type_; - - explicit - type_info_( core::typeinfo const & type ): - type_(&type) - { - } - - friend - bool - operator<( type_info_ const & a, type_info_ const & b ) - { - return 0!=(a.type_->before(*b.type_)); - } - }; - } - } - -#define BOOST_EXCEPTION_STATIC_TYPEID(T) ::boost::exception_detail::type_info_(BOOST_CORE_TYPEID(T)) - -#ifndef BOOST_NO_RTTI -#define BOOST_EXCEPTION_DYNAMIC_TYPEID(x) ::boost::exception_detail::type_info_(typeid(x)) -#endif - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/diagnostic_information.hpp b/ThirdParty/boost/exception/diagnostic_information.hpp deleted file mode 100644 index b5496d32ec5f3134ba1b513beb9d907da0dc37c3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/diagnostic_information.hpp +++ /dev/null @@ -1,213 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_0552D49838DD11DD90146B8956D89593 -#define BOOST_EXCEPTION_0552D49838DD11DD90146B8956D89593 - -#include <boost/config.hpp> -#include <boost/exception/get_error_info.hpp> -#include <boost/exception/info.hpp> -#include <boost/utility/enable_if.hpp> -#ifndef BOOST_NO_RTTI -#include <boost/core/demangle.hpp> -#endif -#include <exception> -#include <sstream> -#include <string> -#ifndef BOOST_NO_EXCEPTIONS -#include <boost/exception/current_exception_cast.hpp> -#endif - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -#ifndef BOOST_NO_EXCEPTIONS -namespace -boost - { - namespace - exception_detail - { - std::string diagnostic_information_impl( boost::exception const *, std::exception const *, bool, bool ); - } - - inline - std::string - current_exception_diagnostic_information( bool verbose=true) - { - boost::exception const * be=current_exception_cast<boost::exception const>(); - std::exception const * se=current_exception_cast<std::exception const>(); - if( be || se ) - return exception_detail::diagnostic_information_impl(be,se,true,verbose); -#if defined(__GLIBCXX__) && __cplusplus >= 201103L && !defined(BOOST_NO_RTTI) - else if (auto* p=std::current_exception().__cxa_exception_type()) - return "Dynamic exception type: "+boost::core::demangle(p->name()); -#endif - else - return "No diagnostic information available."; - } - } -#endif - -namespace -boost - { - namespace - exception_detail - { - inline - exception const * - get_boost_exception( exception const * e ) - { - return e; - } - - inline - exception const * - get_boost_exception( ... ) - { - return 0; - } - - inline - std::exception const * - get_std_exception( std::exception const * e ) - { - return e; - } - - inline - std::exception const * - get_std_exception( ... ) - { - return 0; - } - - inline - char const * - get_diagnostic_information( exception const & x, char const * header ) - { -#ifndef BOOST_NO_EXCEPTIONS - try - { -#endif - error_info_container * c=x.data_.get(); - if( !c ) - x.data_.adopt(c=new exception_detail::error_info_container_impl); - char const * di=c->diagnostic_information(header); - BOOST_ASSERT(di!=0); - return di; -#ifndef BOOST_NO_EXCEPTIONS - } - catch(...) - { - return 0; - } -#endif - } - - inline - std::string - diagnostic_information_impl( boost::exception const * be, std::exception const * se, bool with_what, bool verbose ) - { - if( !be && !se ) - return "Unknown exception."; -#ifndef BOOST_NO_RTTI - if( !be ) - be=dynamic_cast<boost::exception const *>(se); - if( !se ) - se=dynamic_cast<std::exception const *>(be); -#endif - char const * wh=0; - if( with_what && se ) - { - wh=se->what(); - if( be && exception_detail::get_diagnostic_information(*be,0)==wh ) - return wh; - } - std::ostringstream tmp; - if( be && verbose ) - { - char const * const * f=get_error_info<throw_file>(*be); - int const * l=get_error_info<throw_line>(*be); - char const * const * fn=get_error_info<throw_function>(*be); - if( !f && !l && !fn ) - tmp << "Throw location unknown (consider using BOOST_THROW_EXCEPTION)\n"; - else - { - if( f ) - { - tmp << *f; - if( int const * l=get_error_info<throw_line>(*be) ) - tmp << '(' << *l << "): "; - } - tmp << "Throw in function "; - if( char const * const * fn=get_error_info<throw_function>(*be) ) - tmp << *fn; - else - tmp << "(unknown)"; - tmp << '\n'; - } - } -#ifndef BOOST_NO_RTTI - if ( verbose ) - tmp << std::string("Dynamic exception type: ") << - core::demangle((be?(BOOST_EXCEPTION_DYNAMIC_TYPEID(*be)):(BOOST_EXCEPTION_DYNAMIC_TYPEID(*se))).type_->name()) << '\n'; -#endif - if( with_what && se && verbose ) - tmp << "std::exception::what: " << (wh ? wh : "(null)") << '\n'; - if( be ) - if( char const * s=exception_detail::get_diagnostic_information(*be,tmp.str().c_str()) ) - if( *s ) - return std::string(s); - return tmp.str(); - } - } - - template <class T> - std::string - diagnostic_information( T const & e, bool verbose=true ) - { - return exception_detail::diagnostic_information_impl(exception_detail::get_boost_exception(&e),exception_detail::get_std_exception(&e),true,verbose); - } - - inline - char const * - diagnostic_information_what( exception const & e, bool verbose=true ) BOOST_NOEXCEPT_OR_NOTHROW - { - char const * w=0; -#ifndef BOOST_NO_EXCEPTIONS - try - { -#endif - (void) exception_detail::diagnostic_information_impl(&e,0,false,verbose); - if( char const * di=exception_detail::get_diagnostic_information(e,0) ) - return di; - else - return "Failed to produce boost::diagnostic_information_what()"; -#ifndef BOOST_NO_EXCEPTIONS - } - catch( - ... ) - { - } -#endif - return w; - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/exception.hpp b/ThirdParty/boost/exception/exception.hpp deleted file mode 100644 index 37a582c2e309c26ea8e3298490937b48df36f9e6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/exception.hpp +++ /dev/null @@ -1,487 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_274DA366004E11DCB1DDFE2E56D89593 -#define BOOST_EXCEPTION_274DA366004E11DCB1DDFE2E56D89593 - -#include <boost/config.hpp> - -#ifdef BOOST_EXCEPTION_MINI_BOOST -#include <memory> -namespace boost { namespace exception_detail { using std::shared_ptr; } } -#else -namespace boost { template <class T> class shared_ptr; } -namespace boost { namespace exception_detail { using boost::shared_ptr; } } -#endif - -#if !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#pragma warning(disable: 4265) -#endif -#endif - -namespace -boost - { - namespace - exception_detail - { - template <class T> - class - refcount_ptr - { - public: - - refcount_ptr(): - px_(0) - { - } - - ~refcount_ptr() - { - release(); - } - - refcount_ptr( refcount_ptr const & x ): - px_(x.px_) - { - add_ref(); - } - - refcount_ptr & - operator=( refcount_ptr const & x ) - { - adopt(x.px_); - return *this; - } - - void - adopt( T * px ) - { - release(); - px_=px; - add_ref(); - } - - T * - get() const - { - return px_; - } - - private: - - T * px_; - - void - add_ref() - { - if( px_ ) - px_->add_ref(); - } - - void - release() - { - if( px_ && px_->release() ) - px_=0; - } - }; - } - - //////////////////////////////////////////////////////////////////////// - - template <class Tag,class T> - class error_info; - - typedef error_info<struct throw_function_,char const *> throw_function; - typedef error_info<struct throw_file_,char const *> throw_file; - typedef error_info<struct throw_line_,int> throw_line; - - template <> - class - error_info<throw_function_,char const *> - { - public: - typedef char const * value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - - template <> - class - error_info<throw_file_,char const *> - { - public: - typedef char const * value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - - template <> - class - error_info<throw_line_,int> - { - public: - typedef int value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - - class - BOOST_SYMBOL_VISIBLE - exception; - - namespace - exception_detail - { - class error_info_base; - struct type_info_; - - struct - error_info_container - { - virtual char const * diagnostic_information( char const * ) const = 0; - virtual shared_ptr<error_info_base> get( type_info_ const & ) const = 0; - virtual void set( shared_ptr<error_info_base> const &, type_info_ const & ) = 0; - virtual void add_ref() const = 0; - virtual bool release() const = 0; - virtual refcount_ptr<exception_detail::error_info_container> clone() const = 0; - - protected: - - ~error_info_container() BOOST_NOEXCEPT_OR_NOTHROW - { - } - }; - - template <class> - struct get_info; - - template <> - struct get_info<throw_function>; - - template <> - struct get_info<throw_file>; - - template <> - struct get_info<throw_line>; - - template <class> - struct set_info_rv; - - template <> - struct set_info_rv<throw_function>; - - template <> - struct set_info_rv<throw_file>; - - template <> - struct set_info_rv<throw_line>; - - char const * get_diagnostic_information( exception const &, char const * ); - - void copy_boost_exception( exception *, exception const * ); - - template <class E,class Tag,class T> - E const & set_info( E const &, error_info<Tag,T> const & ); - - template <class E> - E const & set_info( E const &, throw_function const & ); - - template <class E> - E const & set_info( E const &, throw_file const & ); - - template <class E> - E const & set_info( E const &, throw_line const & ); - } - - class - BOOST_SYMBOL_VISIBLE - exception - { - //<N3757> - public: - template <class Tag> void set( typename Tag::type const & ); - template <class Tag> typename Tag::type const * get() const; - //</N3757> - - protected: - - exception(): - throw_function_(0), - throw_file_(0), - throw_line_(-1) - { - } - -#ifdef __HP_aCC - //On HP aCC, this protected copy constructor prevents throwing boost::exception. - //On all other platforms, the same effect is achieved by the pure virtual destructor. - exception( exception const & x ) BOOST_NOEXCEPT_OR_NOTHROW: - data_(x.data_), - throw_function_(x.throw_function_), - throw_file_(x.throw_file_), - throw_line_(x.throw_line_) - { - } -#endif - - virtual ~exception() BOOST_NOEXCEPT_OR_NOTHROW -#ifndef __HP_aCC - = 0 //Workaround for HP aCC, =0 incorrectly leads to link errors. -#endif - ; - -#if (defined(__MWERKS__) && __MWERKS__<=0x3207) || (defined(_MSC_VER) && _MSC_VER<=1310) - public: -#else - private: - - template <class E> - friend E const & exception_detail::set_info( E const &, throw_function const & ); - - template <class E> - friend E const & exception_detail::set_info( E const &, throw_file const & ); - - template <class E> - friend E const & exception_detail::set_info( E const &, throw_line const & ); - - template <class E,class Tag,class T> - friend E const & exception_detail::set_info( E const &, error_info<Tag,T> const & ); - - friend char const * exception_detail::get_diagnostic_information( exception const &, char const * ); - - template <class> - friend struct exception_detail::get_info; - friend struct exception_detail::get_info<throw_function>; - friend struct exception_detail::get_info<throw_file>; - friend struct exception_detail::get_info<throw_line>; - template <class> - friend struct exception_detail::set_info_rv; - friend struct exception_detail::set_info_rv<throw_function>; - friend struct exception_detail::set_info_rv<throw_file>; - friend struct exception_detail::set_info_rv<throw_line>; - friend void exception_detail::copy_boost_exception( exception *, exception const * ); -#endif - mutable exception_detail::refcount_ptr<exception_detail::error_info_container> data_; - mutable char const * throw_function_; - mutable char const * throw_file_; - mutable int throw_line_; - }; - - inline - exception:: - ~exception() BOOST_NOEXCEPT_OR_NOTHROW - { - } - - namespace - exception_detail - { - template <class E> - E const & - set_info( E const & x, throw_function const & y ) - { - x.throw_function_=y.v_; - return x; - } - - template <class E> - E const & - set_info( E const & x, throw_file const & y ) - { - x.throw_file_=y.v_; - return x; - } - - template <class E> - E const & - set_info( E const & x, throw_line const & y ) - { - x.throw_line_=y.v_; - return x; - } - } - - //////////////////////////////////////////////////////////////////////// - - namespace - exception_detail - { - template <class T> - struct - BOOST_SYMBOL_VISIBLE - error_info_injector: - public T, - public exception - { - explicit - error_info_injector( T const & x ): - T(x) - { - } - - ~error_info_injector() BOOST_NOEXCEPT_OR_NOTHROW - { - } - }; - - struct large_size { char c[256]; }; - large_size dispatch_boost_exception( exception const * ); - - struct small_size { }; - small_size dispatch_boost_exception( void const * ); - - template <class,int> - struct enable_error_info_helper; - - template <class T> - struct - enable_error_info_helper<T,sizeof(large_size)> - { - typedef T type; - }; - - template <class T> - struct - enable_error_info_helper<T,sizeof(small_size)> - { - typedef error_info_injector<T> type; - }; - - template <class T> - struct - enable_error_info_return_type - { - typedef typename enable_error_info_helper<T,sizeof(exception_detail::dispatch_boost_exception(static_cast<T *>(0)))>::type type; - }; - } - - template <class T> - inline - typename - exception_detail::enable_error_info_return_type<T>::type - enable_error_info( T const & x ) - { - typedef typename exception_detail::enable_error_info_return_type<T>::type rt; - return rt(x); - } - - //////////////////////////////////////////////////////////////////////// - - namespace - exception_detail - { - class - BOOST_SYMBOL_VISIBLE - clone_base - { - public: - - virtual clone_base const * clone() const = 0; - virtual void rethrow() const = 0; - - virtual - ~clone_base() BOOST_NOEXCEPT_OR_NOTHROW - { - } - }; - - inline - void - copy_boost_exception( exception * a, exception const * b ) - { - refcount_ptr<error_info_container> data; - if( error_info_container * d=b->data_.get() ) - data = d->clone(); - a->throw_file_ = b->throw_file_; - a->throw_line_ = b->throw_line_; - a->throw_function_ = b->throw_function_; - a->data_ = data; - } - - inline - void - copy_boost_exception( void *, void const * ) - { - } - - template <class T> - class - BOOST_SYMBOL_VISIBLE - clone_impl: - public T, - public virtual clone_base - { - struct clone_tag { }; - clone_impl( clone_impl const & x, clone_tag ): - T(x) - { - copy_boost_exception(this,&x); - } - - public: - - explicit - clone_impl( T const & x ): - T(x) - { - copy_boost_exception(this,&x); - } - - ~clone_impl() BOOST_NOEXCEPT_OR_NOTHROW - { - } - - private: - - clone_base const * - clone() const - { - return new clone_impl(*this,clone_tag()); - } - - void - rethrow() const - { - throw*this; - } - }; - } - - template <class T> - inline - exception_detail::clone_impl<T> - enable_current_exception( T const & x ) - { - return exception_detail::clone_impl<T>(x); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif - -#endif // #ifndef BOOST_EXCEPTION_274DA366004E11DCB1DDFE2E56D89593 diff --git a/ThirdParty/boost/exception/get_error_info.hpp b/ThirdParty/boost/exception/get_error_info.hpp deleted file mode 100644 index 09a224aa532afe3d24e893f1b95f8f1a4a25183d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/get_error_info.hpp +++ /dev/null @@ -1,138 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_1A590226753311DD9E4CCF6156D89593 -#define BOOST_EXCEPTION_1A590226753311DD9E4CCF6156D89593 - -#include <boost/config.hpp> -#include <boost/exception/exception.hpp> -#include <boost/exception/detail/error_info_impl.hpp> -#include <boost/exception/detail/type_info.hpp> -#include <boost/exception/detail/shared_ptr.hpp> -#include <boost/assert.hpp> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - namespace - exception_detail - { - template <class ErrorInfo> - struct - get_info - { - static - typename ErrorInfo::value_type * - get( exception const & x ) - { - if( exception_detail::error_info_container * c=x.data_.get() ) - if( shared_ptr<exception_detail::error_info_base> eib = c->get(BOOST_EXCEPTION_STATIC_TYPEID(ErrorInfo)) ) - { -#ifndef BOOST_NO_RTTI - BOOST_ASSERT( 0!=dynamic_cast<ErrorInfo *>(eib.get()) ); -#endif - ErrorInfo * w = static_cast<ErrorInfo *>(eib.get()); - return &w->value(); - } - return 0; - } - }; - - template <> - struct - get_info<throw_function> - { - static - char const * * - get( exception const & x ) - { - return x.throw_function_ ? &x.throw_function_ : 0; - } - }; - - template <> - struct - get_info<throw_file> - { - static - char const * * - get( exception const & x ) - { - return x.throw_file_ ? &x.throw_file_ : 0; - } - }; - - template <> - struct - get_info<throw_line> - { - static - int * - get( exception const & x ) - { - return x.throw_line_!=-1 ? &x.throw_line_ : 0; - } - }; - - template <class T,class R> - struct - get_error_info_return_type - { - typedef R * type; - }; - - template <class T,class R> - struct - get_error_info_return_type<T const,R> - { - typedef R const * type; - }; - } - -#ifdef BOOST_NO_RTTI - template <class ErrorInfo> - inline - typename ErrorInfo::value_type const * - get_error_info( boost::exception const & x ) - { - return exception_detail::get_info<ErrorInfo>::get(x); - } - template <class ErrorInfo> - inline - typename ErrorInfo::value_type * - get_error_info( boost::exception & x ) - { - return exception_detail::get_info<ErrorInfo>::get(x); - } -#else - template <class ErrorInfo,class E> - inline - typename exception_detail::get_error_info_return_type<E,typename ErrorInfo::value_type>::type - get_error_info( E & some_exception ) - { - if( exception const * x = dynamic_cast<exception const *>(&some_exception) ) - return exception_detail::get_info<ErrorInfo>::get(*x); - else - return 0; - } -#endif - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/info.hpp b/ThirdParty/boost/exception/info.hpp deleted file mode 100644 index a877cbd7d9eced65183633b7c201d76a1fc894b4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/info.hpp +++ /dev/null @@ -1,282 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_8D22C4CA9CC811DCAA9133D256D89593 -#define BOOST_EXCEPTION_8D22C4CA9CC811DCAA9133D256D89593 - -#include <boost/config.hpp> -#include <boost/exception/exception.hpp> -#include <boost/exception/to_string_stub.hpp> -#include <boost/exception/detail/error_info_impl.hpp> -#include <boost/exception/detail/shared_ptr.hpp> -#include <map> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - template <class Tag,class T> - inline - std::string - error_info_name( error_info<Tag,T> const & x ) - { - return tag_type_name<Tag>(); - } - - template <class Tag,class T> - inline - std::string - to_string( error_info<Tag,T> const & x ) - { - return '[' + error_info_name(x) + "] = " + to_string_stub(x.value()) + '\n'; - } - - template <class Tag,class T> - inline - std::string - error_info<Tag,T>:: - name_value_string() const - { - return to_string_stub(*this); - } - - namespace - exception_detail - { - class - error_info_container_impl: - public error_info_container - { - public: - - error_info_container_impl(): - count_(0) - { - } - - ~error_info_container_impl() BOOST_NOEXCEPT_OR_NOTHROW - { - } - - void - set( shared_ptr<error_info_base> const & x, type_info_ const & typeid_ ) - { - BOOST_ASSERT(x); - info_[typeid_] = x; - diagnostic_info_str_.clear(); - } - - shared_ptr<error_info_base> - get( type_info_ const & ti ) const - { - error_info_map::const_iterator i=info_.find(ti); - if( info_.end()!=i ) - { - shared_ptr<error_info_base> const & p = i->second; -#ifndef BOOST_NO_RTTI - BOOST_ASSERT( *BOOST_EXCEPTION_DYNAMIC_TYPEID(*p).type_==*ti.type_ ); -#endif - return p; - } - return shared_ptr<error_info_base>(); - } - - char const * - diagnostic_information( char const * header ) const - { - if( header ) - { - std::ostringstream tmp; - tmp << header; - for( error_info_map::const_iterator i=info_.begin(),end=info_.end(); i!=end; ++i ) - { - error_info_base const & x = *i->second; - tmp << x.name_value_string(); - } - tmp.str().swap(diagnostic_info_str_); - } - return diagnostic_info_str_.c_str(); - } - - private: - - friend class boost::exception; - - typedef std::map< type_info_, shared_ptr<error_info_base> > error_info_map; - error_info_map info_; - mutable std::string diagnostic_info_str_; - mutable int count_; - - error_info_container_impl( error_info_container_impl const & ); - error_info_container_impl & operator=( error_info_container const & ); - - void - add_ref() const - { - ++count_; - } - - bool - release() const - { - if( --count_ ) - return false; - else - { - delete this; - return true; - } - } - - refcount_ptr<error_info_container> - clone() const - { - refcount_ptr<error_info_container> p; - error_info_container_impl * c=new error_info_container_impl; - p.adopt(c); - for( error_info_map::const_iterator i=info_.begin(),e=info_.end(); i!=e; ++i ) - { - shared_ptr<error_info_base> cp(i->second->clone()); - c->info_.insert(std::make_pair(i->first,cp)); - } - return p; - } - }; - - template <class E,class Tag,class T> - inline - E const & - set_info( E const & x, error_info<Tag,T> const & v ) - { - typedef error_info<Tag,T> error_info_tag_t; - shared_ptr<error_info_tag_t> p( new error_info_tag_t(v) ); - exception_detail::error_info_container * c=x.data_.get(); - if( !c ) - x.data_.adopt(c=new exception_detail::error_info_container_impl); - c->set(p,BOOST_EXCEPTION_STATIC_TYPEID(error_info_tag_t)); - return x; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - template <class E,class Tag,class T> - E const & set_info( E const &, error_info<Tag,T> && ); - template <class T> - struct set_info_rv; - template <class Tag,class T> - struct - set_info_rv<error_info<Tag,T> > - { - template <class E,class Tag1,class T1> - friend E const & set_info( E const &, error_info<Tag1,T1> && ); - template <class E> - static - E const & - set( E const & x, error_info<Tag,T> && v ) - { - typedef error_info<Tag,T> error_info_tag_t; - shared_ptr<error_info_tag_t> p( new error_info_tag_t(std::move(v)) ); - exception_detail::error_info_container * c=x.data_.get(); - if( !c ) - x.data_.adopt(c=new exception_detail::error_info_container_impl); - c->set(p,BOOST_EXCEPTION_STATIC_TYPEID(error_info_tag_t)); - return x; - } - }; - template <> - struct - set_info_rv<throw_function> - { - template <class E,class Tag1,class T1> - friend E const & set_info( E const &, error_info<Tag1,T1> && ); - template <class E> - static - E const & - set( E const & x, throw_function && y ) - { - x.throw_function_=y.v_; - return x; - } - }; - template <> - struct - set_info_rv<throw_file> - { - template <class E,class Tag1,class T1> - friend E const & set_info( E const &, error_info<Tag1,T1> && ); - template <class E> - static - E const & - set( E const & x, throw_file && y ) - { - x.throw_file_=y.v_; - return x; - } - }; - template <> - struct - set_info_rv<throw_line> - { - template <class E,class Tag1,class T1> - friend E const & set_info( E const &, error_info<Tag1,T1> && ); - template <class E> - static - E const & - set( E const & x, throw_line && y ) - { - x.throw_line_=y.v_; - return x; - } - }; - template <class E,class Tag,class T> - inline - E const & - set_info( E const & x, error_info<Tag,T> && v ) - { - return set_info_rv<error_info<Tag,T> >::template set<E>(x,std::move(v)); - } -#endif - - template <class T> - struct - derives_boost_exception - { - enum e { value = (sizeof(dispatch_boost_exception((T*)0))==sizeof(large_size)) }; - }; - } - - template <class E,class Tag,class T> - inline - typename enable_if<exception_detail::derives_boost_exception<E>,E const &>::type - operator<<( E const & x, error_info<Tag,T> const & v ) - { - return exception_detail::set_info(x,v); - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - template <class E,class Tag,class T> - inline - typename enable_if<exception_detail::derives_boost_exception<E>,E const &>::type - operator<<( E const & x, error_info<Tag,T> && v ) - { - return exception_detail::set_info(x,std::move(v)); - } -#endif - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/to_string.hpp b/ThirdParty/boost/exception/to_string.hpp deleted file mode 100644 index 9a2c05794c4fb422821f03377afea22ff59534ce..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/to_string.hpp +++ /dev/null @@ -1,94 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_7E48761AD92811DC9011477D56D89593 -#define BOOST_EXCEPTION_7E48761AD92811DC9011477D56D89593 - -#include <boost/utility/enable_if.hpp> -#include <boost/exception/detail/is_output_streamable.hpp> -#include <sstream> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - template <class T,class U> - std::string to_string( std::pair<T,U> const & ); - std::string to_string( std::exception const & ); - - namespace - to_string_detail - { - template <class T> - typename disable_if<is_output_streamable<T>,char>::type to_string( T const & ); - using boost::to_string; - - template <class,bool IsOutputStreamable> - struct has_to_string_impl; - - template <class T> - struct - has_to_string_impl<T,true> - { - enum e { value=1 }; - }; - - template <class T> - struct - has_to_string_impl<T,false> - { - static T const & f(); - enum e { value=1!=sizeof(to_string(f())) }; - }; - } - - template <class T> - inline - typename enable_if<is_output_streamable<T>,std::string>::type - to_string( T const & x ) - { - std::ostringstream out; - out << x; - return out.str(); - } - - template <class T> - struct - has_to_string - { - enum e { value=to_string_detail::has_to_string_impl<T,is_output_streamable<T>::value>::value }; - }; - - template <class T,class U> - inline - std::string - to_string( std::pair<T,U> const & x ) - { - return std::string("(") + to_string(x.first) + ',' + to_string(x.second) + ')'; - } - - inline - std::string - to_string( std::exception const & x ) - { - return x.what(); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/exception/to_string_stub.hpp b/ThirdParty/boost/exception/to_string_stub.hpp deleted file mode 100644 index 5fbfba7ec21047f17784bcf451059198cc6b9dc8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/exception/to_string_stub.hpp +++ /dev/null @@ -1,123 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//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_EXCEPTION_E788439ED9F011DCB181F25B55D89593 -#define BOOST_EXCEPTION_E788439ED9F011DCB181F25B55D89593 - -#include <boost/exception/to_string.hpp> -#include <boost/exception/detail/object_hex_dump.hpp> -#include <boost/assert.hpp> - -#ifndef BOOST_EXCEPTION_ENABLE_WARNINGS -#if __GNUC__*100+__GNUC_MINOR__>301 -#pragma GCC system_header -#endif -#ifdef __clang__ -#pragma clang system_header -#endif -#ifdef _MSC_VER -#pragma warning(push,1) -#endif -#endif - -namespace -boost - { - namespace - exception_detail - { - template <bool ToStringAvailable> - struct - to_string_dispatcher - { - template <class T,class Stub> - static - std::string - convert( T const & x, Stub ) - { - return to_string(x); - } - }; - - template <> - struct - to_string_dispatcher<false> - { - template <class T,class Stub> - static - std::string - convert( T const & x, Stub s ) - { - return s(x); - } - - template <class T> - static - std::string - convert( T const & x, std::string s ) - { - return s; - } - - template <class T> - static - std::string - convert( T const & x, char const * s ) - { - BOOST_ASSERT(s!=0); - return s; - } - }; - - namespace - to_string_dispatch - { - template <class T,class Stub> - inline - std::string - dispatch( T const & x, Stub s ) - { - return to_string_dispatcher<has_to_string<T>::value>::convert(x,s); - } - } - - template <class T> - inline - std::string - string_stub_dump( T const & x ) - { - return "[ " + exception_detail::object_hex_dump(x) + " ]"; - } - } - - template <class T> - inline - std::string - to_string_stub( T const & x ) - { - return exception_detail::to_string_dispatch::dispatch(x,&exception_detail::string_stub_dump<T>); - } - - template <class T,class Stub> - inline - std::string - to_string_stub( T const & x, Stub s ) - { - return exception_detail::to_string_dispatch::dispatch(x,s); - } - - template <class T,class U,class Stub> - inline - std::string - to_string_stub( std::pair<T,U> const & x, Stub s ) - { - return std::string("(") + to_string_stub(x.first,s) + ',' + to_string_stub(x.second,s) + ')'; - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/ThirdParty/boost/filesystem.hpp b/ThirdParty/boost/filesystem.hpp deleted file mode 100644 index 0bf4c6442ab5f3c0ad2fb846281939cff54b8f03..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// boost/filesystem.hpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2010 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM_FILESYSTEM_HPP -#define BOOST_FILESYSTEM_FILESYSTEM_HPP - -# include <boost/filesystem/config.hpp> -# include <boost/filesystem/path.hpp> -# include <boost/filesystem/exception.hpp> -# include <boost/filesystem/directory.hpp> -# include <boost/filesystem/operations.hpp> -# include <boost/filesystem/file_status.hpp> -# include <boost/filesystem/convenience.hpp> -# include <boost/filesystem/string_file.hpp> - -#endif // BOOST_FILESYSTEM_FILESYSTEM_HPP diff --git a/ThirdParty/boost/filesystem/directory.hpp b/ThirdParty/boost/filesystem/directory.hpp deleted file mode 100644 index 90dcaa885bf486a3aaecbbfdef65e02e9e78fe2d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem/directory.hpp +++ /dev/null @@ -1,620 +0,0 @@ -// boost/filesystem/directory.hpp ---------------------------------------------------// - -// Copyright Beman Dawes 2002-2009 -// Copyright Jan Langer 2002 -// Copyright Dietmar Kuehl 2001 -// Copyright Vladimir Prus 2002 -// Copyright Andrey Semashev 2019 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_DIRECTORY_HPP -#define BOOST_FILESYSTEM3_DIRECTORY_HPP - -#include <boost/config.hpp> - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include <boost/filesystem/config.hpp> -#include <boost/filesystem/path.hpp> -#include <boost/filesystem/file_status.hpp> - -#include <string> -#include <vector> -#include <utility> // std::move - -#include <boost/assert.hpp> -#include <boost/core/scoped_enum.hpp> -#include <boost/detail/bitmask.hpp> -#include <boost/system/error_code.hpp> -#include <boost/smart_ptr/intrusive_ptr.hpp> -#include <boost/smart_ptr/intrusive_ref_counter.hpp> -#include <boost/iterator/iterator_facade.hpp> -#include <boost/iterator/iterator_categories.hpp> - -#include <boost/config/abi_prefix.hpp> // must be the last #include - -//--------------------------------------------------------------------------------------// - -namespace boost { -namespace filesystem { - -//--------------------------------------------------------------------------------------// -// // -// directory_entry // -// // -//--------------------------------------------------------------------------------------// - -// GCC has a problem with a member function named path within a namespace or -// sub-namespace that also has a class named path. The workaround is to always -// fully qualify the name path when it refers to the class name. - -class directory_entry -{ -public: - typedef boost::filesystem::path::value_type value_type; // enables class path ctor taking directory_entry - - directory_entry() BOOST_NOEXCEPT {} - explicit directory_entry(const boost::filesystem::path& p) : - m_path(p), m_status(file_status()), m_symlink_status(file_status()) - { - } - directory_entry(const boost::filesystem::path& p, - file_status st, file_status symlink_st = file_status()) : - m_path(p), m_status(st), m_symlink_status(symlink_st) - { - } - - directory_entry(const directory_entry& rhs) : - m_path(rhs.m_path), m_status(rhs.m_status), m_symlink_status(rhs.m_symlink_status) - { - } - - directory_entry& operator=(const directory_entry& rhs) - { - m_path = rhs.m_path; - m_status = rhs.m_status; - m_symlink_status = rhs.m_symlink_status; - return *this; - } - - // As of October 2015 the interaction between noexcept and =default is so troublesome - // for VC++, GCC, and probably other compilers, that =default is not used with noexcept - // functions. GCC is not even consistent for the same release on different platforms. - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - directory_entry(directory_entry&& rhs) BOOST_NOEXCEPT : - m_path(std::move(rhs.m_path)), m_status(std::move(rhs.m_status)), m_symlink_status(std::move(rhs.m_symlink_status)) - { - } - directory_entry& operator=(directory_entry&& rhs) BOOST_NOEXCEPT - { - m_path = std::move(rhs.m_path); - m_status = std::move(rhs.m_status); - m_symlink_status = std::move(rhs.m_symlink_status); - return *this; - } -#endif - - void assign(const boost::filesystem::path& p, - file_status st = file_status(), file_status symlink_st = file_status()) - { - m_path = p; - m_status = st; - m_symlink_status = symlink_st; - } - - void replace_filename(const boost::filesystem::path& p, - file_status st = file_status(), file_status symlink_st = file_status()) - { - m_path.remove_filename(); - m_path /= p; - m_status = st; - m_symlink_status = symlink_st; - } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - void replace_leaf(const boost::filesystem::path& p, file_status st, file_status symlink_st) - { - replace_filename(p, st, symlink_st); - } -# endif - - const boost::filesystem::path& path() const BOOST_NOEXCEPT { return m_path; } - operator const boost::filesystem::path&() const BOOST_NOEXCEPT { return m_path; } - file_status status() const { return get_status(); } - file_status status(system::error_code& ec) const BOOST_NOEXCEPT { return get_status(&ec); } - file_status symlink_status() const { return get_symlink_status(); } - file_status symlink_status(system::error_code& ec) const BOOST_NOEXCEPT { return get_symlink_status(&ec); } - - bool operator==(const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path == rhs.m_path; } - bool operator!=(const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path != rhs.m_path; } - bool operator< (const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path < rhs.m_path; } - bool operator<=(const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path <= rhs.m_path; } - bool operator> (const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path > rhs.m_path; } - bool operator>=(const directory_entry& rhs) const BOOST_NOEXCEPT { return m_path >= rhs.m_path; } - -private: - BOOST_FILESYSTEM_DECL file_status get_status(system::error_code* ec=0) const; - BOOST_FILESYSTEM_DECL file_status get_symlink_status(system::error_code* ec=0) const; - -private: - boost::filesystem::path m_path; - mutable file_status m_status; // stat()-like - mutable file_status m_symlink_status; // lstat()-like -}; // directory_entry - - -//--------------------------------------------------------------------------------------// -// // -// directory_entry overloads // -// // -//--------------------------------------------------------------------------------------// - -// Without these functions, calling (for example) 'is_directory' with a 'directory_entry' results in: -// - a conversion to 'path' using 'operator const boost::filesystem::path&()', -// - then a call to 'is_directory(const path& p)' which recomputes the status with 'detail::status(p)'. -// -// These functions avoid a costly recomputation of the status if one calls 'is_directory(e)' instead of 'is_directory(e.status)' - -inline file_status status (const directory_entry& e) BOOST_NOEXCEPT { return e.status(); } -inline bool type_present (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::type_present(e.status()); } -inline bool status_known (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::status_known(e.status()); } -inline bool exists (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::exists(e.status()); } -inline bool is_regular_file(const directory_entry& e) BOOST_NOEXCEPT { return filesystem::is_regular_file(e.status()); } -inline bool is_directory (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::is_directory(e.status()); } -inline bool is_symlink (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::is_symlink(e.status()); } -inline bool is_other (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::is_other(e.status()); } -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED -inline bool is_regular (const directory_entry& e) BOOST_NOEXCEPT { return filesystem::is_regular(e.status()); } -#endif - -//--------------------------------------------------------------------------------------// -// // -// directory_iterator helpers // -// // -//--------------------------------------------------------------------------------------// - -BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(directory_options, unsigned int) -{ - none = 0u, - skip_permission_denied = 1u, // if a directory cannot be opened because of insufficient permissions, pretend that the directory is empty - follow_directory_symlink = 1u << 1, // recursive_directory_iterator: follow directory symlinks - skip_dangling_symlinks = 1u << 2, // non-standard extension for recursive_directory_iterator: don't follow dangling directory symlinks, - pop_on_error = 1u << 3, // non-standard extension for recursive_directory_iterator: instead of producing an end iterator on errors, - // repeatedly invoke pop() until it succeeds or the iterator becomes equal to end iterator - _detail_no_push = 1u << 4 // internal use only -} -BOOST_SCOPED_ENUM_DECLARE_END(directory_options) - -BOOST_BITMASK(BOOST_SCOPED_ENUM_NATIVE(directory_options)) - -class directory_iterator; - -namespace detail { - -BOOST_FILESYSTEM_DECL -system::error_code dir_itr_close(// never throws() - void*& handle -#if defined(BOOST_POSIX_API) - , void*& buffer -#endif -) BOOST_NOEXCEPT; - -struct dir_itr_imp : - public boost::intrusive_ref_counter< dir_itr_imp > -{ - directory_entry dir_entry; - void* handle; - -#if defined(BOOST_POSIX_API) - void* buffer; // see dir_itr_increment implementation -#endif - - dir_itr_imp() BOOST_NOEXCEPT : - handle(0) -#if defined(BOOST_POSIX_API) - , buffer(0) -#endif - { - } - - ~dir_itr_imp() BOOST_NOEXCEPT - { - dir_itr_close(handle -#if defined(BOOST_POSIX_API) - , buffer -#endif - ); - } -}; - -// see path::iterator: comment below -BOOST_FILESYSTEM_DECL void directory_iterator_construct(directory_iterator& it, const path& p, unsigned int opts, system::error_code* ec); -BOOST_FILESYSTEM_DECL void directory_iterator_increment(directory_iterator& it, system::error_code* ec); - -} // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// directory_iterator // -// // -//--------------------------------------------------------------------------------------// - -class directory_iterator : - public boost::iterator_facade< - directory_iterator, - directory_entry, - boost::single_pass_traversal_tag - > -{ - friend class boost::iterator_core_access; - - friend BOOST_FILESYSTEM_DECL void detail::directory_iterator_construct(directory_iterator& it, const path& p, unsigned int opts, system::error_code* ec); - friend BOOST_FILESYSTEM_DECL void detail::directory_iterator_increment(directory_iterator& it, system::error_code* ec); - -public: - directory_iterator() BOOST_NOEXCEPT {} // creates the "end" iterator - - // iterator_facade derived classes don't seem to like implementations in - // separate translation unit dll's, so forward to detail functions - explicit directory_iterator(const path& p, BOOST_SCOPED_ENUM_NATIVE(directory_options) opts = directory_options::none) - { - detail::directory_iterator_construct(*this, p, static_cast< unsigned int >(opts), 0); - } - - directory_iterator(const path& p, system::error_code& ec) BOOST_NOEXCEPT - { - detail::directory_iterator_construct(*this, p, static_cast< unsigned int >(directory_options::none), &ec); - } - - directory_iterator(const path& p, BOOST_SCOPED_ENUM_NATIVE(directory_options) opts, system::error_code& ec) BOOST_NOEXCEPT - { - detail::directory_iterator_construct(*this, p, static_cast< unsigned int >(opts), &ec); - } - - BOOST_DEFAULTED_FUNCTION(directory_iterator(directory_iterator const& that), : m_imp(that.m_imp) {}) - BOOST_DEFAULTED_FUNCTION(directory_iterator& operator= (directory_iterator const& that), { m_imp = that.m_imp; return *this; }) - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - directory_iterator(directory_iterator&& that) BOOST_NOEXCEPT : - m_imp(std::move(that.m_imp)) - { - } - - directory_iterator& operator= (directory_iterator&& that) BOOST_NOEXCEPT - { - m_imp = std::move(that.m_imp); - return *this; - } -#endif // !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - - directory_iterator& increment(system::error_code& ec) BOOST_NOEXCEPT - { - detail::directory_iterator_increment(*this, &ec); - return *this; - } - -private: - boost::iterator_facade< - directory_iterator, - directory_entry, - boost::single_pass_traversal_tag - >::reference dereference() const - { - BOOST_ASSERT_MSG(!is_end(), "attempt to dereference end directory iterator"); - return m_imp->dir_entry; - } - - void increment() { detail::directory_iterator_increment(*this, 0); } - - bool equal(const directory_iterator& rhs) const BOOST_NOEXCEPT - { - return m_imp == rhs.m_imp || (is_end() && rhs.is_end()); - } - - bool is_end() const BOOST_NOEXCEPT - { - // Note: The check for handle is needed because the iterator can be copied and the copy - // can be incremented to end while the original iterator still refers to the same dir_itr_imp. - return !m_imp || !m_imp->handle; - } - -private: - // intrusive_ptr provides the shallow-copy semantics required for single pass iterators - // (i.e. InputIterators). The end iterator is indicated by is_end(). - boost::intrusive_ptr< detail::dir_itr_imp > m_imp; -}; - -// enable directory_iterator C++11 range-based for statement use --------------------// - -// begin() and end() are only used by a range-based for statement in the context of -// auto - thus the top-level const is stripped - so returning const is harmless and -// emphasizes begin() is just a pass through. -inline const directory_iterator& begin(const directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline directory_iterator end(const directory_iterator&) BOOST_NOEXCEPT { return directory_iterator(); } - -// enable C++14 generic accessors for range const iterators -inline const directory_iterator& cbegin(const directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline directory_iterator cend(const directory_iterator&) BOOST_NOEXCEPT { return directory_iterator(); } - -// enable directory_iterator BOOST_FOREACH -----------------------------------------// - -inline directory_iterator& range_begin(directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline directory_iterator range_begin(const directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline directory_iterator range_end(directory_iterator&) BOOST_NOEXCEPT { return directory_iterator(); } -inline directory_iterator range_end(const directory_iterator&) BOOST_NOEXCEPT { return directory_iterator(); } - -} // namespace filesystem - -// namespace boost template specializations -template<typename C, typename Enabler> -struct range_mutable_iterator; - -template<> -struct range_mutable_iterator<boost::filesystem::directory_iterator, void> -{ - typedef boost::filesystem::directory_iterator type; -}; - -template<typename C, typename Enabler> -struct range_const_iterator; - -template<> -struct range_const_iterator<boost::filesystem::directory_iterator, void> -{ - typedef boost::filesystem::directory_iterator type; -}; - -namespace filesystem { - -//--------------------------------------------------------------------------------------// -// // -// recursive_directory_iterator helpers // -// // -//--------------------------------------------------------------------------------------// - -#if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) -// Deprecated enum, use directory_options instead -BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(symlink_option, unsigned int) -{ - none = static_cast< unsigned int >(directory_options::none), - no_recurse = none, // don't follow directory symlinks (default behavior) - recurse = static_cast< unsigned int >(directory_options::follow_directory_symlink), // follow directory symlinks - _detail_no_push = static_cast< unsigned int >(directory_options::_detail_no_push) // internal use only -} -BOOST_SCOPED_ENUM_DECLARE_END(symlink_option) - -BOOST_BITMASK(BOOST_SCOPED_ENUM_NATIVE(symlink_option)) -#endif // BOOST_FILESYSTEM_NO_DEPRECATED - -class recursive_directory_iterator; - -namespace detail { - -struct recur_dir_itr_imp : - public boost::intrusive_ref_counter< recur_dir_itr_imp > -{ - typedef directory_iterator element_type; - std::vector< element_type > m_stack; - // directory_options values, declared as unsigned int for ABI compatibility - unsigned int m_options; - - explicit recur_dir_itr_imp(unsigned int opts) BOOST_NOEXCEPT : m_options(opts) {} -}; - -BOOST_FILESYSTEM_DECL void recursive_directory_iterator_construct(recursive_directory_iterator& it, const path& dir_path, unsigned int opts, system::error_code* ec); -BOOST_FILESYSTEM_DECL void recursive_directory_iterator_increment(recursive_directory_iterator& it, system::error_code* ec); -BOOST_FILESYSTEM_DECL void recursive_directory_iterator_pop(recursive_directory_iterator& it, system::error_code* ec); - -} // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// recursive_directory_iterator // -// // -//--------------------------------------------------------------------------------------// - -class recursive_directory_iterator : - public boost::iterator_facade< - recursive_directory_iterator, - directory_entry, - boost::single_pass_traversal_tag - > -{ - friend class boost::iterator_core_access; - - friend BOOST_FILESYSTEM_DECL void detail::recursive_directory_iterator_construct(recursive_directory_iterator& it, const path& dir_path, unsigned int opts, system::error_code* ec); - friend BOOST_FILESYSTEM_DECL void detail::recursive_directory_iterator_increment(recursive_directory_iterator& it, system::error_code* ec); - friend BOOST_FILESYSTEM_DECL void detail::recursive_directory_iterator_pop(recursive_directory_iterator& it, system::error_code* ec); - -public: - recursive_directory_iterator() BOOST_NOEXCEPT {} // creates the "end" iterator - - explicit recursive_directory_iterator(const path& dir_path) - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(directory_options::none), 0); - } - - recursive_directory_iterator(const path& dir_path, system::error_code& ec) - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(directory_options::none), &ec); - } - - recursive_directory_iterator(const path& dir_path, BOOST_SCOPED_ENUM_NATIVE(directory_options) opts) - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(opts), 0); - } - - recursive_directory_iterator(const path& dir_path, BOOST_SCOPED_ENUM_NATIVE(directory_options) opts, system::error_code& ec) - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(opts), &ec); - } - -#if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) - // Deprecated constructors - recursive_directory_iterator(const path& dir_path, BOOST_SCOPED_ENUM_NATIVE(symlink_option) opts) - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(opts), 0); - } - - recursive_directory_iterator(const path& dir_path, BOOST_SCOPED_ENUM_NATIVE(symlink_option) opts, system::error_code& ec) BOOST_NOEXCEPT - { - detail::recursive_directory_iterator_construct(*this, dir_path, static_cast< unsigned int >(opts), &ec); - } -#endif // BOOST_FILESYSTEM_NO_DEPRECATED - - BOOST_DEFAULTED_FUNCTION(recursive_directory_iterator(recursive_directory_iterator const& that), : m_imp(that.m_imp) {}) - BOOST_DEFAULTED_FUNCTION(recursive_directory_iterator& operator= (recursive_directory_iterator const& that), { m_imp = that.m_imp; return *this; }) - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - recursive_directory_iterator(recursive_directory_iterator&& that) BOOST_NOEXCEPT : - m_imp(std::move(that.m_imp)) - { - } - - recursive_directory_iterator& operator= (recursive_directory_iterator&& that) BOOST_NOEXCEPT - { - m_imp = std::move(that.m_imp); - return *this; - } -#endif // !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - - recursive_directory_iterator& increment(system::error_code& ec) BOOST_NOEXCEPT - { - detail::recursive_directory_iterator_increment(*this, &ec); - return *this; - } - - int depth() const BOOST_NOEXCEPT - { - BOOST_ASSERT_MSG(!is_end(), "depth() on end recursive_directory_iterator"); - return static_cast< int >(m_imp->m_stack.size() - 1u); - } - - bool recursion_pending() const BOOST_NOEXCEPT - { - BOOST_ASSERT_MSG(!is_end(), "recursion_pending() on end recursive_directory_iterator"); - return (m_imp->m_options & static_cast< unsigned int >(directory_options::_detail_no_push)) == 0u; - } - -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED - int level() const BOOST_NOEXCEPT { return depth(); } - bool no_push_pending() const BOOST_NOEXCEPT { return !recursion_pending(); } - bool no_push_request() const BOOST_NOEXCEPT { return !recursion_pending(); } -#endif - - void pop() - { - detail::recursive_directory_iterator_pop(*this, 0); - } - - void pop(system::error_code& ec) BOOST_NOEXCEPT - { - detail::recursive_directory_iterator_pop(*this, &ec); - } - - void disable_recursion_pending(bool value = true) BOOST_NOEXCEPT - { - BOOST_ASSERT_MSG(!is_end(), "disable_recursion_pending() on end recursive_directory_iterator"); - if (value) - m_imp->m_options |= static_cast< unsigned int >(directory_options::_detail_no_push); - else - m_imp->m_options &= ~static_cast< unsigned int >(directory_options::_detail_no_push); - } - -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED - void no_push(bool value = true) BOOST_NOEXCEPT { disable_recursion_pending(value); } -#endif - - file_status status() const - { - BOOST_ASSERT_MSG(!is_end(), "status() on end recursive_directory_iterator"); - return m_imp->m_stack.back()->status(); - } - - file_status symlink_status() const - { - BOOST_ASSERT_MSG(!is_end(), "symlink_status() on end recursive_directory_iterator"); - return m_imp->m_stack.back()->symlink_status(); - } - -private: - boost::iterator_facade< - recursive_directory_iterator, - directory_entry, - boost::single_pass_traversal_tag - >::reference dereference() const - { - BOOST_ASSERT_MSG(!is_end(), "dereference of end recursive_directory_iterator"); - return *m_imp->m_stack.back(); - } - - void increment() { detail::recursive_directory_iterator_increment(*this, 0); } - - bool equal(const recursive_directory_iterator& rhs) const BOOST_NOEXCEPT - { - return m_imp == rhs.m_imp || (is_end() && rhs.is_end()); - } - - bool is_end() const BOOST_NOEXCEPT - { - // Note: The check for m_stack.empty() is needed because the iterator can be copied and the copy - // can be incremented to end while the original iterator still refers to the same recur_dir_itr_imp. - return !m_imp || m_imp->m_stack.empty(); - } - -private: - // intrusive_ptr provides the shallow-copy semantics required for single pass iterators - // (i.e. InputIterators). The end iterator is indicated by is_end(). - boost::intrusive_ptr< detail::recur_dir_itr_imp > m_imp; -}; - -#if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) -typedef recursive_directory_iterator wrecursive_directory_iterator; -#endif - -// enable recursive directory iterator C++11 range-base for statement use ----------// - -// begin() and end() are only used by a range-based for statement in the context of -// auto - thus the top-level const is stripped - so returning const is harmless and -// emphasizes begin() is just a pass through. -inline const recursive_directory_iterator& begin(const recursive_directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline recursive_directory_iterator end(const recursive_directory_iterator&) BOOST_NOEXCEPT { return recursive_directory_iterator(); } - -// enable C++14 generic accessors for range const iterators -inline const recursive_directory_iterator& cbegin(const recursive_directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline recursive_directory_iterator cend(const recursive_directory_iterator&) BOOST_NOEXCEPT { return recursive_directory_iterator(); } - -// enable recursive directory iterator BOOST_FOREACH -------------------------------// - -inline recursive_directory_iterator& range_begin(recursive_directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline recursive_directory_iterator range_begin(const recursive_directory_iterator& iter) BOOST_NOEXCEPT { return iter; } -inline recursive_directory_iterator range_end(recursive_directory_iterator&) BOOST_NOEXCEPT { return recursive_directory_iterator(); } -inline recursive_directory_iterator range_end(const recursive_directory_iterator&) BOOST_NOEXCEPT { return recursive_directory_iterator(); } - -} // namespace filesystem - -// namespace boost template specializations -template<> -struct range_mutable_iterator<boost::filesystem::recursive_directory_iterator, void> -{ - typedef boost::filesystem::recursive_directory_iterator type; -}; -template<> -struct range_const_iterator<boost::filesystem::recursive_directory_iterator, void> -{ - typedef boost::filesystem::recursive_directory_iterator type; -}; - -} // namespace boost - -#include <boost/config/abi_suffix.hpp> // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_DIRECTORY_HPP diff --git a/ThirdParty/boost/filesystem/exception.hpp b/ThirdParty/boost/filesystem/exception.hpp deleted file mode 100644 index 0560f686cd1b6c6f5101053d93e74bdbc4f51678..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem/exception.hpp +++ /dev/null @@ -1,100 +0,0 @@ -// boost/filesystem/exception.hpp -----------------------------------------------------// - -// Copyright Beman Dawes 2003 -// Copyright Andrey Semashev 2019 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -#ifndef BOOST_FILESYSTEM3_EXCEPTION_HPP -#define BOOST_FILESYSTEM3_EXCEPTION_HPP - -#include <boost/config.hpp> - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include <boost/filesystem/config.hpp> -#include <boost/filesystem/path.hpp> - -#include <string> -#include <boost/system/error_code.hpp> -#include <boost/system/system_error.hpp> -#include <boost/smart_ptr/intrusive_ptr.hpp> -#include <boost/smart_ptr/intrusive_ref_counter.hpp> - -#include <boost/config/abi_prefix.hpp> // must be the last #include - -#if defined(BOOST_MSVC) -#pragma warning(push) -// 'm_A' : class 'A' needs to have dll-interface to be used by clients of class 'B' -#pragma warning(disable: 4251) -// non dll-interface class 'A' used as base for dll-interface class 'B' -#pragma warning(disable: 4275) -#endif - -namespace boost { -namespace filesystem { - -//--------------------------------------------------------------------------------------// -// // -// class filesystem_error // -// // -//--------------------------------------------------------------------------------------// - -class BOOST_FILESYSTEM_DECL filesystem_error : - public system::system_error -{ - // see http://www.boost.org/more/error_handling.html for design rationale - -public: - filesystem_error(const std::string& what_arg, system::error_code ec); - filesystem_error(const std::string& what_arg, const path& path1_arg, system::error_code ec); - filesystem_error(const std::string& what_arg, const path& path1_arg, const path& path2_arg, system::error_code ec); - - filesystem_error(filesystem_error const& that); - filesystem_error& operator= (filesystem_error const& that); - - ~filesystem_error() BOOST_NOEXCEPT_OR_NOTHROW; - - const path& path1() const BOOST_NOEXCEPT - { - return m_imp_ptr.get() ? m_imp_ptr->m_path1 : get_empty_path(); - } - const path& path2() const BOOST_NOEXCEPT - { - return m_imp_ptr.get() ? m_imp_ptr->m_path2 : get_empty_path(); - } - - const char* what() const BOOST_NOEXCEPT_OR_NOTHROW; - -private: - static const path& get_empty_path() BOOST_NOEXCEPT; - -private: - struct impl : - public boost::intrusive_ref_counter< impl > - { - path m_path1; // may be empty() - path m_path2; // may be empty() - std::string m_what; // not built until needed - - BOOST_DEFAULTED_FUNCTION(impl(), {}) - explicit impl(path const& path1) : m_path1(path1) {} - impl(path const& path1, path const& path2) : m_path1(path1), m_path2(path2) {} - }; - boost::intrusive_ptr< impl > m_imp_ptr; -}; - -} // namespace filesystem -} // namespace boost - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#include <boost/config/abi_suffix.hpp> // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_EXCEPTION_HPP diff --git a/ThirdParty/boost/filesystem/file_status.hpp b/ThirdParty/boost/filesystem/file_status.hpp deleted file mode 100644 index 7e4f0b4d20946196da4570cfe5f21f66f6d4e5c1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem/file_status.hpp +++ /dev/null @@ -1,237 +0,0 @@ -// boost/filesystem/file_status.hpp --------------------------------------------------// - -// Copyright Beman Dawes 2002-2009 -// Copyright Jan Langer 2002 -// Copyright Dietmar Kuehl 2001 -// Copyright Vladimir Prus 2002 -// Copyright Andrey Semashev 2019 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_FILE_STATUS_HPP -#define BOOST_FILESYSTEM3_FILE_STATUS_HPP - -#include <boost/config.hpp> - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include <boost/filesystem/config.hpp> - -#include <boost/detail/bitmask.hpp> - -#include <boost/config/abi_prefix.hpp> // must be the last #include - -//--------------------------------------------------------------------------------------// - -namespace boost { -namespace filesystem { - -//--------------------------------------------------------------------------------------// -// file_type // -//--------------------------------------------------------------------------------------// - -enum file_type -{ - status_error, -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - status_unknown = status_error, -# endif - file_not_found, - regular_file, - directory_file, - // the following may not apply to some operating systems or file systems - symlink_file, - block_file, - character_file, - fifo_file, - socket_file, - reparse_file, // Windows: FILE_ATTRIBUTE_REPARSE_POINT that is not a symlink - type_unknown, // file does exist, but isn't one of the above types or - // we don't have strong enough permission to find its type - - _detail_directory_symlink // internal use only; never exposed to users -}; - -//--------------------------------------------------------------------------------------// -// perms // -//--------------------------------------------------------------------------------------// - -enum perms -{ - no_perms = 0, // file_not_found is no_perms rather than perms_not_known - - // POSIX equivalent macros given in comments. - // Values are from POSIX and are given in octal per the POSIX standard. - - // permission bits - - owner_read = 0400, // S_IRUSR, Read permission, owner - owner_write = 0200, // S_IWUSR, Write permission, owner - owner_exe = 0100, // S_IXUSR, Execute/search permission, owner - owner_all = 0700, // S_IRWXU, Read, write, execute/search by owner - - group_read = 040, // S_IRGRP, Read permission, group - group_write = 020, // S_IWGRP, Write permission, group - group_exe = 010, // S_IXGRP, Execute/search permission, group - group_all = 070, // S_IRWXG, Read, write, execute/search by group - - others_read = 04, // S_IROTH, Read permission, others - others_write = 02, // S_IWOTH, Write permission, others - others_exe = 01, // S_IXOTH, Execute/search permission, others - others_all = 07, // S_IRWXO, Read, write, execute/search by others - - all_all = 0777, // owner_all|group_all|others_all - - // other POSIX bits - - set_uid_on_exe = 04000, // S_ISUID, Set-user-ID on execution - set_gid_on_exe = 02000, // S_ISGID, Set-group-ID on execution - sticky_bit = 01000, // S_ISVTX, - // (POSIX XSI) On directories, restricted deletion flag - // (V7) 'sticky bit': save swapped text even after use - // (SunOS) On non-directories: don't cache this file - // (SVID-v4.2) On directories: restricted deletion flag - // Also see http://en.wikipedia.org/wiki/Sticky_bit - - perms_mask = 07777, // all_all|set_uid_on_exe|set_gid_on_exe|sticky_bit - - perms_not_known = 0xFFFF, // present when directory_entry cache not loaded - - // options for permissions() function - - add_perms = 0x1000, // adds the given permission bits to the current bits - remove_perms = 0x2000, // removes the given permission bits from the current bits; - // choose add_perms or remove_perms, not both; if neither add_perms - // nor remove_perms is given, replace the current bits with - // the given bits. - - symlink_perms = 0x4000, // on POSIX, don't resolve symlinks; implied on Windows - - // BOOST_BITMASK op~ casts to int32_least_t, producing invalid enum values - _detail_extend_perms_32_1 = 0x7fffffff, - _detail_extend_perms_32_2 = -0x7fffffff-1 -}; - -BOOST_BITMASK(perms) - -//--------------------------------------------------------------------------------------// -// file_status // -//--------------------------------------------------------------------------------------// - -class file_status -{ -public: - BOOST_CONSTEXPR file_status() BOOST_NOEXCEPT : - m_value(status_error), m_perms(perms_not_known) - { - } - explicit BOOST_CONSTEXPR file_status(file_type v) BOOST_NOEXCEPT : - m_value(v), m_perms(perms_not_known) - { - } - BOOST_CONSTEXPR file_status(file_type v, perms prms) BOOST_NOEXCEPT : - m_value(v), m_perms(prms) - { - } - - // As of October 2015 the interaction between noexcept and =default is so troublesome - // for VC++, GCC, and probably other compilers, that =default is not used with noexcept - // functions. GCC is not even consistent for the same release on different platforms. - - BOOST_CONSTEXPR file_status(const file_status& rhs) BOOST_NOEXCEPT : - m_value(rhs.m_value), m_perms(rhs.m_perms) - { - } - BOOST_CXX14_CONSTEXPR file_status& operator=(const file_status& rhs) BOOST_NOEXCEPT - { - m_value = rhs.m_value; - m_perms = rhs.m_perms; - return *this; - } - -# if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - // Note: std::move is not constexpr in C++11, that's why we're not using it here - BOOST_CONSTEXPR file_status(file_status&& rhs) BOOST_NOEXCEPT : - m_value(static_cast< file_type&& >(rhs.m_value)), m_perms(static_cast< enum perms&& >(rhs.m_perms)) - { - } - BOOST_CXX14_CONSTEXPR file_status& operator=(file_status&& rhs) BOOST_NOEXCEPT - { - m_value = static_cast< file_type&& >(rhs.m_value); - m_perms = static_cast< enum perms&& >(rhs.m_perms); - return *this; - } -# endif - - // observers - BOOST_CONSTEXPR file_type type() const BOOST_NOEXCEPT { return m_value; } - BOOST_CONSTEXPR perms permissions() const BOOST_NOEXCEPT { return m_perms; } - - // modifiers - BOOST_CXX14_CONSTEXPR void type(file_type v) BOOST_NOEXCEPT { m_value = v; } - BOOST_CXX14_CONSTEXPR void permissions(perms prms) BOOST_NOEXCEPT { m_perms = prms; } - - BOOST_CONSTEXPR bool operator==(const file_status& rhs) const BOOST_NOEXCEPT - { - return type() == rhs.type() && permissions() == rhs.permissions(); - } - BOOST_CONSTEXPR bool operator!=(const file_status& rhs) const BOOST_NOEXCEPT - { - return !(*this == rhs); - } - -private: - file_type m_value; - enum perms m_perms; -}; - -inline BOOST_CONSTEXPR bool type_present(file_status f) BOOST_NOEXCEPT -{ - return f.type() != status_error; -} -inline BOOST_CONSTEXPR bool permissions_present(file_status f) BOOST_NOEXCEPT -{ - return f.permissions() != perms_not_known; -} -inline BOOST_CONSTEXPR bool status_known(file_status f) BOOST_NOEXCEPT -{ - return filesystem::type_present(f) && filesystem::permissions_present(f); -} -inline BOOST_CONSTEXPR bool exists(file_status f) BOOST_NOEXCEPT -{ - return f.type() != status_error && f.type() != file_not_found; -} -inline BOOST_CONSTEXPR bool is_regular_file(file_status f) BOOST_NOEXCEPT -{ - return f.type() == regular_file; -} -inline BOOST_CONSTEXPR bool is_directory(file_status f) BOOST_NOEXCEPT -{ - return f.type() == directory_file; -} -inline BOOST_CONSTEXPR bool is_symlink(file_status f) BOOST_NOEXCEPT -{ - return f.type() == symlink_file; -} -inline BOOST_CONSTEXPR bool is_other(file_status f) BOOST_NOEXCEPT -{ - return filesystem::exists(f) && !filesystem::is_regular_file(f) - && !filesystem::is_directory(f) && !filesystem::is_symlink(f); -} - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED -inline bool is_regular(file_status f) BOOST_NOEXCEPT { return filesystem::is_regular_file(f); } -# endif - -} // namespace filesystem -} // namespace boost - -#include <boost/config/abi_suffix.hpp> // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_FILE_STATUS_HPP diff --git a/ThirdParty/boost/filesystem/operations.hpp b/ThirdParty/boost/filesystem/operations.hpp deleted file mode 100644 index 2838343cbe9e4b1c6d2597ea089d1ff949d42ea1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem/operations.hpp +++ /dev/null @@ -1,463 +0,0 @@ -// boost/filesystem/operations.hpp ---------------------------------------------------// - -// Copyright Beman Dawes 2002-2009 -// Copyright Jan Langer 2002 -// Copyright Dietmar Kuehl 2001 -// Copyright Vladimir Prus 2002 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_OPERATIONS_HPP -#define BOOST_FILESYSTEM3_OPERATIONS_HPP - -#include <boost/config.hpp> - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include <boost/filesystem/config.hpp> -#include <boost/filesystem/path.hpp> -#include <boost/filesystem/file_status.hpp> - -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED -// These includes are left for backward compatibility and should be included directly by users, as needed -#include <boost/filesystem/exception.hpp> -#include <boost/filesystem/directory.hpp> -#endif - -#include <boost/core/scoped_enum.hpp> -#include <boost/system/error_code.hpp> -#include <boost/cstdint.hpp> -#include <string> -#include <ctime> - -#include <boost/config/abi_prefix.hpp> // must be the last #include - -//--------------------------------------------------------------------------------------// - -namespace boost { -namespace filesystem { - -struct space_info -{ - // all values are byte counts - boost::uintmax_t capacity; - boost::uintmax_t free; // <= capacity - boost::uintmax_t available; // <= free -}; - -BOOST_SCOPED_ENUM_DECLARE_BEGIN(copy_option) - {none=0, fail_if_exists = none, overwrite_if_exists} -BOOST_SCOPED_ENUM_DECLARE_END(copy_option) - -//--------------------------------------------------------------------------------------// -// implementation details // -//--------------------------------------------------------------------------------------// - -namespace detail { - -// We cannot pass a BOOST_SCOPED_ENUM to a compled function because it will result -// in an undefined reference if the library is compled with -std=c++0x but the use -// is compiled in C++03 mode, or vice versa. See tickets 6124, 6779, 10038. -enum copy_option {none=0, fail_if_exists = none, overwrite_if_exists}; - -BOOST_FILESYSTEM_DECL -file_status status(const path&p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -file_status symlink_status(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -bool is_empty(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path initial_path(system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path canonical(const path& p, const path& base, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void copy(const path& from, const path& to, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void copy_directory(const path& from, const path& to, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void copy_file(const path& from, const path& to, // See ticket #2925 - detail::copy_option option, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void copy_symlink(const path& existing_symlink, const path& new_symlink, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -bool create_directories(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -bool create_directory(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void create_directory_symlink(const path& to, const path& from, - system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void create_hard_link(const path& to, const path& from, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void create_symlink(const path& to, const path& from, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path current_path(system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void current_path(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -bool equivalent(const path& p1, const path& p2, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -boost::uintmax_t file_size(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -boost::uintmax_t hard_link_count(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -std::time_t last_write_time(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void last_write_time(const path& p, const std::time_t new_time, - system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void permissions(const path& p, perms prms, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path read_symlink(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path relative(const path& p, const path& base, system::error_code* ec = 0); -BOOST_FILESYSTEM_DECL -bool remove(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -boost::uintmax_t remove_all(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void rename(const path& old_p, const path& new_p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -void resize_file(const path& p, uintmax_t size, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -space_info space(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path system_complete(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path temp_directory_path(system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path unique_path(const path& p, system::error_code* ec=0); -BOOST_FILESYSTEM_DECL -path weakly_canonical(const path& p, system::error_code* ec = 0); - -} // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// status query functions // -// // -//--------------------------------------------------------------------------------------// - -inline -file_status status(const path& p) {return detail::status(p);} -inline -file_status status(const path& p, system::error_code& ec) - {return detail::status(p, &ec);} -inline -file_status symlink_status(const path& p) {return detail::symlink_status(p);} -inline -file_status symlink_status(const path& p, system::error_code& ec) - {return detail::symlink_status(p, &ec);} -inline -bool exists(const path& p) {return exists(detail::status(p));} -inline -bool exists(const path& p, system::error_code& ec) - {return exists(detail::status(p, &ec));} -inline -bool is_directory(const path& p) {return is_directory(detail::status(p));} -inline -bool is_directory(const path& p, system::error_code& ec) - {return is_directory(detail::status(p, &ec));} -inline -bool is_regular_file(const path& p) {return is_regular_file(detail::status(p));} -inline -bool is_regular_file(const path& p, system::error_code& ec) - {return is_regular_file(detail::status(p, &ec));} -inline -bool is_other(const path& p) {return is_other(detail::status(p));} -inline -bool is_other(const path& p, system::error_code& ec) - {return is_other(detail::status(p, &ec));} -inline -bool is_symlink(const path& p) {return is_symlink(detail::symlink_status(p));} -inline -bool is_symlink(const path& p, system::error_code& ec) - {return is_symlink(detail::symlink_status(p, &ec));} -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED -inline -bool is_regular(const path& p) {return is_regular(detail::status(p));} -inline -bool is_regular(const path& p, system::error_code& ec) - {return is_regular(detail::status(p, &ec));} -#endif - -inline -bool is_empty(const path& p) {return detail::is_empty(p);} -inline -bool is_empty(const path& p, system::error_code& ec) - {return detail::is_empty(p, &ec);} - -//--------------------------------------------------------------------------------------// -// // -// operational functions // -// in alphabetical order, unless otherwise noted // -// // -//--------------------------------------------------------------------------------------// - -// forward declarations -path current_path(); // fwd declaration -path initial_path(); - -BOOST_FILESYSTEM_DECL -path absolute(const path& p, const path& base=current_path()); -// If base.is_absolute(), throws nothing. Thus no need for ec argument - -inline -path canonical(const path& p, const path& base=current_path()) - {return detail::canonical(p, base);} -inline -path canonical(const path& p, system::error_code& ec) - {return detail::canonical(p, current_path(), &ec);} -inline -path canonical(const path& p, const path& base, system::error_code& ec) - {return detail::canonical(p, base, &ec);} - -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED -inline -path complete(const path& p) -{ - return absolute(p, initial_path()); -} - -inline -path complete(const path& p, const path& base) -{ - return absolute(p, base); -} -#endif - -inline -void copy(const path& from, const path& to) {detail::copy(from, to);} - -inline -void copy(const path& from, const path& to, system::error_code& ec) BOOST_NOEXCEPT - {detail::copy(from, to, &ec);} -inline -void copy_directory(const path& from, const path& to) - {detail::copy_directory(from, to);} -inline -void copy_directory(const path& from, const path& to, system::error_code& ec) BOOST_NOEXCEPT - {detail::copy_directory(from, to, &ec);} -inline -void copy_file(const path& from, const path& to, // See ticket #2925 - BOOST_SCOPED_ENUM_NATIVE(copy_option) option) -{ - detail::copy_file(from, to, static_cast<detail::copy_option>(option)); -} -inline -void copy_file(const path& from, const path& to) -{ - detail::copy_file(from, to, detail::fail_if_exists); -} -inline -void copy_file(const path& from, const path& to, // See ticket #2925 - BOOST_SCOPED_ENUM_NATIVE(copy_option) option, system::error_code& ec) BOOST_NOEXCEPT -{ - detail::copy_file(from, to, static_cast<detail::copy_option>(option), &ec); -} -inline -void copy_file(const path& from, const path& to, system::error_code& ec) BOOST_NOEXCEPT -{ - detail::copy_file(from, to, detail::fail_if_exists, &ec); -} -inline -void copy_symlink(const path& existing_symlink, - const path& new_symlink) {detail::copy_symlink(existing_symlink, new_symlink);} - -inline -void copy_symlink(const path& existing_symlink, const path& new_symlink, - system::error_code& ec) BOOST_NOEXCEPT - {detail::copy_symlink(existing_symlink, new_symlink, &ec);} -inline -bool create_directories(const path& p) {return detail::create_directories(p);} - -inline -bool create_directories(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::create_directories(p, &ec);} -inline -bool create_directory(const path& p) {return detail::create_directory(p);} - -inline -bool create_directory(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::create_directory(p, &ec);} -inline -void create_directory_symlink(const path& to, const path& from) - {detail::create_directory_symlink(to, from);} -inline -void create_directory_symlink(const path& to, const path& from, system::error_code& ec) BOOST_NOEXCEPT - {detail::create_directory_symlink(to, from, &ec);} -inline -void create_hard_link(const path& to, const path& new_hard_link) {detail::create_hard_link(to, new_hard_link);} - -inline -void create_hard_link(const path& to, const path& new_hard_link, system::error_code& ec) BOOST_NOEXCEPT - {detail::create_hard_link(to, new_hard_link, &ec);} -inline -void create_symlink(const path& to, const path& new_symlink) {detail::create_symlink(to, new_symlink);} - -inline -void create_symlink(const path& to, const path& new_symlink, system::error_code& ec) BOOST_NOEXCEPT - {detail::create_symlink(to, new_symlink, &ec);} -inline -path current_path() {return detail::current_path();} - -inline -path current_path(system::error_code& ec) {return detail::current_path(&ec);} - -inline -void current_path(const path& p) {detail::current_path(p);} - -inline -void current_path(const path& p, system::error_code& ec) BOOST_NOEXCEPT {detail::current_path(p, &ec);} - -inline -bool equivalent(const path& p1, const path& p2) {return detail::equivalent(p1, p2);} - -inline -bool equivalent(const path& p1, const path& p2, system::error_code& ec) BOOST_NOEXCEPT - {return detail::equivalent(p1, p2, &ec);} -inline -boost::uintmax_t file_size(const path& p) {return detail::file_size(p);} - -inline -boost::uintmax_t file_size(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::file_size(p, &ec);} -inline -boost::uintmax_t hard_link_count(const path& p) {return detail::hard_link_count(p);} - -inline -boost::uintmax_t hard_link_count(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::hard_link_count(p, &ec);} -inline -path initial_path() {return detail::initial_path();} - -inline -path initial_path(system::error_code& ec) {return detail::initial_path(&ec);} - -template <class Path> -path initial_path() {return initial_path();} -template <class Path> -path initial_path(system::error_code& ec) {return detail::initial_path(&ec);} - -inline -std::time_t last_write_time(const path& p) {return detail::last_write_time(p);} - -inline -std::time_t last_write_time(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::last_write_time(p, &ec);} -inline -void last_write_time(const path& p, const std::time_t new_time) - {detail::last_write_time(p, new_time);} -inline -void last_write_time(const path& p, const std::time_t new_time, - system::error_code& ec) BOOST_NOEXCEPT - {detail::last_write_time(p, new_time, &ec);} -inline -void permissions(const path& p, perms prms) - {detail::permissions(p, prms);} -inline -void permissions(const path& p, perms prms, system::error_code& ec) BOOST_NOEXCEPT - {detail::permissions(p, prms, &ec);} - -inline -path read_symlink(const path& p) {return detail::read_symlink(p);} - -inline -path read_symlink(const path& p, system::error_code& ec) - {return detail::read_symlink(p, &ec);} - -inline -bool remove(const path& p) {return detail::remove(p);} - -inline -bool remove(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::remove(p, &ec);} - -inline -boost::uintmax_t remove_all(const path& p) {return detail::remove_all(p);} - -inline -boost::uintmax_t remove_all(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::remove_all(p, &ec);} -inline -void rename(const path& old_p, const path& new_p) {detail::rename(old_p, new_p);} - -inline -void rename(const path& old_p, const path& new_p, system::error_code& ec) BOOST_NOEXCEPT - {detail::rename(old_p, new_p, &ec);} -inline // name suggested by Scott McMurray -void resize_file(const path& p, uintmax_t size) {detail::resize_file(p, size);} - -inline -void resize_file(const path& p, uintmax_t size, system::error_code& ec) BOOST_NOEXCEPT - {detail::resize_file(p, size, &ec);} -inline -path relative(const path& p, const path& base=current_path()) - {return detail::relative(p, base);} -inline -path relative(const path& p, system::error_code& ec) - {return detail::relative(p, current_path(), &ec);} -inline -path relative(const path& p, const path& base, system::error_code& ec) - {return detail::relative(p, base, &ec);} -inline -space_info space(const path& p) {return detail::space(p);} - -inline -space_info space(const path& p, system::error_code& ec) BOOST_NOEXCEPT - {return detail::space(p, &ec);} - -#ifndef BOOST_FILESYSTEM_NO_DEPRECATED -inline bool symbolic_link_exists(const path& p) - { return is_symlink(filesystem::symlink_status(p)); } -#endif - -inline -path system_complete(const path& p) {return detail::system_complete(p);} - -inline -path system_complete(const path& p, system::error_code& ec) - {return detail::system_complete(p, &ec);} -inline -path temp_directory_path() {return detail::temp_directory_path();} - -inline -path temp_directory_path(system::error_code& ec) - {return detail::temp_directory_path(&ec);} -inline -path unique_path(const path& p="%%%%-%%%%-%%%%-%%%%") - {return detail::unique_path(p);} -inline -path unique_path(const path& p, system::error_code& ec) - {return detail::unique_path(p, &ec);} -inline -path weakly_canonical(const path& p) {return detail::weakly_canonical(p);} - -inline -path weakly_canonical(const path& p, system::error_code& ec) - {return detail::weakly_canonical(p, &ec);} - -// test helper -----------------------------------------------------------------------// - -// Not part of the documented interface since false positives are possible; -// there is no law that says that an OS that has large stat.st_size -// actually supports large file sizes. - -namespace detail { - -BOOST_FILESYSTEM_DECL bool possible_large_file_size_support(); - -} // namespace detail - -} // namespace filesystem -} // namespace boost - -#include <boost/config/abi_suffix.hpp> // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_OPERATIONS_HPP diff --git a/ThirdParty/boost/filesystem/path.hpp b/ThirdParty/boost/filesystem/path.hpp deleted file mode 100644 index d8fe2039300d8551737a4e36a699c69a950e5579..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/filesystem/path.hpp +++ /dev/null @@ -1,1039 +0,0 @@ -// filesystem path.hpp ---------------------------------------------------------------// - -// Copyright Beman Dawes 2002-2005, 2009 -// Copyright Vladimir Prus 2002 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -// path::stem(), extension(), and replace_extension() are based on -// basename(), extension(), and change_extension() from the original -// filesystem/convenience.hpp header by Vladimir Prus. - -#ifndef BOOST_FILESYSTEM_PATH_HPP -#define BOOST_FILESYSTEM_PATH_HPP - -#include <boost/config.hpp> - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include <boost/assert.hpp> -#include <boost/filesystem/config.hpp> -#include <boost/filesystem/path_traits.hpp> // includes <cwchar> -#include <boost/system/error_code.hpp> -#include <boost/system/system_error.hpp> -#include <boost/iterator/iterator_facade.hpp> -#include <boost/iterator/iterator_categories.hpp> -#include <boost/core/enable_if.hpp> -#include <boost/io/quoted.hpp> -#include <boost/functional/hash_fwd.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <string> -#include <iterator> -#include <cstring> -#include <iosfwd> -#include <stdexcept> -#include <cassert> -#include <locale> -#include <algorithm> - -#include <boost/config/abi_prefix.hpp> // must be the last #include - -namespace boost -{ -namespace filesystem -{ -namespace path_detail // intentionally don't use filesystem::detail to not bring internal Boost.Filesystem functions into ADL via path_constants -{ - - template< typename Char, Char Separator, Char PreferredSeparator, Char Dot > - struct path_constants - { - typedef path_constants< Char, Separator, PreferredSeparator, Dot > path_constants_base; - typedef Char value_type; - static BOOST_CONSTEXPR_OR_CONST value_type separator = Separator; - static BOOST_CONSTEXPR_OR_CONST value_type preferred_separator = PreferredSeparator; - static BOOST_CONSTEXPR_OR_CONST value_type dot = Dot; - }; - -#if defined(BOOST_NO_CXX17_INLINE_VARIABLES) - template< typename Char, Char Separator, Char PreferredSeparator, Char Dot > - BOOST_CONSTEXPR_OR_CONST typename path_constants< Char, Separator, PreferredSeparator, Dot >::value_type - path_constants< Char, Separator, PreferredSeparator, Dot >::separator; - template< typename Char, Char Separator, Char PreferredSeparator, Char Dot > - BOOST_CONSTEXPR_OR_CONST typename path_constants< Char, Separator, PreferredSeparator, Dot >::value_type - path_constants< Char, Separator, PreferredSeparator, Dot >::preferred_separator; - template< typename Char, Char Separator, Char PreferredSeparator, Char Dot > - BOOST_CONSTEXPR_OR_CONST typename path_constants< Char, Separator, PreferredSeparator, Dot >::value_type - path_constants< Char, Separator, PreferredSeparator, Dot >::dot; -#endif - -} // namespace path_detail - - //------------------------------------------------------------------------------------// - // // - // class path // - // // - //------------------------------------------------------------------------------------// - - class path : - public filesystem::path_detail::path_constants< -#ifdef BOOST_WINDOWS_API - wchar_t, L'/', L'\\', L'.' -#else - char, '/', '/', '.' -#endif - > - { - public: - - // value_type is the character type used by the operating system API to - // represent paths. - - typedef path_constants_base::value_type value_type; - typedef std::basic_string<value_type> string_type; - typedef std::codecvt<wchar_t, char, - std::mbstate_t> codecvt_type; - - - // ----- character encoding conversions ----- - - // Following the principle of least astonishment, path input arguments - // passed to or obtained from the operating system via objects of - // class path behave as if they were directly passed to or - // obtained from the O/S API, unless conversion is explicitly requested. - // - // POSIX specfies that path strings are passed unchanged to and from the - // API. Note that this is different from the POSIX command line utilities, - // which convert according to a locale. - // - // Thus for POSIX, char strings do not undergo conversion. wchar_t strings - // are converted to/from char using the path locale or, if a conversion - // argument is given, using a conversion object modeled on - // std::wstring_convert. - // - // The path locale, which is global to the thread, can be changed by the - // imbue() function. It is initialized to an implementation defined locale. - // - // For Windows, wchar_t strings do not undergo conversion. char strings - // are converted using the "ANSI" or "OEM" code pages, as determined by - // the AreFileApisANSI() function, or, if a conversion argument is given, - // using a conversion object modeled on std::wstring_convert. - // - // See m_pathname comments for further important rationale. - - // TODO: rules needed for operating systems that use / or . - // differently, or format directory paths differently from file paths. - // - // ********************************************************************************** - // - // More work needed: How to handle an operating system that may have - // slash characters or dot characters in valid filenames, either because - // it doesn't follow the POSIX standard, or because it allows MBCS - // filename encodings that may contain slash or dot characters. For - // example, ISO/IEC 2022 (JIS) encoding which allows switching to - // JIS x0208-1983 encoding. A valid filename in this set of encodings is - // 0x1B 0x24 0x42 [switch to X0208-1983] 0x24 0x2F [U+304F Kiragana letter KU] - // ^^^^ - // Note that 0x2F is the ASCII slash character - // - // ********************************************************************************** - - // Supported source arguments: half-open iterator range, container, c-array, - // and single pointer to null terminated string. - - // All source arguments except pointers to null terminated byte strings support - // multi-byte character strings which may have embedded nulls. Embedded null - // support is required for some Asian languages on Windows. - - // "const codecvt_type& cvt=codecvt()" default arguments are not used because this - // limits the impact of locale("") initialization failures on POSIX systems to programs - // that actually depend on locale(""). It further ensures that exceptions thrown - // as a result of such failues occur after main() has started, so can be caught. - - // ----- constructors ----- - - path() BOOST_NOEXCEPT {} - path(const path& p) : m_pathname(p.m_pathname) {} - - template <class Source> - path(Source const& source, - typename boost::enable_if<path_traits::is_pathable< - typename boost::decay<Source>::type> >::type* =0) - { - path_traits::dispatch(source, m_pathname); - } - - path(const value_type* s) : m_pathname(s) {} - path(value_type* s) : m_pathname(s) {} - path(const string_type& s) : m_pathname(s) {} - path(string_type& s) : m_pathname(s) {} - - // As of October 2015 the interaction between noexcept and =default is so troublesome - // for VC++, GCC, and probably other compilers, that =default is not used with noexcept - // functions. GCC is not even consistent for the same release on different platforms. - -# if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - path(path&& p) BOOST_NOEXCEPT : m_pathname(std::move(p.m_pathname)) {} - path& operator=(path&& p) BOOST_NOEXCEPT - { m_pathname = std::move(p.m_pathname); return *this; } -# endif - - template <class Source> - path(Source const& source, const codecvt_type& cvt) - { - path_traits::dispatch(source, m_pathname, cvt); - } - - template <class InputIterator> - path(InputIterator begin, InputIterator end) - { - if (begin != end) - { - // convert requires contiguous string, so copy - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname); - } - } - - template <class InputIterator> - path(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin != end) - { - // convert requires contiguous string, so copy - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname, cvt); - } - } - - // ----- assignments ----- - - path& operator=(const path& p) - { - m_pathname = p.m_pathname; - return *this; - } - - template <class Source> - typename boost::enable_if<path_traits::is_pathable< - typename boost::decay<Source>::type>, path&>::type - operator=(Source const& source) - { - m_pathname.clear(); - path_traits::dispatch(source, m_pathname); - return *this; - } - - // value_type overloads - - path& operator=(const value_type* ptr) // required in case ptr overlaps *this - {m_pathname = ptr; return *this;} - path& operator=(value_type* ptr) // required in case ptr overlaps *this - {m_pathname = ptr; return *this;} - path& operator=(const string_type& s) {m_pathname = s; return *this;} - path& operator=(string_type& s) {m_pathname = s; return *this;} - - path& assign(const value_type* ptr, const codecvt_type&) // required in case ptr overlaps *this - {m_pathname = ptr; return *this;} - template <class Source> - path& assign(Source const& source, const codecvt_type& cvt) - { - m_pathname.clear(); - path_traits::dispatch(source, m_pathname, cvt); - return *this; - } - - template <class InputIterator> - path& assign(InputIterator begin, InputIterator end) - { - m_pathname.clear(); - if (begin != end) - { - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname); - } - return *this; - } - - template <class InputIterator> - path& assign(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - m_pathname.clear(); - if (begin != end) - { - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname, cvt); - } - return *this; - } - - // ----- concatenation ----- - - template <class Source> - typename boost::enable_if<path_traits::is_pathable< - typename boost::decay<Source>::type>, path&>::type - operator+=(Source const& source) - { - return concat(source); - } - - // value_type overloads. Same rationale as for constructors above - path& operator+=(const path& p) { m_pathname += p.m_pathname; return *this; } - path& operator+=(const value_type* ptr) { m_pathname += ptr; return *this; } - path& operator+=(value_type* ptr) { m_pathname += ptr; return *this; } - path& operator+=(const string_type& s) { m_pathname += s; return *this; } - path& operator+=(string_type& s) { m_pathname += s; return *this; } - path& operator+=(value_type c) { m_pathname += c; return *this; } - - template <class CharT> - typename boost::enable_if<boost::is_integral<CharT>, path&>::type - operator+=(CharT c) - { - CharT tmp[2]; - tmp[0] = c; - tmp[1] = 0; - return concat(tmp); - } - - template <class Source> - path& concat(Source const& source) - { - path_traits::dispatch(source, m_pathname); - return *this; - } - - template <class Source> - path& concat(Source const& source, const codecvt_type& cvt) - { - path_traits::dispatch(source, m_pathname, cvt); - return *this; - } - - template <class InputIterator> - path& concat(InputIterator begin, InputIterator end) - { - if (begin == end) - return *this; - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname); - return *this; - } - - template <class InputIterator> - path& concat(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin == end) - return *this; - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname, cvt); - return *this; - } - - // ----- appends ----- - - // if a separator is added, it is the preferred separator for the platform; - // slash for POSIX, backslash for Windows - - BOOST_FILESYSTEM_DECL path& operator/=(const path& p); - - template <class Source> - typename boost::enable_if<path_traits::is_pathable< - typename boost::decay<Source>::type>, path&>::type - operator/=(Source const& source) - { - return append(source); - } - - BOOST_FILESYSTEM_DECL path& operator/=(const value_type* ptr); - path& operator/=(value_type* ptr) - { - return this->operator/=(const_cast<const value_type*>(ptr)); - } - path& operator/=(const string_type& s) { return this->operator/=(path(s)); } - path& operator/=(string_type& s) { return this->operator/=(path(s)); } - - path& append(const value_type* ptr) // required in case ptr overlaps *this - { - this->operator/=(ptr); - return *this; - } - - path& append(const value_type* ptr, const codecvt_type&) // required in case ptr overlaps *this - { - this->operator/=(ptr); - return *this; - } - - template <class Source> - path& append(Source const& source); - - template <class Source> - path& append(Source const& source, const codecvt_type& cvt); - - template <class InputIterator> - path& append(InputIterator begin, InputIterator end); - - template <class InputIterator> - path& append(InputIterator begin, InputIterator end, const codecvt_type& cvt); - - // ----- modifiers ----- - - void clear() BOOST_NOEXCEPT { m_pathname.clear(); } -# ifdef BOOST_POSIX_API - path& make_preferred() { return *this; } // POSIX no effect -# else // BOOST_WINDOWS_API - BOOST_FILESYSTEM_DECL path& make_preferred(); // change slashes to backslashes -# endif - BOOST_FILESYSTEM_DECL path& remove_filename(); - BOOST_FILESYSTEM_DECL path& remove_trailing_separator(); - BOOST_FILESYSTEM_DECL path& replace_extension(const path& new_extension = path()); - void swap(path& rhs) BOOST_NOEXCEPT { m_pathname.swap(rhs.m_pathname); } - - // ----- observers ----- - - // For operating systems that format file paths differently than directory - // paths, return values from observers are formatted as file names unless there - // is a trailing separator, in which case returns are formatted as directory - // paths. POSIX and Windows make no such distinction. - - // Implementations are permitted to return const values or const references. - - // The string or path returned by an observer are specified as being formatted - // as "native" or "generic". - // - // For POSIX, these are all the same format; slashes and backslashes are as input and - // are not modified. - // - // For Windows, native: as input; slashes and backslashes are not modified; - // this is the format of the internally stored string. - // generic: backslashes are converted to slashes - - // ----- native format observers ----- - - const string_type& native() const BOOST_NOEXCEPT { return m_pathname; } - const value_type* c_str() const BOOST_NOEXCEPT { return m_pathname.c_str(); } - string_type::size_type size() const BOOST_NOEXCEPT { return m_pathname.size(); } - - template <class String> - String string() const; - - template <class String> - String string(const codecvt_type& cvt) const; - -# ifdef BOOST_WINDOWS_API - const std::string string() const - { - std::string tmp; - if (!m_pathname.empty()) - path_traits::convert(m_pathname.c_str(), m_pathname.c_str()+m_pathname.size(), - tmp); - return tmp; - } - const std::string string(const codecvt_type& cvt) const - { - std::string tmp; - if (!m_pathname.empty()) - path_traits::convert(m_pathname.c_str(), m_pathname.c_str()+m_pathname.size(), - tmp, cvt); - return tmp; - } - - // string_type is std::wstring, so there is no conversion - const std::wstring& wstring() const { return m_pathname; } - const std::wstring& wstring(const codecvt_type&) const { return m_pathname; } -# else // BOOST_POSIX_API - // string_type is std::string, so there is no conversion - const std::string& string() const { return m_pathname; } - const std::string& string(const codecvt_type&) const { return m_pathname; } - - const std::wstring wstring() const - { - std::wstring tmp; - if (!m_pathname.empty()) - path_traits::convert(m_pathname.c_str(), m_pathname.c_str()+m_pathname.size(), - tmp); - return tmp; - } - const std::wstring wstring(const codecvt_type& cvt) const - { - std::wstring tmp; - if (!m_pathname.empty()) - path_traits::convert(m_pathname.c_str(), m_pathname.c_str()+m_pathname.size(), - tmp, cvt); - return tmp; - } -# endif - - // ----- generic format observers ----- - - // Experimental generic function returning generic formatted path (i.e. separators - // are forward slashes). Motivation: simpler than a family of generic_*string - // functions. -# ifdef BOOST_WINDOWS_API - BOOST_FILESYSTEM_DECL path generic_path() const; -# else - path generic_path() const { return path(*this); } -# endif - - template <class String> - String generic_string() const; - - template <class String> - String generic_string(const codecvt_type& cvt) const; - -# ifdef BOOST_WINDOWS_API - const std::string generic_string() const { return generic_path().string(); } - const std::string generic_string(const codecvt_type& cvt) const { return generic_path().string(cvt); } - const std::wstring generic_wstring() const { return generic_path().wstring(); } - const std::wstring generic_wstring(const codecvt_type&) const { return generic_wstring(); } -# else // BOOST_POSIX_API - // On POSIX-like systems, the generic format is the same as the native format - const std::string& generic_string() const { return m_pathname; } - const std::string& generic_string(const codecvt_type&) const { return m_pathname; } - const std::wstring generic_wstring() const { return this->wstring(); } - const std::wstring generic_wstring(const codecvt_type& cvt) const { return this->wstring(cvt); } -# endif - - // ----- compare ----- - - BOOST_FILESYSTEM_DECL int compare(const path& p) const BOOST_NOEXCEPT; // generic, lexicographical - int compare(const std::string& s) const { return compare(path(s)); } - int compare(const value_type* s) const { return compare(path(s)); } - - // ----- decomposition ----- - - BOOST_FILESYSTEM_DECL path root_path() const; - BOOST_FILESYSTEM_DECL path root_name() const; // returns 0 or 1 element path - // even on POSIX, root_name() is non-empty() for network paths - BOOST_FILESYSTEM_DECL path root_directory() const; // returns 0 or 1 element path - BOOST_FILESYSTEM_DECL path relative_path() const; - BOOST_FILESYSTEM_DECL path parent_path() const; - BOOST_FILESYSTEM_DECL path filename() const; // returns 0 or 1 element path - BOOST_FILESYSTEM_DECL path stem() const; // returns 0 or 1 element path - BOOST_FILESYSTEM_DECL path extension() const; // returns 0 or 1 element path - - // ----- query ----- - - bool empty() const BOOST_NOEXCEPT { return m_pathname.empty(); } - bool filename_is_dot() const; - bool filename_is_dot_dot() const; - bool has_root_path() const { return has_root_directory() || has_root_name(); } - bool has_root_name() const { return !root_name().empty(); } - bool has_root_directory() const { return !root_directory().empty(); } - bool has_relative_path() const { return !relative_path().empty(); } - bool has_parent_path() const { return !parent_path().empty(); } - bool has_filename() const { return !m_pathname.empty(); } - bool has_stem() const { return !stem().empty(); } - bool has_extension() const { return !extension().empty(); } - bool is_relative() const { return !is_absolute(); } - bool is_absolute() const - { - // Windows CE has no root name (aka drive letters) -# if defined(BOOST_WINDOWS_API) && !defined(UNDER_CE) - return has_root_name() && has_root_directory(); -# else - return has_root_directory(); -# endif - } - - // ----- lexical operations ----- - - BOOST_FILESYSTEM_DECL path lexically_normal() const; - BOOST_FILESYSTEM_DECL path lexically_relative(const path& base) const; - path lexically_proximate(const path& base) const - { - path tmp(lexically_relative(base)); - return tmp.empty() ? *this : tmp; - } - - // ----- iterators ----- - - class iterator; - typedef iterator const_iterator; - class reverse_iterator; - typedef reverse_iterator const_reverse_iterator; - - BOOST_FILESYSTEM_DECL iterator begin() const; - BOOST_FILESYSTEM_DECL iterator end() const; - reverse_iterator rbegin() const; - reverse_iterator rend() const; - - // ----- static member functions ----- - - static BOOST_FILESYSTEM_DECL std::locale imbue(const std::locale& loc); - static BOOST_FILESYSTEM_DECL const codecvt_type& codecvt(); - - // ----- deprecated functions ----- - -# if defined(BOOST_FILESYSTEM_DEPRECATED) && defined(BOOST_FILESYSTEM_NO_DEPRECATED) -# error both BOOST_FILESYSTEM_DEPRECATED and BOOST_FILESYSTEM_NO_DEPRECATED are defined -# endif - -# if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) - // recently deprecated functions supplied by default - path& normalize() { - path tmp(lexically_normal()); - m_pathname.swap(tmp.m_pathname); - return *this; - } - path& remove_leaf() { return remove_filename(); } - path leaf() const { return filename(); } - path branch_path() const { return parent_path(); } - path generic() const { return generic_path(); } - bool has_leaf() const { return !m_pathname.empty(); } - bool has_branch_path() const { return !parent_path().empty(); } - bool is_complete() const { return is_absolute(); } -# endif - -# if defined(BOOST_FILESYSTEM_DEPRECATED) - // deprecated functions with enough signature or semantic changes that they are - // not supplied by default - const std::string file_string() const { return string(); } - const std::string directory_string() const { return string(); } - const std::string native_file_string() const { return string(); } - const std::string native_directory_string() const { return string(); } - const string_type external_file_string() const { return native(); } - const string_type external_directory_string() const { return native(); } - - // older functions no longer supported - //typedef bool (*name_check)(const std::string & name); - //basic_path(const string_type& str, name_check) { operator/=(str); } - //basic_path(const typename string_type::value_type* s, name_check) - // { operator/=(s);} - //static bool default_name_check_writable() { return false; } - //static void default_name_check(name_check) {} - //static name_check default_name_check() { return 0; } - //basic_path& canonize(); -# endif - -//--------------------------------------------------------------------------------------// -// class path private members // -//--------------------------------------------------------------------------------------// - - private: - -# if defined(_MSC_VER) -# pragma warning(push) // Save warning settings -# pragma warning(disable : 4251) // disable warning: class 'std::basic_string<_Elem,_Traits,_Ax>' -# endif // needs to have dll-interface... -/* - m_pathname has the type, encoding, and format required by the native - operating system. Thus for POSIX and Windows there is no conversion for - passing m_pathname.c_str() to the O/S API or when obtaining a path from the - O/S API. POSIX encoding is unspecified other than for dot and slash - characters; POSIX just treats paths as a sequence of bytes. Windows - encoding is UCS-2 or UTF-16 depending on the version. -*/ - string_type m_pathname; // Windows: as input; backslashes NOT converted to slashes, - // slashes NOT converted to backslashes -# if defined(_MSC_VER) -# pragma warning(pop) // restore warning settings. -# endif - - // Returns: If separator is to be appended, m_pathname.size() before append. Otherwise 0. - // Note: An append is never performed if size()==0, so a returned 0 is unambiguous. - BOOST_FILESYSTEM_DECL string_type::size_type m_append_separator_if_needed(); - - BOOST_FILESYSTEM_DECL void m_erase_redundant_separator(string_type::size_type sep_pos); - BOOST_FILESYSTEM_DECL string_type::size_type m_parent_path_end() const; - - // Was qualified; como433beta8 reports: - // warning #427-D: qualified name is not allowed in member declaration - friend class iterator; - friend bool operator<(const path& lhs, const path& rhs); - - // see path::iterator::increment/decrement comment below - static BOOST_FILESYSTEM_DECL void m_path_iterator_increment(path::iterator& it); - static BOOST_FILESYSTEM_DECL void m_path_iterator_decrement(path::iterator& it); - - }; // class path - - namespace detail - { - BOOST_FILESYSTEM_DECL - int lex_compare(path::iterator first1, path::iterator last1, - path::iterator first2, path::iterator last2); - BOOST_FILESYSTEM_DECL - const path& dot_path(); - BOOST_FILESYSTEM_DECL - const path& dot_dot_path(); - } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - typedef path wpath; -# endif - - //------------------------------------------------------------------------------------// - // class path::iterator // - //------------------------------------------------------------------------------------// - - class path::iterator - : public boost::iterator_facade< - path::iterator, - path const, - boost::bidirectional_traversal_tag > - { - private: - friend class boost::iterator_core_access; - friend class boost::filesystem::path; - friend class boost::filesystem::path::reverse_iterator; - friend void m_path_iterator_increment(path::iterator & it); - friend void m_path_iterator_decrement(path::iterator & it); - - const path& dereference() const { return m_element; } - - bool equal(const iterator & rhs) const - { - return m_path_ptr == rhs.m_path_ptr && m_pos == rhs.m_pos; - } - - // iterator_facade derived classes don't seem to like implementations in - // separate translation unit dll's, so forward to class path static members - void increment() { m_path_iterator_increment(*this); } - void decrement() { m_path_iterator_decrement(*this); } - - path m_element; // current element - const path* m_path_ptr; // path being iterated over - string_type::size_type m_pos; // position of m_element in - // m_path_ptr->m_pathname. - // if m_element is implicit dot, m_pos is the - // position of the last separator in the path. - // end() iterator is indicated by - // m_pos == m_path_ptr->m_pathname.size() - }; // path::iterator - - //------------------------------------------------------------------------------------// - // class path::reverse_iterator // - //------------------------------------------------------------------------------------// - - class path::reverse_iterator - : public boost::iterator_facade< - path::reverse_iterator, - path const, - boost::bidirectional_traversal_tag > - { - public: - explicit reverse_iterator(iterator itr) : m_itr(itr) - { - if (itr != itr.m_path_ptr->begin()) - m_element = *--itr; - } - - private: - friend class boost::iterator_core_access; - friend class boost::filesystem::path; - - const path& dereference() const { return m_element; } - bool equal(const reverse_iterator& rhs) const { return m_itr == rhs.m_itr; } - void increment() - { - --m_itr; - if (m_itr != m_itr.m_path_ptr->begin()) - { - iterator tmp = m_itr; - m_element = *--tmp; - } - } - void decrement() - { - m_element = *m_itr; - ++m_itr; - } - - iterator m_itr; - path m_element; - - }; // path::reverse_iterator - - //------------------------------------------------------------------------------------// - // // - // non-member functions // - // // - //------------------------------------------------------------------------------------// - - // std::lexicographical_compare would infinitely recurse because path iterators - // yield paths, so provide a path aware version - inline bool lexicographical_compare(path::iterator first1, path::iterator last1, - path::iterator first2, path::iterator last2) - { return detail::lex_compare(first1, last1, first2, last2) < 0; } - - inline bool operator==(const path& lhs, const path& rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path& lhs, const path::string_type& rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path::string_type& lhs, const path& rhs) {return rhs.compare(lhs) == 0;} - inline bool operator==(const path& lhs, const path::value_type* rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path::value_type* lhs, const path& rhs) {return rhs.compare(lhs) == 0;} - - inline bool operator!=(const path& lhs, const path& rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path& lhs, const path::string_type& rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path::string_type& lhs, const path& rhs) {return rhs.compare(lhs) != 0;} - inline bool operator!=(const path& lhs, const path::value_type* rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path::value_type* lhs, const path& rhs) {return rhs.compare(lhs) != 0;} - - // TODO: why do == and != have additional overloads, but the others don't? - - inline bool operator<(const path& lhs, const path& rhs) {return lhs.compare(rhs) < 0;} - inline bool operator<=(const path& lhs, const path& rhs) {return !(rhs < lhs);} - inline bool operator> (const path& lhs, const path& rhs) {return rhs < lhs;} - inline bool operator>=(const path& lhs, const path& rhs) {return !(lhs < rhs);} - - inline std::size_t hash_value(const path& x) BOOST_NOEXCEPT - { -# ifdef BOOST_WINDOWS_API - std::size_t seed = 0; - for(const path::value_type* it = x.c_str(); *it; ++it) - hash_combine(seed, *it == L'/' ? L'\\' : *it); - return seed; -# else // BOOST_POSIX_API - return hash_range(x.native().begin(), x.native().end()); -# endif - } - - inline void swap(path& lhs, path& rhs) BOOST_NOEXCEPT { lhs.swap(rhs); } - - inline path operator/(const path& lhs, const path& rhs) - { - path p = lhs; - p /= rhs; - return p; - } -# if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - inline path operator/(path&& lhs, const path& rhs) - { - lhs /= rhs; - return std::move(lhs); - } -# endif - - // inserters and extractors - // use boost::io::quoted() to handle spaces in paths - // use '&' as escape character to ease use for Windows paths - - template <class Char, class Traits> - inline std::basic_ostream<Char, Traits>& - operator<<(std::basic_ostream<Char, Traits>& os, const path& p) - { - return os - << boost::io::quoted(p.template string<std::basic_string<Char> >(), static_cast<Char>('&')); - } - - template <class Char, class Traits> - inline std::basic_istream<Char, Traits>& - operator>>(std::basic_istream<Char, Traits>& is, path& p) - { - std::basic_string<Char> str; - is >> boost::io::quoted(str, static_cast<Char>('&')); - p = str; - return is; - } - - // name_checks - - // These functions are holdovers from version 1. It isn't clear they have much - // usefulness, or how to generalize them for later versions. - - BOOST_FILESYSTEM_DECL bool portable_posix_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool windows_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_directory_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_file_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool native(const std::string & name); - - namespace detail - { - // For POSIX, is_directory_separator() and is_element_separator() are identical since - // a forward slash is the only valid directory separator and also the only valid - // element separator. For Windows, forward slash and back slash are the possible - // directory separators, but colon (example: "c:foo") is also an element separator. - - inline bool is_directory_separator(path::value_type c) BOOST_NOEXCEPT - { - return c == path::separator -# ifdef BOOST_WINDOWS_API - || c == path::preferred_separator -# endif - ; - } - inline bool is_element_separator(path::value_type c) BOOST_NOEXCEPT - { - return c == path::separator -# ifdef BOOST_WINDOWS_API - || c == path::preferred_separator || c == L':' -# endif - ; - } - } // namespace detail - - //------------------------------------------------------------------------------------// - // class path miscellaneous function implementations // - //------------------------------------------------------------------------------------// - - inline path::reverse_iterator path::rbegin() const { return reverse_iterator(end()); } - inline path::reverse_iterator path::rend() const { return reverse_iterator(begin()); } - - inline bool path::filename_is_dot() const - { - // implicit dot is tricky, so actually call filename(); see path::filename() example - // in reference.html - path p(filename()); - return p.size() == 1 && *p.c_str() == dot; - } - - inline bool path::filename_is_dot_dot() const - { - return size() >= 2 && m_pathname[size()-1] == dot && m_pathname[size()-2] == dot - && (m_pathname.size() == 2 || detail::is_element_separator(m_pathname[size()-3])); - // use detail::is_element_separator() rather than detail::is_directory_separator - // to deal with "c:.." edge case on Windows when ':' acts as a separator - } - -//--------------------------------------------------------------------------------------// -// class path member template implementation // -//--------------------------------------------------------------------------------------// - - template <class InputIterator> - path& path::append(InputIterator begin, InputIterator end) - { - if (begin == end) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - - template <class InputIterator> - path& path::append(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin == end) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - std::basic_string<typename std::iterator_traits<InputIterator>::value_type> - seq(begin, end); - path_traits::convert(seq.c_str(), seq.c_str()+seq.size(), m_pathname, cvt); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - - template <class Source> - path& path::append(Source const& source) - { - if (path_traits::empty(source)) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - path_traits::dispatch(source, m_pathname); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - - template <class Source> - path& path::append(Source const& source, const codecvt_type& cvt) - { - if (path_traits::empty(source)) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - path_traits::dispatch(source, m_pathname, cvt); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - -//--------------------------------------------------------------------------------------// -// class path member template specializations // -//--------------------------------------------------------------------------------------// - - template <> inline - std::string path::string<std::string>() const - { return string(); } - - template <> inline - std::wstring path::string<std::wstring>() const - { return wstring(); } - - template <> inline - std::string path::string<std::string>(const codecvt_type& cvt) const - { return string(cvt); } - - template <> inline - std::wstring path::string<std::wstring>(const codecvt_type& cvt) const - { return wstring(cvt); } - - template <> inline - std::string path::generic_string<std::string>() const - { return generic_string(); } - - template <> inline - std::wstring path::generic_string<std::wstring>() const - { return generic_wstring(); } - - template <> inline - std::string path::generic_string<std::string>(const codecvt_type& cvt) const - { return generic_string(cvt); } - - template <> inline - std::wstring path::generic_string<std::wstring>(const codecvt_type& cvt) const - { return generic_wstring(cvt); } - - //--------------------------------------------------------------------------------------// - // path_traits convert function implementations // - // requiring path::codecvt() be visable // - //--------------------------------------------------------------------------------------// - -namespace path_traits -{ // without codecvt - - inline - void convert(const char* from, - const char* from_end, // 0 for null terminated MBCS - std::wstring & to) - { - convert(from, from_end, to, path::codecvt()); - } - - inline - void convert(const wchar_t* from, - const wchar_t* from_end, // 0 for null terminated MBCS - std::string & to) - { - convert(from, from_end, to, path::codecvt()); - } - - inline - void convert(const char* from, - std::wstring & to) - { - BOOST_ASSERT(!!from); - convert(from, 0, to, path::codecvt()); - } - - inline - void convert(const wchar_t* from, - std::string & to) - { - BOOST_ASSERT(!!from); - convert(from, 0, to, path::codecvt()); - } -} // namespace path_traits -} // namespace filesystem -} // namespace boost - -//----------------------------------------------------------------------------// - -#include <boost/config/abi_suffix.hpp> // pops abi_prefix.hpp pragmas - -#endif // BOOST_FILESYSTEM_PATH_HPP diff --git a/ThirdParty/boost/function/function_base.hpp b/ThirdParty/boost/function/function_base.hpp deleted file mode 100644 index bd0e548bdff74b08f5f5d1914a363265ce9b86c9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/function/function_base.hpp +++ /dev/null @@ -1,878 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2001-2006 -// Copyright Emil Dotchevski 2007 -// Use, modification and distribution is subject to 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) - -// For more information, see http://www.boost.org - -#ifndef BOOST_FUNCTION_BASE_HEADER -#define BOOST_FUNCTION_BASE_HEADER - -#include <stdexcept> -#include <string> -#include <memory> -#include <new> -#include <boost/config.hpp> -#include <boost/assert.hpp> -#include <boost/integer.hpp> -#include <boost/type_index.hpp> -#include <boost/type_traits/has_trivial_copy.hpp> -#include <boost/type_traits/has_trivial_destructor.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <boost/type_traits/is_volatile.hpp> -#include <boost/type_traits/composite_traits.hpp> -#include <boost/ref.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/config/workaround.hpp> -#include <boost/type_traits/alignment_of.hpp> -#ifndef BOOST_NO_SFINAE -#include <boost/type_traits/enable_if.hpp> -#else -#include <boost/type_traits/integral_constant.hpp> -#endif -#include <boost/function_equal.hpp> -#include <boost/function/function_fwd.hpp> - -#if defined(BOOST_MSVC) -# pragma warning( push ) -# pragma warning( disable : 4793 ) // complaint about native code generation -# pragma warning( disable : 4127 ) // "conditional expression is constant" -#endif - -#if defined(__ICL) && __ICL <= 600 || defined(__MWERKS__) && __MWERKS__ < 0x2406 && !defined(BOOST_STRICT_CONFIG) -# define BOOST_FUNCTION_TARGET_FIX(x) x -#else -# define BOOST_FUNCTION_TARGET_FIX(x) -#endif // __ICL etc - -# define BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor,Type) \ - typename ::boost::enable_if_< \ - !(::boost::is_integral<Functor>::value), \ - Type>::type - -namespace boost { - namespace detail { - namespace function { - class X; - - /** - * A buffer used to store small function objects in - * boost::function. It is a union containing function pointers, - * object pointers, and a structure that resembles a bound - * member function pointer. - */ - union function_buffer_members - { - // For pointers to function objects - typedef void* obj_ptr_t; - mutable obj_ptr_t obj_ptr; - - // For pointers to std::type_info objects - struct type_t { - // (get_functor_type_tag, check_functor_type_tag). - const boost::typeindex::type_info* type; - - // Whether the type is const-qualified. - bool const_qualified; - // Whether the type is volatile-qualified. - bool volatile_qualified; - } type; - - // For function pointers of all kinds - typedef void (*func_ptr_t)(); - mutable func_ptr_t func_ptr; - - // For bound member pointers - struct bound_memfunc_ptr_t { - void (X::*memfunc_ptr)(int); - void* obj_ptr; - } bound_memfunc_ptr; - - // For references to function objects. We explicitly keep - // track of the cv-qualifiers on the object referenced. - struct obj_ref_t { - mutable void* obj_ptr; - bool is_const_qualified; - bool is_volatile_qualified; - } obj_ref; - }; - - union BOOST_SYMBOL_VISIBLE function_buffer - { - // Type-specific union members - mutable function_buffer_members members; - - // To relax aliasing constraints - mutable char data[sizeof(function_buffer_members)]; - }; - - /** - * The unusable class is a placeholder for unused function arguments - * It is also completely unusable except that it constructable from - * anything. This helps compilers without partial specialization to - * handle Boost.Function objects returning void. - */ - struct unusable - { - unusable() {} - template<typename T> unusable(const T&) {} - }; - - /* Determine the return type. This supports compilers that do not support - * void returns or partial specialization by silently changing the return - * type to "unusable". - */ - template<typename T> struct function_return_type { typedef T type; }; - - template<> - struct function_return_type<void> - { - typedef unusable type; - }; - - // The operation type to perform on the given functor/function pointer - enum functor_manager_operation_type { - clone_functor_tag, - move_functor_tag, - destroy_functor_tag, - check_functor_type_tag, - get_functor_type_tag - }; - - // Tags used to decide between different types of functions - struct function_ptr_tag {}; - struct function_obj_tag {}; - struct member_ptr_tag {}; - struct function_obj_ref_tag {}; - - template<typename F> - class get_function_tag - { - typedef typename conditional<(is_pointer<F>::value), - function_ptr_tag, - function_obj_tag>::type ptr_or_obj_tag; - - typedef typename conditional<(is_member_pointer<F>::value), - member_ptr_tag, - ptr_or_obj_tag>::type ptr_or_obj_or_mem_tag; - - typedef typename conditional<(is_reference_wrapper<F>::value), - function_obj_ref_tag, - ptr_or_obj_or_mem_tag>::type or_ref_tag; - - public: - typedef or_ref_tag type; - }; - - // The trivial manager does nothing but return the same pointer (if we - // are cloning) or return the null pointer (if we are deleting). - template<typename F> - struct reference_manager - { - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - switch (op) { - case clone_functor_tag: - out_buffer.members.obj_ref = in_buffer.members.obj_ref; - return; - - case move_functor_tag: - out_buffer.members.obj_ref = in_buffer.members.obj_ref; - in_buffer.members.obj_ref.obj_ptr = 0; - return; - - case destroy_functor_tag: - out_buffer.members.obj_ref.obj_ptr = 0; - return; - - case check_functor_type_tag: - { - // Check whether we have the same type. We can add - // cv-qualifiers, but we can't take them away. - if (*out_buffer.members.type.type == boost::typeindex::type_id<F>() - && (!in_buffer.members.obj_ref.is_const_qualified - || out_buffer.members.type.const_qualified) - && (!in_buffer.members.obj_ref.is_volatile_qualified - || out_buffer.members.type.volatile_qualified)) - out_buffer.members.obj_ptr = in_buffer.members.obj_ref.obj_ptr; - else - out_buffer.members.obj_ptr = 0; - } - return; - - case get_functor_type_tag: - out_buffer.members.type.type = &boost::typeindex::type_id<F>().type_info(); - out_buffer.members.type.const_qualified = in_buffer.members.obj_ref.is_const_qualified; - out_buffer.members.type.volatile_qualified = in_buffer.members.obj_ref.is_volatile_qualified; - return; - } - } - }; - - /** - * Determine if boost::function can use the small-object - * optimization with the function object type F. - */ - template<typename F> - struct function_allows_small_object_optimization - { - BOOST_STATIC_CONSTANT - (bool, - value = ((sizeof(F) <= sizeof(function_buffer) && - (alignment_of<function_buffer>::value - % alignment_of<F>::value == 0)))); - }; - - template <typename F,typename A> - struct functor_wrapper: public F, public A - { - functor_wrapper( F f, A a ): - F(f), - A(a) - { - } - - functor_wrapper(const functor_wrapper& f) : - F(static_cast<const F&>(f)), - A(static_cast<const A&>(f)) - { - } - }; - - /** - * The functor_manager class contains a static function "manage" which - * can clone or destroy the given function/function object pointer. - */ - template<typename Functor> - struct functor_manager_common - { - typedef Functor functor_type; - - // Function pointers - static inline void - manage_ptr(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - if (op == clone_functor_tag) - out_buffer.members.func_ptr = in_buffer.members.func_ptr; - else if (op == move_functor_tag) { - out_buffer.members.func_ptr = in_buffer.members.func_ptr; - in_buffer.members.func_ptr = 0; - } else if (op == destroy_functor_tag) - out_buffer.members.func_ptr = 0; - else if (op == check_functor_type_tag) { - if (*out_buffer.members.type.type == boost::typeindex::type_id<Functor>()) - out_buffer.members.obj_ptr = &in_buffer.members.func_ptr; - else - out_buffer.members.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } - } - - // Function objects that fit in the small-object buffer. - static inline void - manage_small(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - if (op == clone_functor_tag || op == move_functor_tag) { - const functor_type* in_functor = - reinterpret_cast<const functor_type*>(in_buffer.data); - new (reinterpret_cast<void*>(out_buffer.data)) functor_type(*in_functor); - - if (op == move_functor_tag) { - functor_type* f = reinterpret_cast<functor_type*>(in_buffer.data); - (void)f; // suppress warning about the value of f not being used (MSVC) - f->~Functor(); - } - } else if (op == destroy_functor_tag) { - // Some compilers (Borland, vc6, ...) are unhappy with ~functor_type. - functor_type* f = reinterpret_cast<functor_type*>(out_buffer.data); - (void)f; // suppress warning about the value of f not being used (MSVC) - f->~Functor(); - } else if (op == check_functor_type_tag) { - if (*out_buffer.members.type.type == boost::typeindex::type_id<Functor>()) - out_buffer.members.obj_ptr = in_buffer.data; - else - out_buffer.members.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } - } - }; - - template<typename Functor> - struct functor_manager - { - private: - typedef Functor functor_type; - - // Function pointers - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_ptr_tag) - { - functor_manager_common<Functor>::manage_ptr(in_buffer,out_buffer,op); - } - - // Function objects that fit in the small-object buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, true_type) - { - functor_manager_common<Functor>::manage_small(in_buffer,out_buffer,op); - } - - // Function objects that require heap allocation - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, false_type) - { - if (op == clone_functor_tag) { - // Clone the functor - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - // jewillco: Changing this to static_cast because GCC 2.95.3 is - // obsolete. - const functor_type* f = - static_cast<const functor_type*>(in_buffer.members.obj_ptr); - functor_type* new_f = new functor_type(*f); - out_buffer.members.obj_ptr = new_f; - } else if (op == move_functor_tag) { - out_buffer.members.obj_ptr = in_buffer.members.obj_ptr; - in_buffer.members.obj_ptr = 0; - } else if (op == destroy_functor_tag) { - /* Cast from the void pointer to the functor pointer type */ - functor_type* f = - static_cast<functor_type*>(out_buffer.members.obj_ptr); - delete f; - out_buffer.members.obj_ptr = 0; - } else if (op == check_functor_type_tag) { - if (*out_buffer.members.type.type == boost::typeindex::type_id<Functor>()) - out_buffer.members.obj_ptr = in_buffer.members.obj_ptr; - else - out_buffer.members.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } - } - - // For function objects, we determine whether the function - // object can use the small-object optimization buffer or - // whether we need to allocate it on the heap. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_obj_tag) - { - manager(in_buffer, out_buffer, op, - integral_constant<bool, (function_allows_small_object_optimization<functor_type>::value)>()); - } - - // For member pointers, we use the small-object optimization buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, member_ptr_tag) - { - manager(in_buffer, out_buffer, op, true_type()); - } - - public: - /* Dispatch to an appropriate manager based on whether we have a - function pointer or a function object pointer. */ - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - typedef typename get_function_tag<functor_type>::type tag_type; - if (op == get_functor_type_tag) { - out_buffer.members.type.type = &boost::typeindex::type_id<functor_type>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } else { - manager(in_buffer, out_buffer, op, tag_type()); - } - } - }; - - template<typename Functor, typename Allocator> - struct functor_manager_a - { - private: - typedef Functor functor_type; - - // Function pointers - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_ptr_tag) - { - functor_manager_common<Functor>::manage_ptr(in_buffer,out_buffer,op); - } - - // Function objects that fit in the small-object buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, true_type) - { - functor_manager_common<Functor>::manage_small(in_buffer,out_buffer,op); - } - - // Function objects that require heap allocation - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, false_type) - { - typedef functor_wrapper<Functor,Allocator> functor_wrapper_type; -#if defined(BOOST_NO_CXX11_ALLOCATOR) - typedef typename Allocator::template rebind<functor_wrapper_type>::other - wrapper_allocator_type; - typedef typename wrapper_allocator_type::pointer wrapper_allocator_pointer_type; -#else - using wrapper_allocator_type = typename std::allocator_traits<Allocator>::template rebind_alloc<functor_wrapper_type>; - using wrapper_allocator_pointer_type = typename std::allocator_traits<wrapper_allocator_type>::pointer; -#endif - - if (op == clone_functor_tag) { - // Clone the functor - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - const functor_wrapper_type* f = - static_cast<const functor_wrapper_type*>(in_buffer.members.obj_ptr); - wrapper_allocator_type wrapper_allocator(static_cast<Allocator const &>(*f)); - wrapper_allocator_pointer_type copy = wrapper_allocator.allocate(1); -#if defined(BOOST_NO_CXX11_ALLOCATOR) - wrapper_allocator.construct(copy, *f); -#else - std::allocator_traits<wrapper_allocator_type>::construct(wrapper_allocator, copy, *f); -#endif - - // Get back to the original pointer type - functor_wrapper_type* new_f = static_cast<functor_wrapper_type*>(copy); - out_buffer.members.obj_ptr = new_f; - } else if (op == move_functor_tag) { - out_buffer.members.obj_ptr = in_buffer.members.obj_ptr; - in_buffer.members.obj_ptr = 0; - } else if (op == destroy_functor_tag) { - /* Cast from the void pointer to the functor_wrapper_type */ - functor_wrapper_type* victim = - static_cast<functor_wrapper_type*>(in_buffer.members.obj_ptr); - wrapper_allocator_type wrapper_allocator(static_cast<Allocator const &>(*victim)); -#if defined(BOOST_NO_CXX11_ALLOCATOR) - wrapper_allocator.destroy(victim); -#else - std::allocator_traits<wrapper_allocator_type>::destroy(wrapper_allocator, victim); -#endif - wrapper_allocator.deallocate(victim,1); - out_buffer.members.obj_ptr = 0; - } else if (op == check_functor_type_tag) { - if (*out_buffer.members.type.type == boost::typeindex::type_id<Functor>()) - out_buffer.members.obj_ptr = in_buffer.members.obj_ptr; - else - out_buffer.members.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } - } - - // For function objects, we determine whether the function - // object can use the small-object optimization buffer or - // whether we need to allocate it on the heap. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_obj_tag) - { - manager(in_buffer, out_buffer, op, - integral_constant<bool, (function_allows_small_object_optimization<functor_type>::value)>()); - } - - public: - /* Dispatch to an appropriate manager based on whether we have a - function pointer or a function object pointer. */ - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - typedef typename get_function_tag<functor_type>::type tag_type; - if (op == get_functor_type_tag) { - out_buffer.members.type.type = &boost::typeindex::type_id<functor_type>().type_info(); - out_buffer.members.type.const_qualified = false; - out_buffer.members.type.volatile_qualified = false; - } else { - manager(in_buffer, out_buffer, op, tag_type()); - } - } - }; - - // A type that is only used for comparisons against zero - struct useless_clear_type {}; - -#ifdef BOOST_NO_SFINAE - // These routines perform comparisons between a Boost.Function - // object and an arbitrary function object (when the last - // parameter is false_type) or against zero (when the - // last parameter is true_type). They are only necessary - // for compilers that don't support SFINAE. - template<typename Function, typename Functor> - bool - compare_equal(const Function& f, const Functor&, int, true_type) - { return f.empty(); } - - template<typename Function, typename Functor> - bool - compare_not_equal(const Function& f, const Functor&, int, - true_type) - { return !f.empty(); } - - template<typename Function, typename Functor> - bool - compare_equal(const Function& f, const Functor& g, long, - false_type) - { - if (const Functor* fp = f.template target<Functor>()) - return function_equal(*fp, g); - else return false; - } - - template<typename Function, typename Functor> - bool - compare_equal(const Function& f, const reference_wrapper<Functor>& g, - int, false_type) - { - if (const Functor* fp = f.template target<Functor>()) - return fp == g.get_pointer(); - else return false; - } - - template<typename Function, typename Functor> - bool - compare_not_equal(const Function& f, const Functor& g, long, - false_type) - { - if (const Functor* fp = f.template target<Functor>()) - return !function_equal(*fp, g); - else return true; - } - - template<typename Function, typename Functor> - bool - compare_not_equal(const Function& f, - const reference_wrapper<Functor>& g, int, - false_type) - { - if (const Functor* fp = f.template target<Functor>()) - return fp != g.get_pointer(); - else return true; - } -#endif // BOOST_NO_SFINAE - - /** - * Stores the "manager" portion of the vtable for a - * boost::function object. - */ - struct vtable_base - { - void (*manager)(const function_buffer& in_buffer, - function_buffer& out_buffer, - functor_manager_operation_type op); - }; - } // end namespace function - } // end namespace detail - -/** - * The function_base class contains the basic elements needed for the - * function1, function2, function3, etc. classes. It is common to all - * functions (and as such can be used to tell if we have one of the - * functionN objects). - */ -class function_base -{ -public: - function_base() : vtable(0) { } - - /** Determine if the function is empty (i.e., has no target). */ - bool empty() const { return !vtable; } - - /** Retrieve the type of the stored function object, or type_id<void>() - if this is empty. */ - const boost::typeindex::type_info& target_type() const - { - if (!vtable) return boost::typeindex::type_id<void>().type_info(); - - detail::function::function_buffer type; - get_vtable()->manager(functor, type, detail::function::get_functor_type_tag); - return *type.members.type.type; - } - - template<typename Functor> - Functor* target() - { - if (!vtable) return 0; - - detail::function::function_buffer type_result; - type_result.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - type_result.members.type.const_qualified = is_const<Functor>::value; - type_result.members.type.volatile_qualified = is_volatile<Functor>::value; - get_vtable()->manager(functor, type_result, - detail::function::check_functor_type_tag); - return static_cast<Functor*>(type_result.members.obj_ptr); - } - - template<typename Functor> - const Functor* target() const - { - if (!vtable) return 0; - - detail::function::function_buffer type_result; - type_result.members.type.type = &boost::typeindex::type_id<Functor>().type_info(); - type_result.members.type.const_qualified = true; - type_result.members.type.volatile_qualified = is_volatile<Functor>::value; - get_vtable()->manager(functor, type_result, - detail::function::check_functor_type_tag); - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - return static_cast<const Functor*>(type_result.members.obj_ptr); - } - - template<typename F> - bool contains(const F& f) const - { - if (const F* fp = this->template target<F>()) - { - return function_equal(*fp, f); - } else { - return false; - } - } - -#if defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3 - // GCC 3.3 and newer cannot copy with the global operator==, due to - // problems with instantiation of function return types before it - // has been verified that the argument types match up. - template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(Functor g) const - { - if (const Functor* fp = target<Functor>()) - return function_equal(*fp, g); - else return false; - } - - template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(Functor g) const - { - if (const Functor* fp = target<Functor>()) - return !function_equal(*fp, g); - else return true; - } -#endif - -public: // should be protected, but GCC 2.95.3 will fail to allow access - detail::function::vtable_base* get_vtable() const { - return reinterpret_cast<detail::function::vtable_base*>( - reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); - } - - bool has_trivial_copy_and_destroy() const { - return reinterpret_cast<std::size_t>(vtable) & 0x01; - } - - detail::function::vtable_base* vtable; - mutable detail::function::function_buffer functor; -}; - -#if defined(BOOST_CLANG) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Wweak-vtables" -#endif -/** - * The bad_function_call exception class is thrown when a boost::function - * object is invoked - */ -class BOOST_SYMBOL_VISIBLE bad_function_call : public std::runtime_error -{ -public: - bad_function_call() : std::runtime_error("call to empty boost::function") {} -}; -#if defined(BOOST_CLANG) -# pragma clang diagnostic pop -#endif - -#ifndef BOOST_NO_SFINAE -inline bool operator==(const function_base& f, - detail::function::useless_clear_type*) -{ - return f.empty(); -} - -inline bool operator!=(const function_base& f, - detail::function::useless_clear_type*) -{ - return !f.empty(); -} - -inline bool operator==(detail::function::useless_clear_type*, - const function_base& f) -{ - return f.empty(); -} - -inline bool operator!=(detail::function::useless_clear_type*, - const function_base& f) -{ - return !f.empty(); -} -#endif - -#ifdef BOOST_NO_SFINAE -// Comparisons between boost::function objects and arbitrary function objects -template<typename Functor> - inline bool operator==(const function_base& f, Functor g) - { - typedef integral_constant<bool, (is_integral<Functor>::value)> integral; - return detail::function::compare_equal(f, g, 0, integral()); - } - -template<typename Functor> - inline bool operator==(Functor g, const function_base& f) - { - typedef integral_constant<bool, (is_integral<Functor>::value)> integral; - return detail::function::compare_equal(f, g, 0, integral()); - } - -template<typename Functor> - inline bool operator!=(const function_base& f, Functor g) - { - typedef integral_constant<bool, (is_integral<Functor>::value)> integral; - return detail::function::compare_not_equal(f, g, 0, integral()); - } - -template<typename Functor> - inline bool operator!=(Functor g, const function_base& f) - { - typedef integral_constant<bool, (is_integral<Functor>::value)> integral; - return detail::function::compare_not_equal(f, g, 0, integral()); - } -#else - -# if !(defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) -// Comparisons between boost::function objects and arbitrary function -// objects. GCC 3.3 and before has an obnoxious bug that prevents this -// from working. -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(const function_base& f, Functor g) - { - if (const Functor* fp = f.template target<Functor>()) - return function_equal(*fp, g); - else return false; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(Functor g, const function_base& f) - { - if (const Functor* fp = f.template target<Functor>()) - return function_equal(g, *fp); - else return false; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(const function_base& f, Functor g) - { - if (const Functor* fp = f.template target<Functor>()) - return !function_equal(*fp, g); - else return true; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(Functor g, const function_base& f) - { - if (const Functor* fp = f.template target<Functor>()) - return !function_equal(g, *fp); - else return true; - } -# endif - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(const function_base& f, reference_wrapper<Functor> g) - { - if (const Functor* fp = f.template target<Functor>()) - return fp == g.get_pointer(); - else return false; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(reference_wrapper<Functor> g, const function_base& f) - { - if (const Functor* fp = f.template target<Functor>()) - return g.get_pointer() == fp; - else return false; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(const function_base& f, reference_wrapper<Functor> g) - { - if (const Functor* fp = f.template target<Functor>()) - return fp != g.get_pointer(); - else return true; - } - -template<typename Functor> - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(reference_wrapper<Functor> g, const function_base& f) - { - if (const Functor* fp = f.template target<Functor>()) - return g.get_pointer() != fp; - else return true; - } - -#endif // Compiler supporting SFINAE - -namespace detail { - namespace function { - inline bool has_empty_target(const function_base* f) - { - return f->empty(); - } - -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1310) - inline bool has_empty_target(const void*) - { - return false; - } -#else - inline bool has_empty_target(...) - { - return false; - } -#endif - } // end namespace function -} // end namespace detail -} // end namespace boost - -#undef BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL - -#if defined(BOOST_MSVC) -# pragma warning( pop ) -#endif - -#endif // BOOST_FUNCTION_BASE_HEADER diff --git a/ThirdParty/boost/function/function_template.hpp b/ThirdParty/boost/function/function_template.hpp deleted file mode 100644 index 26f1d67d03b575469c33284880d1438ed20afe57..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/function/function_template.hpp +++ /dev/null @@ -1,1203 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2001-2006 -// Copyright Emil Dotchevski 2007 -// Use, modification and distribution is subject to 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) - -// For more information, see http://www.boost.org - -// Note: this header is a header template and must NOT have multiple-inclusion -// protection. -#include <boost/function/detail/prologue.hpp> -#include <boost/core/no_exceptions_support.hpp> - -#if defined(BOOST_MSVC) -# pragma warning( push ) -# pragma warning( disable : 4127 ) // "conditional expression is constant" -#endif - -#define BOOST_FUNCTION_TEMPLATE_PARMS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, typename T) - -#define BOOST_FUNCTION_TEMPLATE_ARGS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, T) - -#define BOOST_FUNCTION_PARM(J,I,D) BOOST_PP_CAT(T,I) BOOST_PP_CAT(a,I) - -#define BOOST_FUNCTION_PARMS BOOST_PP_ENUM(BOOST_FUNCTION_NUM_ARGS,BOOST_FUNCTION_PARM,BOOST_PP_EMPTY) - -#ifdef BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_FUNCTION_ARGS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, a) -#else -# define BOOST_FUNCTION_ARG(J,I,D) static_cast<BOOST_PP_CAT(T,I)&&>(BOOST_PP_CAT(a,I)) -# define BOOST_FUNCTION_ARGS BOOST_PP_ENUM(BOOST_FUNCTION_NUM_ARGS,BOOST_FUNCTION_ARG,BOOST_PP_EMPTY) -#endif - -#define BOOST_FUNCTION_ARG_TYPE(J,I,D) \ - typedef BOOST_PP_CAT(T,I) BOOST_PP_CAT(BOOST_PP_CAT(arg, BOOST_PP_INC(I)),_type); - -#define BOOST_FUNCTION_ARG_TYPES BOOST_PP_REPEAT(BOOST_FUNCTION_NUM_ARGS,BOOST_FUNCTION_ARG_TYPE,BOOST_PP_EMPTY) - -// Comma if nonzero number of arguments -#if BOOST_FUNCTION_NUM_ARGS == 0 -# define BOOST_FUNCTION_COMMA -#else -# define BOOST_FUNCTION_COMMA , -#endif // BOOST_FUNCTION_NUM_ARGS > 0 - -// Class names used in this version of the code -#define BOOST_FUNCTION_FUNCTION BOOST_JOIN(function,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_INVOKER \ - BOOST_JOIN(function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_INVOKER \ - BOOST_JOIN(void_function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(void_function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_REF_INVOKER \ - BOOST_JOIN(function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER \ - BOOST_JOIN(void_function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_MEMBER_INVOKER \ - BOOST_JOIN(function_mem_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_MEMBER_INVOKER \ - BOOST_JOIN(function_void_mem_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_INVOKER \ - BOOST_JOIN(get_function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(get_function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER \ - BOOST_JOIN(get_function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_MEMBER_INVOKER \ - BOOST_JOIN(get_member_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_INVOKER \ - BOOST_JOIN(get_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VTABLE BOOST_JOIN(basic_vtable,BOOST_FUNCTION_NUM_ARGS) - -#ifndef BOOST_NO_VOID_RETURNS -# define BOOST_FUNCTION_VOID_RETURN_TYPE void -# define BOOST_FUNCTION_RETURN(X) X -#else -# define BOOST_FUNCTION_VOID_RETURN_TYPE boost::detail::function::unusable -# define BOOST_FUNCTION_RETURN(X) X; return BOOST_FUNCTION_VOID_RETURN_TYPE () -#endif - -namespace boost { - namespace detail { - namespace function { - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_INVOKER - { - static R invoke(function_buffer& function_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - { - FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.members.func_ptr); - return f(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.members.func_ptr); - BOOST_FUNCTION_RETURN(f(BOOST_FUNCTION_ARGS)); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_OBJ_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f; - if (function_allows_small_object_optimization<FunctionObj>::value) - f = reinterpret_cast<FunctionObj*>(function_obj_ptr.data); - else - f = reinterpret_cast<FunctionObj*>(function_obj_ptr.members.obj_ptr); - return (*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f; - if (function_allows_small_object_optimization<FunctionObj>::value) - f = reinterpret_cast<FunctionObj*>(function_obj_ptr.data); - else - f = reinterpret_cast<FunctionObj*>(function_obj_ptr.members.obj_ptr); - BOOST_FUNCTION_RETURN((*f)(BOOST_FUNCTION_ARGS)); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_REF_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f = - reinterpret_cast<FunctionObj*>(function_obj_ptr.members.obj_ptr); - return (*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f = - reinterpret_cast<FunctionObj*>(function_obj_ptr.members.obj_ptr); - BOOST_FUNCTION_RETURN((*f)(BOOST_FUNCTION_ARGS)); - } - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Handle invocation of member pointers. */ - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_MEMBER_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - MemberPtr* f = - reinterpret_cast<MemberPtr*>(function_obj_ptr.data); - return boost::mem_fn(*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_MEMBER_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - MemberPtr* f = - reinterpret_cast<MemberPtr*>(function_obj_ptr.data); - BOOST_FUNCTION_RETURN(boost::mem_fn(*f)(BOOST_FUNCTION_ARGS)); - } - }; -#endif - - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_INVOKER - { - typedef typename conditional<(is_void<R>::value), - BOOST_FUNCTION_VOID_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER - { - typedef typename conditional<(is_void<R>::value), - BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER - { - typedef typename conditional<(is_void<R>::value), - BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_REF_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Retrieve the appropriate invoker for a member pointer. */ - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_MEMBER_INVOKER - { - typedef typename conditional<(is_void<R>::value), - BOOST_FUNCTION_VOID_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; -#endif - - /* Given the tag returned by get_function_tag, retrieve the - actual invoker that will be used for the given function - object. - - Each specialization contains an "apply" nested class template - that accepts the function object, return type, function - argument types, and allocator. The resulting "apply" class - contains two typedefs, "invoker_type" and "manager_type", - which correspond to the invoker and manager types. */ - template<typename Tag> - struct BOOST_FUNCTION_GET_INVOKER { }; - - /* Retrieve the invoker for a function pointer. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER<function_ptr_tag> - { - template<typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager<FunctionPtr> manager_type; - }; - - template<typename FunctionPtr, typename Allocator, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager<FunctionPtr> manager_type; - }; - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Retrieve the invoker for a member pointer. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER<member_ptr_tag> - { - template<typename MemberPtr, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply - { - typedef typename BOOST_FUNCTION_GET_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager<MemberPtr> manager_type; - }; - - template<typename MemberPtr, typename Allocator, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager<MemberPtr> manager_type; - }; - }; -#endif - - /* Retrieve the invoker for a function object. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER<function_obj_tag> - { - template<typename FunctionObj, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager<FunctionObj> manager_type; - }; - - template<typename FunctionObj, typename Allocator, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager_a<FunctionObj, Allocator> manager_type; - }; - }; - - /* Retrieve the invoker for a reference to a function object. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER<function_obj_ref_tag> - { - template<typename RefWrapper, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER< - typename RefWrapper::type, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef reference_manager<typename RefWrapper::type> manager_type; - }; - - template<typename RefWrapper, typename Allocator, - typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER< - typename RefWrapper::type, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef reference_manager<typename RefWrapper::type> manager_type; - }; - }; - - - /** - * vtable for a specific boost::function instance. This - * structure must be an aggregate so that we can use static - * initialization in boost::function's assign_to and assign_to_a - * members. It therefore cannot have any constructors, - * destructors, base classes, etc. - */ - template<typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - struct BOOST_FUNCTION_VTABLE - { -#ifndef BOOST_NO_VOID_RETURNS - typedef R result_type; -#else - typedef typename function_return_type<R>::type result_type; -#endif // BOOST_NO_VOID_RETURNS - - typedef result_type (*invoker_type)(function_buffer& - BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS); - - template<typename F> - bool assign_to(F f, function_buffer& functor) const - { - typedef typename get_function_tag<F>::type tag; - return assign_to(f, functor, tag()); - } - template<typename F,typename Allocator> - bool assign_to_a(F f, function_buffer& functor, Allocator a) const - { - typedef typename get_function_tag<F>::type tag; - return assign_to_a(f, functor, a, tag()); - } - - void clear(function_buffer& functor) const - { - if (base.manager) - base.manager(functor, functor, destroy_functor_tag); - } - - private: - // Function pointers - template<typename FunctionPtr> - bool - assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const - { - this->clear(functor); - if (f) { - // should be a reinterpret cast, but some compilers insist - // on giving cv-qualifiers to free functions - functor.members.func_ptr = reinterpret_cast<void (*)()>(f); - return true; - } else { - return false; - } - } - template<typename FunctionPtr,typename Allocator> - bool - assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const - { - return assign_to(f,functor,function_ptr_tag()); - } - - // Member pointers -#if BOOST_FUNCTION_NUM_ARGS > 0 - template<typename MemberPtr> - bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const - { - // DPG TBD: Add explicit support for member function - // objects, so we invoke through mem_fn() but we retain the - // right target_type() values. - if (f) { - this->assign_to(boost::mem_fn(f), functor); - return true; - } else { - return false; - } - } - template<typename MemberPtr,typename Allocator> - bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const - { - // DPG TBD: Add explicit support for member function - // objects, so we invoke through mem_fn() but we retain the - // right target_type() values. - if (f) { - this->assign_to_a(boost::mem_fn(f), functor, a); - return true; - } else { - return false; - } - } -#endif // BOOST_FUNCTION_NUM_ARGS > 0 - - // Function objects - // Assign to a function object using the small object optimization - template<typename FunctionObj> - void - assign_functor(FunctionObj f, function_buffer& functor, true_type) const - { - new (reinterpret_cast<void*>(functor.data)) FunctionObj(f); - } - template<typename FunctionObj,typename Allocator> - void - assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, true_type) const - { - assign_functor(f,functor,true_type()); - } - - // Assign to a function object allocated on the heap. - template<typename FunctionObj> - void - assign_functor(FunctionObj f, function_buffer& functor, false_type) const - { - functor.members.obj_ptr = new FunctionObj(f); - } - template<typename FunctionObj,typename Allocator> - void - assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, false_type) const - { - typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; -#if defined(BOOST_NO_CXX11_ALLOCATOR) - typedef typename Allocator::template rebind<functor_wrapper_type>::other - wrapper_allocator_type; - typedef typename wrapper_allocator_type::pointer wrapper_allocator_pointer_type; -#else - using wrapper_allocator_type = typename std::allocator_traits<Allocator>::template rebind_alloc<functor_wrapper_type>; - using wrapper_allocator_pointer_type = typename std::allocator_traits<wrapper_allocator_type>::pointer; -#endif - wrapper_allocator_type wrapper_allocator(a); - wrapper_allocator_pointer_type copy = wrapper_allocator.allocate(1); -#if defined(BOOST_NO_CXX11_ALLOCATOR) - wrapper_allocator.construct(copy, functor_wrapper_type(f,a)); -#else - std::allocator_traits<wrapper_allocator_type>::construct(wrapper_allocator, copy, functor_wrapper_type(f,a)); -#endif - functor_wrapper_type* new_f = static_cast<functor_wrapper_type*>(copy); - functor.members.obj_ptr = new_f; - } - - template<typename FunctionObj> - bool - assign_to(FunctionObj f, function_buffer& functor, function_obj_tag) const - { - if (!boost::detail::function::has_empty_target(boost::addressof(f))) { - assign_functor(f, functor, - integral_constant<bool, (function_allows_small_object_optimization<FunctionObj>::value)>()); - return true; - } else { - return false; - } - } - template<typename FunctionObj,typename Allocator> - bool - assign_to_a(FunctionObj f, function_buffer& functor, Allocator a, function_obj_tag) const - { - if (!boost::detail::function::has_empty_target(boost::addressof(f))) { - assign_functor_a(f, functor, a, - integral_constant<bool, (function_allows_small_object_optimization<FunctionObj>::value)>()); - return true; - } else { - return false; - } - } - - // Reference to a function object - template<typename FunctionObj> - bool - assign_to(const reference_wrapper<FunctionObj>& f, - function_buffer& functor, function_obj_ref_tag) const - { - functor.members.obj_ref.obj_ptr = (void *)(f.get_pointer()); - functor.members.obj_ref.is_const_qualified = is_const<FunctionObj>::value; - functor.members.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; - return true; - } - template<typename FunctionObj,typename Allocator> - bool - assign_to_a(const reference_wrapper<FunctionObj>& f, - function_buffer& functor, Allocator, function_obj_ref_tag) const - { - return assign_to(f,functor,function_obj_ref_tag()); - } - - public: - vtable_base base; - invoker_type invoker; - }; - } // end namespace function - } // end namespace detail - - template< - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - class BOOST_FUNCTION_FUNCTION : public function_base - { - public: -#ifndef BOOST_NO_VOID_RETURNS - typedef R result_type; -#else - typedef typename boost::detail::function::function_return_type<R>::type - result_type; -#endif // BOOST_NO_VOID_RETURNS - - private: - typedef boost::detail::function::BOOST_FUNCTION_VTABLE< - R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_ARGS> - vtable_type; - - vtable_type* get_vtable() const { - return reinterpret_cast<vtable_type*>( - reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); - } - - struct clear_type {}; - - public: - BOOST_STATIC_CONSTANT(int, args = BOOST_FUNCTION_NUM_ARGS); - - // add signature for boost::lambda - template<typename Args> - struct sig - { - typedef result_type type; - }; - -#if BOOST_FUNCTION_NUM_ARGS == 1 - typedef T0 argument_type; -#elif BOOST_FUNCTION_NUM_ARGS == 2 - typedef T0 first_argument_type; - typedef T1 second_argument_type; -#endif - - BOOST_STATIC_CONSTANT(int, arity = BOOST_FUNCTION_NUM_ARGS); - BOOST_FUNCTION_ARG_TYPES - - typedef BOOST_FUNCTION_FUNCTION self_type; - - BOOST_DEFAULTED_FUNCTION(BOOST_FUNCTION_FUNCTION(), : function_base() {}) - - // MSVC chokes if the following two constructors are collapsed into - // one with a default parameter. - template<typename Functor> - BOOST_FUNCTION_FUNCTION(Functor BOOST_FUNCTION_TARGET_FIX(const &) f -#ifndef BOOST_NO_SFINAE - ,typename boost::enable_if_< - !(is_integral<Functor>::value), - int>::type = 0 -#endif // BOOST_NO_SFINAE - ) : - function_base() - { - this->assign_to(f); - } - template<typename Functor,typename Allocator> - BOOST_FUNCTION_FUNCTION(Functor BOOST_FUNCTION_TARGET_FIX(const &) f, Allocator a -#ifndef BOOST_NO_SFINAE - ,typename boost::enable_if_< - !(is_integral<Functor>::value), - int>::type = 0 -#endif // BOOST_NO_SFINAE - ) : - function_base() - { - this->assign_to_a(f,a); - } - -#ifndef BOOST_NO_SFINAE - BOOST_FUNCTION_FUNCTION(clear_type*) : function_base() { } -#else - BOOST_FUNCTION_FUNCTION(int zero) : function_base() - { - BOOST_ASSERT(zero == 0); - } -#endif - - BOOST_FUNCTION_FUNCTION(const BOOST_FUNCTION_FUNCTION& f) : function_base() - { - this->assign_to_own(f); - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - BOOST_FUNCTION_FUNCTION(BOOST_FUNCTION_FUNCTION&& f) : function_base() - { - this->move_assign(f); - } -#endif - - ~BOOST_FUNCTION_FUNCTION() { clear(); } - - result_type operator()(BOOST_FUNCTION_PARMS) const - { - if (this->empty()) - boost::throw_exception(bad_function_call()); - - return get_vtable()->invoker - (this->functor BOOST_FUNCTION_COMMA BOOST_FUNCTION_ARGS); - } - - // The distinction between when to use BOOST_FUNCTION_FUNCTION and - // when to use self_type is obnoxious. MSVC cannot handle self_type as - // the return type of these assignment operators, but Borland C++ cannot - // handle BOOST_FUNCTION_FUNCTION as the type of the temporary to - // construct. - template<typename Functor> -#ifndef BOOST_NO_SFINAE - typename boost::enable_if_< - !(is_integral<Functor>::value), - BOOST_FUNCTION_FUNCTION&>::type -#else - BOOST_FUNCTION_FUNCTION& -#endif - operator=(Functor BOOST_FUNCTION_TARGET_FIX(const &) f) - { - this->clear(); - BOOST_TRY { - this->assign_to(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } - template<typename Functor,typename Allocator> - void assign(Functor BOOST_FUNCTION_TARGET_FIX(const &) f, Allocator a) - { - this->clear(); - BOOST_TRY{ - this->assign_to_a(f,a); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - } - -#ifndef BOOST_NO_SFINAE - BOOST_FUNCTION_FUNCTION& operator=(clear_type*) - { - this->clear(); - return *this; - } -#else - BOOST_FUNCTION_FUNCTION& operator=(int zero) - { - BOOST_ASSERT(zero == 0); - this->clear(); - return *this; - } -#endif - - // Assignment from another BOOST_FUNCTION_FUNCTION - BOOST_FUNCTION_FUNCTION& operator=(const BOOST_FUNCTION_FUNCTION& f) - { - if (&f == this) - return *this; - - this->clear(); - BOOST_TRY { - this->assign_to_own(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - // Move assignment from another BOOST_FUNCTION_FUNCTION - BOOST_FUNCTION_FUNCTION& operator=(BOOST_FUNCTION_FUNCTION&& f) - { - if (&f == this) - return *this; - - this->clear(); - BOOST_TRY { - this->move_assign(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } -#endif - - void swap(BOOST_FUNCTION_FUNCTION& other) - { - if (&other == this) - return; - - BOOST_FUNCTION_FUNCTION tmp; - tmp.move_assign(*this); - this->move_assign(other); - other.move_assign(tmp); - } - - // Clear out a target, if there is one - void clear() - { - if (vtable) { - if (!this->has_trivial_copy_and_destroy()) - get_vtable()->clear(this->functor); - vtable = 0; - } - } - -#if (defined __SUNPRO_CC) && (__SUNPRO_CC <= 0x530) && !(defined BOOST_NO_COMPILER_CONFIG) - // Sun C++ 5.3 can't handle the safe_bool idiom, so don't use it - operator bool () const { return !this->empty(); } -#else - private: - struct dummy { - void nonnull() {} - }; - - typedef void (dummy::*safe_bool)(); - - public: - operator safe_bool () const - { return (this->empty())? 0 : &dummy::nonnull; } - - bool operator!() const - { return this->empty(); } -#endif - - private: - void assign_to_own(const BOOST_FUNCTION_FUNCTION& f) - { - if (!f.empty()) { - this->vtable = f.vtable; - if (this->has_trivial_copy_and_destroy()) { - // Don't operate on storage directly since union type doesn't relax - // strict aliasing rules, despite of having member char type. -# if defined(BOOST_GCC) && (BOOST_GCC >= 40700) -# pragma GCC diagnostic push - // This warning is technically correct, but we don't want to pay the price for initializing - // just to silence a warning: https://github.com/boostorg/function/issues/27 -# pragma GCC diagnostic ignored "-Wmaybe-uninitialized" -# endif - std::memcpy(this->functor.data, f.functor.data, sizeof(boost::detail::function::function_buffer)); -# if defined(BOOST_GCC) && (BOOST_GCC >= 40700) -# pragma GCC diagnostic pop -# endif - } else - get_vtable()->base.manager(f.functor, this->functor, - boost::detail::function::clone_functor_tag); - } - } - - template<typename Functor> - void assign_to(Functor f) - { - using boost::detail::function::vtable_base; - - typedef typename boost::detail::function::get_function_tag<Functor>::type tag; - typedef boost::detail::function::BOOST_FUNCTION_GET_INVOKER<tag> get_invoker; - typedef typename get_invoker:: - template apply<Functor, R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS> - handler_type; - - typedef typename handler_type::invoker_type invoker_type; - typedef typename handler_type::manager_type manager_type; - - // Note: it is extremely important that this initialization use - // static initialization. Otherwise, we will have a race - // condition here in multi-threaded code. See - // http://thread.gmane.org/gmane.comp.lib.boost.devel/164902/. - static const vtable_type stored_vtable = - { { &manager_type::manage }, &invoker_type::invoke }; - - if (stored_vtable.assign_to(f, functor)) { - std::size_t value = reinterpret_cast<std::size_t>(&stored_vtable.base); - // coverity[pointless_expression]: suppress coverity warnings on apparant if(const). - if (boost::has_trivial_copy_constructor<Functor>::value && - boost::has_trivial_destructor<Functor>::value && - boost::detail::function::function_allows_small_object_optimization<Functor>::value) - value |= static_cast<std::size_t>(0x01); - vtable = reinterpret_cast<boost::detail::function::vtable_base *>(value); - } else - vtable = 0; - } - - template<typename Functor,typename Allocator> - void assign_to_a(Functor f,Allocator a) - { - using boost::detail::function::vtable_base; - - typedef typename boost::detail::function::get_function_tag<Functor>::type tag; - typedef boost::detail::function::BOOST_FUNCTION_GET_INVOKER<tag> get_invoker; - typedef typename get_invoker:: - template apply_a<Functor, Allocator, R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS> - handler_type; - - typedef typename handler_type::invoker_type invoker_type; - typedef typename handler_type::manager_type manager_type; - - // Note: it is extremely important that this initialization use - // static initialization. Otherwise, we will have a race - // condition here in multi-threaded code. See - // http://thread.gmane.org/gmane.comp.lib.boost.devel/164902/. - static const vtable_type stored_vtable = - { { &manager_type::manage }, &invoker_type::invoke }; - - if (stored_vtable.assign_to_a(f, functor, a)) { - std::size_t value = reinterpret_cast<std::size_t>(&stored_vtable.base); - // coverity[pointless_expression]: suppress coverity warnings on apparant if(const). - if (boost::has_trivial_copy_constructor<Functor>::value && - boost::has_trivial_destructor<Functor>::value && - boost::detail::function::function_allows_small_object_optimization<Functor>::value) - value |= static_cast<std::size_t>(0x01); - vtable = reinterpret_cast<boost::detail::function::vtable_base *>(value); - } else - vtable = 0; - } - - // Moves the value from the specified argument to *this. If the argument - // has its function object allocated on the heap, move_assign will pass - // its buffer to *this, and set the argument's buffer pointer to NULL. - void move_assign(BOOST_FUNCTION_FUNCTION& f) - { - if (&f == this) - return; - - BOOST_TRY { - if (!f.empty()) { - this->vtable = f.vtable; - if (this->has_trivial_copy_and_destroy()) { - // Don't operate on storage directly since union type doesn't relax - // strict aliasing rules, despite of having member char type. -# if defined(BOOST_GCC) && (BOOST_GCC >= 40700) -# pragma GCC diagnostic push - // This warning is technically correct, but we don't want to pay the price for initializing - // just to silence a warning: https://github.com/boostorg/function/issues/27 -# pragma GCC diagnostic ignored "-Wmaybe-uninitialized" -# endif - std::memcpy(this->functor.data, f.functor.data, sizeof(this->functor.data)); -# if defined(BOOST_GCC) && (BOOST_GCC >= 40700) -# pragma GCC diagnostic pop -# endif - } else - get_vtable()->base.manager(f.functor, this->functor, - boost::detail::function::move_functor_tag); - f.vtable = 0; - } else { - clear(); - } - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - } - }; - - template<typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - inline void swap(BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >& f1, - BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >& f2) - { - f1.swap(f2); - } - -// Poison comparisons between boost::function objects of the same type. -template<typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - void operator==(const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&, - const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&); -template<typename R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_PARMS> - void operator!=(const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&, - const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>& ); - -#if !defined(BOOST_FUNCTION_NO_FUNCTION_TYPE_SYNTAX) - -#if BOOST_FUNCTION_NUM_ARGS == 0 -#define BOOST_FUNCTION_PARTIAL_SPEC R (void) -#else -#define BOOST_FUNCTION_PARTIAL_SPEC R (BOOST_FUNCTION_TEMPLATE_ARGS) -#endif - -template<typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS> -class function<BOOST_FUNCTION_PARTIAL_SPEC> - : public BOOST_FUNCTION_FUNCTION<R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_ARGS> -{ - typedef BOOST_FUNCTION_FUNCTION<R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_ARGS> base_type; - typedef function self_type; - - struct clear_type {}; - -public: - - BOOST_DEFAULTED_FUNCTION(function(), : base_type() {}) - - template<typename Functor> - function(Functor f -#ifndef BOOST_NO_SFINAE - ,typename boost::enable_if_< - !(is_integral<Functor>::value), - int>::type = 0 -#endif - ) : - base_type(f) - { - } - template<typename Functor,typename Allocator> - function(Functor f, Allocator a -#ifndef BOOST_NO_SFINAE - ,typename boost::enable_if_< - !(is_integral<Functor>::value), - int>::type = 0 -#endif - ) : - base_type(f,a) - { - } - -#ifndef BOOST_NO_SFINAE - function(clear_type*) : base_type() {} -#endif - - function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} - - function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - // Move constructors - function(self_type&& f): base_type(static_cast<base_type&&>(f)){} - function(base_type&& f): base_type(static_cast<base_type&&>(f)){} -#endif - - self_type& operator=(const self_type& f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - self_type& operator=(self_type&& f) - { - self_type(static_cast<self_type&&>(f)).swap(*this); - return *this; - } -#endif - - template<typename Functor> -#ifndef BOOST_NO_SFINAE - typename boost::enable_if_< - !(is_integral<Functor>::value), - self_type&>::type -#else - self_type& -#endif - operator=(Functor f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_SFINAE - self_type& operator=(clear_type*) - { - this->clear(); - return *this; - } -#endif - - self_type& operator=(const base_type& f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - self_type& operator=(base_type&& f) - { - self_type(static_cast<base_type&&>(f)).swap(*this); - return *this; - } -#endif -}; - -#undef BOOST_FUNCTION_PARTIAL_SPEC -#endif // have partial specialization - -} // end namespace boost - -// Cleanup after ourselves... -#undef BOOST_FUNCTION_VTABLE -#undef BOOST_FUNCTION_COMMA -#undef BOOST_FUNCTION_FUNCTION -#undef BOOST_FUNCTION_FUNCTION_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_INVOKER -#undef BOOST_FUNCTION_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_MEMBER_INVOKER -#undef BOOST_FUNCTION_VOID_MEMBER_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_GET_MEM_FUNCTION_INVOKER -#undef BOOST_FUNCTION_GET_INVOKER -#undef BOOST_FUNCTION_TEMPLATE_PARMS -#undef BOOST_FUNCTION_TEMPLATE_ARGS -#undef BOOST_FUNCTION_PARMS -#undef BOOST_FUNCTION_PARM -#ifdef BOOST_FUNCTION_ARG -# undef BOOST_FUNCTION_ARG -#endif -#undef BOOST_FUNCTION_ARGS -#undef BOOST_FUNCTION_ARG_TYPE -#undef BOOST_FUNCTION_ARG_TYPES -#undef BOOST_FUNCTION_VOID_RETURN_TYPE -#undef BOOST_FUNCTION_RETURN - -#if defined(BOOST_MSVC) -# pragma warning( pop ) -#endif diff --git a/ThirdParty/boost/function_types/property_tags.hpp b/ThirdParty/boost/function_types/property_tags.hpp deleted file mode 100644 index 3760a8b174552ae87a04a34326bed869bc1a931b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/function_types/property_tags.hpp +++ /dev/null @@ -1,199 +0,0 @@ - -// (C) Copyright Tobias Schwinger -// -// Use modification and distribution are subject to the boost Software License, -// Version 1.0. (See http://www.boost.org/LICENSE_1_0.txt). - -//------------------------------------------------------------------------------ - -#ifndef BOOST_FT_DETAIL_TAGS_HPP_INCLUDED -#define BOOST_FT_DETAIL_TAGS_HPP_INCLUDED - -#include <cstddef> - -#include <boost/type_traits/integral_constant.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/mpl/bitxor.hpp> - - -namespace boost { namespace function_types { - -namespace detail -{ - typedef long bits_t; - - template<bits_t Value> struct constant - : boost::integral_constant<bits_t,Value> - { }; - - template<bits_t Bits, bits_t Mask> struct property_tag - { - typedef constant<Bits> bits; - typedef constant<Mask> mask; - }; - - template<typename T> struct bits : T::bits { }; - template<typename T> struct mask : T::mask { }; - - // forward declaration, defined in pp_tags - template<bits_t Bits, bits_t CCID> struct encode_bits_impl; - - // forward declaration, defined in pp_tags - template<bits_t LHS_bits, bits_t LHS_mask, - bits_t RHS_bits, bits_t RHS_mask> - struct tag_ice; - - // forward declaration, defined in retag_default_cc - template<class Tag, class RegTag = Tag> struct retag_default_cc; - - template<bits_t Bits, bits_t CCID> struct encode_bits - : constant< - ::boost::function_types::detail::encode_bits_impl<Bits,CCID>::value - > - { }; - - template<class LHS, class RHS> struct compound_tag - { - typedef constant< - ::boost::function_types::detail::tag_ice - < ::boost::function_types::detail::bits<LHS>::value - , ::boost::function_types::detail::mask<LHS>::value - , ::boost::function_types::detail::bits<RHS>::value - , ::boost::function_types::detail::mask<RHS>::value - >::combined_bits - > bits; - - typedef constant< - ::boost::function_types::detail::tag_ice - < ::boost::function_types::detail::bits<LHS>::value - , ::boost::function_types::detail::mask<LHS>::value - , ::boost::function_types::detail::bits<RHS>::value - , ::boost::function_types::detail::mask<RHS>::value - >::combined_mask - > mask; - }; - - template <class Base, class PropOld, class PropNew> - struct changed_tag - : Base - { - typedef mpl::bitxor_ - <typename Base::bits, typename PropOld::bits, typename PropNew::bits> - bits; - }; - - template<class Tag, class QueryTag> struct represents_impl - : boost::integral_constant<bool, - ::boost::function_types::detail::tag_ice - < ::boost::function_types::detail::bits<Tag>::value - , ::boost::function_types::detail::mask<Tag>::value - , ::boost::function_types::detail::bits<QueryTag>::value - , ::boost::function_types::detail::mask<QueryTag>::value - >::match - > - { }; - -} // namespace detail - -typedef detail::property_tag<0,0> null_tag; - -template<class Tag1, class Tag2, class Tag3 = null_tag, class Tag4 = null_tag> -struct tag - : detail::compound_tag< detail::compound_tag<Tag1,Tag2>, - detail::compound_tag<Tag3,Tag4> > -{ }; - -template<class Tag1, class Tag2, class Tag3> struct tag<Tag1,Tag2,Tag3,null_tag> - : detail::compound_tag<detail::compound_tag<Tag1,Tag2>,Tag3> -{ }; -template<class Tag1, class Tag2> struct tag<Tag1,Tag2,null_tag,null_tag> - : detail::compound_tag<Tag1,Tag2> -{ }; -template<class Tag1> struct tag<Tag1,null_tag,null_tag,null_tag> - : Tag1 -{ }; - - -template<class Tag, class QueryTag> struct represents - : detail::represents_impl<Tag, detail::retag_default_cc<QueryTag,Tag> > -{ }; - - -template<class Tag, class QueryTag> struct extract -{ - typedef detail::constant< - ::boost::function_types::detail::tag_ice - < ::boost::function_types::detail::bits<Tag>::value - , ::boost::function_types::detail::mask<Tag>::value - , ::boost::function_types::detail::bits<QueryTag>::value - , ::boost::function_types::detail::mask<QueryTag>::value - >::extracted_bits - > bits; - - typedef detail::constant< - ::boost::function_types::detail::mask<QueryTag>::value - > mask; -}; - -/* - - The following is a metafunction which checks whether a - property tag is in a possibly compounded tag type. - - Here both the possibly compounded tag type and a property tag - is given. - -*/ - -template<class Tag, class PropertyTag> struct has_property_tag - : detail::represents_impl<Tag, PropertyTag> -{ }; - -} } // namespace ::boost::function_types - -#include <boost/function_types/detail/pp_tags/preprocessed.hpp> - -namespace boost { namespace function_types { -#define BOOST_FT_cc_file <boost/function_types/detail/pp_tags/cc_tag.hpp> -#include <boost/function_types/detail/pp_loop.hpp> - -/* - - The following are metafunctions which check whether the - specific property tag is in a possibly compounded tag type. - Here only the possibly compounded tag type is given. - -*/ - -template<class Tag> struct has_property_tag<Tag,null_tag> - : ::boost::is_same<Tag, null_tag> -{ }; - -template<class Tag> struct has_variadic_property_tag - : has_property_tag<Tag, variadic> -{ }; - -template<class Tag> struct has_default_cc_property_tag - : has_property_tag<Tag, default_cc> -{ }; - -template<class Tag> struct has_const_property_tag - : has_property_tag<Tag, const_qualified> -{ }; - -template<class Tag> struct has_volatile_property_tag - : has_property_tag<Tag, volatile_qualified> -{ }; - -template<class Tag> struct has_cv_property_tag - : has_property_tag<Tag, cv_qualified> -{ }; - -template<class Tag> struct has_null_property_tag - : has_property_tag<Tag, null_tag> -{ }; - -} } // namespace boost::function_types - -#endif - diff --git a/ThirdParty/boost/functional/hash.hpp b/ThirdParty/boost/functional/hash.hpp deleted file mode 100644 index 327a3ecae7675f085e52c735d798d18f75c38d6d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/functional/hash.hpp +++ /dev/null @@ -1,6 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// 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/container_hash/hash.hpp> diff --git a/ThirdParty/boost/fusion/adapted/boost_tuple/boost_tuple_iterator.hpp b/ThirdParty/boost/fusion/adapted/boost_tuple/boost_tuple_iterator.hpp deleted file mode 100644 index ea30cb55c18bb5b0c4e147a9303735ae67b6c2d9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/adapted/boost_tuple/boost_tuple_iterator.hpp +++ /dev/null @@ -1,220 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_BOOST_TUPLE_ITERATOR_09262006_1851) -#define FUSION_BOOST_TUPLE_ITERATOR_09262006_1851 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/iterator/iterator_facade.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/add_const.hpp> -#include <boost/mpl/identity.hpp> -#include <boost/mpl/if.hpp> -#include <boost/mpl/eval_if.hpp> -#include <boost/mpl/or.hpp> -#include <boost/mpl/plus.hpp> -#include <boost/mpl/int.hpp> -#include <boost/mpl/apply.hpp> -#include <boost/tuple/tuple.hpp> - -namespace boost { namespace fusion -{ - struct forward_traversal_tag; - - namespace detail - { - template <typename T> - struct boost_tuple_is_empty : mpl::false_ {}; - - template <> - struct boost_tuple_is_empty<tuples::null_type> : mpl::true_ {}; - - template <> - struct boost_tuple_is_empty<tuples::null_type const> : mpl::true_ {}; - - template <> - struct boost_tuple_is_empty<tuples::tuple<> > : mpl::true_ {}; - - template <> - struct boost_tuple_is_empty<tuples::tuple<> const> : mpl::true_ {}; - } - - template <typename Cons> - struct boost_tuple_iterator_identity; - - template <typename Cons = tuples::null_type> - struct boost_tuple_iterator - : iterator_facade<boost_tuple_iterator<Cons>, forward_traversal_tag> - { - typedef Cons cons_type; - - typedef boost_tuple_iterator_identity< - typename add_const<Cons>::type> identity; - - BOOST_FUSION_GPU_ENABLED - explicit boost_tuple_iterator(Cons& in_cons) - : cons(in_cons) {} - Cons& cons; - - template <typename Iterator> - struct value_of : mpl::identity<typename Iterator::cons_type::head_type> {}; - - template <typename Iterator> - struct deref - { - typedef typename value_of<Iterator>::type element; - - typedef typename - mpl::if_< - is_const<typename Iterator::cons_type> - , typename tuples::access_traits<element>::const_type - , typename tuples::access_traits<element>::non_const_type - >::type - type; - - BOOST_FUSION_GPU_ENABLED - static type - call(Iterator const& iter) - { - return iter.cons.get_head(); - } - }; - - template <typename Iterator> - struct next - { - typedef typename Iterator::cons_type cons_type; - typedef typename cons_type::tail_type tail_type; - - typedef boost_tuple_iterator< - typename mpl::eval_if< - is_const<cons_type> - , add_const<tail_type> - , mpl::identity<tail_type> - >::type> - type; - - BOOST_FUSION_GPU_ENABLED - static type - call(Iterator const& iter) - { - return type(iter.cons.get_tail()); - } - }; - - template <typename I1, typename I2> - struct distance; - - // detail - template <typename I1, typename I2> - struct lazy_next_distance - { - typedef - typename mpl::plus< - mpl::int_<1>, - typename distance< - typename next<I1>::type, - I2 - >::type - >::type type; - }; - - template <typename I1, typename I2> - struct distance - { - typedef typename mpl::eval_if< - boost::is_same<I1, I2>, - mpl::int_<0>, - lazy_next_distance<I1, I2> - >::type type; - - BOOST_FUSION_GPU_ENABLED - static type - call(I1 const&, I2 const&) - { - return type(); - } - }; - - template <typename I1, typename I2> - struct equal_to - : is_same<typename I1::identity, typename I2::identity> - {}; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(boost_tuple_iterator& operator= (boost_tuple_iterator const&)) - }; - - template <typename Null> - struct boost_tuple_null_iterator - : iterator_facade<boost_tuple_iterator<Null>, forward_traversal_tag> - { - typedef Null cons_type; - - typedef boost_tuple_iterator_identity< - typename add_const<Null>::type> identity; - - template <typename I1, typename I2> - struct equal_to - : mpl::or_< - is_same<I1, I2> - , mpl::and_< - detail::boost_tuple_is_empty<typename I1::cons_type> - , detail::boost_tuple_is_empty<typename I2::cons_type> - > - > - {}; - }; - - template <> - struct boost_tuple_iterator<tuples::null_type> - : boost_tuple_null_iterator<tuples::null_type> - { - template <typename Cons> - BOOST_FUSION_GPU_ENABLED - explicit boost_tuple_iterator(Cons const&) {} - }; - - template <> - struct boost_tuple_iterator<tuples::null_type const> - : boost_tuple_null_iterator<tuples::null_type const> - { - template <typename Cons> - BOOST_FUSION_GPU_ENABLED - explicit boost_tuple_iterator(Cons const&) {} - }; - - template <> - struct boost_tuple_iterator<tuples::tuple<> > - : boost_tuple_null_iterator<tuples::tuple<> > - { - template <typename Cons> - BOOST_FUSION_GPU_ENABLED - explicit boost_tuple_iterator(Cons const&) {} - }; - - template <> - struct boost_tuple_iterator<tuples::tuple<> const> - : boost_tuple_null_iterator<tuples::tuple<> const> - { - template <typename Cons> - BOOST_FUSION_GPU_ENABLED - explicit boost_tuple_iterator(Cons const&) {} - }; -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename Cons> - struct iterator_traits< ::boost::fusion::boost_tuple_iterator<Cons> > - { }; -} -#endif - -#endif - - diff --git a/ThirdParty/boost/fusion/container/deque/deque_iterator.hpp b/ThirdParty/boost/fusion/container/deque/deque_iterator.hpp deleted file mode 100644 index b0335e5f2bd98f80a77e55245c3a4b8d868eab7d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/container/deque/deque_iterator.hpp +++ /dev/null @@ -1,129 +0,0 @@ -/*============================================================================= - Copyright (c) 2005-2012 Joel de Guzman - Copyright (c) 2005-2006 Dan Marsden - - 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) -==============================================================================*/ -#if !defined(BOOST_FUSION_DEQUE_ITERATOR_26112006_2154) -#define BOOST_FUSION_DEQUE_ITERATOR_26112006_2154 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/iterator/iterator_facade.hpp> -#include <boost/fusion/container/deque/detail/keyed_element.hpp> -#include <boost/mpl/int.hpp> -#include <boost/mpl/minus.hpp> -#include <boost/mpl/equal_to.hpp> -#include <boost/mpl/identity.hpp> -#include <boost/mpl/if.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/add_const.hpp> -#include <boost/type_traits/add_reference.hpp> - -namespace boost { namespace fusion { - - struct bidirectional_traversal_tag; - - template <typename Seq, int Pos> - struct deque_iterator - : iterator_facade<deque_iterator<Seq, Pos>, bidirectional_traversal_tag> - { - typedef Seq sequence; - typedef mpl::int_<Pos> index; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - deque_iterator(Seq& seq) - : seq_(seq) - {} - - template<typename Iterator> - struct value_of - : detail::keyed_element_value_at< - typename Iterator::sequence, typename Iterator::index> - {}; - - template<typename Iterator> - struct deref - { - typedef typename detail::keyed_element_value_at< - typename Iterator::sequence, typename Iterator::index>::type element_type; - - typedef typename add_reference< - typename mpl::eval_if< - is_const<typename Iterator::sequence>, - add_const<element_type>, - mpl::identity<element_type> >::type>::type type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - static type - call(Iterator const& it) - { - return it.seq_.get(typename Iterator::index()); - } - }; - - template <typename Iterator, typename N> - struct advance - { - typedef typename Iterator::index index; - typedef typename Iterator::sequence sequence; - typedef deque_iterator<sequence, index::value + N::value> type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - static type - call(Iterator const& i) - { - return type(i.seq_); - } - }; - - template<typename Iterator> - struct next - : advance<Iterator, mpl::int_<1> > - {}; - - template<typename Iterator> - struct prior - : advance<Iterator, mpl::int_<-1> > - {}; - - template <typename I1, typename I2> - struct distance : mpl::minus<typename I2::index, typename I1::index> - { - typedef typename - mpl::minus< - typename I2::index, typename I1::index - >::type - type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - static type - call(I1 const&, I2 const&) - { - return type(); - } - }; - - template<typename I1, typename I2> - struct equal_to - : mpl::equal_to<typename I1::index, typename I2::index> - {}; - - Seq& seq_; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(deque_iterator& operator= (deque_iterator const&)) - }; - -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename Seq, int Pos> - struct iterator_traits< ::boost::fusion::deque_iterator<Seq, Pos> > - { }; -} -#endif - -#endif diff --git a/ThirdParty/boost/fusion/container/list/cons_iterator.hpp b/ThirdParty/boost/fusion/container/list/cons_iterator.hpp deleted file mode 100644 index 5c0491dbc8bab6eb46891af7c3336912838a9a59..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/container/list/cons_iterator.hpp +++ /dev/null @@ -1,110 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - Copyright (c) 2005 Eric Niebler - - 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) -==============================================================================*/ -#if !defined(FUSION_CONS_ITERATOR_07172005_0849) -#define FUSION_CONS_ITERATOR_07172005_0849 - -#include <boost/fusion/support/config.hpp> -#include <boost/type_traits/add_const.hpp> -#include <boost/fusion/support/iterator_base.hpp> -#include <boost/fusion/container/list/detail/deref_impl.hpp> -#include <boost/fusion/container/list/detail/next_impl.hpp> -#include <boost/fusion/container/list/detail/value_of_impl.hpp> -#include <boost/fusion/container/list/detail/equal_to_impl.hpp> -#include <boost/fusion/container/list/list_fwd.hpp> - -namespace boost { namespace fusion -{ - struct nil_; - struct cons_iterator_tag; - struct forward_traversal_tag; - - template <typename Cons> - struct cons_iterator_identity; - - template <typename Cons = nil_> - struct cons_iterator : iterator_base<cons_iterator<Cons> > - { - typedef cons_iterator_tag fusion_tag; - typedef forward_traversal_tag category; - typedef Cons cons_type; - typedef cons_iterator_identity< - typename add_const<Cons>::type> - identity; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit cons_iterator(cons_type& in_cons) BOOST_NOEXCEPT - : cons(in_cons) {} - - cons_type& cons; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(cons_iterator& operator= (cons_iterator const&)) - }; - - struct nil_iterator : iterator_base<nil_iterator> - { - typedef forward_traversal_tag category; - typedef cons_iterator_tag fusion_tag; - typedef nil_ cons_type; - typedef cons_iterator_identity< - add_const<nil_>::type> - identity; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - nil_iterator() BOOST_NOEXCEPT {} - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit nil_iterator(nil_ const&) BOOST_NOEXCEPT {} - }; - - template <> - struct cons_iterator<nil_> : nil_iterator - { - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - cons_iterator() BOOST_NOEXCEPT {} - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit cons_iterator(nil_ const&) BOOST_NOEXCEPT {} - }; - - template <> - struct cons_iterator<nil_ const> : nil_iterator - { - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - cons_iterator() BOOST_NOEXCEPT {} - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit cons_iterator(nil_ const&) BOOST_NOEXCEPT {} - }; - - template <> - struct cons_iterator<list<> > : nil_iterator - { - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - cons_iterator() BOOST_NOEXCEPT {} - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit cons_iterator(nil_ const&) BOOST_NOEXCEPT {} - }; - - template <> - struct cons_iterator<list<> const> : nil_iterator - { - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - cons_iterator() BOOST_NOEXCEPT {} - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - explicit cons_iterator(nil_ const&) BOOST_NOEXCEPT {} - }; -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename Cons> - struct iterator_traits< ::boost::fusion::cons_iterator<Cons> > - { }; -} -#endif - -#endif diff --git a/ThirdParty/boost/fusion/container/vector/vector_iterator.hpp b/ThirdParty/boost/fusion/container/vector/vector_iterator.hpp deleted file mode 100644 index 6f8033e6f85b0a260684b5e963ef4b31a42bc2b1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/container/vector/vector_iterator.hpp +++ /dev/null @@ -1,61 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_VECTOR_ITERATOR_05042005_0635) -#define FUSION_VECTOR_ITERATOR_05042005_0635 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/support/iterator_base.hpp> -#include <boost/fusion/container/vector/detail/deref_impl.hpp> -#include <boost/fusion/container/vector/detail/value_of_impl.hpp> -#include <boost/fusion/container/vector/detail/next_impl.hpp> -#include <boost/fusion/container/vector/detail/prior_impl.hpp> -#include <boost/fusion/container/vector/detail/equal_to_impl.hpp> -#include <boost/fusion/container/vector/detail/distance_impl.hpp> -#include <boost/fusion/container/vector/detail/advance_impl.hpp> -#include <boost/type_traits/add_const.hpp> -#include <boost/mpl/int.hpp> - -namespace boost { namespace fusion -{ - struct vector_iterator_tag; - struct random_access_traversal_tag; - - template <typename Vector, int N> - struct vector_iterator_identity; - - template <typename Vector, int N> - struct vector_iterator : iterator_base<vector_iterator<Vector, N> > - { - typedef mpl::int_<N> index; - typedef Vector vector; - typedef vector_iterator_tag fusion_tag; - typedef random_access_traversal_tag category; - typedef vector_iterator_identity< - typename add_const<Vector>::type, N> identity; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - vector_iterator(Vector& in_vec) - : vec(in_vec) {} - - Vector& vec; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(vector_iterator& operator= (vector_iterator const&)) - }; -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename Vector, int N> - struct iterator_traits< ::boost::fusion::vector_iterator<Vector, N> > - { }; -} -#endif - -#endif - diff --git a/ThirdParty/boost/fusion/sequence/comparison/enable_comparison.hpp b/ThirdParty/boost/fusion/sequence/comparison/enable_comparison.hpp deleted file mode 100644 index b65c75529fc1853416eb5d01dd81a8c2ab973985..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/sequence/comparison/enable_comparison.hpp +++ /dev/null @@ -1,35 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_ENABLE_COMPARISON_09232005_1958) -#define FUSION_ENABLE_COMPARISON_09232005_1958 - -#include <boost/fusion/support/config.hpp> -#include <boost/mpl/or.hpp> -#include <boost/mpl/and.hpp> -#include <boost/mpl/not.hpp> -#include <boost/mpl/equal_to.hpp> -#include <boost/fusion/support/sequence_base.hpp> -#include <boost/fusion/support/is_sequence.hpp> -#include <boost/fusion/sequence/intrinsic/size.hpp> - -namespace boost { namespace fusion { namespace traits -{ - template <typename Seq1, typename Seq2, typename Enable = void> - struct enable_equality - : mpl::and_<traits::is_sequence<Seq1>, traits::is_sequence<Seq2> > - {}; - - template <typename Seq1, typename Seq2, typename Enable = void> - struct enable_comparison - : mpl::and_< - traits::is_sequence<Seq1>, traits::is_sequence<Seq2> - , mpl::equal_to<result_of::size<Seq1>, result_of::size<Seq2> > - > - {}; -}}} - -#endif diff --git a/ThirdParty/boost/fusion/sequence/intrinsic/at.hpp b/ThirdParty/boost/fusion/sequence/intrinsic/at.hpp deleted file mode 100644 index 348a2e5fd7074d183fb8690fadd9a2f951996030..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/sequence/intrinsic/at.hpp +++ /dev/null @@ -1,134 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_AT_05042005_0722) -#define FUSION_AT_05042005_0722 - -#include <boost/fusion/support/config.hpp> -#include <boost/mpl/int.hpp> -#include <boost/mpl/if.hpp> -#include <boost/mpl/or.hpp> -#include <boost/mpl/less.hpp> -#include <boost/mpl/empty_base.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/fusion/sequence/intrinsic_fwd.hpp> -#include <boost/fusion/support/tag_of.hpp> -#include <boost/fusion/support/category_of.hpp> - -namespace boost { namespace fusion -{ - // Special tags: - struct sequence_facade_tag; - struct boost_tuple_tag; // boost::tuples::tuple tag - struct boost_array_tag; // boost::array tag - struct mpl_sequence_tag; // mpl sequence tag - struct std_pair_tag; // std::pair tag - struct std_tuple_tag; // std::tuple tag - - namespace extension - { - template <typename Tag> - struct at_impl - { - template <typename Sequence, typename N> - struct apply; - }; - - template <> - struct at_impl<sequence_facade_tag> - { - template <typename Sequence, typename N> - struct apply : Sequence::template at<Sequence, N> {}; - }; - - template <> - struct at_impl<boost_tuple_tag>; - - template <> - struct at_impl<boost_array_tag>; - - template <> - struct at_impl<mpl_sequence_tag>; - - template <> - struct at_impl<std_pair_tag>; - - template <> - struct at_impl<std_tuple_tag>; - } - - namespace detail - { - template <typename Sequence, typename N, typename Tag> - struct at_impl - : mpl::if_< - mpl::or_< - mpl::less<N, typename extension::size_impl<Tag>::template apply<Sequence>::type> - , traits::is_unbounded<Sequence> - > - , typename extension::at_impl<Tag>::template apply<Sequence, N> - , mpl::empty_base - >::type - {}; - } - - namespace result_of - { - template <typename Sequence, typename N> - struct at - : detail::at_impl<Sequence, N, typename detail::tag_of<Sequence>::type> - {}; - - template <typename Sequence, int N> - struct at_c - : at<Sequence, mpl::int_<N> > - {}; - } - - - template <typename N, typename Sequence> - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - inline typename - lazy_disable_if< - is_const<Sequence> - , result_of::at<Sequence, N> - >::type - at(Sequence& seq) - { - return result_of::at<Sequence, N>::call(seq); - } - - template <typename N, typename Sequence> - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - inline typename result_of::at<Sequence const, N>::type - at(Sequence const& seq) - { - return result_of::at<Sequence const, N>::call(seq); - } - - template <int N, typename Sequence> - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - inline typename - lazy_disable_if< - is_const<Sequence> - , result_of::at_c<Sequence, N> - >::type - at_c(Sequence& seq) - { - return result_of::at_c<Sequence, N>::call(seq); - } - - template <int N, typename Sequence> - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - inline typename result_of::at_c<Sequence const, N>::type - at_c(Sequence const& seq) - { - return result_of::at_c<Sequence const, N>::call(seq); - } -}} - -#endif - diff --git a/ThirdParty/boost/fusion/view/joint_view/joint_view.hpp b/ThirdParty/boost/fusion/view/joint_view/joint_view.hpp deleted file mode 100644 index 03e38d694cb4240c67459fafe1b86eae1daee16c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/view/joint_view/joint_view.hpp +++ /dev/null @@ -1,83 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_JOINT_VIEW_07162005_0140) -#define FUSION_JOINT_VIEW_07162005_0140 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/view/joint_view/joint_view_fwd.hpp> -#include <boost/fusion/support/detail/access.hpp> -#include <boost/fusion/support/is_view.hpp> -#include <boost/fusion/sequence/intrinsic/begin.hpp> -#include <boost/fusion/sequence/intrinsic/end.hpp> -#include <boost/fusion/sequence/intrinsic/size.hpp> -#include <boost/fusion/view/joint_view/joint_view_iterator.hpp> -#include <boost/fusion/view/joint_view/detail/begin_impl.hpp> -#include <boost/fusion/view/joint_view/detail/end_impl.hpp> -#include <boost/fusion/support/sequence_base.hpp> -#include <boost/mpl/if.hpp> -#include <boost/mpl/plus.hpp> -#include <boost/mpl/bool.hpp> -#include <boost/mpl/eval_if.hpp> -#include <boost/mpl/inherit.hpp> -#include <boost/mpl/identity.hpp> - -namespace boost { namespace fusion -{ - struct joint_view_tag; - struct forward_traversal_tag; - struct fusion_sequence_tag; - - template <typename Sequence1, typename Sequence2> - struct joint_view : sequence_base<joint_view<Sequence1, Sequence2> > - { - typedef joint_view_tag fusion_tag; - typedef fusion_sequence_tag tag; // this gets picked up by MPL - typedef typename - mpl::eval_if< - mpl::and_< - traits::is_associative<Sequence1> - , traits::is_associative<Sequence2> - > - , mpl::inherit2<forward_traversal_tag,associative_tag> - , mpl::identity<forward_traversal_tag> - >::type - category; - typedef mpl::true_ is_view; - - typedef typename result_of::begin<Sequence1>::type first_type; - typedef typename result_of::end<Sequence1>::type last_type; - typedef typename result_of::begin<Sequence2>::type concat_type; - typedef typename result_of::end<Sequence2>::type concat_last_type; - typedef typename mpl::int_< - result_of::size<Sequence1>::value + result_of::size<Sequence2>::value> - size; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - joint_view(Sequence1& in_seq1, Sequence2& in_seq2) - : seq1(in_seq1) - , seq2(in_seq2) - {} - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - first_type first() const { return fusion::begin(seq1); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - concat_type concat() const { return fusion::begin(seq2); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - concat_last_type concat_last() const { return fusion::end(seq2); } - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(joint_view& operator= (joint_view const&)) - - private: - typename mpl::if_<traits::is_view<Sequence1>, Sequence1, Sequence1&>::type seq1; - typename mpl::if_<traits::is_view<Sequence2>, Sequence2, Sequence2&>::type seq2; - }; -}} - -#endif - - diff --git a/ThirdParty/boost/fusion/view/joint_view/joint_view_iterator.hpp b/ThirdParty/boost/fusion/view/joint_view/joint_view_iterator.hpp deleted file mode 100644 index f6db30915e25264f58ace59342dc4bac56ad810f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/view/joint_view/joint_view_iterator.hpp +++ /dev/null @@ -1,69 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_JOINT_VIEW_ITERATOR_07162005_0140) -#define FUSION_JOINT_VIEW_ITERATOR_07162005_0140 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/support/iterator_base.hpp> -#include <boost/fusion/iterator/equal_to.hpp> -#include <boost/fusion/iterator/mpl/convert_iterator.hpp> -#include <boost/fusion/adapted/mpl/mpl_iterator.hpp> -#include <boost/fusion/view/joint_view/detail/deref_impl.hpp> -#include <boost/fusion/view/joint_view/detail/next_impl.hpp> -#include <boost/fusion/view/joint_view/detail/value_of_impl.hpp> -#include <boost/fusion/view/joint_view/detail/deref_data_impl.hpp> -#include <boost/fusion/view/joint_view/detail/value_of_data_impl.hpp> -#include <boost/fusion/view/joint_view/detail/key_of_impl.hpp> -#include <boost/static_assert.hpp> - -namespace boost { namespace fusion -{ - struct joint_view_iterator_tag; - struct forward_traversal_tag; - - template <typename Category, typename First, typename Last, typename Concat> - struct joint_view_iterator - : iterator_base<joint_view_iterator<Category, First, Last, Concat> > - { - typedef convert_iterator<First> first_converter; - typedef convert_iterator<Last> last_converter; - typedef convert_iterator<Concat> concat_converter; - - typedef typename first_converter::type first_type; - typedef typename last_converter::type last_type; - typedef typename concat_converter::type concat_type; - - typedef joint_view_iterator_tag fusion_tag; - typedef Category category; - BOOST_STATIC_ASSERT((!result_of::equal_to<first_type, last_type>::value)); - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - joint_view_iterator(First const& in_first, Concat const& in_concat) - : first(first_converter::call(in_first)) - , concat(concat_converter::call(in_concat)) - {} - - first_type first; - concat_type concat; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(joint_view_iterator& operator= (joint_view_iterator const&)) - }; -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename Category, typename First, typename Last, typename Concat> - struct iterator_traits< ::boost::fusion::joint_view_iterator<Category, First, Last, Concat> > - { }; -} -#endif - -#endif - - diff --git a/ThirdParty/boost/fusion/view/transform_view/transform_view.hpp b/ThirdParty/boost/fusion/view/transform_view/transform_view.hpp deleted file mode 100644 index f0633018ee8379cc27e76d3af3f0e7ea69290e68..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/view/transform_view/transform_view.hpp +++ /dev/null @@ -1,122 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_TRANSFORM_VIEW_07162005_1037) -#define FUSION_TRANSFORM_VIEW_07162005_1037 - -#include <boost/fusion/support/config.hpp> -#include <boost/static_assert.hpp> -#include <boost/fusion/support/detail/access.hpp> -#include <boost/fusion/support/is_view.hpp> -#include <boost/fusion/support/category_of.hpp> -#include <boost/fusion/view/transform_view/transform_view_iterator.hpp> -#include <boost/fusion/view/transform_view/transform_view_fwd.hpp> -#include <boost/fusion/view/transform_view/detail/begin_impl.hpp> -#include <boost/fusion/view/transform_view/detail/end_impl.hpp> -#include <boost/fusion/view/transform_view/detail/at_impl.hpp> -#include <boost/fusion/view/transform_view/detail/value_at_impl.hpp> -#include <boost/fusion/view/detail/strictest_traversal.hpp> -#include <boost/fusion/container/vector/vector10.hpp> -#include <boost/fusion/sequence/intrinsic/size.hpp> -#include <boost/fusion/support/sequence_base.hpp> -#include <boost/fusion/sequence/intrinsic/begin.hpp> -#include <boost/fusion/sequence/intrinsic/end.hpp> -#include <boost/fusion/sequence/intrinsic/size.hpp> -#include <boost/mpl/bool.hpp> - -namespace boost { namespace fusion -{ - struct void_; - struct transform_view_tag; - struct transform_view2_tag; - struct fusion_sequence_tag; - - // Binary Version - template <typename Sequence1, typename Sequence2, typename F> - struct transform_view : sequence_base<transform_view<Sequence1, Sequence2, F> > - { - BOOST_STATIC_ASSERT(result_of::size<Sequence1>::value == result_of::size<Sequence2>::value); - typedef transform_view2_tag fusion_tag; - typedef fusion_sequence_tag tag; // this gets picked up by MPL - typedef mpl::true_ is_view; - - typedef typename traits::category_of<Sequence1>::type category1; - typedef typename traits::category_of<Sequence2>::type category2; - typedef typename detail::strictest_traversal< - fusion::vector2<Sequence1, Sequence2> >::type category; - typedef typename result_of::begin<Sequence1>::type first1_type; - typedef typename result_of::begin<Sequence2>::type first2_type; - typedef typename result_of::end<Sequence1>::type last1_type; - typedef typename result_of::end<Sequence2>::type last2_type; - typedef typename result_of::size<Sequence1>::type size; - typedef Sequence1 sequence1_type; - typedef Sequence2 sequence2_type; - typedef F transform_type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - transform_view(Sequence1& in_seq1, Sequence2& in_seq2, F const& binop) - : f(binop) - , seq1(in_seq1) - , seq2(in_seq2) - {} - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - first1_type first1() const { return fusion::begin(seq1); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - first2_type first2() const { return fusion::begin(seq2); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - last1_type last1() const { return fusion::end(seq1); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - last2_type last2() const { return fusion::end(seq2); } - - transform_type f; - typename mpl::if_<traits::is_view<Sequence1>, Sequence1, Sequence1&>::type seq1; - typename mpl::if_<traits::is_view<Sequence2>, Sequence2, Sequence2&>::type seq2; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(transform_view& operator= (transform_view const&)) - }; - - // Unary Version - template <typename Sequence, typename F> -#if defined(BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS) - struct transform_view<Sequence, F, void_> : sequence_base<transform_view<Sequence, F, void_> > -#else - struct transform_view<Sequence, F> : sequence_base<transform_view<Sequence, F> > -#endif - { - typedef transform_view_tag fusion_tag; - typedef fusion_sequence_tag tag; // this gets picked up by MPL - typedef mpl::true_ is_view; - - typedef typename traits::category_of<Sequence>::type category; - typedef typename result_of::begin<Sequence>::type first_type; - typedef typename result_of::end<Sequence>::type last_type; - typedef typename result_of::size<Sequence>::type size; - typedef Sequence sequence_type; - typedef F transform_type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - transform_view(Sequence& in_seq, F const& in_f) - : seq(in_seq) - , f(in_f) - {} - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - first_type first() const { return fusion::begin(seq); } - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - last_type last() const { return fusion::end(seq); } - typename mpl::if_<traits::is_view<Sequence>, Sequence, Sequence&>::type seq; - transform_type f; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(transform_view& operator= (transform_view const&)) - }; -}} - -#endif - - diff --git a/ThirdParty/boost/fusion/view/transform_view/transform_view_iterator.hpp b/ThirdParty/boost/fusion/view/transform_view/transform_view_iterator.hpp deleted file mode 100644 index 2689ae8aabe6d00fc657f3385016cf1b49a8ea0f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/fusion/view/transform_view/transform_view_iterator.hpp +++ /dev/null @@ -1,90 +0,0 @@ -/*============================================================================= - Copyright (c) 2001-2011 Joel de Guzman - - 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) -==============================================================================*/ -#if !defined(FUSION_TRANSFORM_VIEW_ITERATOR_07162005_1033) -#define FUSION_TRANSFORM_VIEW_ITERATOR_07162005_1033 - -#include <boost/fusion/support/config.hpp> -#include <boost/fusion/support/iterator_base.hpp> -#include <boost/fusion/support/category_of.hpp> -#include <boost/fusion/iterator/mpl/convert_iterator.hpp> -#include <boost/fusion/adapted/mpl/mpl_iterator.hpp> -#include <boost/fusion/view/transform_view/detail/deref_impl.hpp> -#include <boost/fusion/view/transform_view/detail/next_impl.hpp> -#include <boost/fusion/view/transform_view/detail/prior_impl.hpp> -#include <boost/fusion/view/transform_view/detail/value_of_impl.hpp> -#include <boost/fusion/view/transform_view/detail/advance_impl.hpp> -#include <boost/fusion/view/transform_view/detail/distance_impl.hpp> -#include <boost/fusion/view/transform_view/detail/equal_to_impl.hpp> - -namespace boost { namespace fusion -{ - // Unary Version - struct transform_view_iterator_tag; - - template <typename First, typename F> - struct transform_view_iterator - : iterator_base<transform_view_iterator<First, F> > - { - typedef transform_view_iterator_tag fusion_tag; - typedef convert_iterator<First> converter; - typedef typename converter::type first_type; - typedef typename traits::category_of<first_type>::type category; - typedef F transform_type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - transform_view_iterator(First const& in_first, F const& in_f) - : first(converter::call(in_first)), f(in_f) {} - - first_type first; - transform_type f; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(transform_view_iterator& operator= (transform_view_iterator const&)) - }; - - // Binary Version - struct transform_view_iterator2_tag; - - template <typename First1, typename First2, typename F> - struct transform_view_iterator2 - : iterator_base<transform_view_iterator2<First1, First2, F> > - { - typedef transform_view_iterator2_tag fusion_tag; - typedef convert_iterator<First1> converter1; - typedef convert_iterator<First2> converter2; - typedef typename converter1::type first1_type; - typedef typename converter2::type first2_type; - typedef typename traits::category_of<first1_type>::type category; - typedef F transform_type; - - BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED - transform_view_iterator2(First1 const& in_first1, First2 const& in_first2, F const& in_f) - : first1(converter1::call(in_first1)), first2(converter2::call(in_first2)), f(in_f) {} - - first1_type first1; - first2_type first2; - transform_type f; - - // silence MSVC warning C4512: assignment operator could not be generated - BOOST_DELETED_FUNCTION(transform_view_iterator2& operator= (transform_view_iterator2 const&)) - }; -}} - -#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 -namespace std -{ - template <typename First, typename F> - struct iterator_traits< ::boost::fusion::transform_view_iterator<First, F> > - { }; - template <typename First1, typename First2, typename F> - struct iterator_traits< ::boost::fusion::transform_view_iterator2<First1, First2, F> > - { }; -} -#endif - -#endif - diff --git a/ThirdParty/boost/histogram.hpp b/ThirdParty/boost/histogram.hpp deleted file mode 100644 index 8b91ce27487ced792f9cdd72fbb769830d028da2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram.hpp +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_HPP -#define BOOST_HISTOGRAM_HPP - -/** - \file boost/histogram.hpp - Includes all standard headers of the Boost.Histogram library. - - Extra headers not automatically included are: - - [boost/histogram/ostream.hpp][1] - - [boost/histogram/axis/ostream.hpp][2] - - [boost/histogram/accumulators/ostream.hpp][3] - - [boost/histogram/serialization.hpp][4] - - [1]: histogram/reference.html#header.boost.histogram.ostream_hpp - [2]: histogram/reference.html#header.boost.histogram.axis.ostream_hpp - [3]: histogram/reference.html#header.boost.histogram.accumulators.ostream_hpp - [4]: histogram/reference.html#header.boost.histogram.serialization_hpp -*/ - -#include <boost/histogram/accumulators.hpp> -#include <boost/histogram/algorithm.hpp> -#include <boost/histogram/axis.hpp> -#include <boost/histogram/histogram.hpp> -#include <boost/histogram/indexed.hpp> -#include <boost/histogram/literals.hpp> -#include <boost/histogram/make_histogram.hpp> -#include <boost/histogram/make_profile.hpp> -#include <boost/histogram/storage_adaptor.hpp> -#include <boost/histogram/unlimited_storage.hpp> - -#endif diff --git a/ThirdParty/boost/histogram/accumulators.hpp b/ThirdParty/boost/histogram/accumulators.hpp deleted file mode 100644 index fec479d3c75397c06c1a1953981beb250ba3c27d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators.hpp +++ /dev/null @@ -1,27 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_HPP - -/** - \file boost/histogram/accumulators.hpp - Includes all accumulator headers of the Boost.Histogram library. - - Extra header not automatically included: - - [boost/histogram/accumulators/ostream.hpp][1] - - [1]: histogram/reference.html#header.boost.histogram.accumulators.ostream_hpp -*/ - -#include <boost/histogram/accumulators/count.hpp> -#include <boost/histogram/accumulators/mean.hpp> -#include <boost/histogram/accumulators/sum.hpp> -#include <boost/histogram/accumulators/thread_safe.hpp> -#include <boost/histogram/accumulators/weighted_mean.hpp> -#include <boost/histogram/accumulators/weighted_sum.hpp> - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/count.hpp b/ThirdParty/boost/histogram/accumulators/count.hpp deleted file mode 100644 index 2fe1dbfbe80ea9f2ad7e65417cfe868662ca6f58..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/count.hpp +++ /dev/null @@ -1,137 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_NUMBER_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_NUMBER_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/fwd.hpp> // for count<> -#include <type_traits> // for std::common_type - -namespace boost { -namespace histogram { -namespace accumulators { - -/** - Uses a C++ builtin arithmetic type to accumulate a count. - - This wrapper class may be used as a base class by users who want to add custom metadata - to each bin of a histogram. Otherwise, arithmetic types should be used directly as - accumulators in storages for simplicity. In other words, prefer `dense_storage<double>` - over `dense_storage<count<double>>`, both are functionally equivalent. - - When weighted data is accumulated and high precision is required, use - `accumulators::sum` instead. If a local variance estimate for the weight distribution - should be computed as well (generally needed for a detailed statistical analysis), use - `accumulators::weighted_sum`. -*/ -template <class ValueType> -class count { -public: - using value_type = ValueType; - using const_reference = const value_type&; - - count() = default; - - /// Initialize count to value and allow implicit conversion - count(const_reference value) noexcept : value_(value) {} - - /// Allow implicit conversion from other count - template <class T> - count(const count<T>& c) noexcept : count(c.value()) {} - - /// Increment count by one - count& operator++() noexcept { - ++value_; - return *this; - } - - /// Increment count by value - count& operator+=(const_reference value) noexcept { - value_ += value; - return *this; - } - - /// Add another count - count& operator+=(const count& s) noexcept { - value_ += s.value_; - return *this; - } - - /// Scale by value - count& operator*=(const_reference value) noexcept { - value_ *= value; - return *this; - } - - bool operator==(const count& rhs) const noexcept { return value_ == rhs.value_; } - - bool operator!=(const count& rhs) const noexcept { return !operator==(rhs); } - - /// Return count - const_reference value() const noexcept { return value_; } - - // conversion to value_type must be explicit - explicit operator value_type() const noexcept { return value_; } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("value", value_); - } - - // begin: extra operators to make count behave like a regular number - - count& operator*=(const count& rhs) noexcept { - value_ *= rhs.value_; - return *this; - } - - count operator*(const count& rhs) const noexcept { - count x = *this; - x *= rhs; - return x; - } - - count& operator/=(const count& rhs) noexcept { - value_ /= rhs.value_; - return *this; - } - - count operator/(const count& rhs) const noexcept { - count x = *this; - x /= rhs; - return x; - } - - bool operator<(const count& rhs) const noexcept { return value_ < rhs.value_; } - - bool operator>(const count& rhs) const noexcept { return value_ > rhs.value_; } - - bool operator<=(const count& rhs) const noexcept { return value_ <= rhs.value_; } - - bool operator>=(const count& rhs) const noexcept { return value_ >= rhs.value_; } - - // end: extra operators - -private: - value_type value_{}; -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -namespace std { -template <class T, class U> -struct common_type<boost::histogram::accumulators::count<T>, - boost::histogram::accumulators::count<U>> { - using type = boost::histogram::accumulators::count<common_type_t<T, U>>; -}; -} // namespace std -#endif - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/mean.hpp b/ThirdParty/boost/histogram/accumulators/mean.hpp deleted file mode 100644 index 6bdc27f7a02957f5f2151477c621fde7c9e8bd9a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/mean.hpp +++ /dev/null @@ -1,147 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_MEAN_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_MEAN_HPP - -#include <boost/assert.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/fwd.hpp> // for mean<> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace accumulators { - -/** Calculates mean and variance of sample. - - Uses Welfords's incremental algorithm to improve the numerical - stability of mean and variance computation. -*/ -template <class ValueType> -class mean { -public: - using value_type = ValueType; - using const_reference = const value_type&; - - mean() = default; - - /// Allow implicit conversion from mean<T> - template <class T> - mean(const mean<T>& o) noexcept - : sum_{o.sum_}, mean_{o.mean_}, sum_of_deltas_squared_{o.sum_of_deltas_squared_} {} - - /// Initialize to external count, mean, and variance - mean(const_reference n, const_reference mean, const_reference variance) noexcept - : sum_(n), mean_(mean), sum_of_deltas_squared_(variance * (n - 1)) {} - - /// Insert sample x - void operator()(const_reference x) noexcept { - sum_ += static_cast<value_type>(1); - const auto delta = x - mean_; - mean_ += delta / sum_; - sum_of_deltas_squared_ += delta * (x - mean_); - } - - /// Insert sample x with weight w - void operator()(const weight_type<value_type>& w, const_reference x) noexcept { - sum_ += w.value; - const auto delta = x - mean_; - mean_ += w.value * delta / sum_; - sum_of_deltas_squared_ += w.value * delta * (x - mean_); - } - - /// Add another mean accumulator - mean& operator+=(const mean& rhs) noexcept { - if (sum_ != 0 || rhs.sum_ != 0) { - const auto tmp = mean_ * sum_ + rhs.mean_ * rhs.sum_; - sum_ += rhs.sum_; - mean_ = tmp / sum_; - } - sum_of_deltas_squared_ += rhs.sum_of_deltas_squared_; - return *this; - } - - /** Scale by value - - This acts as if all samples were scaled by the value. - */ - mean& operator*=(const_reference s) noexcept { - mean_ *= s; - sum_of_deltas_squared_ *= s * s; - return *this; - } - - bool operator==(const mean& rhs) const noexcept { - return sum_ == rhs.sum_ && mean_ == rhs.mean_ && - sum_of_deltas_squared_ == rhs.sum_of_deltas_squared_; - } - - bool operator!=(const mean& rhs) const noexcept { return !operator==(rhs); } - - /// Return how many samples were accumulated - const_reference count() const noexcept { return sum_; } - - /// Return mean value of accumulated samples - const_reference value() const noexcept { return mean_; } - - /// Return variance of accumulated samples - value_type variance() const noexcept { return sum_of_deltas_squared_ / (sum_ - 1); } - - template <class Archive> - void serialize(Archive& ar, unsigned version) { - if (version == 0) { - // read only - std::size_t sum; - ar& make_nvp("sum", sum); - sum_ = static_cast<value_type>(sum); - } else { - ar& make_nvp("sum", sum_); - } - ar& make_nvp("mean", mean_); - ar& make_nvp("sum_of_deltas_squared", sum_of_deltas_squared_); - } - -private: - value_type sum_{}; - value_type mean_{}; - value_type sum_of_deltas_squared_{}; -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -namespace boost { -namespace serialization { - -template <class T> -struct version; - -// version 1 for boost::histogram::accumulators::mean<T> -template <class T> -struct version<boost::histogram::accumulators::mean<T>> : std::integral_constant<int, 1> { -}; - -} // namespace serialization -} // namespace boost - -namespace std { -template <class T, class U> -/// Specialization for boost::histogram::accumulators::mean. -struct common_type<boost::histogram::accumulators::mean<T>, - boost::histogram::accumulators::mean<U>> { - using type = boost::histogram::accumulators::mean<common_type_t<T, U>>; -}; -} // namespace std - -#endif - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/ostream.hpp b/ThirdParty/boost/histogram/accumulators/ostream.hpp deleted file mode 100644 index 7c602500ddc4f8b834396435ce43e01ab9856233..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/ostream.hpp +++ /dev/null @@ -1,106 +0,0 @@ -// Copyright 2015-2017 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_OSTREAM_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_OSTREAM_HPP - -#include <boost/histogram/detail/counting_streambuf.hpp> -#include <boost/histogram/fwd.hpp> -#include <ios> - -/** - \file boost/histogram/accumulators/ostream.hpp - Simple streaming operators for the builtin accumulator types. - - The text representation is not guaranteed to be stable between versions of - Boost.Histogram. This header is only included by - [boost/histogram/ostream.hpp](histogram/reference.html#header.boost.histogram.ostream_hpp). - To you use your own, include your own implementation instead of this header and do not - include - [boost/histogram/ostream.hpp](histogram/reference.html#header.boost.histogram.ostream_hpp). - */ - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -namespace boost { -namespace histogram { - -namespace detail { - -template <class CharT, class Traits, class T> -std::basic_ostream<CharT, Traits>& handle_nonzero_width( - std::basic_ostream<CharT, Traits>& os, const T& x) { - const auto w = os.width(); - os.width(0); - counting_streambuf<CharT, Traits> cb; - const auto saved = os.rdbuf(&cb); - os << x; - os.rdbuf(saved); - if (os.flags() & std::ios::left) { - os << x; - for (auto i = cb.count; i < w; ++i) os << os.fill(); - } else { - for (auto i = cb.count; i < w; ++i) os << os.fill(); - os << x; - } - return os; -} - -} // namespace detail - -namespace accumulators { - -template <class CharT, class Traits, class U> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const count<U>& x) { - return os << x.value(); -} - -template <class CharT, class Traits, class U> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const sum<U>& x) { - if (os.width() == 0) return os << "sum(" << x.large() << " + " << x.small() << ")"; - return detail::handle_nonzero_width(os, x); -} - -template <class CharT, class Traits, class U> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const weighted_sum<U>& x) { - if (os.width() == 0) - return os << "weighted_sum(" << x.value() << ", " << x.variance() << ")"; - return detail::handle_nonzero_width(os, x); -} - -template <class CharT, class Traits, class U> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const mean<U>& x) { - if (os.width() == 0) - return os << "mean(" << x.count() << ", " << x.value() << ", " << x.variance() << ")"; - return detail::handle_nonzero_width(os, x); -} - -template <class CharT, class Traits, class U> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const weighted_mean<U>& x) { - if (os.width() == 0) - return os << "weighted_mean(" << x.sum_of_weights() << ", " << x.value() << ", " - << x.variance() << ")"; - return detail::handle_nonzero_width(os, x); -} - -template <class CharT, class Traits, class T> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const thread_safe<T>& x) { - os << x.load(); - return os; -} -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/sum.hpp b/ThirdParty/boost/histogram/accumulators/sum.hpp deleted file mode 100644 index d1577f0ba6a07facb7a8c280b80ccb8048df8aae..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/sum.hpp +++ /dev/null @@ -1,178 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_SUM_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_SUM_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/fwd.hpp> // for sum<> -#include <cmath> // std::abs -#include <type_traits> // std::is_floating_point, std::common_type - -namespace boost { -namespace histogram { -namespace accumulators { - -/** - Uses Neumaier algorithm to compute accurate sums of floats. - - The algorithm is an improved Kahan algorithm - (https://en.wikipedia.org/wiki/Kahan_summation_algorithm). The algorithm uses memory for - two numbers and is three to five times slower compared to using a single number to - accumulate a sum, but the relative error of the sum is at the level of the machine - precision, independent of the number of samples. - - A. Neumaier, Zeitschrift fuer Angewandte Mathematik und Mechanik 54 (1974) 39-51. -*/ -template <class ValueType> -class sum { - static_assert(std::is_floating_point<ValueType>::value, - "ValueType must be a floating point type"); - -public: - using value_type = ValueType; - using const_reference = const value_type&; - - sum() = default; - - /// Initialize sum to value and allow implicit conversion - sum(const_reference value) noexcept : sum(value, 0) {} - - /// Allow implicit conversion from sum<T> - template <class T> - sum(const sum<T>& s) noexcept : sum(s.large(), s.small()) {} - - /// Initialize sum explicitly with large and small parts - sum(const_reference large, const_reference small) noexcept - : large_(large), small_(small) {} - - /// Increment sum by one - sum& operator++() noexcept { return operator+=(1); } - - /// Increment sum by value - sum& operator+=(const_reference value) noexcept { - // prevent compiler optimization from destroying the algorithm - // when -ffast-math is enabled - volatile value_type l; - value_type s; - if (std::abs(large_) >= std::abs(value)) { - l = large_; - s = value; - } else { - l = value; - s = large_; - } - large_ += value; - l -= large_; - l += s; - small_ += l; - return *this; - } - - /// Add another sum - sum& operator+=(const sum& s) noexcept { - operator+=(s.large_); - small_ += s.small_; - return *this; - } - - /// Scale by value - sum& operator*=(const_reference value) noexcept { - large_ *= value; - small_ *= value; - return *this; - } - - bool operator==(const sum& rhs) const noexcept { - return large_ + small_ == rhs.large_ + rhs.small_; - } - - bool operator!=(const sum& rhs) const noexcept { return !operator==(rhs); } - - /// Return value of the sum. - value_type value() const noexcept { return large_ + small_; } - - /// Return large part of the sum. - const_reference large() const noexcept { return large_; } - - /// Return small part of the sum. - const_reference small() const noexcept { return small_; } - - // lossy conversion to value type must be explicit - explicit operator value_type() const noexcept { return value(); } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("large", large_); - ar& make_nvp("small", small_); - } - - // begin: extra operators to make sum behave like a regular number - - sum& operator*=(const sum& rhs) noexcept { - const auto scale = static_cast<value_type>(rhs); - large_ *= scale; - small_ *= scale; - return *this; - } - - sum operator*(const sum& rhs) const noexcept { - sum s = *this; - s *= rhs; - return s; - } - - sum& operator/=(const sum& rhs) noexcept { - const auto scale = 1.0 / static_cast<value_type>(rhs); - large_ *= scale; - small_ *= scale; - return *this; - } - - sum operator/(const sum& rhs) const noexcept { - sum s = *this; - s /= rhs; - return s; - } - - bool operator<(const sum& rhs) const noexcept { - return operator value_type() < rhs.operator value_type(); - } - - bool operator>(const sum& rhs) const noexcept { - return operator value_type() > rhs.operator value_type(); - } - - bool operator<=(const sum& rhs) const noexcept { - return operator value_type() <= rhs.operator value_type(); - } - - bool operator>=(const sum& rhs) const noexcept { - return operator value_type() >= rhs.operator value_type(); - } - - // end: extra operators - -private: - value_type large_{}; - value_type small_{}; -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -namespace std { -template <class T, class U> -struct common_type<boost::histogram::accumulators::sum<T>, - boost::histogram::accumulators::sum<U>> { - using type = boost::histogram::accumulators::sum<common_type_t<T, U>>; -}; -} // namespace std -#endif - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/thread_safe.hpp b/ThirdParty/boost/histogram/accumulators/thread_safe.hpp deleted file mode 100644 index 87ea416c8ca7bd7569db73a5533fe17f6b06cd3c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/thread_safe.hpp +++ /dev/null @@ -1,76 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_THREAD_SAFE_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_THREAD_SAFE_HPP - -#include <atomic> -#include <boost/core/nvp.hpp> -#include <boost/mp11/utility.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace accumulators { - -/** Thread-safe adaptor for builtin integral and floating point numbers. - - This adaptor uses std::atomic to make concurrent increments and additions safe for the - stored value. - - On common computing platforms, the adapted integer has the same size and - alignment as underlying type. The atomicity is implemented with a special CPU - instruction. On exotic platforms the size of the adapted number may be larger and/or the - type may have different alignment, which means it cannot be tightly packed into arrays. - - @tparam T type to adapt, must be supported by std::atomic. - */ -template <class T> -class thread_safe : public std::atomic<T> { -public: - using value_type = T; - using super_t = std::atomic<T>; - - thread_safe() noexcept : super_t(static_cast<T>(0)) {} - // non-atomic copy and assign is allowed, because storage is locked in this case - thread_safe(const thread_safe& o) noexcept : super_t(o.load()) {} - thread_safe& operator=(const thread_safe& o) noexcept { - super_t::store(o.load()); - return *this; - } - - thread_safe(value_type arg) : super_t(arg) {} - thread_safe& operator=(value_type arg) { - super_t::store(arg); - return *this; - } - - thread_safe& operator+=(const thread_safe& arg) { - operator+=(arg.load()); - return *this; - } - thread_safe& operator+=(value_type arg) { - super_t::fetch_add(arg, std::memory_order_relaxed); - return *this; - } - thread_safe& operator++() { - operator+=(static_cast<value_type>(1)); - return *this; - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - auto value = super_t::load(); - ar& make_nvp("value", value); - super_t::store(value); - } -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/weighted_mean.hpp b/ThirdParty/boost/histogram/accumulators/weighted_mean.hpp deleted file mode 100644 index c163c49c9e50e8da92a46afb7b6fcce3d343acc5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/weighted_mean.hpp +++ /dev/null @@ -1,142 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_WEIGHTED_MEAN_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_WEIGHTED_MEAN_HPP - -#include <boost/assert.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/fwd.hpp> // for weighted_mean<> -#include <boost/histogram/weight.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace accumulators { - -/** - Calculates mean and variance of weighted sample. - - Uses West's incremental algorithm to improve numerical stability - of mean and variance computation. -*/ -template <class ValueType> -class weighted_mean { -public: - using value_type = ValueType; - using const_reference = const value_type&; - - weighted_mean() = default; - - /// Allow implicit conversion from other weighted_means - template <class T> - weighted_mean(const weighted_mean<T>& o) - : sum_of_weights_{o.sum_of_weights_} - , sum_of_weights_squared_{o.sum_of_weights_squared_} - , weighted_mean_{o.weighted_mean_} - , sum_of_weighted_deltas_squared_{o.sum_of_weighted_deltas_squared_} {} - - /// Initialize to external sum of weights, sum of weights squared, mean, and variance - weighted_mean(const_reference wsum, const_reference wsum2, const_reference mean, - const_reference variance) - : sum_of_weights_(wsum) - , sum_of_weights_squared_(wsum2) - , weighted_mean_(mean) - , sum_of_weighted_deltas_squared_( - variance * (sum_of_weights_ - sum_of_weights_squared_ / sum_of_weights_)) {} - - /// Insert sample x - void operator()(const_reference x) { operator()(weight(1), x); } - - /// Insert sample x with weight w - void operator()(const weight_type<value_type>& w, const_reference x) { - sum_of_weights_ += w.value; - sum_of_weights_squared_ += w.value * w.value; - const auto delta = x - weighted_mean_; - weighted_mean_ += w.value * delta / sum_of_weights_; - sum_of_weighted_deltas_squared_ += w.value * delta * (x - weighted_mean_); - } - - /// Add another weighted_mean - weighted_mean& operator+=(const weighted_mean& rhs) { - if (sum_of_weights_ != 0 || rhs.sum_of_weights_ != 0) { - const auto tmp = - weighted_mean_ * sum_of_weights_ + rhs.weighted_mean_ * rhs.sum_of_weights_; - sum_of_weights_ += rhs.sum_of_weights_; - sum_of_weights_squared_ += rhs.sum_of_weights_squared_; - weighted_mean_ = tmp / sum_of_weights_; - } - sum_of_weighted_deltas_squared_ += rhs.sum_of_weighted_deltas_squared_; - return *this; - } - - /** Scale by value - - This acts as if all samples were scaled by the value. - */ - weighted_mean& operator*=(const_reference s) { - weighted_mean_ *= s; - sum_of_weighted_deltas_squared_ *= s * s; - return *this; - } - - bool operator==(const weighted_mean& rhs) const noexcept { - return sum_of_weights_ == rhs.sum_of_weights_ && - sum_of_weights_squared_ == rhs.sum_of_weights_squared_ && - weighted_mean_ == rhs.weighted_mean_ && - sum_of_weighted_deltas_squared_ == rhs.sum_of_weighted_deltas_squared_; - } - - bool operator!=(const weighted_mean& rhs) const noexcept { return !operator==(rhs); } - - /// Return sum of weights - const_reference sum_of_weights() const noexcept { return sum_of_weights_; } - - /// Return sum of weights squared (variance of weight distribution) - const_reference sum_of_weights_squared() const noexcept { - return sum_of_weights_squared_; - } - - /// Return mean of accumulated weighted samples - const_reference value() const noexcept { return weighted_mean_; } - - /// Return variance of accumulated weighted samples - value_type variance() const { - return sum_of_weighted_deltas_squared_ / - (sum_of_weights_ - sum_of_weights_squared_ / sum_of_weights_); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("sum_of_weights", sum_of_weights_); - ar& make_nvp("sum_of_weights_squared", sum_of_weights_squared_); - ar& make_nvp("weighted_mean", weighted_mean_); - ar& make_nvp("sum_of_weighted_deltas_squared", sum_of_weighted_deltas_squared_); - } - -private: - value_type sum_of_weights_{}; - value_type sum_of_weights_squared_{}; - value_type weighted_mean_{}; - value_type sum_of_weighted_deltas_squared_{}; -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -namespace std { -template <class T, class U> -/// Specialization for boost::histogram::accumulators::weighted_mean. -struct common_type<boost::histogram::accumulators::weighted_mean<T>, - boost::histogram::accumulators::weighted_mean<U>> { - using type = boost::histogram::accumulators::weighted_mean<common_type_t<T, U>>; -}; -} // namespace std -#endif - -#endif diff --git a/ThirdParty/boost/histogram/accumulators/weighted_sum.hpp b/ThirdParty/boost/histogram/accumulators/weighted_sum.hpp deleted file mode 100644 index 692b14293ff50cc12bfa819d5289ea7686b8677b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/accumulators/weighted_sum.hpp +++ /dev/null @@ -1,119 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_ACCUMULATORS_WEIGHTED_SUM_HPP -#define BOOST_HISTOGRAM_ACCUMULATORS_WEIGHTED_SUM_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/fwd.hpp> // for weighted_sum<> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace accumulators { - -/// Holds sum of weights and its variance estimate -template <class ValueType> -class weighted_sum { -public: - using value_type = ValueType; - using const_reference = const value_type&; - - weighted_sum() = default; - - /// Initialize sum to value and allow implicit conversion - weighted_sum(const_reference value) noexcept : weighted_sum(value, value) {} - - /// Allow implicit conversion from sum<T> - template <class T> - weighted_sum(const weighted_sum<T>& s) noexcept - : weighted_sum(s.value(), s.variance()) {} - - /// Initialize sum to value and variance - weighted_sum(const_reference value, const_reference variance) noexcept - : sum_of_weights_(value), sum_of_weights_squared_(variance) {} - - /// Increment by one. - weighted_sum& operator++() { - ++sum_of_weights_; - ++sum_of_weights_squared_; - return *this; - } - - /// Increment by weight. - template <class T> - weighted_sum& operator+=(const weight_type<T>& w) { - sum_of_weights_ += w.value; - sum_of_weights_squared_ += w.value * w.value; - return *this; - } - - /// Added another weighted sum. - weighted_sum& operator+=(const weighted_sum& rhs) { - sum_of_weights_ += rhs.sum_of_weights_; - sum_of_weights_squared_ += rhs.sum_of_weights_squared_; - return *this; - } - - /// Scale by value. - weighted_sum& operator*=(const_reference x) { - sum_of_weights_ *= x; - sum_of_weights_squared_ *= x * x; - return *this; - } - - bool operator==(const weighted_sum& rhs) const noexcept { - return sum_of_weights_ == rhs.sum_of_weights_ && - sum_of_weights_squared_ == rhs.sum_of_weights_squared_; - } - - bool operator!=(const weighted_sum& rhs) const noexcept { return !operator==(rhs); } - - /// Return value of the sum. - const_reference value() const noexcept { return sum_of_weights_; } - - /// Return estimated variance of the sum. - const_reference variance() const noexcept { return sum_of_weights_squared_; } - - // lossy conversion must be explicit - explicit operator const_reference() const { return sum_of_weights_; } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("sum_of_weights", sum_of_weights_); - ar& make_nvp("sum_of_weights_squared", sum_of_weights_squared_); - } - -private: - value_type sum_of_weights_{}; - value_type sum_of_weights_squared_{}; -}; - -} // namespace accumulators -} // namespace histogram -} // namespace boost - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -namespace std { -template <class T, class U> -struct common_type<boost::histogram::accumulators::weighted_sum<T>, - boost::histogram::accumulators::weighted_sum<U>> { - using type = boost::histogram::accumulators::weighted_sum<common_type_t<T, U>>; -}; - -template <class T, class U> -struct common_type<boost::histogram::accumulators::weighted_sum<T>, U> { - using type = boost::histogram::accumulators::weighted_sum<common_type_t<T, U>>; -}; - -template <class T, class U> -struct common_type<T, boost::histogram::accumulators::weighted_sum<U>> { - using type = boost::histogram::accumulators::weighted_sum<common_type_t<T, U>>; -}; -} // namespace std -#endif - -#endif diff --git a/ThirdParty/boost/histogram/algorithm.hpp b/ThirdParty/boost/histogram/algorithm.hpp deleted file mode 100644 index bbf8fe1c3fe96cd8dcf90195c60eb62826259341..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/algorithm.hpp +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_ALGORITHM_HPP -#define BOOST_HISTOGRAM_ALGORITHM_HPP - -/** - \file boost/histogram/algorithm.hpp - Includes all algorithm headers of the Boost.Histogram library. -*/ - -#include <boost/histogram/algorithm/empty.hpp> -#include <boost/histogram/algorithm/project.hpp> -#include <boost/histogram/algorithm/reduce.hpp> -#include <boost/histogram/algorithm/sum.hpp> - -#endif diff --git a/ThirdParty/boost/histogram/algorithm/empty.hpp b/ThirdParty/boost/histogram/algorithm/empty.hpp deleted file mode 100644 index f9f0b1673f2c8836d684fbcd25472cd7fe7e75f1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/algorithm/empty.hpp +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2019 Henry Schreiner -// -// 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_HISTOGRAM_ALGORITHM_EMPTY_HPP -#define BOOST_HISTOGRAM_ALGORITHM_EMPTY_HPP - -#include <boost/histogram/fwd.hpp> -#include <boost/histogram/indexed.hpp> - -namespace boost { -namespace histogram { -namespace algorithm { -/** Check to see if all histogram cells are empty. Use coverage to include or - exclude the underflow/overflow bins. - - This algorithm has O(N) complexity, where N is the number of cells. - - Returns true if all cells are empty, and false otherwise. - */ -template <class A, class S> -auto empty(const histogram<A, S>& h, coverage cov) { - using value_type = typename histogram<A, S>::value_type; - const value_type default_value = value_type(); - for (auto&& ind : indexed(h, cov)) { - if (*ind != default_value) { return false; } - } - return true; -} -} // namespace algorithm -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/algorithm/project.hpp b/ThirdParty/boost/histogram/algorithm/project.hpp deleted file mode 100644 index d897a51b2cc6ef92ee68293f0bb57c22651b21a1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/algorithm/project.hpp +++ /dev/null @@ -1,104 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_ALGORITHM_PROJECT_HPP -#define BOOST_HISTOGRAM_ALGORITHM_PROJECT_HPP - -#include <algorithm> -#include <boost/histogram/axis/variant.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/make_default.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/histogram.hpp> -#include <boost/histogram/indexed.hpp> -#include <boost/histogram/unsafe_access.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/set.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <type_traits> -#include <vector> - -namespace boost { -namespace histogram { -namespace algorithm { - -/** - Returns a lower-dimensional histogram, summing over removed axes. - - Arguments are the source histogram and compile-time numbers, the remaining indices of - the axes. Returns a new histogram which only contains the subset of axes. The source - histogram is summed over the removed axes. -*/ -template <class A, class S, unsigned N, typename... Ns> -auto project(const histogram<A, S>& h, std::integral_constant<unsigned, N>, Ns...) { - using LN = mp11::mp_list<std::integral_constant<unsigned, N>, Ns...>; - static_assert(mp11::mp_is_set<LN>::value, "indices must be unique"); - - const auto& old_axes = unsafe_access::axes(h); - auto axes = detail::static_if<detail::is_tuple<A>>( - [&](const auto& old_axes) { - return std::make_tuple(std::get<N>(old_axes), std::get<Ns::value>(old_axes)...); - }, - [&](const auto& old_axes) { - return std::decay_t<decltype(old_axes)>({old_axes[N], old_axes[Ns::value]...}); - }, - old_axes); - - const auto& old_storage = unsafe_access::storage(h); - using A2 = decltype(axes); - auto result = histogram<A2, S>(std::move(axes), detail::make_default(old_storage)); - auto idx = detail::make_stack_buffer<int>(unsafe_access::axes(result)); - for (auto&& x : indexed(h, coverage::all)) { - auto i = idx.begin(); - mp11::mp_for_each<LN>([&i, &x](auto J) { *i++ = x.index(J); }); - result.at(idx) += *x; - } - return result; -} - -/** - Returns a lower-dimensional histogram, summing over removed axes. - - This version accepts a source histogram and an iterable range containing the remaining - indices. -*/ -template <class A, class S, class Iterable, class = detail::requires_iterable<Iterable>> -auto project(const histogram<A, S>& h, const Iterable& c) { - using namespace boost::mp11; - const auto& old_axes = unsafe_access::axes(h); - - // axes is always std::vector<...>, even if A is tuple - auto axes = detail::make_empty_dynamic_axes(old_axes); - axes.reserve(c.size()); - auto seen = detail::make_stack_buffer<bool>(old_axes, false); - for (auto d : c) { - if (static_cast<unsigned>(d) >= h.rank()) - BOOST_THROW_EXCEPTION(std::invalid_argument("invalid axis index")); - if (seen[d]) BOOST_THROW_EXCEPTION(std::invalid_argument("indices are not unique")); - seen[d] = true; - axes.emplace_back(detail::axis_get(old_axes, d)); - } - - const auto& old_storage = unsafe_access::storage(h); - auto result = - histogram<decltype(axes), S>(std::move(axes), detail::make_default(old_storage)); - auto idx = detail::make_stack_buffer<int>(unsafe_access::axes(result)); - for (auto&& x : indexed(h, coverage::all)) { - auto i = idx.begin(); - for (auto d : c) *i++ = x.index(d); - result.at(idx) += *x; - } - - return result; -} - -} // namespace algorithm -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/algorithm/reduce.hpp b/ThirdParty/boost/histogram/algorithm/reduce.hpp deleted file mode 100644 index 17d80200777f80db73521fdd709cbcad60963203..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/algorithm/reduce.hpp +++ /dev/null @@ -1,494 +0,0 @@ -// Copyright 2018-2019 Hans Dembinski -// -// 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_HISTOGRAM_ALGORITHM_REDUCE_HPP -#define BOOST_HISTOGRAM_ALGORITHM_REDUCE_HPP - -#include <boost/assert.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/make_default.hpp> -#include <boost/histogram/detail/reduce_command.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/histogram/indexed.hpp> -#include <boost/histogram/unsafe_access.hpp> -#include <boost/throw_exception.hpp> -#include <cmath> -#include <initializer_list> -#include <stdexcept> -#include <string> - -namespace boost { -namespace histogram { -namespace algorithm { - -/** Holder for a reduce command. - - Use this type to store reduce commands in a container. The internals of this type are an - implementation detail. -*/ -using reduce_command = detail::reduce_command; - -using reduce_option [[deprecated("use reduce_command instead")]] = - reduce_command; ///< deprecated - -/** Shrink command to be used in `reduce`. - - Command is applied to axis with given index. - - Shrinking is based on an inclusive value interval. The bin which contains the first - value starts the range of bins to keep. The bin which contains the second value is the - last included in that range. When the second value is exactly equal to a lower bin edge, - then the previous bin is the last in the range. - - The counts in removed bins are added to the corresponding underflow and overflow bins, - if they are present. If they are not present, the counts are discarded. Also see - `crop`, which always discards the counts. - - @param iaxis which axis to operate on. - @param lower bin which contains lower is first to be kept. - @param upper bin which contains upper is last to be kept, except if upper is equal to - the lower edge. -*/ -inline reduce_command shrink(unsigned iaxis, double lower, double upper) { - if (lower == upper) - BOOST_THROW_EXCEPTION(std::invalid_argument("lower != upper required")); - reduce_command r; - r.iaxis = iaxis; - r.range = reduce_command::range_t::values; - r.begin.value = lower; - r.end.value = upper; - r.merge = 1; - r.crop = false; - return r; -} - -/** Shrink command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - Shrinking is based on an inclusive value interval. The bin which contains the first - value starts the range of bins to keep. The bin which contains the second value is the - last included in that range. When the second value is exactly equal to a lower bin edge, - then the previous bin is the last in the range. - - The counts in removed bins are added to the corresponding underflow and overflow bins, - if they are present. If they are not present, the counts are discarded. Also see - `crop`, which always discards the counts. - - @param lower bin which contains lower is first to be kept. - @param upper bin which contains upper is last to be kept, except if upper is equal to - the lower edge. -*/ -inline reduce_command shrink(double lower, double upper) { - return shrink(reduce_command::unset, lower, upper); -} - -/** Crop command to be used in `reduce`. - - Command is applied to axis with given index. - - Works like `shrink` (see shrink documentation for details), but counts in removed - bins are always discarded, whether underflow and overflow bins are present or not. - - @param iaxis which axis to operate on. - @param lower bin which contains lower is first to be kept. - @param upper bin which contains upper is last to be kept, except if upper is equal to - the lower edge. -*/ -inline reduce_command crop(unsigned iaxis, double lower, double upper) { - reduce_command r = shrink(iaxis, lower, upper); - r.crop = true; - return r; -} - -/** Crop command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - Works like `shrink` (see shrink documentation for details), but counts in removed bins - are discarded, whether underflow and overflow bins are present or not. - - @param lower bin which contains lower is first to be kept. - @param upper bin which contains upper is last to be kept, except if upper is equal to - the lower edge. -*/ -inline reduce_command crop(double lower, double upper) { - return crop(reduce_command::unset, lower, upper); -} - -/// Whether to behave like `shrink` or `crop` regarding removed bins. -enum class slice_mode { shrink, crop }; - -/** Slice command to be used in `reduce`. - - Command is applied to axis with given index. - - Slicing works like `shrink` or `crop`, but uses bin indices instead of values. - - @param iaxis which axis to operate on. - @param begin first index that should be kept. - @param end one past the last index that should be kept. - @param mode whether to behave like `shrink` or `crop` regarding removed bins. -*/ -inline reduce_command slice(unsigned iaxis, axis::index_type begin, axis::index_type end, - slice_mode mode = slice_mode::shrink) { - if (!(begin < end)) - BOOST_THROW_EXCEPTION(std::invalid_argument("begin < end required")); - - reduce_command r; - r.iaxis = iaxis; - r.range = reduce_command::range_t::indices; - r.begin.index = begin; - r.end.index = end; - r.merge = 1; - r.crop = mode == slice_mode::crop; - return r; -} - -/** Slice command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - Slicing works like `shrink` or `crop`, but uses bin indices instead of values. - - @param begin first index that should be kept. - @param end one past the last index that should be kept. - @param mode whether to behave like `shrink` or `crop` regarding removed bins. -*/ -inline reduce_command slice(axis::index_type begin, axis::index_type end, - slice_mode mode = slice_mode::shrink) { - return slice(reduce_command::unset, begin, end, mode); -} - -/** Rebin command to be used in `reduce`. - - Command is applied to axis with given index. - - The command merges N adjacent bins into one. This makes the axis coarser and the bins - wider. The original number of bins is divided by N. If there is a rest to this devision, - the axis is implicitly shrunk at the upper end by that rest. - - @param iaxis which axis to operate on. - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command rebin(unsigned iaxis, unsigned merge) { - if (merge == 0) BOOST_THROW_EXCEPTION(std::invalid_argument("merge > 0 required")); - reduce_command r; - r.iaxis = iaxis; - r.merge = merge; - r.range = reduce_command::range_t::none; - r.crop = false; - return r; -} - -/** Rebin command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - The command merges N adjacent bins into one. This makes the axis coarser and the bins - wider. The original number of bins is divided by N. If there is a rest to this devision, - the axis is implicitly shrunk at the upper end by that rest. - - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command rebin(unsigned merge) { - return rebin(reduce_command::unset, merge); -} - -/** Shrink and rebin command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - To shrink(unsigned, double, double) and rebin(unsigned, unsigned) in one command (see - the respective commands for more details). Equivalent to passing both commands for the - same axis to `reduce`. - - @param iaxis which axis to operate on. - @param lower lowest bound that should be kept. - @param upper highest bound that should be kept. If upper is inside bin interval, the - whole interval is removed. - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command shrink_and_rebin(unsigned iaxis, double lower, double upper, - unsigned merge) { - reduce_command r = shrink(iaxis, lower, upper); - r.merge = rebin(merge).merge; - return r; -} - -/** Shrink and rebin command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - To `shrink` and `rebin` in one command (see the respective commands for more - details). Equivalent to passing both commands for the same axis to `reduce`. - - @param lower lowest bound that should be kept. - @param upper highest bound that should be kept. If upper is inside bin interval, the - whole interval is removed. - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command shrink_and_rebin(double lower, double upper, unsigned merge) { - return shrink_and_rebin(reduce_command::unset, lower, upper, merge); -} - -/** Crop and rebin command to be used in `reduce`. - - Command is applied to axis with given index. - - To `crop` and `rebin` in one command (see the respective commands for more - details). Equivalent to passing both commands for the same axis to `reduce`. - - @param iaxis which axis to operate on. - @param lower lowest bound that should be kept. - @param upper highest bound that should be kept. If upper is inside bin interval, - the whole interval is removed. - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command crop_and_rebin(unsigned iaxis, double lower, double upper, - unsigned merge) { - reduce_command r = crop(iaxis, lower, upper); - r.merge = rebin(merge).merge; - return r; -} - -/** Crop and rebin command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - To `crop` and `rebin` in one command (see the respective commands for more - details). Equivalent to passing both commands for the same axis to `reduce`. - - @param lower lowest bound that should be kept. - @param upper highest bound that should be kept. If upper is inside bin interval, - the whole interval is removed. - @param merge how many adjacent bins to merge into one. -*/ -inline reduce_command crop_and_rebin(double lower, double upper, unsigned merge) { - return crop_and_rebin(reduce_command::unset, lower, upper, merge); -} - -/** Slice and rebin command to be used in `reduce`. - - Command is applied to axis with given index. - - To `slice` and `rebin` in one command (see the respective commands for more - details). Equivalent to passing both commands for the same axis to `reduce`. - - @param iaxis which axis to operate on. - @param begin first index that should be kept. - @param end one past the last index that should be kept. - @param merge how many adjacent bins to merge into one. - @param mode slice mode, see slice_mode. -*/ -inline reduce_command slice_and_rebin(unsigned iaxis, axis::index_type begin, - axis::index_type end, unsigned merge, - slice_mode mode = slice_mode::shrink) { - reduce_command r = slice(iaxis, begin, end, mode); - r.merge = rebin(merge).merge; - return r; -} - -/** Slice and rebin command to be used in `reduce`. - - Command is applied to corresponding axis in order of reduce arguments. - - To `slice` and `rebin` in one command (see the respective commands for more - details). Equivalent to passing both commands for the same axis to `reduce`. - - @param begin first index that should be kept. - @param end one past the last index that should be kept. - @param merge how many adjacent bins to merge into one. - @param mode slice mode, see slice_mode. -*/ -inline reduce_command slice_and_rebin(axis::index_type begin, axis::index_type end, - unsigned merge, - slice_mode mode = slice_mode::shrink) { - return slice_and_rebin(reduce_command::unset, begin, end, merge, mode); -} - -/** Shrink, crop, slice, and/or rebin axes of a histogram. - - Returns a new reduced histogram and leaves the original histogram untouched. - - The commands `rebin` and `shrink` or `slice` for the same axis are - automatically combined, this is not an error. Passing a `shrink` and a `slice` - command for the same axis or two `rebin` commands triggers an `invalid_argument` - exception. Trying to reducing a non-reducible axis triggers an `invalid_argument` - exception. Histograms with non-reducible axes can still be reduced along the - other axes that are reducible. - - @param hist original histogram. - @param options iterable sequence of reduce commands: `shrink`, `slice`, `rebin`, - `shrink_and_rebin`, or `slice_and_rebin`. The element type of the iterable should be - `reduce_command`. -*/ -template <class Histogram, class Iterable, class = detail::requires_iterable<Iterable>> -Histogram reduce(const Histogram& hist, const Iterable& options) { - using axis::index_type; - - const auto& old_axes = unsafe_access::axes(hist); - - auto opts = detail::make_stack_buffer<reduce_command>(old_axes); - - // check for invalid commands, merge commands, and set iaxis for positional commands - unsigned iaxis = 0; - for (const reduce_command& o_in : options) { - BOOST_ASSERT(o_in.merge > 0); - if (o_in.iaxis != reduce_command::unset && o_in.iaxis >= hist.rank()) - BOOST_THROW_EXCEPTION(std::invalid_argument("invalid axis index")); - auto& o_out = opts[o_in.iaxis == reduce_command::unset ? iaxis : o_in.iaxis]; - if (o_out.merge == 0) { - o_out = o_in; - } else { - // Some command was already set for this axis, see if we can combine commands. - // We can combine a rebin and non-rebin command. - if (!((o_in.range == reduce_command::range_t::none) ^ - (o_out.range == reduce_command::range_t::none)) || - (o_out.merge > 1 && o_in.merge > 1)) - BOOST_THROW_EXCEPTION(std::invalid_argument( - "multiple conflicting reduce commands for axis " + - std::to_string(o_in.iaxis == reduce_command::unset ? iaxis : o_in.iaxis))); - if (o_in.range != reduce_command::range_t::none) { - o_out.range = o_in.range; - o_out.begin = o_in.begin; - o_out.end = o_in.end; - } else { - o_out.merge = o_in.merge; - } - } - ++iaxis; - } - - // make new axes container with default-constructed axis instances - auto axes = detail::make_default(old_axes); - detail::static_if<detail::is_tuple<decltype(axes)>>( - [](auto&, const auto&) {}, - [](auto& axes, const auto& old_axes) { - axes.reserve(old_axes.size()); - detail::for_each_axis(old_axes, [&axes](const auto& a) { - axes.emplace_back(detail::make_default(a)); - }); - }, - axes, old_axes); - - // override default-constructed axis instances with modified instances - iaxis = 0; - hist.for_each_axis([&](const auto& a_in) { - using A = std::decay_t<decltype(a_in)>; - using AO = axis::traits::get_options<A>; - auto& o = opts[iaxis]; - o.is_ordered = axis::traits::ordered(a_in); - if (o.merge > 0) { // option is set? - o.use_underflow_bin = !o.crop && AO::test(axis::option::underflow); - o.use_overflow_bin = !o.crop && AO::test(axis::option::overflow); - detail::static_if_c<axis::traits::is_reducible<A>::value>( - [&o](auto&& a_out, const auto& a_in) { - using A = std::decay_t<decltype(a_in)>; - if (o.range == reduce_command::range_t::none) { - o.begin.index = 0; - o.end.index = a_in.size(); - } else { - if (o.range == reduce_command::range_t::values) { - const auto end_value = o.end.value; - o.begin.index = axis::traits::index(a_in, o.begin.value); - o.end.index = axis::traits::index(a_in, o.end.value); - // end = index + 1, unless end_value is exactly equal to (upper) bin edge - if (axis::traits::value_as<double>(a_in, o.end.index) != end_value) - ++o.end.index; - } - // limit [begin, end] to [0, size()] - if (o.begin.index < 0) o.begin.index = 0; - if (o.end.index > a_in.size()) o.end.index = a_in.size(); - } - // shorten the index range to a multiple of o.merge; - // example [1, 4] with merge = 2 is reduced to [1, 3] - o.end.index -= - (o.end.index - o.begin.index) % static_cast<index_type>(o.merge); - a_out = A(a_in, o.begin.index, o.end.index, o.merge); - }, - [iaxis](auto&&, const auto&) { - BOOST_THROW_EXCEPTION(std::invalid_argument("axis " + std::to_string(iaxis) + - " is not reducible")); - }, - axis::get<A>(detail::axis_get(axes, iaxis)), a_in); - } else { - // command was not set for this axis; fill noop values and copy original axis - o.use_underflow_bin = AO::test(axis::option::underflow); - o.use_overflow_bin = AO::test(axis::option::overflow); - o.merge = 1; - o.begin.index = 0; - o.end.index = a_in.size(); - axis::get<A>(detail::axis_get(axes, iaxis)) = a_in; - } - ++iaxis; - }); - - auto idx = detail::make_stack_buffer<index_type>(axes); - auto result = - Histogram(std::move(axes), detail::make_default(unsafe_access::storage(hist))); - for (auto&& x : indexed(hist, coverage::all)) { - auto i = idx.begin(); - auto o = opts.begin(); - bool skip = false; - - for (auto j : x.indices()) { - *i = (j - o->begin.index); - if (o->is_ordered && *i <= -1) { - *i = -1; - if (!o->use_underflow_bin) skip = true; - } else { - if (*i >= 0) - *i /= static_cast<index_type>(o->merge); - else - *i = o->end.index; - const auto reduced_axis_end = - (o->end.index - o->begin.index) / static_cast<index_type>(o->merge); - if (*i >= reduced_axis_end) { - *i = reduced_axis_end; - if (!o->use_overflow_bin) skip = true; - } - } - - ++i; - ++o; - } - - if (!skip) result.at(idx) += *x; - } - - return result; -} - -/** Shrink, slice, and/or rebin axes of a histogram. - - Returns a new reduced histogram and leaves the original histogram untouched. - - The commands `rebin` and `shrink` or `slice` for the same axis are - automatically combined, this is not an error. Passing a `shrink` and a `slice` - command for the same axis or two `rebin` commands triggers an invalid_argument - exception. It is safe to reduce histograms with some axis that are not reducible along - the other axes. Trying to reducing a non-reducible axis triggers an invalid_argument - exception. - - @param hist original histogram. - @param opt first reduce command; one of `shrink`, `slice`, `rebin`, - `shrink_and_rebin`, or `slice_or_rebin`. - @param opts more reduce commands. -*/ -template <class Histogram, class... Ts> -Histogram reduce(const Histogram& hist, const reduce_command& opt, const Ts&... opts) { - // this must be in one line, because any of the ts could be a temporary - return reduce(hist, std::initializer_list<reduce_command>{opt, opts...}); -} - -} // namespace algorithm -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/algorithm/sum.hpp b/ThirdParty/boost/histogram/algorithm/sum.hpp deleted file mode 100644 index c6573be9acb2b365889289b12fde9c38e043a8ac..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/algorithm/sum.hpp +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_ALGORITHM_SUM_HPP -#define BOOST_HISTOGRAM_ALGORITHM_SUM_HPP - -#include <boost/histogram/accumulators/sum.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/histogram/indexed.hpp> -#include <boost/mp11/utility.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace algorithm { - -/** Compute the sum over all histogram cells (underflow/overflow included by default). - - The implementation favors accuracy and protection against overflow over speed. If the - value type of the histogram is an integral or floating point type, - accumulators::sum<double> is used to compute the sum, else the original value type is - used. Compilation fails, if the value type does not support operator+=. The return type - is double if the value type of the histogram is integral or floating point, and the - original value type otherwise. - - If you need a different trade-off, you can write your own loop or use `std::accumulate`: - ``` - // iterate over all bins - auto sum_all = std::accumulate(hist.begin(), hist.end(), 0.0); - - // skip underflow/overflow bins - double sum = 0; - for (auto&& x : indexed(hist)) - sum += *x; // dereference accessor - - // or: - // auto ind = boost::histogram::indexed(hist); - // auto sum = std::accumulate(ind.begin(), ind.end(), 0.0); - ``` - - @returns accumulator type or double - - @param hist Const reference to the histogram. - @param cov Iterate over all or only inner bins (optional, default: all). -*/ -template <class A, class S> -auto sum(const histogram<A, S>& hist, const coverage cov = coverage::all) { - using T = typename histogram<A, S>::value_type; - using sum_type = mp11::mp_if<std::is_arithmetic<T>, accumulators::sum<double>, T>; - sum_type sum; - if (cov == coverage::all) - for (auto&& x : hist) sum += x; - else - // sum += x also works if sum_type::operator+=(const sum_type&) exists - for (auto&& x : indexed(hist)) sum += *x; - using R = mp11::mp_if<std::is_arithmetic<T>, double, T>; - return static_cast<R>(sum); -} - -} // namespace algorithm -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis.hpp b/ThirdParty/boost/histogram/axis.hpp deleted file mode 100644 index 88d86780ac0c5050c6fa9f606443239caae3c877..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis.hpp +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_HPP -#define BOOST_HISTOGRAM_AXIS_HPP - -/** - \file boost/histogram/axis.hpp - Includes all axis headers of the Boost.Histogram library. - - Extra header not automatically included: - - [boost/histogram/axis/ostream.hpp][1] - - [1]: histogram/reference.html#header.boost.histogram.axis.ostream_hpp -*/ - -#include <boost/histogram/axis/category.hpp> -#include <boost/histogram/axis/integer.hpp> -#include <boost/histogram/axis/regular.hpp> -#include <boost/histogram/axis/variable.hpp> -#include <boost/histogram/axis/variant.hpp> - -#endif diff --git a/ThirdParty/boost/histogram/axis/category.hpp b/ThirdParty/boost/histogram/axis/category.hpp deleted file mode 100644 index d3d69e29ef0708e2fdc7dd501e48dc87eb81fd7e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/category.hpp +++ /dev/null @@ -1,202 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_CATEGORY_HPP -#define BOOST_HISTOGRAM_AXIS_CATEGORY_HPP - -#include <algorithm> -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/iterator.hpp> -#include <boost/histogram/axis/metadata_base.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <string> -#include <type_traits> -#include <utility> -#include <vector> - -namespace boost { -namespace histogram { -namespace axis { - -/** - Maps at a set of unique values to bin indices. - - The axis maps a set of values to bins, following the order of arguments in the - constructor. The optional overflow bin for this axis counts input values that - are not part of the set. Binning has O(N) complexity, but with a very small - factor. For small N (the typical use case) it beats other kinds of lookup. - - @tparam Value input value type, must be equal-comparable. - @tparam MetaData type to store meta data. - @tparam Options see boost::histogram::axis::option. - @tparam Allocator allocator to use for dynamic memory management. - - The options `underflow` and `circular` are not allowed. The options `growth` - and `overflow` are mutually exclusive. -*/ -template <class Value, class MetaData, class Options, class Allocator> -class category : public iterator_mixin<category<Value, MetaData, Options, Allocator>>, - public metadata_base<MetaData> { - // these must be private, so that they are not automatically inherited - using value_type = Value; - using metadata_type = typename metadata_base<MetaData>::metadata_type; - using options_type = detail::replace_default<Options, option::overflow_t>; - using allocator_type = Allocator; - using vector_type = std::vector<value_type, allocator_type>; - - static_assert(!options_type::test(option::underflow), - "category axis cannot have underflow"); - static_assert(!options_type::test(option::circular), - "category axis cannot be circular"); - static_assert(!(options_type::test(option::growth) && - options_type::test(option::overflow)), - "growing category axis cannot have entries in overflow bin"); - -public: - constexpr category() = default; - explicit category(allocator_type alloc) : vec_(alloc) {} - - /** Construct from iterator range of unique values. - * - * \param begin begin of category range of unique values. - * \param end end of category range of unique values. - * \param meta description of the axis. - * \param alloc allocator instance to use. - */ - template <class It, class = detail::requires_iterator<It>> - category(It begin, It end, metadata_type meta = {}, allocator_type alloc = {}) - : metadata_base<MetaData>(std::move(meta)), vec_(alloc) { - if (std::distance(begin, end) < 0) - BOOST_THROW_EXCEPTION( - std::invalid_argument("end must be reachable by incrementing begin")); - vec_.reserve(std::distance(begin, end)); - while (begin != end) vec_.emplace_back(*begin++); - } - - /** Construct axis from iterable sequence of unique values. - * - * \param iterable sequence of unique values. - * \param meta description of the axis. - * \param alloc allocator instance to use. - */ - template <class C, class = detail::requires_iterable<C>> - category(const C& iterable, metadata_type meta = {}, allocator_type alloc = {}) - : category(std::begin(iterable), std::end(iterable), std::move(meta), - std::move(alloc)) {} - - /** Construct axis from an initializer list of unique values. - * - * \param list `std::initializer_list` of unique values. - * \param meta description of the axis. - * \param alloc allocator instance to use. - */ - template <class U> - category(std::initializer_list<U> list, metadata_type meta = {}, - allocator_type alloc = {}) - : category(list.begin(), list.end(), std::move(meta), std::move(alloc)) {} - - /// Constructor used by algorithm::reduce to shrink and rebin (not for users). - category(const category& src, index_type begin, index_type end, unsigned merge) - // LCOV_EXCL_START: gcc-8 is missing the delegated ctor for no reason - : category(src.vec_.begin() + begin, src.vec_.begin() + end, src.metadata(), - src.get_allocator()) - // LCOV_EXCL_STOP - { - if (merge > 1) - BOOST_THROW_EXCEPTION(std::invalid_argument("cannot merge bins for category axis")); - } - - /// Return index for value argument. - index_type index(const value_type& x) const noexcept { - const auto beg = vec_.begin(); - const auto end = vec_.end(); - return static_cast<index_type>(std::distance(beg, std::find(beg, end, x))); - } - - /// Returns index and shift (if axis has grown) for the passed argument. - std::pair<index_type, index_type> update(const value_type& x) { - const auto i = index(x); - if (i < size()) return {i, 0}; - vec_.emplace_back(x); - return {i, -1}; - } - - /// Return value for index argument. - /// Throws `std::out_of_range` if the index is out of bounds. - auto value(index_type idx) const - -> std::conditional_t<std::is_scalar<value_type>::value, value_type, - const value_type&> { - if (idx < 0 || idx >= size()) - BOOST_THROW_EXCEPTION(std::out_of_range("category index out of range")); - return vec_[idx]; - } - - /// Return value for index argument; alias for value(...). - decltype(auto) bin(index_type idx) const { return value(idx); } - - /// Returns the number of bins, without over- or underflow. - index_type size() const noexcept { return static_cast<index_type>(vec_.size()); } - - /// Returns the options. - static constexpr unsigned options() noexcept { return options_type::value; } - - /// Whether the axis is inclusive (see axis::traits::is_inclusive). - static constexpr bool inclusive() noexcept { - return options() & (option::overflow | option::growth); - } - - /// Indicate that the axis is not ordered. - static constexpr bool ordered() noexcept { return false; } - - template <class V, class M, class O, class A> - bool operator==(const category<V, M, O, A>& o) const noexcept { - const auto& a = vec_; - const auto& b = o.vec_; - return std::equal(a.begin(), a.end(), b.begin(), b.end()) && - metadata_base<MetaData>::operator==(o); - } - - template <class V, class M, class O, class A> - bool operator!=(const category<V, M, O, A>& o) const noexcept { - return !operator==(o); - } - - allocator_type get_allocator() const { return vec_.get_allocator(); } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("seq", vec_); - ar& make_nvp("meta", this->metadata()); - } - -private: - vector_type vec_; - - template <class V, class M, class O, class A> - friend class category; -}; - -#if __cpp_deduction_guides >= 201606 - -template <class T> -category(std::initializer_list<T>) - ->category<detail::replace_cstring<std::decay_t<T>>, null_type>; - -template <class T, class M> -category(std::initializer_list<T>, M) - ->category<detail::replace_cstring<std::decay_t<T>>, - detail::replace_cstring<std::decay_t<M>>>; - -#endif - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/integer.hpp b/ThirdParty/boost/histogram/axis/integer.hpp deleted file mode 100644 index 0403cc6720bb23a44f303697ca0bff1840ef1b9e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/integer.hpp +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_INTEGER_HPP -#define BOOST_HISTOGRAM_AXIS_INTEGER_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/iterator.hpp> -#include <boost/histogram/axis/metadata_base.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/detail/convert_integer.hpp> -#include <boost/histogram/detail/limits.hpp> -#include <boost/histogram/detail/replace_type.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/throw_exception.hpp> -#include <cmath> -#include <limits> -#include <stdexcept> -#include <string> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace axis { - -/** - Axis for an interval of integer values with unit steps. - - Binning is a O(1) operation. This axis bins faster than a regular axis. - - @tparam Value input value type. Must be integer or floating point. - @tparam MetaData type to store meta data. - @tparam Options see boost::histogram::axis::option (all values allowed). - */ -template <class Value, class MetaData, class Options> -class integer : public iterator_mixin<integer<Value, MetaData, Options>>, - public metadata_base<MetaData> { - // these must be private, so that they are not automatically inherited - using value_type = Value; - using metadata_type = typename metadata_base<MetaData>::metadata_type; - using options_type = - detail::replace_default<Options, decltype(option::underflow | option::overflow)>; - - static_assert(std::is_integral<value_type>::value || - std::is_floating_point<value_type>::value, - "integer axis requires floating point or integral type"); - - static_assert(!options_type::test(option::circular | option::growth) || - (options_type::test(option::circular) ^ - options_type::test(option::growth)), - "circular and growth options are mutually exclusive"); - - static_assert(std::is_floating_point<value_type>::value || - (!options_type::test(option::circular) && - !options_type::test(option::growth)) || - (!options_type::test(option::overflow) && - !options_type::test(option::underflow)), - "circular or growing integer axis with integral type " - "cannot have entries in underflow or overflow bins"); - - using local_index_type = std::conditional_t<std::is_integral<value_type>::value, - index_type, real_index_type>; - -public: - constexpr integer() = default; - - /** Construct over semi-open integer interval [start, stop). - * - * \param start first integer of covered range. - * \param stop one past last integer of covered range. - * \param meta description of the axis. - */ - integer(value_type start, value_type stop, metadata_type meta = {}) - : metadata_base<MetaData>(std::move(meta)) - , size_(static_cast<index_type>(stop - start)) - , min_(start) { - if (!(stop >= start)) - BOOST_THROW_EXCEPTION(std::invalid_argument("stop >= start required")); - } - - /// Constructor used by algorithm::reduce to shrink and rebin. - integer(const integer& src, index_type begin, index_type end, unsigned merge) - : integer(src.value(begin), src.value(end), src.metadata()) { - if (merge > 1) - BOOST_THROW_EXCEPTION(std::invalid_argument("cannot merge bins for integer axis")); - if (options_type::test(option::circular) && !(begin == 0 && end == src.size())) - BOOST_THROW_EXCEPTION(std::invalid_argument("cannot shrink circular axis")); - } - - /// Return index for value argument. - index_type index(value_type x) const noexcept { - return detail::static_if<std::is_floating_point<value_type>>( - [this](const auto z) -> index_type { - // need to handle NaN, cannot simply cast to int and call int-implementation - if (options_type::test(option::circular)) { - if (std::isfinite(z)) - return static_cast<index_type>(std::floor(z) - - std::floor(z / this->size()) * this->size()); - } else if (z < this->size()) - return z >= 0 ? static_cast<index_type>(z) : -1; - return this->size(); - }, - [this](const auto z) -> index_type { - if (options_type::test(option::circular)) - return static_cast<index_type>(z - std::floor(float(z) / this->size()) * - this->size()); - if (z < this->size()) return z >= 0 ? z : -1; - return this->size(); - }, - x - min_); - } - - /// Returns index and shift (if axis has grown) for the passed argument. - auto update(value_type x) noexcept { - auto impl = [this](long x) -> std::pair<index_type, index_type> { - const auto i = x - min_; - if (i >= 0) { - const auto k = static_cast<axis::index_type>(i); - if (k < size()) return {k, 0}; - const auto n = k - size() + 1; - size_ += n; - return {k, -n}; - } - const auto k = static_cast<axis::index_type>( - detail::static_if<std::is_floating_point<value_type>>( - [](auto x) { return std::floor(x); }, [](auto x) { return x; }, i)); - min_ += k; - size_ -= k; - return {0, -k}; - }; - - return detail::static_if<std::is_floating_point<value_type>>( - [this, impl](auto x) -> std::pair<index_type, index_type> { - if (std::isfinite(x)) return impl(static_cast<long>(std::floor(x))); - return {x < 0 ? -1 : this->size(), 0}; - }, - impl, x); - } - - /// Return value for index argument. - value_type value(local_index_type i) const noexcept { - if (!options_type::test(option::circular) && - std::is_floating_point<value_type>::value) { - if (i < 0) return detail::lowest<value_type>(); - if (i > size()) return detail::highest<value_type>(); - } - return min_ + i; - } - - /// Return bin for index argument. - decltype(auto) bin(index_type idx) const noexcept { - return detail::static_if<std::is_floating_point<value_type>>( - [this](auto idx) { return interval_view<integer>(*this, idx); }, - [this](auto idx) { return this->value(idx); }, idx); - } - - /// Returns the number of bins, without over- or underflow. - index_type size() const noexcept { return size_; } - - /// Returns the options. - static constexpr unsigned options() noexcept { return options_type::value; } - - /// Whether the axis is inclusive (see axis::traits::is_inclusive). - static constexpr bool inclusive() noexcept { - return (options() & option::underflow || options() & option::overflow) || - (std::is_integral<value_type>::value && - (options() & (option::growth | option::circular))); - } - - template <class V, class M, class O> - bool operator==(const integer<V, M, O>& o) const noexcept { - return size() == o.size() && min_ == o.min_ && metadata_base<MetaData>::operator==(o); - } - - template <class V, class M, class O> - bool operator!=(const integer<V, M, O>& o) const noexcept { - return !operator==(o); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("size", size_); - ar& make_nvp("meta", this->metadata()); - ar& make_nvp("min", min_); - } - -private: - index_type size_{0}; - value_type min_{0}; - - template <class V, class M, class O> - friend class integer; -}; - -#if __cpp_deduction_guides >= 201606 - -template <class T> -integer(T, T)->integer<detail::convert_integer<T, index_type>, null_type>; - -template <class T, class M> -integer(T, T, M) - ->integer<detail::convert_integer<T, index_type>, - detail::replace_type<std::decay_t<M>, const char*, std::string>>; - -#endif - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/interval_view.hpp b/ThirdParty/boost/histogram/axis/interval_view.hpp deleted file mode 100644 index 278d7a496b3b23abcd1f3bcdd06774da11478183..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/interval_view.hpp +++ /dev/null @@ -1,56 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_INTERVAL_VIEW_HPP -#define BOOST_HISTOGRAM_AXIS_INTERVAL_VIEW_HPP - -#include <boost/histogram/fwd.hpp> - -namespace boost { -namespace histogram { -namespace axis { - -/** - Lightweight bin view. - - Represents the current bin interval. -*/ -template <class Axis> -class interval_view { -public: - interval_view(const Axis& axis, index_type idx) : axis_(axis), idx_(idx) {} - // avoid viewing a temporary that goes out of scope - interval_view(Axis&& axis, index_type idx) = delete; - - /// Return lower edge of bin. - decltype(auto) lower() const noexcept { return axis_.value(idx_); } - /// Return upper edge of bin. - decltype(auto) upper() const noexcept { return axis_.value(idx_ + 1); } - /// Return center of bin. - decltype(auto) center() const noexcept { return axis_.value(idx_ + 0.5); } - /// Return width of bin. - decltype(auto) width() const noexcept { return upper() - lower(); } - - template <class BinType> - bool operator==(const BinType& rhs) const noexcept { - return lower() == rhs.lower() && upper() == rhs.upper(); - } - - template <class BinType> - bool operator!=(const BinType& rhs) const noexcept { - return !operator==(rhs); - } - -private: - const Axis& axis_; - const index_type idx_; -}; - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/iterator.hpp b/ThirdParty/boost/histogram/axis/iterator.hpp deleted file mode 100644 index 77ce425c89df6b3dc38d74f0d41f51e342738f58..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/iterator.hpp +++ /dev/null @@ -1,66 +0,0 @@ -// Copyright 2015-2017 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_ITERATOR_HPP -#define BOOST_HISTOGRAM_AXIS_ITERATOR_HPP - -#include <boost/histogram/axis/interval_view.hpp> -#include <boost/histogram/detail/iterator_adaptor.hpp> -#include <iterator> - -namespace boost { -namespace histogram { -namespace axis { - -template <class Axis> -class iterator : public detail::iterator_adaptor<iterator<Axis>, index_type, - decltype(std::declval<Axis>().bin(0))> { -public: - /// Make iterator from axis and index. - iterator(const Axis& axis, index_type idx) - : iterator::iterator_adaptor_(idx), axis_(axis) {} - - /// Return current bin object. - decltype(auto) operator*() const { return axis_.bin(this->base()); } - -private: - const Axis& axis_; -}; - -/// Uses CRTP to inject iterator logic into Derived. -template <class Derived> -class iterator_mixin { -public: - using const_iterator = iterator<Derived>; - using const_reverse_iterator = std::reverse_iterator<const_iterator>; - - /// Bin iterator to beginning of the axis (read-only). - const_iterator begin() const noexcept { - return const_iterator(*static_cast<const Derived*>(this), 0); - } - - /// Bin iterator to the end of the axis (read-only). - const_iterator end() const noexcept { - return const_iterator(*static_cast<const Derived*>(this), - static_cast<const Derived*>(this)->size()); - } - - /// Reverse bin iterator to the last entry of the axis (read-only). - const_reverse_iterator rbegin() const noexcept { - return std::make_reverse_iterator(end()); - } - - /// Reverse bin iterator to the end (read-only). - const_reverse_iterator rend() const noexcept { - return std::make_reverse_iterator(begin()); - } -}; - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/metadata_base.hpp b/ThirdParty/boost/histogram/axis/metadata_base.hpp deleted file mode 100644 index ff3d99d398cfadd624556b454bfdcfb1138dd8be..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/metadata_base.hpp +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_METADATA_BASE_HPP -#define BOOST_HISTOGRAM_AXIS_METADATA_BASE_HPP - -#include <boost/core/empty_value.hpp> -#include <boost/histogram/detail/relaxed_equal.hpp> -#include <boost/histogram/detail/replace_type.hpp> -#include <string> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace axis { - -/// Meta data holder with space optimization for empty meta data types. -template <class Metadata, - class DetailMetadata = detail::replace_default<Metadata, std::string>> -class metadata_base : empty_value<DetailMetadata> { - using base_t = empty_value<DetailMetadata>; - -protected: - using metadata_type = DetailMetadata; - - // std::string explicitly guarantees nothrow only in C++17 - static_assert(std::is_same<metadata_type, std::string>::value || - std::is_nothrow_move_constructible<metadata_type>::value, - "metadata must be nothrow move constructible"); - - metadata_base() = default; - metadata_base(const metadata_base&) = default; - metadata_base& operator=(const metadata_base&) = default; - - // make noexcept because std::string is nothrow move constructible only in C++17 - metadata_base(metadata_base&& o) noexcept : base_t(std::move(o)) {} - metadata_base(metadata_type&& o) noexcept : base_t(empty_init_t{}, std::move(o)) {} - // make noexcept because std::string is nothrow move constructible only in C++17 - metadata_base& operator=(metadata_base&& o) noexcept { - base_t::operator=(o); - return *this; - } - -public: - /// Returns reference to metadata. - metadata_type& metadata() noexcept { return base_t::get(); } - - /// Returns reference to const metadata. - const metadata_type& metadata() const noexcept { return base_t::get(); } - - bool operator==(const metadata_base& o) const noexcept { - return detail::relaxed_equal(metadata(), o.metadata()); - } - - bool operator!=(const metadata_base& o) const noexcept { - return operator==(o.metadata()); - } -}; - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/option.hpp b/ThirdParty/boost/histogram/axis/option.hpp deleted file mode 100644 index f6142f94454a7c67dcdc81863b158a8bb9e1a681..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/option.hpp +++ /dev/null @@ -1,81 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_OPTION_HPP -#define BOOST_HISTOGRAM_AXIS_OPTION_HPP - -#include <type_traits> - -/** - \file option.hpp Options for builtin axis types. - - Options `circular` and `growth` are mutually exclusive. - Options `circular` and `underflow` are mutually exclusive. -*/ - -namespace boost { -namespace histogram { -namespace axis { -namespace option { - -/// Holder of axis options. -template <unsigned Bits> -struct bitset : std::integral_constant<unsigned, Bits> { - /// Returns true if all option flags in the argument are set and false otherwise. - template <unsigned B> - static constexpr auto test(bitset<B>) { - return std::integral_constant<bool, static_cast<bool>((Bits & B) == B)>{}; - } -}; - -/// Set union of the axis option arguments. -template <unsigned B1, unsigned B2> -constexpr auto operator|(bitset<B1>, bitset<B2>) { - return bitset<(B1 | B2)>{}; -} - -/// Set intersection of the option arguments. -template <unsigned B1, unsigned B2> -constexpr auto operator&(bitset<B1>, bitset<B2>) { - return bitset<(B1 & B2)>{}; -} - -/// Set difference of the option arguments. -template <unsigned B1, unsigned B2> -constexpr auto operator-(bitset<B1>, bitset<B2>) { - return bitset<(B1 & ~B2)>{}; -} - -/** - Single option flag. - - @tparam Pos position of the bit in the set. -*/ -template <unsigned Pos> -struct bit : bitset<(1 << Pos)> {}; - -/// All options off. -using none_t = bitset<0>; -constexpr none_t none{}; ///< Instance of `none_t`. -/// Axis has an underflow bin. Mutually exclusive with `circular`. -using underflow_t = bit<0>; -constexpr underflow_t underflow{}; ///< Instance of `underflow_t`. -/// Axis has overflow bin. -using overflow_t = bit<1>; -constexpr overflow_t overflow{}; ///< Instance of `overflow_t`. -/// Axis is circular. Mutually exclusive with `growth` and `underflow`. -using circular_t = bit<2>; -constexpr circular_t circular{}; ///< Instance of `circular_t`. -/// Axis can grow. Mutually exclusive with `circular`. -using growth_t = bit<3>; -constexpr growth_t growth{}; ///< Instance of `growth_t`. - -} // namespace option -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/ostream.hpp b/ThirdParty/boost/histogram/axis/ostream.hpp deleted file mode 100644 index ca307a59f2df50c1275cc23b8078eb59ffb00554..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/ostream.hpp +++ /dev/null @@ -1,197 +0,0 @@ -// Copyright 2015-2017 Hans Dembinski -// -// 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) -// -// String representations here evaluate correctly in Python. - -#ifndef BOOST_HISTOGRAM_AXIS_OSTREAM_HPP -#define BOOST_HISTOGRAM_AXIS_OSTREAM_HPP - -#include <boost/assert.hpp> -#include <boost/histogram/axis/regular.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/detail/type_name.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/throw_exception.hpp> -#include <iomanip> -#include <iosfwd> -#include <sstream> -#include <stdexcept> -#include <type_traits> - -/** - \file boost/histogram/axis/ostream.hpp - Simple streaming operators for the builtin axis types. - - The text representation is not guaranteed to be stable between versions of - Boost.Histogram. This header is only included by - [boost/histogram/ostream.hpp](histogram/reference.html#header.boost.histogram.ostream_hpp). - To you use your own, include your own implementation instead of this header and do not - include - [boost/histogram/ostream.hpp](histogram/reference.html#header.boost.histogram.ostream_hpp). - */ - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -namespace boost { -namespace histogram { - -namespace detail { -inline const char* axis_suffix(const axis::transform::id&) { return ""; } -inline const char* axis_suffix(const axis::transform::log&) { return "_log"; } -inline const char* axis_suffix(const axis::transform::sqrt&) { return "_sqrt"; } -inline const char* axis_suffix(const axis::transform::pow&) { return "_pow"; } - -template <class OStream, class T> -void stream_metadata(OStream& os, const T& t) { - detail::static_if<detail::is_streamable<T>>( - [&os](const auto& t) { - std::ostringstream oss; - oss << t; - if (!oss.str().empty()) { os << ", metadata=" << std::quoted(oss.str()); } - }, - [&os](const auto&) { os << ", metadata=" << detail::type_name<T>(); }, t); -} - -template <class OStream> -void stream_options(OStream& os, const unsigned bits) { - os << ", options="; - bool first = true; - -#define BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM(x) \ - if (bits & axis::option::x) { \ - if (first) \ - first = false; \ - else { \ - os << " | "; \ - } \ - os << #x; \ - } - - BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM(underflow); - BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM(overflow); - BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM(circular); - BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM(growth); - -#undef BOOST_HISTOGRAM_AXIS_OPTION_OSTREAM - - if (first) os << "none"; -} - -template <class OStream, class T> -void stream_transform(OStream&, const T&) {} - -template <class OStream> -void stream_transform(OStream& os, const axis::transform::pow& t) { - os << ", power=" << t.power; -} - -template <class OStream, class T> -void stream_value(OStream& os, const T& t) { - os << t; -} - -template <class OStream, class... Ts> -void stream_value(OStream& os, const std::basic_string<Ts...>& t) { - os << std::quoted(t); -} - -} // namespace detail - -namespace axis { - -template <class T> -class polymorphic_bin; - -template <class... Ts> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, const null_type&) { - return os; // do nothing -} - -template <class... Ts, class U> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const interval_view<U>& i) { - os << "[" << i.lower() << ", " << i.upper() << ")"; - return os; -} - -template <class... Ts, class U> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const polymorphic_bin<U>& i) { - if (i.is_discrete()) - os << static_cast<double>(i); - else - os << "[" << i.lower() << ", " << i.upper() << ")"; - return os; -} - -template <class... Ts, class... Us> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const regular<Us...>& a) { - os << "regular" << detail::axis_suffix(a.transform()) << "(" << a.size() << ", " - << a.value(0) << ", " << a.value(a.size()); - detail::stream_metadata(os, a.metadata()); - detail::stream_options(os, a.options()); - detail::stream_transform(os, a.transform()); - os << ")"; - return os; -} - -template <class... Ts, class... Us> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const integer<Us...>& a) { - os << "integer(" << a.value(0) << ", " << a.value(a.size()); - detail::stream_metadata(os, a.metadata()); - detail::stream_options(os, a.options()); - os << ")"; - return os; -} - -template <class... Ts, class... Us> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const variable<Us...>& a) { - os << "variable(" << a.value(0); - for (index_type i = 1, n = a.size(); i <= n; ++i) { os << ", " << a.value(i); } - detail::stream_metadata(os, a.metadata()); - detail::stream_options(os, a.options()); - os << ")"; - return os; -} - -template <class... Ts, class... Us> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const category<Us...>& a) { - os << "category("; - for (index_type i = 0, n = a.size(); i < n; ++i) { - detail::stream_value(os, a.value(i)); - os << (i == (a.size() - 1) ? "" : ", "); - } - detail::stream_metadata(os, a.metadata()); - detail::stream_options(os, a.options()); - os << ")"; - return os; -} - -template <class... Ts, class... Us> -std::basic_ostream<Ts...>& operator<<(std::basic_ostream<Ts...>& os, - const variant<Us...>& v) { - visit( - [&os](const auto& x) { - using A = std::decay_t<decltype(x)>; - detail::static_if<detail::is_streamable<A>>( - [&os](const auto& x) { os << x; }, - [&os](const auto&) { os << "<unstreamable>"; }, x); - }, - v); - return os; -} - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -#endif diff --git a/ThirdParty/boost/histogram/axis/polymorphic_bin.hpp b/ThirdParty/boost/histogram/axis/polymorphic_bin.hpp deleted file mode 100644 index 3849711d4b2d66834c72303c3ea8394cb076ced1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/polymorphic_bin.hpp +++ /dev/null @@ -1,89 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_POLYMORPHIC_BIN_HPP -#define BOOST_HISTOGRAM_AXIS_POLYMORPHIC_BIN_HPP - -#include <boost/histogram/detail/detect.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace axis { - -/** - Holds the bin data of an axis::variant. - - The interface is a superset of the axis::interval_view - class. In addition, the object is implicitly convertible to the value type, - returning the equivalent of a call to lower(). For discrete axes, lower() == - upper(), and width() returns zero. - - This is not a view like axis::interval_view for two reasons. - - Sequential calls to lower() and upper() would have to each loop through - the variant types. This is likely to be slower than filling all the data in - one loop. - - polymorphic_bin may be created from a temporary instance of axis::variant, - like in the call histogram::axis(0). Storing a reference to the axis would - result in a dangling reference. Rather than specialing the code to handle - this, it seems easier to just use a value instead of a view. -*/ -template <class RealType> -class polymorphic_bin { - using value_type = RealType; - -public: - polymorphic_bin(value_type lower, value_type upper) - : lower_or_value_(lower), upper_(upper) {} - - /// Implicitly convert to bin value (for axis with discrete values). - operator const value_type&() const noexcept { return lower_or_value_; } - - /// Return lower edge of bin. - value_type lower() const noexcept { return lower_or_value_; } - /// Return upper edge of bin. - value_type upper() const noexcept { return upper_; } - /// Return center of bin. - value_type center() const noexcept { return 0.5 * (lower() + upper()); } - /// Return width of bin. - value_type width() const noexcept { return upper() - lower(); } - - template <class BinType> - bool operator==(const BinType& rhs) const noexcept { - return equal_impl(detail::has_method_lower<BinType>(), rhs); - } - - template <class BinType> - bool operator!=(const BinType& rhs) const noexcept { - return !operator==(rhs); - } - - /// Return true if bin is discrete. - bool is_discrete() const noexcept { return lower_or_value_ == upper_; } - -private: - bool equal_impl(std::true_type, const polymorphic_bin& rhs) const noexcept { - return lower_or_value_ == rhs.lower_or_value_ && upper_ == rhs.upper_; - } - - template <class BinType> - bool equal_impl(std::true_type, const BinType& rhs) const noexcept { - return lower() == rhs.lower() && upper() == rhs.upper(); - } - - template <class BinType> - bool equal_impl(std::false_type, const BinType& rhs) const noexcept { - return is_discrete() && static_cast<value_type>(*this) == rhs; - } - - const value_type lower_or_value_, upper_; -}; - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/regular.hpp b/ThirdParty/boost/histogram/axis/regular.hpp deleted file mode 100644 index 5db0a38eba18f614405efdaa2aab8ab9f41fda3f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/regular.hpp +++ /dev/null @@ -1,429 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_REGULAR_HPP -#define BOOST_HISTOGRAM_AXIS_REGULAR_HPP - -#include <boost/assert.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/interval_view.hpp> -#include <boost/histogram/axis/iterator.hpp> -#include <boost/histogram/axis/metadata_base.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/detail/convert_integer.hpp> -#include <boost/histogram/detail/relaxed_equal.hpp> -#include <boost/histogram/detail/replace_type.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <cmath> -#include <limits> -#include <stdexcept> -#include <string> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -using get_scale_type_helper = typename T::value_type; - -template <class T> -using get_scale_type = mp11::mp_eval_or<T, detail::get_scale_type_helper, T>; - -struct one_unit {}; - -template <class T> -T operator*(T&& t, const one_unit&) { - return std::forward<T>(t); -} - -template <class T> -T operator/(T&& t, const one_unit&) { - return std::forward<T>(t); -} - -template <class T> -using get_unit_type_helper = typename T::unit_type; - -template <class T> -using get_unit_type = mp11::mp_eval_or<one_unit, detail::get_unit_type_helper, T>; - -template <class T, class R = get_scale_type<T>> -R get_scale(const T& t) { - return t / get_unit_type<T>(); -} - -} // namespace detail - -namespace axis { - -namespace transform { - -/// Identity transform for equidistant bins. -struct id { - /// Pass-through. - template <class T> - static T forward(T&& x) noexcept { - return std::forward<T>(x); - } - - /// Pass-through. - template <class T> - static T inverse(T&& x) noexcept { - return std::forward<T>(x); - } - - template <class Archive> - void serialize(Archive&, unsigned /* version */) {} -}; - -/// Log transform for equidistant bins in log-space. -struct log { - /// Returns log(x) of external value x. - template <class T> - static T forward(T x) { - return std::log(x); - } - - /// Returns exp(x) for internal value x. - template <class T> - static T inverse(T x) { - return std::exp(x); - } - - template <class Archive> - void serialize(Archive&, unsigned /* version */) {} -}; - -/// Sqrt transform for equidistant bins in sqrt-space. -struct sqrt { - /// Returns sqrt(x) of external value x. - template <class T> - static T forward(T x) { - return std::sqrt(x); - } - - /// Returns x^2 of internal value x. - template <class T> - static T inverse(T x) { - return x * x; - } - - template <class Archive> - void serialize(Archive&, unsigned /* version */) {} -}; - -/// Pow transform for equidistant bins in pow-space. -struct pow { - double power = 1; /**< power index */ - - /// Make transform with index p. - explicit pow(double p) : power(p) {} - pow() = default; - - /// Returns pow(x, power) of external value x. - template <class T> - auto forward(T x) const { - return std::pow(x, power); - } - - /// Returns pow(x, 1/power) of external value x. - template <class T> - auto inverse(T x) const { - return std::pow(x, 1.0 / power); - } - - bool operator==(const pow& o) const noexcept { return power == o.power; } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("power", power); - } -}; - -} // namespace transform - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -// Type envelope to mark value as step size -template <class T> -struct step_type { - T value; -}; -#endif - -/** - Helper function to mark argument as step size. - */ -template <class T> -step_type<T> step(T t) { - return step_type<T>{t}; -} - -/** - Axis for equidistant intervals on the real line. - - The most common binning strategy. Very fast. Binning is a O(1) operation. - - @tparam Value input value type, must be floating point. - @tparam Transform builtin or user-defined transform type. - @tparam MetaData type to store meta data. - @tparam Options see boost::histogram::axis::option (all values allowed). - */ -template <class Value, class Transform, class MetaData, class Options> -class regular : public iterator_mixin<regular<Value, Transform, MetaData, Options>>, - protected detail::replace_default<Transform, transform::id>, - public metadata_base<MetaData> { - // these must be private, so that they are not automatically inherited - using value_type = Value; - using transform_type = detail::replace_default<Transform, transform::id>; - using metadata_type = typename metadata_base<MetaData>::metadata_type; - using options_type = - detail::replace_default<Options, decltype(option::underflow | option::overflow)>; - - static_assert(std::is_nothrow_move_constructible<transform_type>::value, - "transform must be no-throw move constructible"); - static_assert(std::is_nothrow_move_assignable<transform_type>::value, - "transform must be no-throw move assignable"); - - using unit_type = detail::get_unit_type<value_type>; - using internal_value_type = detail::get_scale_type<value_type>; - - static_assert(std::is_floating_point<internal_value_type>::value, - "regular axis requires floating point type"); - - static_assert( - (!options_type::test(option::circular) && !options_type::test(option::growth)) || - (options_type::test(option::circular) ^ options_type::test(option::growth)), - "circular and growth options are mutually exclusive"); - -public: - constexpr regular() = default; - - /** Construct n bins over real transformed range [start, stop). - * - * @param trans transform instance to use. - * @param n number of bins. - * @param start low edge of first bin. - * @param stop high edge of last bin. - * @param meta description of the axis (optional). - */ - regular(transform_type trans, unsigned n, value_type start, value_type stop, - metadata_type meta = {}) - : transform_type(std::move(trans)) - , metadata_base<MetaData>(std::move(meta)) - , size_(static_cast<index_type>(n)) - , min_(this->forward(detail::get_scale(start))) - , delta_(this->forward(detail::get_scale(stop)) - min_) { - if (size() == 0) BOOST_THROW_EXCEPTION(std::invalid_argument("bins > 0 required")); - if (!std::isfinite(min_) || !std::isfinite(delta_)) - BOOST_THROW_EXCEPTION( - std::invalid_argument("forward transform of start or stop invalid")); - if (delta_ == 0) - BOOST_THROW_EXCEPTION(std::invalid_argument("range of axis is zero")); - } - - /** Construct n bins over real range [start, stop). - * - * @param n number of bins. - * @param start low edge of first bin. - * @param stop high edge of last bin. - * @param meta description of the axis (optional). - */ - regular(unsigned n, value_type start, value_type stop, metadata_type meta = {}) - : regular({}, n, start, stop, std::move(meta)) {} - - /** Construct bins with the given step size over real transformed range - * [start, stop). - * - * @param trans transform instance to use. - * @param step width of a single bin. - * @param start low edge of first bin. - * @param stop upper limit of high edge of last bin (see below). - * @param meta description of the axis (optional). - * - * The axis computes the number of bins as n = abs(stop - start) / step, - * rounded down. This means that stop is an upper limit to the actual value - * (start + n * step). - */ - template <class T> - regular(transform_type trans, step_type<T> step, value_type start, value_type stop, - metadata_type meta = {}) - : regular(trans, static_cast<index_type>(std::abs(stop - start) / step.value), - start, - start + static_cast<index_type>(std::abs(stop - start) / step.value) * - step.value, - std::move(meta)) {} - - /** Construct bins with the given step size over real range [start, stop). - * - * @param step width of a single bin. - * @param start low edge of first bin. - * @param stop upper limit of high edge of last bin (see below). - * @param meta description of the axis (optional). - * - * The axis computes the number of bins as n = abs(stop - start) / step, - * rounded down. This means that stop is an upper limit to the actual value - * (start + n * step). - */ - template <class T> - regular(step_type<T> step, value_type start, value_type stop, metadata_type meta = {}) - : regular({}, step, start, stop, std::move(meta)) {} - - /// Constructor used by algorithm::reduce to shrink and rebin (not for users). - regular(const regular& src, index_type begin, index_type end, unsigned merge) - : regular(src.transform(), (end - begin) / merge, src.value(begin), src.value(end), - src.metadata()) { - BOOST_ASSERT((end - begin) % merge == 0); - if (options_type::test(option::circular) && !(begin == 0 && end == src.size())) - BOOST_THROW_EXCEPTION(std::invalid_argument("cannot shrink circular axis")); - } - - /// Return instance of the transform type. - const transform_type& transform() const noexcept { return *this; } - - /// Return index for value argument. - index_type index(value_type x) const noexcept { - // Runs in hot loop, please measure impact of changes - auto z = (this->forward(x / unit_type{}) - min_) / delta_; - if (options_type::test(option::circular)) { - if (std::isfinite(z)) { - z -= std::floor(z); - return static_cast<index_type>(z * size()); - } - } else { - if (z < 1) { - if (z >= 0) - return static_cast<index_type>(z * size()); - else - return -1; - } - } - return size(); // also returned if x is NaN - } - - /// Returns index and shift (if axis has grown) for the passed argument. - std::pair<index_type, index_type> update(value_type x) noexcept { - BOOST_ASSERT(options_type::test(option::growth)); - const auto z = (this->forward(x / unit_type{}) - min_) / delta_; - if (z < 1) { // don't use i here! - if (z >= 0) { - const auto i = static_cast<axis::index_type>(z * size()); - return {i, 0}; - } - if (z != -std::numeric_limits<internal_value_type>::infinity()) { - const auto stop = min_ + delta_; - const auto i = static_cast<axis::index_type>(std::floor(z * size())); - min_ += i * (delta_ / size()); - delta_ = stop - min_; - size_ -= i; - return {0, -i}; - } - // z is -infinity - return {-1, 0}; - } - // z either beyond range, infinite, or NaN - if (z < std::numeric_limits<internal_value_type>::infinity()) { - const auto i = static_cast<axis::index_type>(z * size()); - const auto n = i - size() + 1; - delta_ /= size(); - delta_ *= size() + n; - size_ += n; - return {i, -n}; - } - // z either infinite or NaN - return {size(), 0}; - } - - /// Return value for fractional index argument. - value_type value(real_index_type i) const noexcept { - auto z = i / size(); - if (!options_type::test(option::circular) && z < 0.0) - z = -std::numeric_limits<internal_value_type>::infinity() * delta_; - else if (options_type::test(option::circular) || z <= 1.0) - z = (1.0 - z) * min_ + z * (min_ + delta_); - else { - z = std::numeric_limits<internal_value_type>::infinity() * delta_; - } - return static_cast<value_type>(this->inverse(z) * unit_type()); - } - - /// Return bin for index argument. - decltype(auto) bin(index_type idx) const noexcept { - return interval_view<regular>(*this, idx); - } - - /// Returns the number of bins, without over- or underflow. - index_type size() const noexcept { return size_; } - - /// Returns the options. - static constexpr unsigned options() noexcept { return options_type::value; } - - template <class V, class T, class M, class O> - bool operator==(const regular<V, T, M, O>& o) const noexcept { - return detail::relaxed_equal(transform(), o.transform()) && size() == o.size() && - min_ == o.min_ && delta_ == o.delta_ && metadata_base<MetaData>::operator==(o); - } - template <class V, class T, class M, class O> - bool operator!=(const regular<V, T, M, O>& o) const noexcept { - return !operator==(o); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("transform", static_cast<transform_type&>(*this)); - ar& make_nvp("size", size_); - ar& make_nvp("meta", this->metadata()); - ar& make_nvp("min", min_); - ar& make_nvp("delta", delta_); - } - -private: - index_type size_{0}; - internal_value_type min_{0}, delta_{1}; - - template <class V, class T, class M, class O> - friend class regular; -}; - -#if __cpp_deduction_guides >= 201606 - -template <class T> -regular(unsigned, T, T) - ->regular<detail::convert_integer<T, double>, transform::id, null_type>; - -template <class T, class M> -regular(unsigned, T, T, M) - ->regular<detail::convert_integer<T, double>, transform::id, - detail::replace_cstring<std::decay_t<M>>>; - -template <class Tr, class T, class = detail::requires_transform<Tr, T>> -regular(Tr, unsigned, T, T)->regular<detail::convert_integer<T, double>, Tr, null_type>; - -template <class Tr, class T, class M> -regular(Tr, unsigned, T, T, M) - ->regular<detail::convert_integer<T, double>, Tr, - detail::replace_cstring<std::decay_t<M>>>; - -#endif - -/// Regular axis with circular option already set. -template <class Value = double, class MetaData = use_default, class Options = use_default> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using circular = regular<Value, transform::id, MetaData, - decltype(detail::replace_default<Options, option::overflow_t>{} | - option::circular)>; -#else -class circular; -#endif - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/traits.hpp b/ThirdParty/boost/histogram/axis/traits.hpp deleted file mode 100644 index b4f8486ea94ae78af0df9e4142027e6898078b90..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/traits.hpp +++ /dev/null @@ -1,475 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_TRAITS_HPP -#define BOOST_HISTOGRAM_AXIS_TRAITS_HPP - -#include <boost/core/ignore_unused.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/detail/args_type.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/priority.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/detail/try_cast.hpp> -#include <boost/histogram/detail/type_name.hpp> -#include <boost/variant2/variant.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <string> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -template <class Axis> -struct value_type_deducer { - using type = - std::remove_cv_t<std::remove_reference_t<detail::arg_type<decltype(&Axis::index)>>>; -}; - -template <class Axis> -auto traits_options(priority<2>) -> axis::option::bitset<Axis::options()>; - -template <class Axis> -auto traits_options(priority<1>) -> decltype(&Axis::update, axis::option::growth_t{}); - -template <class Axis> -auto traits_options(priority<0>) -> axis::option::none_t; - -template <class Axis> -auto traits_is_inclusive(priority<1>) -> std::integral_constant<bool, Axis::inclusive()>; - -template <class Axis> -auto traits_is_inclusive(priority<0>) - -> decltype(traits_options<Axis>(priority<2>{}) - .test(axis::option::underflow | axis::option::overflow)); - -template <class Axis> -auto traits_is_ordered(priority<1>) -> std::integral_constant<bool, Axis::ordered()>; - -template <class Axis, class ValueType = typename value_type_deducer<Axis>::type> -auto traits_is_ordered(priority<0>) -> typename std::is_arithmetic<ValueType>::type; - -template <class I, class D, class A, - class J = std::decay_t<arg_type<decltype(&A::value)>>> -decltype(auto) value_method_switch(I&& i, D&& d, const A& a, priority<1>) { - return static_if<std::is_same<J, axis::index_type>>(std::forward<I>(i), - std::forward<D>(d), a); -} - -template <class I, class D, class A> -double value_method_switch(I&&, D&&, const A&, priority<0>) { - // comma trick to make all compilers happy; some would complain about - // unreachable code after the throw, others about a missing return - return BOOST_THROW_EXCEPTION( - std::runtime_error(type_name<A>() + " has no value method")), - double{}; -} - -static axis::null_type null_value; - -struct variant_access { - template <class T, class Variant> - static auto get_if(Variant* v) noexcept { - using T0 = mp11::mp_first<std::decay_t<Variant>>; - return static_if<std::is_pointer<T0>>( - [](auto* vptr) { - using TP = mp11::mp_if<std::is_const<std::remove_pointer_t<T0>>, const T*, T*>; - auto ptp = variant2::get_if<TP>(vptr); - return ptp ? *ptp : nullptr; - }, - [](auto* vptr) { return variant2::get_if<T>(vptr); }, &(v->impl)); - } - - template <class T0, class Visitor, class Variant> - static decltype(auto) visit_impl(mp11::mp_identity<T0>, Visitor&& vis, Variant&& v) { - return variant2::visit(std::forward<Visitor>(vis), v.impl); - } - - template <class T0, class Visitor, class Variant> - static decltype(auto) visit_impl(mp11::mp_identity<T0*>, Visitor&& vis, Variant&& v) { - return variant2::visit( - [&vis](auto&& x) -> decltype(auto) { return std::forward<Visitor>(vis)(*x); }, - v.impl); - } - - template <class Visitor, class Variant> - static decltype(auto) visit(Visitor&& vis, Variant&& v) { - using T0 = mp11::mp_first<std::decay_t<Variant>>; - return visit_impl(mp11::mp_identity<T0>{}, std::forward<Visitor>(vis), - std::forward<Variant>(v)); - } -}; - -} // namespace detail - -namespace axis { -namespace traits { - -/** Value type for axis type. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and returns the value type. - - The value type is deduced from the argument of the `Axis::index` method. Const - references are decayed to the their value types, for example, the type deduced for - `Axis::index(const int&)` is `int`. - - The deduction always succeeds if the axis type models the Axis concept correctly. Errors - come from violations of the concept, in particular, an index method that is templated or - overloaded is not allowed. - - @tparam Axis axis type. -*/ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using value_type = typename detail::value_type_deducer<Axis>::type; -#else -struct value_type; -#endif - -/** Whether axis is continuous or discrete. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and returns a compile-time boolean. - - If the boolean is true, the axis is continuous (covers a continuous range of values). - Otherwise it is discrete (covers discrete values). -*/ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using is_continuous = typename std::is_floating_point<traits::value_type<Axis>>::type; -#else -struct is_continuous; -#endif - -/** Meta-function to detect whether an axis is reducible. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and represents compile-time boolean which is true or false, depending on - whether the axis can be reduced with boost::histogram::algorithm::reduce(). - - An axis can be made reducible by adding a special constructor, see Axis concept for - details. - - @tparam Axis axis type. - */ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using is_reducible = std::is_constructible<Axis, const Axis&, axis::index_type, - axis::index_type, unsigned>; -#else -struct is_reducible; -#endif - -/** Get axis options for axis type. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and returns the boost::histogram::axis::option::bitset. - - If Axis::options() is valid and constexpr, get_options is the corresponding - option type. Otherwise, it is boost::histogram::axis::option::growth_t, if the - axis has a method `update`, else boost::histogram::axis::option::none_t. - - @tparam Axis axis type -*/ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using get_options = decltype(detail::traits_options<Axis>(detail::priority<2>{})); - -template <class Axis> -using static_options [[deprecated("use get_options instead")]] = get_options<Axis>; - -#else -struct get_options; -#endif - -/** Meta-function to detect whether an axis is inclusive. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and represents compile-time boolean which is true or false, depending on - whether the axis is inclusive or not. - - An axis with underflow and overflow bins is always inclusive, but an axis may be - inclusive under other conditions. The meta-function checks for the method `constexpr - static bool inclusive()`, and uses the result. If this method is not present, it uses - get_options<Axis> and checks whether the underflow and overflow bits are present. - - An inclusive axis has a bin for every possible input value. A histogram which consists - only of inclusive axes can be filled more efficiently, since input values always - end up in a valid cell and there is no need to keep track of input tuples that need to - be discarded. - - @tparam Axis axis type -*/ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using is_inclusive = decltype(detail::traits_is_inclusive<Axis>(detail::priority<1>{})); - -template <class Axis> -using static_is_inclusive [[deprecated("use is_inclusive instead")]] = is_inclusive<Axis>; - -#else -struct is_inclusive; -#endif - -/** Meta-function to detect whether an axis is ordered. - - Doxygen does not render this well. This is a meta-function (template alias), it accepts - an axis type and returns a compile-time boolean. If the boolean is true, the axis is - ordered. - - The meta-function checks for the method `constexpr static bool ordered()`, and uses the - result. If this method is not present, it returns true if the value type of the Axis is - arithmetic and false otherwise. - - An ordered axis has a value type that is ordered, which means that indices i < - j < k implies either value(i) < value(j) < value(k) or value(i) > value(j) > value(k) - for all i,j,k. For example, the integer axis is ordered, but the category axis is not. - Axis which are not ordered must not have underflow bins, because they only have an - "other" category, which is identified with the overflow bin if it is available. - - @tparam Axis axis type -*/ -template <class Axis> -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED -using is_ordered = decltype(detail::traits_is_ordered<Axis>(detail::priority<1>{})); -#else -struct is_ordered; -#endif - -/** Returns axis options as unsigned integer. - - See get_options for details. - - @param axis any axis instance -*/ -template <class Axis> -constexpr unsigned options(const Axis& axis) noexcept { - boost::ignore_unused(axis); - return get_options<Axis>::value; -} - -// specialization for variant -template <class... Ts> -unsigned options(const variant<Ts...>& axis) noexcept { - return axis.options(); -} - -/** Returns true if axis is inclusive or false. - - See is_inclusive for details. - - @param axis any axis instance -*/ -template <class Axis> -constexpr bool inclusive(const Axis& axis) noexcept { - boost::ignore_unused(axis); - return is_inclusive<Axis>::value; -} - -// specialization for variant -template <class... Ts> -bool inclusive(const variant<Ts...>& axis) noexcept { - return axis.inclusive(); -} - -/** Returns true if axis is ordered or false. - - See is_ordered for details. - - @param axis any axis instance -*/ -template <class Axis> -constexpr bool ordered(const Axis& axis) noexcept { - boost::ignore_unused(axis); - return is_ordered<Axis>::value; -} - -// specialization for variant -template <class... Ts> -bool ordered(const variant<Ts...>& axis) noexcept { - return axis.ordered(); -} - -/** Returns axis size plus any extra bins for under- and overflow. - - @param axis any axis instance -*/ -template <class Axis> -index_type extent(const Axis& axis) noexcept { - const auto opt = options(axis); - return axis.size() + (opt & option::underflow ? 1 : 0) + - (opt & option::overflow ? 1 : 0); -} - -/** Returns reference to metadata of an axis. - - If the expression x.metadata() for an axis instance `x` (maybe const) is valid, return - the result. Otherwise, return a reference to a static instance of - boost::histogram::axis::null_type. - - @param axis any axis instance -*/ -template <class Axis> -decltype(auto) metadata(Axis&& axis) noexcept { - return detail::static_if<detail::has_method_metadata<std::decay_t<Axis>>>( - [](auto&& a) -> decltype(auto) { return a.metadata(); }, - [](auto &&) -> mp11::mp_if<std::is_const<std::remove_reference_t<Axis>>, - axis::null_type const&, axis::null_type&> { - return detail::null_value; - }, - std::forward<Axis>(axis)); -} - -/** Returns axis value for index. - - If the axis has no `value` method, throw std::runtime_error. If the method exists and - accepts a floating point index, pass the index and return the result. If the method - exists but accepts only integer indices, cast the floating point index to int, pass this - index and return the result. - - @param axis any axis instance - @param index floating point axis index -*/ -template <class Axis> -decltype(auto) value(const Axis& axis, real_index_type index) { - return detail::value_method_switch( - [index](const auto& a) { return a.value(static_cast<index_type>(index)); }, - [index](const auto& a) { return a.value(index); }, axis, detail::priority<1>{}); -} - -/** Returns axis value for index if it is convertible to target type or throws. - - Like boost::histogram::axis::traits::value, but converts the result into the requested - return type. If the conversion is not possible, throws std::runtime_error. - - @tparam Result requested return type - @tparam Axis axis type - @param axis any axis instance - @param index floating point axis index -*/ -template <class Result, class Axis> -Result value_as(const Axis& axis, real_index_type index) { - return detail::try_cast<Result, std::runtime_error>( - value(axis, index)); // avoid conversion warning -} - -/** Returns axis index for value. - - Throws std::invalid_argument if the value argument is not implicitly convertible. - - @param axis any axis instance - @param value argument to be passed to `index` method -*/ -template <class Axis, class U> -axis::index_type index(const Axis& axis, const U& value) noexcept( - std::is_convertible<U, value_type<Axis>>::value) { - return axis.index(detail::try_cast<value_type<Axis>, std::invalid_argument>(value)); -} - -// specialization for variant -template <class... Ts, class U> -axis::index_type index(const variant<Ts...>& axis, const U& value) { - return axis.index(value); -} - -/** Return axis rank (how many arguments it processes). - - @param axis any axis instance -*/ -template <class Axis> -constexpr unsigned rank(const Axis& axis) { - boost::ignore_unused(axis); - using T = value_type<Axis>; - // cannot use mp_eval_or since T could be a fixed-sized sequence - return mp11::mp_eval_if_not<detail::is_tuple<T>, mp11::mp_size_t<1>, mp11::mp_size, - T>::value; -} - -// specialization for variant -template <class... Ts> -unsigned rank(const axis::variant<Ts...>& axis) { - return detail::variant_access::visit([](const auto& a) { return rank(a); }, axis); -} - -/** Returns pair of axis index and shift for the value argument. - - Throws `std::invalid_argument` if the value argument is not implicitly convertible to - the argument expected by the `index` method. If the result of - boost::histogram::axis::traits::get_options<decltype(axis)> has the growth flag set, - call `update` method with the argument and return the result. Otherwise, call `index` - and return the pair of the result and a zero shift. - - @param axis any axis instance - @param value argument to be passed to `update` or `index` method -*/ -template <class Axis, class U> -std::pair<index_type, index_type> update(Axis& axis, const U& value) noexcept( - std::is_convertible<U, value_type<Axis>>::value) { - return detail::static_if_c<get_options<Axis>::test(option::growth)>( - [&value](auto& a) { - return a.update(detail::try_cast<value_type<Axis>, std::invalid_argument>(value)); - }, - [&value](auto& a) -> std::pair<index_type, index_type> { - return {index(a, value), 0}; - }, - axis); -} - -// specialization for variant -template <class... Ts, class U> -std::pair<index_type, index_type> update(variant<Ts...>& axis, const U& value) { - return visit([&value](auto& a) { return a.update(value); }, axis); -} - -/** Returns bin width at axis index. - - If the axis has no `value` method, throw std::runtime_error. If the method exists and - accepts a floating point index, return the result of `axis.value(index + 1) - - axis.value(index)`. If the method exists but accepts only integer indices, return 0. - - @param axis any axis instance - @param index bin index - */ -template <class Axis> -decltype(auto) width(const Axis& axis, index_type index) { - return detail::value_method_switch( - [](const auto&) { return 0; }, - [index](const auto& a) { return a.value(index + 1) - a.value(index); }, axis, - detail::priority<1>{}); -} - -/** Returns bin width at axis index. - - Like boost::histogram::axis::traits::width, but converts the result into the requested - return type. If the conversion is not possible, throw std::runtime_error. - - @param axis any axis instance - @param index bin index - */ -template <class Result, class Axis> -Result width_as(const Axis& axis, index_type index) { - return detail::value_method_switch( - [](const auto&) { return Result{}; }, - [index](const auto& a) { - return detail::try_cast<Result, std::runtime_error>(a.value(index + 1) - - a.value(index)); - }, - axis, detail::priority<1>{}); -} - -} // namespace traits -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/variable.hpp b/ThirdParty/boost/histogram/axis/variable.hpp deleted file mode 100644 index 43772d753c5d2eaddc7f436857d930930e3b9657..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/variable.hpp +++ /dev/null @@ -1,248 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_VARIABLE_HPP -#define BOOST_HISTOGRAM_AXIS_VARIABLE_HPP - -#include <algorithm> -#include <boost/assert.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/interval_view.hpp> -#include <boost/histogram/axis/iterator.hpp> -#include <boost/histogram/axis/metadata_base.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/detail/convert_integer.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/limits.hpp> -#include <boost/histogram/detail/replace_type.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/throw_exception.hpp> -#include <cmath> -#include <limits> -#include <memory> -#include <stdexcept> -#include <string> -#include <type_traits> -#include <utility> -#include <vector> - -namespace boost { -namespace histogram { -namespace axis { - -/** - Axis for non-equidistant bins on the real line. - - Binning is a O(log(N)) operation. If speed matters and the problem domain - allows it, prefer a regular axis, possibly with a transform. - - @tparam Value input value type, must be floating point. - @tparam MetaData type to store meta data. - @tparam Options see boost::histogram::axis::option (all values allowed). - @tparam Allocator allocator to use for dynamic memory management. - */ -template <class Value, class MetaData, class Options, class Allocator> -class variable : public iterator_mixin<variable<Value, MetaData, Options, Allocator>>, - public metadata_base<MetaData> { - // these must be private, so that they are not automatically inherited - using value_type = Value; - using metadata_type = typename metadata_base<MetaData>::metadata_type; - using options_type = - detail::replace_default<Options, decltype(option::underflow | option::overflow)>; - using allocator_type = Allocator; - using vector_type = std::vector<Value, allocator_type>; - - static_assert( - std::is_floating_point<value_type>::value, - "current version of variable axis requires floating point type; " - "if you need a variable axis with an integral type, please submit an issue"); - - static_assert( - (!options_type::test(option::circular) && !options_type::test(option::growth)) || - (options_type::test(option::circular) ^ options_type::test(option::growth)), - "circular and growth options are mutually exclusive"); - -public: - constexpr variable() = default; - explicit variable(allocator_type alloc) : vec_(alloc) {} - - /** Construct from iterator range of bin edges. - * - * \param begin begin of edge sequence. - * \param end end of edge sequence. - * \param meta description of the axis. - * \param alloc allocator instance to use. - */ - template <class It, class = detail::requires_iterator<It>> - variable(It begin, It end, metadata_type meta = {}, allocator_type alloc = {}) - : metadata_base<MetaData>(std::move(meta)), vec_(std::move(alloc)) { - if (std::distance(begin, end) < 2) - BOOST_THROW_EXCEPTION(std::invalid_argument("bins > 0 required")); - - vec_.reserve(std::distance(begin, end)); - vec_.emplace_back(*begin++); - bool strictly_ascending = true; - while (begin != end) { - if (*begin <= vec_.back()) strictly_ascending = false; - vec_.emplace_back(*begin++); - } - if (!strictly_ascending) - BOOST_THROW_EXCEPTION( - std::invalid_argument("input sequence must be strictly ascending")); - } - - /** Construct variable axis from iterable range of bin edges. - * - * \param iterable iterable range of bin edges. - * \param meta description of the axis. - * \param alloc allocator instance to use. - */ - template <class U, class = detail::requires_iterable<U>> - variable(const U& iterable, metadata_type meta = {}, allocator_type alloc = {}) - : variable(std::begin(iterable), std::end(iterable), std::move(meta), - std::move(alloc)) {} - - /** Construct variable axis from initializer list of bin edges. - * - * @param list `std::initializer_list` of bin edges. - * @param meta description of the axis. - * @param alloc allocator instance to use. - */ - template <class U> - variable(std::initializer_list<U> list, metadata_type meta = {}, - allocator_type alloc = {}) - : variable(list.begin(), list.end(), std::move(meta), std::move(alloc)) {} - - /// Constructor used by algorithm::reduce to shrink and rebin (not for users). - variable(const variable& src, index_type begin, index_type end, unsigned merge) - : metadata_base<MetaData>(src), vec_(src.get_allocator()) { - BOOST_ASSERT((end - begin) % merge == 0); - if (options_type::test(option::circular) && !(begin == 0 && end == src.size())) - BOOST_THROW_EXCEPTION(std::invalid_argument("cannot shrink circular axis")); - vec_.reserve((end - begin) / merge); - const auto beg = src.vec_.begin(); - for (index_type i = begin; i <= end; i += merge) vec_.emplace_back(*(beg + i)); - } - - /// Return index for value argument. - index_type index(value_type x) const noexcept { - if (options_type::test(option::circular)) { - const auto a = vec_[0]; - const auto b = vec_[size()]; - x -= std::floor((x - a) / (b - a)) * (b - a); - } - return static_cast<index_type>(std::upper_bound(vec_.begin(), vec_.end(), x) - - vec_.begin() - 1); - } - - std::pair<index_type, index_type> update(value_type x) noexcept { - const auto i = index(x); - if (std::isfinite(x)) { - if (0 <= i) { - if (i < size()) return std::make_pair(i, 0); - const auto d = value(size()) - value(size() - 0.5); - x = std::nextafter(x, (std::numeric_limits<value_type>::max)()); - x = (std::max)(x, vec_.back() + d); - vec_.push_back(x); - return {i, -1}; - } - const auto d = value(0.5) - value(0); - x = (std::min)(x, value(0) - d); - vec_.insert(vec_.begin(), x); - return {0, -i}; - } - return {x < 0 ? -1 : size(), 0}; - } - - /// Return value for fractional index argument. - value_type value(real_index_type i) const noexcept { - if (options_type::test(option::circular)) { - auto shift = std::floor(i / size()); - i -= shift * size(); - double z; - const auto k = static_cast<index_type>(std::modf(i, &z)); - const auto a = vec_[0]; - const auto b = vec_[size()]; - return (1.0 - z) * vec_[k] + z * vec_[k + 1] + shift * (b - a); - } - if (i < 0) return detail::lowest<value_type>(); - if (i == size()) return vec_.back(); - if (i > size()) return detail::highest<value_type>(); - const auto k = static_cast<index_type>(i); // precond: i >= 0 - const real_index_type z = i - k; - return (1.0 - z) * vec_[k] + z * vec_[k + 1]; - } - - /// Return bin for index argument. - auto bin(index_type idx) const noexcept { return interval_view<variable>(*this, idx); } - - /// Returns the number of bins, without over- or underflow. - index_type size() const noexcept { return static_cast<index_type>(vec_.size()) - 1; } - - /// Returns the options. - static constexpr unsigned options() noexcept { return options_type::value; } - - template <class V, class M, class O, class A> - bool operator==(const variable<V, M, O, A>& o) const noexcept { - const auto& a = vec_; - const auto& b = o.vec_; - return std::equal(a.begin(), a.end(), b.begin(), b.end()) && - metadata_base<MetaData>::operator==(o); - } - - template <class V, class M, class O, class A> - bool operator!=(const variable<V, M, O, A>& o) const noexcept { - return !operator==(o); - } - - /// Return allocator instance. - auto get_allocator() const { return vec_.get_allocator(); } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("seq", vec_); - ar& make_nvp("meta", this->metadata()); - } - -private: - vector_type vec_; - - template <class V, class M, class O, class A> - friend class variable; -}; - -#if __cpp_deduction_guides >= 201606 - -template <class T> -variable(std::initializer_list<T>) - ->variable<detail::convert_integer<T, double>, null_type>; - -template <class T, class M> -variable(std::initializer_list<T>, M) - ->variable<detail::convert_integer<T, double>, - detail::replace_type<std::decay_t<M>, const char*, std::string>>; - -template <class Iterable, class = detail::requires_iterable<Iterable>> -variable(Iterable) - ->variable< - detail::convert_integer< - std::decay_t<decltype(*std::begin(std::declval<Iterable&>()))>, double>, - null_type>; - -template <class Iterable, class M> -variable(Iterable, M) - ->variable< - detail::convert_integer< - std::decay_t<decltype(*std::begin(std::declval<Iterable&>()))>, double>, - detail::replace_type<std::decay_t<M>, const char*, std::string>>; - -#endif - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/axis/variant.hpp b/ThirdParty/boost/histogram/axis/variant.hpp deleted file mode 100644 index 35d7f5b61d6a4d5467885c89fd8a96189d1c832a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/axis/variant.hpp +++ /dev/null @@ -1,325 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_AXIS_VARIANT_HPP -#define BOOST_HISTOGRAM_AXIS_VARIANT_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/iterator.hpp> -#include <boost/histogram/axis/polymorphic_bin.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/detail/relaxed_equal.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/detail/type_name.hpp> -#include <boost/variant2/variant.hpp> -#include <boost/histogram/detail/variant_proxy.hpp> -#include <boost/mp11/algorithm.hpp> // mp_contains -#include <boost/mp11/list.hpp> // mp_first -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace axis { - -/// Polymorphic axis type -template <class... Ts> -class variant : public iterator_mixin<variant<Ts...>> { - using impl_type = boost::variant2::variant<Ts...>; - - template <class T> - using is_bounded_type = mp11::mp_contains<variant, std::decay_t<T>>; - - template <class T> - using requires_bounded_type = std::enable_if_t<is_bounded_type<T>::value>; - - // maybe metadata_type or const metadata_type, if bounded type is const - using metadata_type = std::remove_reference_t<decltype( - traits::metadata(std::declval<std::remove_pointer_t<mp11::mp_first<variant>>>()))>; - -public: - // cannot import ctors with using directive, it breaks gcc and msvc - variant() = default; - variant(const variant&) = default; - variant& operator=(const variant&) = default; - variant(variant&&) = default; - variant& operator=(variant&&) = default; - - template <class T, class = requires_bounded_type<T>> - variant(T&& t) : impl(std::forward<T>(t)) {} - - template <class T, class = requires_bounded_type<T>> - variant& operator=(T&& t) { - impl = std::forward<T>(t); - return *this; - } - - template <class... Us> - variant(const variant<Us...>& u) { - this->operator=(u); - } - - template <class... Us> - variant& operator=(const variant<Us...>& u) { - visit( - [this](const auto& u) { - using U = std::decay_t<decltype(u)>; - detail::static_if<is_bounded_type<U>>( - [this](const auto& u) { this->operator=(u); }, - [](const auto&) { - BOOST_THROW_EXCEPTION(std::runtime_error( - detail::type_name<U>() + " is not convertible to a bounded type of " + - detail::type_name<variant>())); - }, - u); - }, - u); - return *this; - } - - /// Return size of axis. - index_type size() const { - return visit([](const auto& a) -> index_type { return a.size(); }, *this); - } - - /// Return options of axis or option::none_t if axis has no options. - unsigned options() const { - return visit([](const auto& a) { return traits::options(a); }, *this); - } - - /// Returns true if the axis is inclusive or false. - bool inclusive() const { - return visit([](const auto& a) { return traits::inclusive(a); }, *this); - } - - /// Returns true if the axis is ordered or false. - bool ordered() const { - return visit([](const auto& a) { return traits::ordered(a); }, *this); - } - - /// Return reference to const metadata or instance of null_type if axis has no - /// metadata. - const metadata_type& metadata() const { - return visit( - [](const auto& a) -> const metadata_type& { - using M = decltype(traits::metadata(a)); - return detail::static_if<std::is_same<M, const metadata_type&>>( - [](const auto& a) -> const metadata_type& { return traits::metadata(a); }, - [](const auto&) -> const metadata_type& { - BOOST_THROW_EXCEPTION(std::runtime_error( - "cannot return metadata of type " + detail::type_name<M>() + - " through axis::variant interface which uses type " + - detail::type_name<metadata_type>() + - "; use boost::histogram::axis::get to obtain a reference " - "of this axis type")); - }, - a); - }, - *this); - } - - /// Return reference to metadata or instance of null_type if axis has no - /// metadata. - metadata_type& metadata() { - return visit( - [](auto& a) -> metadata_type& { - using M = decltype(traits::metadata(a)); - return detail::static_if<std::is_same<M, metadata_type&>>( - [](auto& a) -> metadata_type& { return traits::metadata(a); }, - [](auto&) -> metadata_type& { - BOOST_THROW_EXCEPTION(std::runtime_error( - "cannot return metadata of type " + detail::type_name<M>() + - " through axis::variant interface which uses type " + - detail::type_name<metadata_type>() + - "; use boost::histogram::axis::get to obtain a reference " - "of this axis type")); - }, - a); - }, - *this); - } - - /** Return index for value argument. - - Throws std::invalid_argument if axis has incompatible call signature. - */ - template <class U> - index_type index(const U& u) const { - return visit([&u](const auto& a) { return traits::index(a, u); }, *this); - } - - /** Return value for index argument. - - Only works for axes with value method that returns something convertible - to double and will throw a runtime_error otherwise, see - axis::traits::value(). - */ - double value(real_index_type idx) const { - return visit([idx](const auto& a) { return traits::value_as<double>(a, idx); }, - *this); - } - - /** Return bin for index argument. - - Only works for axes with value method that returns something convertible - to double and will throw a runtime_error otherwise, see - axis::traits::value(). - */ - auto bin(index_type idx) const { - return visit( - [idx](const auto& a) { - return detail::value_method_switch( - [idx](const auto& a) { // axis is discrete - const double x = traits::value_as<double>(a, idx); - return polymorphic_bin<double>(x, x); - }, - [idx](const auto& a) { // axis is continuous - const double x1 = traits::value_as<double>(a, idx); - const double x2 = traits::value_as<double>(a, idx + 1); - return polymorphic_bin<double>(x1, x2); - }, - a, detail::priority<1>{}); - }, - *this); - } - - /** Compare two variants. - - Return true if the variants point to the same concrete axis type and the types compare - equal. Otherwise return false. - */ - template <class... Us> - bool operator==(const variant<Us...>& u) const { - return visit([&u](const auto& x) { return u == x; }, *this); - } - - /** Compare variant with a concrete axis type. - - Return true if the variant point to the same concrete axis type and the types compare - equal. Otherwise return false. - */ - template <class T> - bool operator==(const T& t) const { - return detail::static_if_c<(mp11::mp_contains<impl_type, T>::value || - mp11::mp_contains<impl_type, T*>::value || - mp11::mp_contains<impl_type, const T*>::value)>( - [&](const auto& t) { - using U = std::decay_t<decltype(t)>; - const U* tp = detail::variant_access::template get_if<U>(this); - return tp && detail::relaxed_equal(*tp, t); - }, - [&](const auto&) { return false; }, t); - } - - /// The negation of operator==. - template <class T> - bool operator!=(const T& t) const { - return !operator==(t); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - detail::variant_proxy<variant> p{*this}; - ar& make_nvp("variant", p); - } - -private: - impl_type impl; - - friend struct detail::variant_access; - friend struct boost::histogram::unsafe_access; -}; - -// specialization for empty argument list, useful for meta-programming -template <> -class variant<> {}; - -/// Apply visitor to variant (reference). -template <class Visitor, class... Us> -decltype(auto) visit(Visitor&& vis, variant<Us...>& var) { - return detail::variant_access::visit(vis, var); -} - -/// Apply visitor to variant (movable reference). -template <class Visitor, class... Us> -decltype(auto) visit(Visitor&& vis, variant<Us...>&& var) { - return detail::variant_access::visit(vis, std::move(var)); -} - -/// Apply visitor to variant (const reference). -template <class Visitor, class... Us> -decltype(auto) visit(Visitor&& vis, const variant<Us...>& var) { - return detail::variant_access::visit(vis, var); -} - -/// Returns pointer to T in variant or null pointer if type does not match. -template <class T, class... Us> -auto get_if(variant<Us...>* v) { - return detail::variant_access::template get_if<T>(v); -} - -/// Returns pointer to const T in variant or null pointer if type does not match. -template <class T, class... Us> -auto get_if(const variant<Us...>* v) { - return detail::variant_access::template get_if<T>(v); -} - -/// Return reference to T, throws std::runtime_error if type does not match. -template <class T, class... Us> -decltype(auto) get(variant<Us...>& v) { - auto tp = get_if<T>(&v); - if (!tp) BOOST_THROW_EXCEPTION(std::runtime_error("T is not the held type")); - return *tp; -} - -/// Return movable reference to T, throws unspecified exception if type does not match. -template <class T, class... Us> -decltype(auto) get(variant<Us...>&& v) { - auto tp = get_if<T>(&v); - if (!tp) BOOST_THROW_EXCEPTION(std::runtime_error("T is not the held type")); - return std::move(*tp); -} - -/// Return const reference to T, throws unspecified exception if type does not match. -template <class T, class... Us> -decltype(auto) get(const variant<Us...>& v) { - auto tp = get_if<T>(&v); - if (!tp) BOOST_THROW_EXCEPTION(std::runtime_error("T is not the held type")); - return *tp; -} - -// pass-through version of visit for generic programming -template <class Visitor, class T> -decltype(auto) visit(Visitor&& vis, T&& var) { - return std::forward<Visitor>(vis)(std::forward<T>(var)); -} - -// pass-through version of get for generic programming -template <class T, class U> -decltype(auto) get(U&& u) { - return std::forward<U>(u); -} - -// pass-through version of get_if for generic programming -template <class T, class U> -auto get_if(U* u) { - return reinterpret_cast<T*>(std::is_same<T, std::decay_t<U>>::value ? u : nullptr); -} - -// pass-through version of get_if for generic programming -template <class T, class U> -auto get_if(const U* u) { - return reinterpret_cast<const T*>(std::is_same<T, std::decay_t<U>>::value ? u - : nullptr); -} - -} // namespace axis -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/accumulator_traits.hpp b/ThirdParty/boost/histogram/detail/accumulator_traits.hpp deleted file mode 100644 index ac46021d330151872ef9720f1c3df627b8f7d843..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/accumulator_traits.hpp +++ /dev/null @@ -1,81 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_ACCUMULATOR_TRAITS_HPP -#define BOOST_HISTOGRAM_DETAIL_ACCUMULATOR_TRAITS_HPP - -#include <boost/histogram/detail/priority.hpp> -#include <boost/histogram/fwd.hpp> -#include <tuple> -#include <type_traits> - -namespace boost { - -// forward declare accumulator_set so that it can be matched below -namespace accumulators { -template <class, class, class> -struct accumulator_set; -} - -namespace histogram { -namespace detail { - -template <bool WeightSupport, class... Ts> -struct accumulator_traits_holder { - static constexpr bool weight_support = WeightSupport; - using args = std::tuple<Ts...>; -}; - -// member function pointer with weight_type as first argument is better match -template <class R, class T, class U, class... Ts> -accumulator_traits_holder<true, Ts...> accumulator_traits_impl_call_op( - R (T::*)(boost::histogram::weight_type<U>, Ts...)); - -template <class R, class T, class U, class... Ts> -accumulator_traits_holder<true, Ts...> accumulator_traits_impl_call_op( - R (T::*)(boost::histogram::weight_type<U>&, Ts...)); - -template <class R, class T, class U, class... Ts> -accumulator_traits_holder<true, Ts...> accumulator_traits_impl_call_op( - R (T::*)(boost::histogram::weight_type<U>&&, Ts...)); - -template <class R, class T, class U, class... Ts> -accumulator_traits_holder<true, Ts...> accumulator_traits_impl_call_op( - R (T::*)(const boost::histogram::weight_type<U>&, Ts...)); - -// member function pointer only considered if all specializations above fail -template <class R, class T, class... Ts> -accumulator_traits_holder<false, Ts...> accumulator_traits_impl_call_op(R (T::*)(Ts...)); - -template <class T> -auto accumulator_traits_impl(T&, priority<1>) - -> decltype(accumulator_traits_impl_call_op(&T::operator())); - -template <class T> -auto accumulator_traits_impl(T&, priority<1>) - -> decltype(std::declval<T&>() += 0, accumulator_traits_holder<true>{}); - -template <class T> -auto accumulator_traits_impl(T&, priority<0>) -> accumulator_traits_holder<false>; - -// for boost.accumulators compatibility -template <class S, class F, class W> -accumulator_traits_holder<false, S> accumulator_traits_impl( - boost::accumulators::accumulator_set<S, F, W>&, priority<1>) { - static_assert(std::is_same<W, void>::value, - "accumulator_set with weights is not directly supported, please use " - "a wrapper class that implements the Accumulator concept"); -} - -template <class T> -using accumulator_traits = - decltype(accumulator_traits_impl(std::declval<T&>(), priority<1>{})); - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/args_type.hpp b/ThirdParty/boost/histogram/detail/args_type.hpp deleted file mode 100644 index d57c1dd7980542adc0b79f7210158686fcd94101..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/args_type.hpp +++ /dev/null @@ -1,63 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_ARGS_TYPE_HPP -#define BOOST_HISTOGRAM_DETAIL_ARGS_TYPE_HPP - -#include <tuple> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -struct args_type_impl { - using T::ERROR_this_should_never_be_instantiated_please_write_an_issue; -}; - -template <class R, class T, class... Ts> -struct args_type_impl<R (T::*)(Ts...)> { - using type = std::tuple<Ts...>; -}; - -template <class R, class T, class... Ts> -struct args_type_impl<R (T ::*)(Ts...) const> { - using type = std::tuple<Ts...>; -}; - -template <class R, class... Ts> -struct args_type_impl<R (*)(Ts...)> { - using type = std::tuple<Ts...>; -}; - -#if __cpp_noexcept_function_type >= 201510 -template <class R, class T, class... Ts> -struct args_type_impl<R (T::*)(Ts...) noexcept> { - using type = std::tuple<Ts...>; -}; - -template <class R, class T, class... Ts> -struct args_type_impl<R (T ::*)(Ts...) const noexcept> { - using type = std::tuple<Ts...>; -}; - -template <class R, class... Ts> -struct args_type_impl<R (*)(Ts...) noexcept> { - using type = std::tuple<Ts...>; -}; -#endif - -template <class FunctionPointer> -using args_type = typename args_type_impl<FunctionPointer>::type; - -template <class T, std::size_t N = 0> -using arg_type = std::tuple_element_t<N, args_type<T>>; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/argument_traits.hpp b/ThirdParty/boost/histogram/detail/argument_traits.hpp deleted file mode 100644 index b32653c63466902766ba4702462e13717c0c3719..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/argument_traits.hpp +++ /dev/null @@ -1,83 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_ARGUMENT_TRAITS_HPP -#define BOOST_HISTOGRAM_DETAIL_ARGUMENT_TRAITS_HPP - -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/integral.hpp> -#include <boost/mp11/list.hpp> -#include <tuple> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -struct is_weight_impl : mp11::mp_false {}; - -template <class T> -struct is_weight_impl<weight_type<T>> : mp11::mp_true {}; - -template <class T> -using is_weight = is_weight_impl<T>; - -template <class T> -struct is_sample_impl : mp11::mp_false {}; - -template <class T> -struct is_sample_impl<sample_type<T>> : mp11::mp_true {}; - -template <class T> -using is_sample = is_sample_impl<T>; - -template <int Idx, class L> -struct sample_args_impl { - using type = mp11::mp_first<std::decay_t<mp11::mp_at_c<L, (Idx >= 0 ? Idx : 0)>>>; -}; - -template <class L> -struct sample_args_impl<-1, L> { - using type = std::tuple<>; -}; - -template <std::size_t NArgs, std::size_t Start, int WeightPos, int SamplePos, - class SampleArgs> -struct argument_traits_holder { - using nargs = mp11::mp_size_t<NArgs>; - using start = mp11::mp_size_t<Start>; - using wpos = mp11::mp_int<WeightPos>; - using spos = mp11::mp_int<SamplePos>; - using sargs = SampleArgs; -}; - -template <class... Ts> -struct argument_traits_impl { - using list_ = mp11::mp_list<Ts...>; - static constexpr std::size_t size_ = sizeof...(Ts); - static constexpr std::size_t weight_ = mp11::mp_find_if<list_, is_weight>::value; - static constexpr std::size_t sample_ = mp11::mp_find_if<list_, is_sample>::value; - static constexpr int spos_ = (sample_ < size_ ? static_cast<int>(sample_) : -1); - static constexpr int wpos_ = (weight_ < size_ ? static_cast<int>(weight_) : -1); - - using type = - argument_traits_holder<(size_ - (weight_ < size_) - (sample_ < size_)), - (weight_ < size_ && sample_ < size_ && - (weight_ + sample_ < 2) - ? 2 - : ((weight_ == 0 || sample_ == 0) ? 1 : 0)), - wpos_, spos_, typename sample_args_impl<spos_, list_>::type>; -}; - -template <class... Ts> -using argument_traits = typename argument_traits_impl<Ts...>::type; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/array_wrapper.hpp b/ThirdParty/boost/histogram/detail/array_wrapper.hpp deleted file mode 100644 index 752a73032768e39c8e5711b259821b3f0a97ba89..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/array_wrapper.hpp +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_ARRAY_WRAPPER_HPP -#define BOOST_HISTOGRAM_DETAIL_ARRAY_WRAPPER_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/detail/span.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/mp11/function.hpp> -#include <boost/mp11/utility.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class = decltype(&T::template save_array<int>)> -struct has_save_array_impl; - -template <class T, class = decltype(&T::template load_array<int>)> -struct has_load_array_impl; - -template <class T> -using has_array_optimization = mp11::mp_or<mp11::mp_valid<has_save_array_impl, T>, - mp11::mp_valid<has_load_array_impl, T>>; - -template <class T> -struct array_wrapper { - using pointer = T*; - - pointer ptr; - std::size_t size; - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - static_if_c<(has_array_optimization<Archive>::value && - std::is_trivially_copyable<T>::value)>( - [this](auto& ar) { - // cannot use and therefore bypass save_array / load_array interface, because - // it requires exact type boost::serialization::array_wrapper<T> - static_if_c<Archive::is_loading::value>( - [this](auto& ar) { ar.load_binary(this->ptr, sizeof(T) * this->size); }, - [this](auto& ar) { ar.save_binary(this->ptr, sizeof(T) * this->size); }, - ar); - }, - [this](auto& ar) { - for (auto&& x : boost::histogram::detail::make_span(this->ptr, this->size)) - ar& make_nvp("item", x); - }, - ar); - } -}; - -template <class T> -auto make_array_wrapper(T* t, std::size_t s) { - return array_wrapper<T>{t, s}; -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/at.hpp b/ThirdParty/boost/histogram/detail/at.hpp deleted file mode 100644 index 0a01c4c7293c69a67b4a3bf584bd3255e7bfb5cb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/at.hpp +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_AT_HPP -#define BOOST_HISTOGRAM_DETAIL_AT_HPP - -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/linearize.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <tuple> - -namespace boost { -namespace histogram { -namespace detail { - -template <class A, class... Us> -optional_index at(const A& axes, const std::tuple<Us...>& args) noexcept { - optional_index idx{0}; // offset not used by linearize_index - mp11::mp_for_each<mp11::mp_iota_c<sizeof...(Us)>>( - [&, stride = static_cast<std::size_t>(1)](auto i) mutable { - stride *= linearize_index(idx, stride, axis_get<i>(axes), - static_cast<axis::index_type>(std::get<i>(args))); - }); - return idx; -} - -template <class A, class U> -optional_index at(const A& axes, const U& args) noexcept { - optional_index idx{0}; - using std::begin; - for_each_axis(axes, [&, it = begin(args), - stride = static_cast<std::size_t>(1)](const auto& a) mutable { - stride *= linearize_index(idx, stride, a, static_cast<axis::index_type>(*it++)); - }); - return idx; -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/axes.hpp b/ThirdParty/boost/histogram/detail/axes.hpp deleted file mode 100644 index 400303b2ac39cb41a2df372f4c5888756dda1db5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/axes.hpp +++ /dev/null @@ -1,385 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_AXES_HPP -#define BOOST_HISTOGRAM_DETAIL_AXES_HPP - -#include <array> -#include <boost/assert.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/axis/variant.hpp> -#include <boost/histogram/detail/make_default.hpp> -#include <boost/histogram/detail/optional_index.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/tuple.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <string> -#include <tuple> -#include <type_traits> - -/* Most of the histogram code is generic and works for any number of axes. Buffers with a - * fixed maximum capacity are used in some places, which have a size equal to the rank of - * a histogram. The buffers are statically allocated to improve performance, which means - * that they need a preset maximum capacity. 32 seems like a safe upper limit for the rank - * (you can nevertheless increase it here if necessary): the simplest non-trivial axis has - * 2 bins; even if counters are used which need only a byte of storage per bin, this still - * corresponds to 4 GB of storage. - */ -#ifndef BOOST_HISTOGRAM_DETAIL_AXES_LIMIT -#define BOOST_HISTOGRAM_DETAIL_AXES_LIMIT 32 -#endif - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -unsigned axes_rank(const T& axes) { - using std::begin; - using std::end; - return static_cast<unsigned>(std::distance(begin(axes), end(axes))); -} - -template <class... Ts> -constexpr unsigned axes_rank(const std::tuple<Ts...>&) { - return static_cast<unsigned>(sizeof...(Ts)); -} - -template <class T> -void throw_if_axes_is_too_large(const T& axes) { - if (axes_rank(axes) > BOOST_HISTOGRAM_DETAIL_AXES_LIMIT) - BOOST_THROW_EXCEPTION( - std::invalid_argument("length of axis vector exceeds internal buffers, " - "recompile with " - "-DBOOST_HISTOGRAM_DETAIL_AXES_LIMIT=<new max size> " - "to increase internal buffers")); -} - -// tuple is never too large because internal buffers adapt to size of tuple -template <class... Ts> -void throw_if_axes_is_too_large(const std::tuple<Ts...>&) {} - -template <unsigned N, class... Ts> -decltype(auto) axis_get(std::tuple<Ts...>& axes) { - return std::get<N>(axes); -} - -template <unsigned N, class... Ts> -decltype(auto) axis_get(const std::tuple<Ts...>& axes) { - return std::get<N>(axes); -} - -template <unsigned N, class T> -decltype(auto) axis_get(T& axes) { - return axes[N]; -} - -template <unsigned N, class T> -decltype(auto) axis_get(const T& axes) { - return axes[N]; -} - -template <class... Ts> -auto axis_get(std::tuple<Ts...>& axes, const unsigned i) { - constexpr auto S = sizeof...(Ts); - using V = mp11::mp_unique<axis::variant<Ts*...>>; - return mp11::mp_with_index<S>(i, [&axes](auto i) { return V(&std::get<i>(axes)); }); -} - -template <class... Ts> -auto axis_get(const std::tuple<Ts...>& axes, const unsigned i) { - constexpr auto S = sizeof...(Ts); - using V = mp11::mp_unique<axis::variant<const Ts*...>>; - return mp11::mp_with_index<S>(i, [&axes](auto i) { return V(&std::get<i>(axes)); }); -} - -template <class T> -decltype(auto) axis_get(T& axes, const unsigned i) { - return axes[i]; -} - -template <class T> -decltype(auto) axis_get(const T& axes, const unsigned i) { - return axes[i]; -} - -template <class... Ts, class... Us> -bool axes_equal(const std::tuple<Ts...>& ts, const std::tuple<Us...>& us) { - using namespace ::boost::mp11; - return static_if<std::is_same<mp_list<Ts...>, mp_list<Us...>>>( - [](const auto& ts, const auto& us) { - using N = mp_size<std::decay_t<decltype(ts)>>; - bool equal = true; - mp_for_each<mp_iota<N>>( - [&](auto I) { equal &= relaxed_equal(std::get<I>(ts), std::get<I>(us)); }); - return equal; - }, - [](const auto&, const auto&) { return false; }, ts, us); -} - -template <class T, class... Us> -bool axes_equal(const T& t, const std::tuple<Us...>& u) { - using namespace ::boost::mp11; - if (t.size() != sizeof...(Us)) return false; - bool equal = true; - mp_for_each<mp_iota_c<sizeof...(Us)>>([&](auto I) { equal &= t[I] == std::get<I>(u); }); - return equal; -} - -template <class... Ts, class U> -bool axes_equal(const std::tuple<Ts...>& t, const U& u) { - return axes_equal(u, t); -} - -template <class T, class U> -bool axes_equal(const T& t, const U& u) { - if (t.size() != u.size()) return false; - return std::equal(t.begin(), t.end(), u.begin()); -} - -template <class... Ts, class... Us> -void axes_assign(std::tuple<Ts...>& t, const std::tuple<Us...>& u) { - using namespace ::boost::mp11; - static_if<std::is_same<mp_list<Ts...>, mp_list<Us...>>>( - [](auto& a, const auto& b) { a = b; }, - [](auto&, const auto&) { - BOOST_THROW_EXCEPTION( - std::invalid_argument("cannot assign axes, types do not match")); - }, - t, u); -} - -template <class... Ts, class U> -void axes_assign(std::tuple<Ts...>& t, const U& u) { - using namespace ::boost::mp11; - mp_for_each<mp_iota_c<sizeof...(Ts)>>([&](auto I) { - using T = mp_at_c<std::tuple<Ts...>, I>; - std::get<I>(t) = axis::get<T>(u[I]); - }); -} - -template <class T, class... Us> -void axes_assign(T& t, const std::tuple<Us...>& u) { - // resize instead of reserve, because t may not be empty and we want exact capacity - t.resize(sizeof...(Us)); - using namespace ::boost::mp11; - mp_for_each<mp_iota_c<sizeof...(Us)>>([&](auto I) { t[I] = std::get<I>(u); }); -} - -template <class T, class U> -void axes_assign(T& t, const U& u) { - t.assign(u.begin(), u.end()); -} - -template <class Archive, class T> -void axes_serialize(Archive& ar, T& axes) { - ar& make_nvp("axes", axes); -} - -template <class Archive, class... Ts> -void axes_serialize(Archive& ar, std::tuple<Ts...>& axes) { - // needed to keep serialization format backward compatible - struct proxy { - std::tuple<Ts...>& t; - void serialize(Archive& ar, unsigned /* version */) { - mp11::tuple_for_each(t, [&ar](auto& x) { ar& make_nvp("item", x); }); - } - }; - proxy p{axes}; - ar& make_nvp("axes", p); -} - -// create empty dynamic axis which can store any axes types from the argument -template <class T> -auto make_empty_dynamic_axes(const T& axes) { - return make_default(axes); -} - -template <class... Ts> -auto make_empty_dynamic_axes(const std::tuple<Ts...>&) { - using namespace ::boost::mp11; - using L = mp_unique<axis::variant<Ts...>>; - // return std::vector<axis::variant<Axis0, Axis1, ...>> or std::vector<Axis0> - return std::vector<mp_if_c<(mp_size<L>::value == 1), mp_first<L>, L>>{}; -} - -template <class T> -void axis_index_is_valid(const T& axes, const unsigned N) { - BOOST_ASSERT_MSG(N < axes_rank(axes), "index out of range"); -} - -template <class Axes, class V> -void for_each_axis_impl(std::true_type, Axes&& axes, V&& v) { - for (auto&& a : axes) { axis::visit(std::forward<V>(v), a); } -} - -template <class Axes, class V> -void for_each_axis_impl(std::false_type, Axes&& axes, V&& v) { - for (auto&& a : axes) std::forward<V>(v)(a); -} - -template <class Axes, class V> -void for_each_axis(Axes&& a, V&& v) { - using namespace ::boost::mp11; - using T = mp_first<std::decay_t<Axes>>; - for_each_axis_impl(is_axis_variant<T>(), std::forward<Axes>(a), std::forward<V>(v)); -} - -template <class V, class... Axis> -void for_each_axis(const std::tuple<Axis...>& a, V&& v) { - mp11::tuple_for_each(a, std::forward<V>(v)); -} - -template <class V, class... Axis> -void for_each_axis(std::tuple<Axis...>& a, V&& v) { - mp11::tuple_for_each(a, std::forward<V>(v)); -} - -// total number of bins including *flow bins -template <class T> -std::size_t bincount(const T& axes) { - std::size_t n = 1; - for_each_axis(axes, [&n](const auto& a) { - const auto old = n; - const auto s = axis::traits::extent(a); - n *= s; - if (s > 0 && n < old) BOOST_THROW_EXCEPTION(std::overflow_error("bincount overflow")); - }); - return n; -} - -// initial offset for the linear index -template <class T> -std::size_t offset(const T& axes) { - std::size_t n = 0; - for_each_axis(axes, [&n, stride = static_cast<std::size_t>(1)](const auto& a) mutable { - if (axis::traits::options(a) & axis::option::growth) - n = invalid_index; - else if (n != invalid_index && axis::traits::options(a) & axis::option::underflow) - n += stride; - stride *= axis::traits::extent(a); - }); - return n; -} - -template <class T> -using buffer_size_impl = typename std::tuple_size<T>::type; - -template <class T> -using buffer_size = mp11::mp_eval_or< - std::integral_constant<std::size_t, BOOST_HISTOGRAM_DETAIL_AXES_LIMIT>, - buffer_size_impl, T>; - -template <class T, std::size_t N> -class sub_array : public std::array<T, N> { - using base_type = std::array<T, N>; - -public: - explicit sub_array(std::size_t s) noexcept( - std::is_nothrow_default_constructible<T>::value) - : size_(s) { - BOOST_ASSERT_MSG(size_ <= N, "requested size exceeds size of static buffer"); - } - - sub_array(std::size_t s, - const T& value) noexcept(std::is_nothrow_copy_constructible<T>::value) - : size_(s) { - BOOST_ASSERT_MSG(size_ <= N, "requested size exceeds size of static buffer"); - std::array<T, N>::fill(value); - } - - // need to override both versions of std::array - auto end() noexcept { return base_type::begin() + size_; } - auto end() const noexcept { return base_type::begin() + size_; } - - auto size() const noexcept { return size_; } - -private: - std::size_t size_; -}; - -template <class U, class T> -using stack_buffer = sub_array<U, buffer_size<T>::value>; - -// make default-constructed buffer (no initialization for POD types) -template <class U, class T> -auto make_stack_buffer(const T& t) { - return stack_buffer<U, T>(axes_rank(t)); -} - -// make buffer with elements initialized to v -template <class U, class T, class V> -auto make_stack_buffer(const T& t, V&& v) { - return stack_buffer<U, T>(axes_rank(t), std::forward<V>(v)); -} - -template <class T> -using has_underflow = - decltype(axis::traits::get_options<T>::test(axis::option::underflow)); - -template <class T> -using is_growing = decltype(axis::traits::get_options<T>::test(axis::option::growth)); - -template <class T> -using is_not_inclusive = mp11::mp_not<axis::traits::is_inclusive<T>>; - -// for vector<T> -template <class T> -struct axis_types_impl { - using type = mp11::mp_list<std::decay_t<T>>; -}; - -// for vector<variant<Ts...>> -template <class... Ts> -struct axis_types_impl<axis::variant<Ts...>> { - using type = mp11::mp_list<std::decay_t<Ts>...>; -}; - -// for tuple<Ts...> -template <class... Ts> -struct axis_types_impl<std::tuple<Ts...>> { - using type = mp11::mp_list<std::decay_t<Ts>...>; -}; - -template <class T> -using axis_types = - typename axis_types_impl<mp11::mp_if<is_vector_like<T>, mp11::mp_first<T>, T>>::type; - -template <template <class> class Trait, class Axes> -using has_special_axis = mp11::mp_any_of<axis_types<Axes>, Trait>; - -template <class Axes> -using has_growing_axis = mp11::mp_any_of<axis_types<Axes>, is_growing>; - -template <class Axes> -using has_non_inclusive_axis = mp11::mp_any_of<axis_types<Axes>, is_not_inclusive>; - -template <class T> -constexpr std::size_t type_score() { - return sizeof(T) * - (std::is_integral<T>::value ? 1 : std::is_floating_point<T>::value ? 10 : 100); -} - -// arbitrary ordering of types -template <class T, class U> -using type_less = mp11::mp_bool<(type_score<T>() < type_score<U>())>; - -template <class Axes> -using value_types = mp11::mp_sort< - mp11::mp_unique<mp11::mp_transform<axis::traits::value_type, axis_types<Axes>>>, - type_less>; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/common_type.hpp b/ThirdParty/boost/histogram/detail/common_type.hpp deleted file mode 100644 index 848d10a4523f91b7e060f7d3def6b9e3af52c063..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/common_type.hpp +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_COMMON_TYPE_HPP -#define BOOST_HISTOGRAM_DETAIL_COMMON_TYPE_HPP - -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/utility.hpp> -#include <tuple> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { -// clang-format off -template <class T, class U> -using common_axes = mp11::mp_cond< - is_tuple<T>, T, - is_tuple<U>, U, - is_sequence_of_axis<T>, T, - is_sequence_of_axis<U>, U, - std::true_type, T ->; -// clang-format on - -// Non-PODs rank highest, then floats, than integers; types with more capacity are higher -template <class Storage> -static constexpr std::size_t type_rank() { - using T = typename Storage::value_type; - return !std::is_pod<T>::value * 10000 + std::is_floating_point<T>::value * 100 + - 10 * sizeof(T) + 2 * is_array_like<Storage>::value + - is_vector_like<Storage>::value; - ; -} - -template <class T, class U> -using common_storage = mp11::mp_if_c<(type_rank<T>() >= type_rank<U>()), T, U>; -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/convert_integer.hpp b/ThirdParty/boost/histogram/detail/convert_integer.hpp deleted file mode 100644 index bed52f759920133f64311bb420b28eea4e31b162..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/convert_integer.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// Copyright 2018-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_CONVERT_INTEGER_HPP -#define BOOST_HISTOGRAM_DETAIL_CONVERT_INTEGER_HPP - -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class U> -using convert_integer = - std::conditional_t<std::is_integral<std::decay_t<T>>::value, U, T>; - -} -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/counting_streambuf.hpp b/ThirdParty/boost/histogram/detail/counting_streambuf.hpp deleted file mode 100644 index 10d81439ad72c0350571281755f2d0231dc8a099..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/counting_streambuf.hpp +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_COUNTING_STREAMBUF_HPP -#define BOOST_HISTOGRAM_DETAIL_COUNTING_STREAMBUF_HPP - -#include <streambuf> - -namespace boost { -namespace histogram { -namespace detail { - -// detect how many characters will be printed by formatted output -template <class CharT, class Traits = std::char_traits<CharT>> -struct counting_streambuf : std::basic_streambuf<CharT, Traits> { - using base_t = std::basic_streambuf<CharT, Traits>; - using typename base_t::char_type; - using typename base_t::int_type; - - std::streamsize count = 0; - - std::streamsize xsputn(const char_type* /* s */, std::streamsize n) override { - count += n; - return n; - } - - int_type overflow(int_type ch) override { - ++count; - return ch; - } -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/detect.hpp b/ThirdParty/boost/histogram/detail/detect.hpp deleted file mode 100644 index 74242aa9b981b50f53fbf4112ea60ec12c9b1b99..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/detect.hpp +++ /dev/null @@ -1,221 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_DETECT_HPP -#define BOOST_HISTOGRAM_DETAIL_DETECT_HPP - -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/function.hpp> -#include <boost/mp11/utility.hpp> -#include <iterator> -#include <tuple> -#include <type_traits> - -// forward declaration -namespace boost { -namespace variant2 { -template <class...> -class variant; -} // namespace variant2 -} // namespace boost - -namespace boost { -namespace histogram { -namespace detail { - -#define BOOST_HISTOGRAM_DETAIL_DETECT(name, cond) \ - template <class T> \ - using name##_impl = decltype(cond); \ - template <class T> \ - using name = typename boost::mp11::mp_valid<name##_impl, T>::type - -#define BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(name, cond) \ - template <class T, class U> \ - using name##_impl = decltype(cond); \ - template <class T, class U = T> \ - using name = typename boost::mp11::mp_valid<name##_impl, T, U>::type - -// metadata has overloads, trying to get pmf in this case always fails -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_metadata, (std::declval<T&>().metadata())); - -// resize has overloads, trying to get pmf in this case always fails -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_resize, (std::declval<T&>().resize(0))); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_size, &T::size); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_clear, &T::clear); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_lower, &T::lower); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_value, &T::value); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_update, &T::update); - -// reset has overloads, trying to get pmf in this case always fails -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_reset, (std::declval<T>().reset(0))); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_method_options, &T::options); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_allocator, &T::get_allocator); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_indexable, (std::declval<T&>()[0])); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY( - is_transform, - (std::declval<T&>().inverse(std::declval<T&>().forward(std::declval<U>())))); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_indexable_container, (std::declval<T>()[0], &T::size, - std::begin(std::declval<T>()), - std::end(std::declval<T>()))); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_vector_like, - (std::declval<T>()[0], &T::size, - std::declval<T>().resize(0), std::begin(std::declval<T>()), - std::end(std::declval<T>()))); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_array_like, - (std::declval<T>()[0], &T::size, std::tuple_size<T>::value, - std::begin(std::declval<T>()), - std::end(std::declval<T>()))); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_map_like, (std::declval<typename T::key_type>(), - std::declval<typename T::mapped_type>(), - std::begin(std::declval<T>()), - std::end(std::declval<T>()))); - -// ok: is_axis is false for axis::variant, because T::index is templated -BOOST_HISTOGRAM_DETAIL_DETECT(is_axis, (&T::size, &T::index)); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_iterable, (std::begin(std::declval<T&>()), - std::end(std::declval<T&>()))); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_iterator, - (typename std::iterator_traits<T>::iterator_category())); - -BOOST_HISTOGRAM_DETAIL_DETECT(is_streamable, - (std::declval<std::ostream&>() << std::declval<T&>())); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_operator_preincrement, (++std::declval<T&>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(has_operator_equal, (std::declval<const T&>() == - std::declval<const U>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(has_operator_radd, - (std::declval<T&>() += std::declval<U>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(has_operator_rsub, - (std::declval<T&>() -= std::declval<U>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(has_operator_rmul, - (std::declval<T&>() *= std::declval<U>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY(has_operator_rdiv, - (std::declval<T&>() /= std::declval<U>())); - -BOOST_HISTOGRAM_DETAIL_DETECT_BINARY( - has_method_eq, (std::declval<const T>().operator==(std::declval<const U>()))); - -BOOST_HISTOGRAM_DETAIL_DETECT(has_threading_support, (T::has_threading_support)); - -template <class T> -using is_storage = mp11::mp_and<is_indexable_container<T>, has_method_reset<T>, - has_threading_support<T>>; - -template <class T> -using is_adaptible = - mp11::mp_and<mp11::mp_not<is_storage<T>>, - mp11::mp_or<is_vector_like<T>, is_array_like<T>, is_map_like<T>>>; - -template <class T> -struct is_tuple_impl : mp11::mp_false {}; - -template <class... Ts> -struct is_tuple_impl<std::tuple<Ts...>> : mp11::mp_true {}; - -template <class T> -using is_tuple = typename is_tuple_impl<T>::type; - -template <class T> -struct is_variant_impl : mp11::mp_false {}; - -template <class... Ts> -struct is_variant_impl<boost::variant2::variant<Ts...>> : mp11::mp_true {}; - -template <class T> -using is_variant = typename is_variant_impl<T>::type; - -template <class T> -struct is_axis_variant_impl : mp11::mp_false {}; - -template <class... Ts> -struct is_axis_variant_impl<axis::variant<Ts...>> : mp11::mp_true {}; - -template <class T> -using is_axis_variant = typename is_axis_variant_impl<T>::type; - -template <class T> -using is_any_axis = mp11::mp_or<is_axis<T>, is_axis_variant<T>>; - -template <class T> -using is_sequence_of_axis = mp11::mp_and<is_iterable<T>, is_axis<mp11::mp_first<T>>>; - -template <class T> -using is_sequence_of_axis_variant = - mp11::mp_and<is_iterable<T>, is_axis_variant<mp11::mp_first<T>>>; - -template <class T> -using is_sequence_of_any_axis = - mp11::mp_and<is_iterable<T>, is_any_axis<mp11::mp_first<T>>>; - -// poor-mans concept checks -template <class T, class = std::enable_if_t<is_storage<std::decay_t<T>>::value>> -struct requires_storage {}; - -template <class T, class _ = std::decay_t<T>, - class = std::enable_if_t<(is_storage<_>::value || is_adaptible<_>::value)>> -struct requires_storage_or_adaptible {}; - -template <class T, class = std::enable_if_t<is_iterator<std::decay_t<T>>::value>> -struct requires_iterator {}; - -template <class T, class = std::enable_if_t< - is_iterable<std::remove_cv_t<std::remove_reference_t<T>>>::value>> -struct requires_iterable {}; - -template <class T, class = std::enable_if_t<is_axis<std::decay_t<T>>::value>> -struct requires_axis {}; - -template <class T, class = std::enable_if_t<is_any_axis<std::decay_t<T>>::value>> -struct requires_any_axis {}; - -template <class T, class = std::enable_if_t<is_sequence_of_axis<std::decay_t<T>>::value>> -struct requires_sequence_of_axis {}; - -template <class T, - class = std::enable_if_t<is_sequence_of_axis_variant<std::decay_t<T>>::value>> -struct requires_sequence_of_axis_variant {}; - -template <class T, - class = std::enable_if_t<is_sequence_of_any_axis<std::decay_t<T>>::value>> -struct requires_sequence_of_any_axis {}; - -template <class T, - class = std::enable_if_t<is_any_axis<mp11::mp_first<std::decay_t<T>>>::value>> -struct requires_axes {}; - -template <class T, class U, class = std::enable_if_t<std::is_convertible<T, U>::value>> -struct requires_convertible {}; - -template <class T, class U, - class = std::enable_if_t<is_transform<std::decay_t<T>, U>::value>> -struct requires_transform {}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/fill.hpp b/ThirdParty/boost/histogram/detail/fill.hpp deleted file mode 100644 index 6205a63f45597491ea7d3ae40e85b8fdae6bb902..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/fill.hpp +++ /dev/null @@ -1,348 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_FILL_HPP -#define BOOST_HISTOGRAM_DETAIL_FILL_HPP - -#include <algorithm> -#include <boost/assert.hpp> -#include <boost/config/workaround.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/axis/variant.hpp> -#include <boost/histogram/detail/argument_traits.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/linearize.hpp> -#include <boost/histogram/detail/make_default.hpp> -#include <boost/histogram/detail/optional_index.hpp> -#include <boost/histogram/detail/priority.hpp> -#include <boost/histogram/detail/tuple_slice.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/integral.hpp> -#include <boost/mp11/tuple.hpp> -#include <boost/mp11/utility.hpp> -#include <mutex> -#include <tuple> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class U> -struct sample_args_passed_vs_expected; - -template <class... Passed, class... Expected> -struct sample_args_passed_vs_expected<std::tuple<Passed...>, std::tuple<Expected...>> { - static_assert(!(sizeof...(Expected) > 0 && sizeof...(Passed) == 0), - "error: accumulator requires samples, but sample argument is missing"); - static_assert( - !(sizeof...(Passed) > 0 && sizeof...(Expected) == 0), - "error: accumulator does not accept samples, but sample argument is passed"); - static_assert(sizeof...(Passed) == sizeof...(Expected), - "error: numbers of passed and expected sample arguments differ"); - static_assert( - std::is_convertible<std::tuple<Passed...>, std::tuple<Expected...>>::value, - "error: sample argument(s) not convertible to accumulator argument(s)"); -}; - -template <class A> -struct storage_grower { - const A& axes_; - struct { - axis::index_type idx, old_extent; - std::size_t new_stride; - } data_[buffer_size<A>::value]; - std::size_t new_size_; - - storage_grower(const A& axes) noexcept : axes_(axes) {} - - void from_shifts(const axis::index_type* shifts) noexcept { - auto dit = data_; - std::size_t s = 1; - for_each_axis(axes_, [&](const auto& a) { - const auto n = axis::traits::extent(a); - *dit++ = {0, n - std::abs(*shifts++), s}; - s *= n; - }); - new_size_ = s; - } - - // must be extents before any shifts were applied - void from_extents(const axis::index_type* old_extents) noexcept { - auto dit = data_; - std::size_t s = 1; - for_each_axis(axes_, [&](const auto& a) { - const auto n = axis::traits::extent(a); - *dit++ = {0, *old_extents++, s}; - s *= n; - }); - new_size_ = s; - } - - template <class S> - void apply(S& storage, const axis::index_type* shifts) { - auto new_storage = make_default(storage); - new_storage.reset(new_size_); - const auto dlast = data_ + axes_rank(axes_) - 1; - for (const auto& x : storage) { - auto ns = new_storage.begin(); - auto sit = shifts; - auto dit = data_; - for_each_axis(axes_, [&](const auto& a) { - using opt = axis::traits::get_options<std::decay_t<decltype(a)>>; - if (opt::test(axis::option::underflow)) { - if (dit->idx == 0) { - // axis has underflow and we are in the underflow bin: - // keep storage pointer unchanged - ++dit; - ++sit; - return; - } - } - if (opt::test(axis::option::overflow)) { - if (dit->idx == dit->old_extent - 1) { - // axis has overflow and we are in the overflow bin: - // move storage pointer to corresponding overflow bin position - ns += (axis::traits::extent(a) - 1) * dit->new_stride; - ++dit; - ++sit; - return; - } - } - // we are in a normal bin: - // move storage pointer to index position; apply positive shifts if any - ns += (dit->idx + (*sit >= 0 ? *sit : 0)) * dit->new_stride; - ++dit; - ++sit; - }); - // assign old value to new location - *ns = x; - // advance multi-dimensional index - dit = data_; - ++dit->idx; - while (dit != dlast && dit->idx == dit->old_extent) { - dit->idx = 0; - ++(++dit)->idx; - } - } - storage = std::move(new_storage); - } -}; - -template <class T, class... Us> -auto fill_storage_element_impl(priority<2>, T&& t, const Us&... args) noexcept - -> decltype(t(args...), void()) { - t(args...); -} - -template <class T, class U> -auto fill_storage_element_impl(priority<1>, T&& t, const weight_type<U>& w) noexcept - -> decltype(t += w, void()) { - t += w; -} - -// fallback for arithmetic types and accumulators that do not handle the weight -template <class T, class U> -auto fill_storage_element_impl(priority<0>, T&& t, const weight_type<U>& w) noexcept - -> decltype(t += w.value, void()) { - t += w.value; -} - -template <class T> -auto fill_storage_element_impl(priority<1>, T&& t) noexcept -> decltype(++t, void()) { - ++t; -} - -template <class T, class... Us> -void fill_storage_element(T&& t, const Us&... args) noexcept { - fill_storage_element_impl(priority<2>{}, std::forward<T>(t), args...); -} - -// t may be a proxy and then it is an rvalue reference, not an lvalue reference -template <class IW, class IS, class T, class U> -void fill_storage_2(IW, IS, T&& t, U&& u) noexcept { - mp11::tuple_apply( - [&](const auto&... args) { - fill_storage_element(std::forward<T>(t), std::get<IW::value>(u), args...); - }, - std::get<IS::value>(u).value); -} - -// t may be a proxy and then it is an rvalue reference, not an lvalue reference -template <class IS, class T, class U> -void fill_storage_2(mp11::mp_int<-1>, IS, T&& t, const U& u) noexcept { - mp11::tuple_apply( - [&](const auto&... args) { fill_storage_element(std::forward<T>(t), args...); }, - std::get<IS::value>(u).value); -} - -// t may be a proxy and then it is an rvalue reference, not an lvalue reference -template <class IW, class T, class U> -void fill_storage_2(IW, mp11::mp_int<-1>, T&& t, const U& u) noexcept { - fill_storage_element(std::forward<T>(t), std::get<IW::value>(u)); -} - -// t may be a proxy and then it is an rvalue reference, not an lvalue reference -template <class T, class U> -void fill_storage_2(mp11::mp_int<-1>, mp11::mp_int<-1>, T&& t, const U&) noexcept { - fill_storage_element(std::forward<T>(t)); -} - -template <class IW, class IS, class Storage, class Index, class Args> -auto fill_storage(IW, IS, Storage& s, const Index idx, const Args& a) noexcept { - if (is_valid(idx)) { - BOOST_ASSERT(idx < s.size()); - fill_storage_2(IW{}, IS{}, s[idx], a); - return s.begin() + idx; - } - return s.end(); -} - -template <int S, int N> -struct linearize_args { - template <class Index, class A, class Args> - static void impl(mp11::mp_int<N>, Index&, const std::size_t, A&, const Args&) {} - - template <int I, class Index, class A, class Args> - static void impl(mp11::mp_int<I>, Index& o, const std::size_t s, A& ax, - const Args& args) { - const auto e = linearize(o, s, axis_get<I>(ax), std::get<(S + I)>(args)); - impl(mp11::mp_int<(I + 1)>{}, o, s * e, ax, args); - } - - template <class Index, class A, class Args> - static void apply(Index& o, A& ax, const Args& args) { - impl(mp11::mp_int<0>{}, o, 1, ax, args); - } -}; - -template <int S> -struct linearize_args<S, 1> { - template <class Index, class A, class Args> - static void apply(Index& o, A& ax, const Args& args) { - linearize(o, 1, axis_get<0>(ax), std::get<S>(args)); - } -}; - -template <class A> -constexpr unsigned min(const unsigned n) noexcept { - constexpr unsigned a = static_cast<unsigned>(buffer_size<A>::value); - return a < n ? a : n; -} - -// not growing -template <class ArgTraits, class Storage, class Axes, class Args> -auto fill_2(ArgTraits, mp11::mp_false, const std::size_t offset, Storage& st, - const Axes& axes, const Args& args) { - mp11::mp_if<has_non_inclusive_axis<Axes>, optional_index, std::size_t> idx{offset}; - linearize_args<ArgTraits::start::value, min<Axes>(ArgTraits::nargs::value)>::apply( - idx, axes, args); - return fill_storage(typename ArgTraits::wpos{}, typename ArgTraits::spos{}, st, idx, - args); -} - -// at least one axis is growing -template <class ArgTraits, class Storage, class Axes, class Args> -auto fill_2(ArgTraits, mp11::mp_true, const std::size_t, Storage& st, Axes& axes, - const Args& args) { - std::array<axis::index_type, ArgTraits::nargs::value> shifts; - // offset must be zero for linearize_growth - mp11::mp_if<has_non_inclusive_axis<Axes>, optional_index, std::size_t> idx{0}; - std::size_t stride = 1; - bool update_needed = false; - mp11::mp_for_each<mp11::mp_iota_c<min<Axes>(ArgTraits::nargs::value)>>([&](auto i) { - auto& ax = axis_get<i>(axes); - const auto extent = linearize_growth(idx, shifts[i], stride, ax, - std::get<(ArgTraits::start::value + i)>(args)); - update_needed |= shifts[i] != 0; - stride *= extent; - }); - if (update_needed) { - storage_grower<Axes> g(axes); - g.from_shifts(shifts.data()); - g.apply(st, shifts.data()); - } - return fill_storage(typename ArgTraits::wpos{}, typename ArgTraits::spos{}, st, idx, - args); -} - -// pack original args tuple into another tuple (which is unpacked later) -template <int Start, int Size, class IW, class IS, class Args> -decltype(auto) pack_args(IW, IS, const Args& args) noexcept { - return std::make_tuple(tuple_slice<Start, Size>(args), std::get<IW::value>(args), - std::get<IS::value>(args)); -} - -template <int Start, int Size, class IW, class Args> -decltype(auto) pack_args(IW, mp11::mp_int<-1>, const Args& args) noexcept { - return std::make_tuple(tuple_slice<Start, Size>(args), std::get<IW::value>(args)); -} - -template <int Start, int Size, class IS, class Args> -decltype(auto) pack_args(mp11::mp_int<-1>, IS, const Args& args) noexcept { - return std::make_tuple(tuple_slice<Start, Size>(args), std::get<IS::value>(args)); -} - -template <int Start, int Size, class Args> -decltype(auto) pack_args(mp11::mp_int<-1>, mp11::mp_int<-1>, const Args& args) noexcept { - return std::make_tuple(args); -} - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 0) -#pragma warning(disable : 4702) // fixing warning would reduce code readability a lot -#endif - -template <class ArgTraits, class S, class A, class Args> -auto fill(std::true_type, ArgTraits, const std::size_t offset, S& storage, A& axes, - const Args& args) -> typename S::iterator { - using growing = has_growing_axis<A>; - - // Sometimes we need to pack the tuple into another tuple: - // - histogram contains one axis which accepts tuple - // - user passes tuple to fill(...) - // Tuple is normally unpacked and arguments are processed, this causes pos::nargs > 1. - // Now we pack tuple into another tuple so that original tuple is send to axis. - // Notes: - // - has nice side-effect of making histogram::operator(1, 2) work as well - // - cannot detect call signature of axis at compile-time in all configurations - // (axis::variant provides generic call interface and hides concrete - // interface), so we throw at runtime if incompatible argument is passed (e.g. - // 3d tuple) - - if (axes_rank(axes) == ArgTraits::nargs::value) - return fill_2(ArgTraits{}, growing{}, offset, storage, axes, args); - else if (axes_rank(axes) == 1 && - axis::traits::rank(axis_get<0>(axes)) == ArgTraits::nargs::value) - return fill_2( - argument_traits_holder< - 1, 0, (ArgTraits::wpos::value >= 0 ? 1 : -1), - (ArgTraits::spos::value >= 0 ? (ArgTraits::wpos::value >= 0 ? 2 : 1) : -1), - typename ArgTraits::sargs>{}, - growing{}, offset, storage, axes, - pack_args<ArgTraits::start::value, ArgTraits::nargs::value>( - typename ArgTraits::wpos{}, typename ArgTraits::spos{}, args)); - return (BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments != histogram rank")), - storage.end()); -} - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 0) -#pragma warning(default : 4702) -#endif - -// empty implementation for bad arguments to stop compiler from showing internals -template <class ArgTraits, class S, class A, class Args> -auto fill(std::false_type, ArgTraits, const std::size_t, S& storage, A&, const Args&) -> - typename S::iterator { - return storage.end(); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/fill_n.hpp b/ThirdParty/boost/histogram/detail/fill_n.hpp deleted file mode 100644 index 224a788cedee64c2c37ab82bd238518d4dbee697..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/fill_n.hpp +++ /dev/null @@ -1,339 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_FILL_N_HPP -#define BOOST_HISTOGRAM_DETAIL_FILL_N_HPP - -#include <algorithm> -#include <boost/assert.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/fill.hpp> -#include <boost/histogram/detail/linearize.hpp> -#include <boost/histogram/detail/non_member_container_access.hpp> -#include <boost/histogram/detail/optional_index.hpp> -#include <boost/histogram/detail/span.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/variant2/variant.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/bind.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -namespace dtl = boost::histogram::detail; - -template <class Axes, class T> -using is_convertible_to_any_value_type = - mp11::mp_any_of_q<value_types<Axes>, mp11::mp_bind_front<std::is_convertible, T>>; - -template <class... Ts> -void fold(Ts&&...) noexcept {} // helper to enable operator folding - -template <class T> -auto to_ptr_size(const T& x) { - return static_if<std::is_scalar<T>>( - [](const auto& x) { return std::make_pair(&x, static_cast<std::size_t>(0)); }, - [](const auto& x) { return std::make_pair(dtl::data(x), dtl::size(x)); }, x); -} - -template <class F, class V> -decltype(auto) maybe_visit(F&& f, V&& v) { - return static_if<is_variant<std::decay_t<V>>>( - [](auto&& f, auto&& v) { - return variant2::visit(std::forward<F>(f), std::forward<V>(v)); - }, - [](auto&& f, auto&& v) { return std::forward<F>(f)(std::forward<V>(v)); }, - std::forward<F>(f), std::forward<V>(v)); -} - -template <class Index, class Axis, class IsGrowing> -struct index_visitor { - using index_type = Index; - using pointer = index_type*; - using value_type = axis::traits::value_type<Axis>; - using Opt = axis::traits::get_options<Axis>; - - Axis& axis_; - const std::size_t stride_, start_, size_; // start and size of value collection - const pointer begin_; - axis::index_type* shift_; - - index_visitor(Axis& a, std::size_t& str, const std::size_t& sta, const std::size_t& si, - const pointer it, axis::index_type* shift) - : axis_(a), stride_(str), start_(sta), size_(si), begin_(it), shift_(shift) {} - - template <class T> - void call_2(std::true_type, pointer it, const T& x) const { - // must use this code for all axes if one of them is growing - axis::index_type shift; - linearize_growth(*it, shift, stride_, axis_, - try_cast<value_type, std::invalid_argument>(x)); - if (shift > 0) { // shift previous indices, because axis zero-point has changed - while (it != begin_) *--it += static_cast<std::size_t>(shift) * stride_; - *shift_ += shift; - } - } - - template <class T> - void call_2(std::false_type, pointer it, const T& x) const { - // no axis is growing - linearize(*it, stride_, axis_, try_cast<value_type, std::invalid_argument>(x)); - } - - template <class T> - void call_1(std::false_type, const T& iterable) const { - // T is iterable; fill N values - const auto* tp = dtl::data(iterable) + start_; - for (auto it = begin_; it != begin_ + size_; ++it) call_2(IsGrowing{}, it, *tp++); - } - - template <class T> - void call_1(std::true_type, const T& value) const { - // T is compatible value; fill single value N times - index_type idx{*begin_}; - call_2(IsGrowing{}, &idx, value); - if (is_valid(idx)) { - const auto delta = - static_cast<std::intptr_t>(idx) - static_cast<std::intptr_t>(*begin_); - for (auto&& i : make_span(begin_, size_)) i += delta; - } else - std::fill(begin_, begin_ + size_, invalid_index); - } - - template <class T> - void operator()(const T& iterable_or_value) const { - call_1(mp11::mp_bool<(std::is_convertible<T, value_type>::value || - !is_iterable<T>::value)>{}, - iterable_or_value); - } -}; - -template <class Index, class S, class Axes, class T> -void fill_n_indices(Index* indices, const std::size_t start, const std::size_t size, - const std::size_t offset, S& storage, Axes& axes, const T* viter) { - axis::index_type extents[buffer_size<Axes>::value]; - axis::index_type shifts[buffer_size<Axes>::value]; - for_each_axis(axes, [eit = extents, sit = shifts](const auto& a) mutable { - *sit++ = 0; - *eit++ = axis::traits::extent(a); - }); // LCOV_EXCL_LINE: gcc-8 is missing this line for no reason - - // offset must be zero for growing axes - using IsGrowing = has_growing_axis<Axes>; - std::fill(indices, indices + size, IsGrowing::value ? 0 : offset); - for_each_axis(axes, [&, stride = static_cast<std::size_t>(1), - pshift = shifts](auto& axis) mutable { - using Axis = std::decay_t<decltype(axis)>; - maybe_visit( - index_visitor<Index, Axis, IsGrowing>{axis, stride, start, size, indices, pshift}, - *viter++); - stride *= static_cast<std::size_t>(axis::traits::extent(axis)); - ++pshift; - }); - - bool update_needed = false; - for_each_axis(axes, [&update_needed, eit = extents](const auto& a) mutable { - update_needed |= *eit++ != axis::traits::extent(a); - }); - if (update_needed) { - storage_grower<Axes> g(axes); - g.from_extents(extents); - g.apply(storage, shifts); - } -} - -template <class S, class Index, class... Ts> -void fill_n_storage(S& s, const Index idx, Ts&&... p) noexcept { - if (is_valid(idx)) { - BOOST_ASSERT(idx < s.size()); - fill_storage_element(s[idx], *p.first...); - } - fold((p.second ? ++p.first : 0)...); -} - -template <class S, class Index, class T, class... Ts> -void fill_n_storage(S& s, const Index idx, weight_type<T>&& w, Ts&&... ps) noexcept { - if (is_valid(idx)) { - BOOST_ASSERT(idx < s.size()); - fill_storage_element(s[idx], weight(*w.value.first), *ps.first...); - } - if (w.value.second) ++w.value.first; - fold((ps.second ? ++ps.first : 0)...); -} - -// general Nd treatment -template <class Index, class S, class A, class T, class... Ts> -void fill_n_nd(const std::size_t offset, S& storage, A& axes, const std::size_t vsize, - const T* values, Ts&&... ts) { - constexpr std::size_t buffer_size = 1ul << 14; - Index indices[buffer_size]; - - /* - Parallelization options. - - A) Run the whole fill2 method in parallel, each thread fills its own buffer of - indices, synchronization (atomics) are needed to synchronize the incrementing of - the storage cells. This leads to a lot of congestion for small histograms. - - B) Run only fill_n_indices in parallel, subsections of the indices buffer - can be filled by different threads. The final loop that fills the storage runs - in the main thread, this requires no synchronization for the storage, cells do - not need to support atomic operations. - - C) Like B), then sort the indices in the main thread and fill the - storage in parallel, where each thread uses a disjunct set of indices. This - should create less congestion and requires no synchronization for the storage. - - Note on C): Let's say we have an axis with 5 bins (with *flow to simplify). - Then after filling 10 values, converting to indices and sorting, the index - buffer may look like this: 0 0 0 1 2 2 2 4 4 5. Let's use two threads to fill - the storage. Still in the main thread, we compute an iterator to the middle of - the index buffer and move it to the right until the pointee changes. Now we have - two ranges which contain disjunct sets of indices. We pass these ranges to the - threads which then fill the storage. Since the threads by construction do not - compete to increment the same cell, no further synchronization is required. - - In all cases, growing axes cannot be parallelized. - */ - - for (std::size_t start = 0; start < vsize; start += buffer_size) { - const std::size_t n = std::min(buffer_size, vsize - start); - // fill buffer of indices... - fill_n_indices(indices, start, n, offset, storage, axes, values); - // ...and fill corresponding storage cells - for (auto&& idx : make_span(indices, n)) - fill_n_storage(storage, idx, std::forward<Ts>(ts)...); - } -} - -template <class S, class... As, class T, class... Us> -void fill_n_1(const std::size_t offset, S& storage, std::tuple<As...>& axes, - const std::size_t vsize, const T* values, Us&&... us) { - using index_type = - mp11::mp_if<has_non_inclusive_axis<std::tuple<As...>>, optional_index, std::size_t>; - fill_n_nd<index_type>(offset, storage, axes, vsize, values, std::forward<Us>(us)...); -} - -template <class S, class A, class T, class... Us> -void fill_n_1(const std::size_t offset, S& storage, A& axes, const std::size_t vsize, - const T* values, Us&&... us) { - bool all_inclusive = true; - for_each_axis(axes, - [&](const auto& ax) { all_inclusive &= axis::traits::inclusive(ax); }); - if (axes_rank(axes) == 1) { - axis::visit( - [&](auto& ax) { - std::tuple<decltype(ax)> axes{ax}; - fill_n_1(offset, storage, axes, vsize, values, std::forward<Us>(us)...); - }, - axes[0]); - } else { - if (all_inclusive) - fill_n_nd<std::size_t>(offset, storage, axes, vsize, values, - std::forward<Us>(us)...); - else - fill_n_nd<optional_index>(offset, storage, axes, vsize, values, - std::forward<Us>(us)...); - } -} - -template <class A, class T, std::size_t N> -std::size_t get_total_size(const A& axes, const dtl::span<const T, N>& values) { - // supported cases (T = value type; CT = containter of T; V<T, CT, ...> = variant): - // - span<CT, N>: for any histogram, N == rank - // - span<V<T, CT>, N>: for any histogram, N == rank - BOOST_ASSERT(axes_rank(axes) == values.size()); - constexpr auto unset = static_cast<std::size_t>(-1); - std::size_t size = unset; - for_each_axis(axes, [&size, vit = values.begin()](const auto& ax) mutable { - using AV = axis::traits::value_type<std::decay_t<decltype(ax)>>; - maybe_visit( - [&size](const auto& v) { - // v is either convertible to value or a sequence of values - using V = std::remove_const_t<std::remove_reference_t<decltype(v)>>; - static_if_c<(std::is_convertible<decltype(v), AV>::value || - !is_iterable<V>::value)>( - [](const auto&) {}, - [&size](const auto& v) { - const auto n = dtl::size(v); - // must repeat this here for msvc :( - constexpr auto unset = static_cast<std::size_t>(-1); - if (size == unset) - size = dtl::size(v); - else if (size != n) - BOOST_THROW_EXCEPTION( - std::invalid_argument("spans must have compatible lengths")); - }, - v); - }, - *vit++); - }); - // if all arguments are not iterables, return size of 1 - return size == unset ? 1 : size; -} - -inline void fill_n_check_extra_args(std::size_t) noexcept {} - -template <class T, class... Ts> -void fill_n_check_extra_args(std::size_t size, T&& x, Ts&&... ts) { - // sequences must have same lengths, but sequences of length 0 are broadcast - if (x.second != 0 && x.second != size) - BOOST_THROW_EXCEPTION(std::invalid_argument("spans must have compatible lengths")); - fill_n_check_extra_args(size, std::forward<Ts>(ts)...); -} - -template <class T, class... Ts> -void fill_n_check_extra_args(std::size_t size, weight_type<T>&& w, Ts&&... ts) { - fill_n_check_extra_args(size, w.value, std::forward<Ts>(ts)...); -} - -template <class S, class A, class T, std::size_t N, class... Us> -void fill_n(std::true_type, const std::size_t offset, S& storage, A& axes, - const dtl::span<const T, N> values, Us&&... us) { - // supported cases (T = value type; CT = containter of T; V<T, CT, ...> = variant): - // - span<T, N>: only valid for 1D histogram, N > 1 allowed - // - span<CT, N>: for any histogram, N == rank - // - span<V<T, CT>, N>: for any histogram, N == rank - static_if<is_convertible_to_any_value_type<A, T>>( - [&](const auto& values, auto&&... us) { - // T matches one of the axis value types, must be 1D special case - if (axes_rank(axes) != 1) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments must match histogram rank")); - fill_n_check_extra_args(values.size(), std::forward<Us>(us)...); - fill_n_1(offset, storage, axes, values.size(), &values, std::forward<Us>(us)...); - }, - [&](const auto& values, auto&&... us) { - // generic ND case - if (axes_rank(axes) != values.size()) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments must match histogram rank")); - const auto vsize = get_total_size(axes, values); - fill_n_check_extra_args(vsize, std::forward<Us>(us)...); - fill_n_1(offset, storage, axes, vsize, values.data(), std::forward<Us>(us)...); - }, - values, std::forward<Us>(us)...); -} - -// empty implementation for bad arguments to stop compiler from showing internals -template <class... Ts> -void fill_n(std::false_type, Ts...) {} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DETAIL_FILL_N_HPP diff --git a/ThirdParty/boost/histogram/detail/iterator_adaptor.hpp b/ThirdParty/boost/histogram/detail/iterator_adaptor.hpp deleted file mode 100644 index 345a4abb194b0212b1652b322e6d9491e6241b7a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/iterator_adaptor.hpp +++ /dev/null @@ -1,162 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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) -// -// Uses code segments from boost/iterator/iterator_adaptor.hpp -// and boost/iterator/iterator_fascade.hpp - -#ifndef BOOST_HISTOGRAM_DETAIL_ITERATOR_ADAPTOR_HPP -#define BOOST_HISTOGRAM_DETAIL_ITERATOR_ADAPTOR_HPP - -#include <iterator> -#include <memory> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -// operator->() needs special support for input iterators to strictly meet the -// standard's requirements. If *i is not a reference type, we must still -// produce an lvalue to which a pointer can be formed. We do that by -// returning a proxy object containing an instance of the reference object. -template <class Reference> -struct operator_arrow_dispatch_t // proxy references -{ - struct proxy { - explicit proxy(Reference const& x) noexcept : m_ref(x) {} - Reference* operator->() noexcept { return std::addressof(m_ref); } - Reference m_ref; - }; - - using result_type = proxy; - static result_type apply(Reference const& x) noexcept { return proxy(x); } -}; - -template <class T> -struct operator_arrow_dispatch_t<T&> // "real" references -{ - using result_type = T*; - static result_type apply(T& x) noexcept { return std::addressof(x); } -}; - -// only for random access Base -template <class Derived, class Base, class Reference = std::remove_pointer_t<Base>&, - class Value = std::decay_t<Reference>> -class iterator_adaptor { - using operator_arrow_dispatch = operator_arrow_dispatch_t<Reference>; - -public: - using base_type = Base; - - using reference = Reference; - using value_type = std::remove_const_t<Value>; - using pointer = typename operator_arrow_dispatch::result_type; - using difference_type = std::ptrdiff_t; - using iterator_category = std::random_access_iterator_tag; - - iterator_adaptor() = default; - - explicit iterator_adaptor(base_type const& iter) : iter_(iter) {} - - pointer operator->() const noexcept { - return operator_arrow_dispatch::apply(this->derived().operator*()); - } - reference operator[](difference_type n) const { return *(this->derived() + n); } - - Derived& operator++() { - ++iter_; - return this->derived(); - } - - Derived& operator--() { - --iter_; - return this->derived(); - } - - Derived operator++(int) { - Derived tmp(this->derived()); - ++iter_; - return tmp; - } - - Derived operator--(int) { - Derived tmp(this->derived()); - --iter_; - return tmp; - } - - Derived& operator+=(difference_type n) { - iter_ += n; - return this->derived(); - } - - Derived& operator-=(difference_type n) { - iter_ -= n; - return this->derived(); - } - - Derived operator+(difference_type n) const { - Derived tmp(this->derived()); - tmp += n; - return tmp; - } - - Derived operator-(difference_type n) const { return operator+(-n); } - - template <class... Ts> - difference_type operator-(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ - x.iter_; - } - - template <class... Ts> - bool operator==(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ == x.iter_; - } - template <class... Ts> - bool operator!=(const iterator_adaptor<Ts...>& x) const noexcept { - return !this->derived().operator==(x); // equal operator may be overridden in derived - } - template <class... Ts> - bool operator<(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ < x.iter_; - } - template <class... Ts> - bool operator>(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ > x.iter_; - } - template <class... Ts> - bool operator<=(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ <= x.iter_; - } - template <class... Ts> - bool operator>=(const iterator_adaptor<Ts...>& x) const noexcept { - return iter_ >= x.iter_; - } - - friend Derived operator+(difference_type n, const Derived& x) { return x + n; } - - Base const& base() const noexcept { return iter_; } - -protected: - // for convenience in derived classes - using iterator_adaptor_ = iterator_adaptor; - -private: - Derived& derived() noexcept { return *static_cast<Derived*>(this); } - const Derived& derived() const noexcept { return *static_cast<Derived const*>(this); } - - Base iter_; - - template <class, class, class, class> - friend class iterator_adaptor; -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/large_int.hpp b/ThirdParty/boost/histogram/detail/large_int.hpp deleted file mode 100644 index 363ca33568f773dc9cb3b590ce9da002f376e5e4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/large_int.hpp +++ /dev/null @@ -1,232 +0,0 @@ -// Copyright 2018-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_LARGE_INT_HPP -#define BOOST_HISTOGRAM_DETAIL_LARGE_INT_HPP - -#include <boost/assert.hpp> -#include <boost/histogram/detail/operators.hpp> -#include <boost/histogram/detail/safe_comparison.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/function.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/utility.hpp> -#include <cmath> -#include <cstdint> -#include <limits> -#include <type_traits> -#include <utility> -#include <vector> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -using is_unsigned_integral = mp11::mp_and<std::is_integral<T>, std::is_unsigned<T>>; - -template <class T> -bool safe_increment(T& t) { - if (t < (std::numeric_limits<T>::max)()) { - ++t; - return true; - } - return false; -} - -template <class T, class U> -bool safe_radd(T& t, const U& u) { - static_assert(is_unsigned_integral<T>::value, "T must be unsigned integral type"); - static_assert(is_unsigned_integral<U>::value, "T must be unsigned integral type"); - if (static_cast<T>((std::numeric_limits<T>::max)() - t) >= u) { - t += static_cast<T>(u); // static_cast to suppress conversion warning - return true; - } - return false; -} - -// An integer type which can grow arbitrarily large (until memory is exhausted). -// Use boost.multiprecision.cpp_int in your own code, it is much more sophisticated. -// We use it only to reduce coupling between boost libs. -template <class Allocator> -struct large_int : totally_ordered<large_int<Allocator>, large_int<Allocator>>, - partially_ordered<large_int<Allocator>, void> { - explicit large_int(const Allocator& a = {}) : data(1, 0, a) {} - explicit large_int(std::uint64_t v, const Allocator& a = {}) : data(1, v, a) {} - - large_int(const large_int&) = default; - large_int& operator=(const large_int&) = default; - large_int(large_int&&) = default; - large_int& operator=(large_int&&) = default; - - large_int& operator=(std::uint64_t o) { - data = decltype(data)(1, o); - return *this; - } - - large_int& operator++() { - BOOST_ASSERT(data.size() > 0u); - std::size_t i = 0; - while (!safe_increment(data[i])) { - data[i] = 0; - ++i; - if (i == data.size()) { - data.push_back(1); - break; - } - } - return *this; - } - - large_int& operator+=(const large_int& o) { - if (this == &o) { - auto tmp{o}; - return operator+=(tmp); - } - bool carry = false; - std::size_t i = 0; - for (std::uint64_t oi : o.data) { - auto& di = maybe_extend(i); - if (carry) { - if (safe_increment(oi)) - carry = false; - else { - ++i; - continue; - } - } - if (!safe_radd(di, oi)) { - add_remainder(di, oi); - carry = true; - } - ++i; - } - while (carry) { - auto& di = maybe_extend(i); - if (safe_increment(di)) break; - di = 0; - ++i; - } - return *this; - } - - large_int& operator+=(std::uint64_t o) { - BOOST_ASSERT(data.size() > 0u); - if (safe_radd(data[0], o)) return *this; - add_remainder(data[0], o); - // carry the one, data may grow several times - std::size_t i = 1; - while (true) { - auto& di = maybe_extend(i); - if (safe_increment(di)) break; - di = 0; - ++i; - } - return *this; - } - - explicit operator double() const noexcept { - BOOST_ASSERT(data.size() > 0u); - double result = static_cast<double>(data[0]); - std::size_t i = 0; - while (++i < data.size()) - result += static_cast<double>(data[i]) * std::pow(2.0, i * 64); - return result; - } - - bool operator<(const large_int& o) const noexcept { - BOOST_ASSERT(data.size() > 0u); - BOOST_ASSERT(o.data.size() > 0u); - // no leading zeros allowed - BOOST_ASSERT(data.size() == 1 || data.back() > 0u); - BOOST_ASSERT(o.data.size() == 1 || o.data.back() > 0u); - if (data.size() < o.data.size()) return true; - if (data.size() > o.data.size()) return false; - auto s = data.size(); - while (s > 0u) { - --s; - if (data[s] < o.data[s]) return true; - if (data[s] > o.data[s]) return false; - } - return false; // args are equal - } - - bool operator==(const large_int& o) const noexcept { - BOOST_ASSERT(data.size() > 0u); - BOOST_ASSERT(o.data.size() > 0u); - // no leading zeros allowed - BOOST_ASSERT(data.size() == 1 || data.back() > 0u); - BOOST_ASSERT(o.data.size() == 1 || o.data.back() > 0u); - if (data.size() != o.data.size()) return false; - return std::equal(data.begin(), data.end(), o.data.begin()); - } - - template <class U> - std::enable_if_t<std::is_integral<U>::value, bool> operator<(const U& o) const - noexcept { - BOOST_ASSERT(data.size() > 0u); - return data.size() == 1 && safe_less()(data[0], o); - } - - template <class U> - std::enable_if_t<std::is_integral<U>::value, bool> operator>(const U& o) const - noexcept { - BOOST_ASSERT(data.size() > 0u); - BOOST_ASSERT(data.size() == 1 || data.back() > 0u); // no leading zeros allowed - return data.size() > 1 || safe_less()(o, data[0]); - } - - template <class U> - std::enable_if_t<std::is_integral<U>::value, bool> operator==(const U& o) const - noexcept { - BOOST_ASSERT(data.size() > 0u); - return data.size() == 1 && safe_equal()(data[0], o); - } - - template <class U> - std::enable_if_t<std::is_floating_point<U>::value, bool> operator<(const U& o) const - noexcept { - return operator double() < o; - } - template <class U> - std::enable_if_t<std::is_floating_point<U>::value, bool> operator>(const U& o) const - noexcept { - return operator double() > o; - } - template <class U> - std::enable_if_t<std::is_floating_point<U>::value, bool> operator==(const U& o) const - noexcept { - return operator double() == o; - } - - std::uint64_t& maybe_extend(std::size_t i) { - while (i >= data.size()) data.push_back(0); - return data[i]; - } - - static void add_remainder(std::uint64_t& d, const std::uint64_t o) noexcept { - BOOST_ASSERT(d > 0u); - // in decimal system it would look like this: - // 8 + 8 = 6 = 8 - (9 - 8) - 1 - // 9 + 1 = 0 = 9 - (9 - 1) - 1 - auto tmp = (std::numeric_limits<std::uint64_t>::max)(); - tmp -= o; - --d -= tmp; - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("data", data); - } - - std::vector<std::uint64_t, Allocator> data; -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/limits.hpp b/ThirdParty/boost/histogram/detail/limits.hpp deleted file mode 100644 index 9fcfe909aef2132e7d18f51f81a3cc11d80047e4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/limits.hpp +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_LIMITS_HPP -#define BOOST_HISTOGRAM_DETAIL_LIMITS_HPP - -#include <limits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -constexpr T lowest() { - return std::numeric_limits<T>::lowest(); -} - -template <> -constexpr double lowest() { - return -std::numeric_limits<double>::infinity(); -} - -template <> -constexpr float lowest() { - return -std::numeric_limits<float>::infinity(); -} - -template <class T> -constexpr T highest() { - return (std::numeric_limits<T>::max)(); -} - -template <> -constexpr double highest() { - return std::numeric_limits<double>::infinity(); -} - -template <> -constexpr float highest() { - return std::numeric_limits<float>::infinity(); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/linearize.hpp b/ThirdParty/boost/histogram/detail/linearize.hpp deleted file mode 100644 index 1c8ba30ddf8901a5a616b08f7164e6d7e43ac131..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/linearize.hpp +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_LINEARIZE_HPP -#define BOOST_HISTOGRAM_DETAIL_LINEARIZE_HPP - -#include <boost/assert.hpp> -#include <boost/config.hpp> -#include <boost/histogram/axis/option.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/axis/variant.hpp> -#include <boost/histogram/detail/optional_index.hpp> -#include <boost/histogram/fwd.hpp> - -namespace boost { -namespace histogram { -namespace detail { - -// initial offset to out must be set -template <class Index, class Opts> -std::size_t linearize(Opts, Index& out, const std::size_t stride, - const axis::index_type size, const axis::index_type idx) { - constexpr bool u = Opts::test(axis::option::underflow); - constexpr bool o = Opts::test(axis::option::overflow); -#ifdef BOOST_NO_CXX17_IF_CONSTEXPR - if -#else - if constexpr -#endif - (std::is_same<Index, std::size_t>::value || (u && o)) { - BOOST_ASSERT(idx >= (u ? -1 : 0)); - BOOST_ASSERT(idx < (o ? size + 1 : size)); - BOOST_ASSERT(idx >= 0 || static_cast<std::size_t>(-idx * stride) <= out); - out += idx * stride; - } else { - BOOST_ASSERT(idx >= -1); - BOOST_ASSERT(idx < size + 1); - if ((u || idx >= 0) && (o || idx < size)) - out += idx * stride; - else - out = invalid_index; - } - return size + u + o; -} - -template <class Index, class Axis, class Value> -std::size_t linearize(Index& out, const std::size_t stride, const Axis& ax, - const Value& v) { - // mask options to reduce no. of template instantiations - constexpr auto opts = axis::traits::get_options<Axis>{} & - (axis::option::underflow | axis::option::overflow); - return linearize(opts, out, stride, ax.size(), axis::traits::index(ax, v)); -} - -// initial offset of out must be zero -template <class Index, class Axis, class Value> -std::size_t linearize_growth(Index& out, axis::index_type& shift, - const std::size_t stride, Axis& a, const Value& v) { - axis::index_type idx; - std::tie(idx, shift) = axis::traits::update(a, v); - constexpr bool u = axis::traits::get_options<Axis>::test(axis::option::underflow); - if (u) ++idx; - if (std::is_same<Index, std::size_t>::value) { - BOOST_ASSERT(idx < axis::traits::extent(a)); - out += idx * stride; - } else { - if (0 <= idx && idx < axis::traits::extent(a)) - out += idx * stride; - else - out = invalid_index; - } - return axis::traits::extent(a); -} - -// initial offset of out must be zero -template <class A> -std::size_t linearize_index(optional_index& out, const std::size_t stride, const A& ax, - const axis::index_type idx) { - // cannot use get_options here, since A may be variant - const auto opt = axis::traits::options(ax); - const axis::index_type begin = opt & axis::option::underflow ? -1 : 0; - const axis::index_type end = opt & axis::option::overflow ? ax.size() + 1 : ax.size(); - const axis::index_type extent = end - begin; - // i may be arbitrarily out of range - if (begin <= idx && idx < end) - out += (idx - begin) * stride; - else - out = invalid_index; - return extent; -} - -template <class Index, class... Ts, class Value> -std::size_t linearize(Index& o, const std::size_t s, const axis::variant<Ts...>& a, - const Value& v) { - return axis::visit([&o, &s, &v](const auto& a) { return linearize(o, s, a, v); }, a); -} - -template <class Index, class... Ts, class Value> -std::size_t linearize_growth(Index& o, axis::index_type& sh, const std::size_t st, - axis::variant<Ts...>& a, const Value& v) { - return axis::visit([&](auto& a) { return linearize_growth(o, sh, st, a, v); }, a); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DETAIL_LINEARIZE_HPP diff --git a/ThirdParty/boost/histogram/detail/make_default.hpp b/ThirdParty/boost/histogram/detail/make_default.hpp deleted file mode 100644 index 738bde6fb6ecc46618ed06c5c3edeb28a6fc4126..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/make_default.hpp +++ /dev/null @@ -1,27 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_MAKE_DEFAULT_HPP -#define BOOST_HISTOGRAM_DETAIL_MAKE_DEFAULT_HPP - -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/static_if.hpp> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -auto make_default(const T& t) { - return static_if<has_allocator<T>>([](const auto& t) { return T(t.get_allocator()); }, - [](const auto&) { return T{}; }, t); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/mutex_base.hpp b/ThirdParty/boost/histogram/detail/mutex_base.hpp deleted file mode 100644 index fac45b441153b7dfb45561f551bb859ac6a73b64..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/mutex_base.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_NOOP_MUTEX_HPP -#define BOOST_HISTOGRAM_DETAIL_NOOP_MUTEX_HPP - -#include <boost/core/empty_value.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/mp11/utility.hpp> // mp_if -#include <mutex> - -namespace boost { -namespace histogram { -namespace detail { - -struct null_mutex { - bool try_lock() noexcept { return true; } - void lock() noexcept {} - void unlock() noexcept {} -}; - -template <class Axes, class Storage, - class DetailMutex = mp11::mp_if_c<(Storage::has_threading_support && - detail::has_growing_axis<Axes>::value), - std::mutex, detail::null_mutex>> -struct mutex_base : empty_value<DetailMutex> { - mutex_base() = default; - // do not copy or move mutex - mutex_base(const mutex_base&) : empty_value<DetailMutex>() {} - // do not copy or move mutex - mutex_base& operator=(const mutex_base&) { return *this; } -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/non_member_container_access.hpp b/ThirdParty/boost/histogram/detail/non_member_container_access.hpp deleted file mode 100644 index 729f7b3316110485af1be9a7c48327e726cf2cc6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/non_member_container_access.hpp +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_NON_MEMBER_CONTAINER_ACCESS_HPP -#define BOOST_HISTOGRAM_DETAIL_NON_MEMBER_CONTAINER_ACCESS_HPP - -#if __cpp_lib_nonmember_container_access >= 201411 - -#include <iterator> - -namespace boost { -namespace histogram { -namespace detail { - -using std::data; -using std::size; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#else - -#include <initializer_list> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class C> -constexpr auto data(C& c) -> decltype(c.data()) { - return c.data(); -} - -template <class C> -constexpr auto data(const C& c) -> decltype(c.data()) { - return c.data(); -} - -template <class T, std::size_t N> -constexpr T* data(T (&array)[N]) noexcept { - return array; -} - -template <class E> -constexpr const E* data(std::initializer_list<E> il) noexcept { - return il.begin(); -} - -template <class C> -constexpr auto size(const C& c) -> decltype(c.size()) { - return c.size(); -} - -template <class T, std::size_t N> -constexpr std::size_t size(const T (&)[N]) noexcept { - return N; -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif - -#endif // BOOST_HISTOGRAM_DETAIL_NON_MEMBER_CONTAINER_ACCESS_HPP diff --git a/ThirdParty/boost/histogram/detail/operators.hpp b/ThirdParty/boost/histogram/detail/operators.hpp deleted file mode 100644 index b781c495ad667539fde86727a35a7278b966a86d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/operators.hpp +++ /dev/null @@ -1,135 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_OPERATORS_HPP -#define BOOST_HISTOGRAM_DETAIL_OPERATORS_HPP - -#include <boost/histogram/detail/detect.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/utility.hpp> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class U> -using if_not_same_and_has_eq = - std::enable_if_t<(!std::is_same<T, U>::value && has_method_eq<T, U>::value), bool>; - -// totally_ordered is for types with a <= b == !(a > b) [floats with NaN violate this] -// Derived must implement <,== for symmetric form and <,>,== for non-symmetric. - -// partially_ordered is for types with a <= b == a < b || a == b [for floats with NaN] -// Derived must implement <,== for the symmetric form and <,>,== for non-symmetric. - -template <class T, class U> -struct mirrored { - friend bool operator<(const U& a, const T& b) noexcept { return b > a; } - friend bool operator>(const U& a, const T& b) noexcept { return b < a; } - friend bool operator==(const U& a, const T& b) noexcept { return b == a; } - friend bool operator<=(const U& a, const T& b) noexcept { return b >= a; } - friend bool operator>=(const U& a, const T& b) noexcept { return b <= a; } - friend bool operator!=(const U& a, const T& b) noexcept { return b != a; } -}; - -template <class T> -struct mirrored<T, void> { - template <class U> - friend if_not_same_and_has_eq<T, U> operator<(const U& a, const T& b) noexcept { - return b > a; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator>(const U& a, const T& b) noexcept { - return b < a; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator==(const U& a, const T& b) noexcept { - return b == a; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator<=(const U& a, const T& b) noexcept { - return b >= a; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator>=(const U& a, const T& b) noexcept { - return b <= a; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator!=(const U& a, const T& b) noexcept { - return b != a; - } -}; - -template <class T> -struct mirrored<T, T> { - friend bool operator>(const T& a, const T& b) noexcept { return b.operator<(a); } -}; - -template <class T, class U> -struct equality { - friend bool operator!=(const T& a, const U& b) noexcept { return !a.operator==(b); } -}; - -template <class T> -struct equality<T, void> { - template <class U> - friend if_not_same_and_has_eq<T, U> operator!=(const T& a, const U& b) noexcept { - return !(a == b); - } -}; - -template <class T, class U> -struct totally_ordered_impl : equality<T, U>, mirrored<T, U> { - friend bool operator<=(const T& a, const U& b) noexcept { return !(a > b); } - friend bool operator>=(const T& a, const U& b) noexcept { return !(a < b); } -}; - -template <class T> -struct totally_ordered_impl<T, void> : equality<T, void>, mirrored<T, void> { - template <class U> - friend if_not_same_and_has_eq<T, U> operator<=(const T& a, const U& b) noexcept { - return !(a > b); - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator>=(const T& a, const U& b) noexcept { - return !(a < b); - } -}; - -template <class T, class... Ts> -using totally_ordered = mp11::mp_rename< - mp11::mp_product<totally_ordered_impl, mp11::mp_list<T>, mp11::mp_list<Ts...> >, - mp11::mp_inherit>; - -template <class T, class U> -struct partially_ordered_impl : equality<T, U>, mirrored<T, U> { - friend bool operator<=(const T& a, const U& b) noexcept { return a < b || a == b; } - friend bool operator>=(const T& a, const U& b) noexcept { return a > b || a == b; } -}; - -template <class T> -struct partially_ordered_impl<T, void> : equality<T, void>, mirrored<T, void> { - template <class U> - friend if_not_same_and_has_eq<T, U> operator<=(const T& a, const U& b) noexcept { - return a < b || a == b; - } - template <class U> - friend if_not_same_and_has_eq<T, U> operator>=(const T& a, const U& b) noexcept { - return a > b || a == b; - } -}; - -template <class T, class... Ts> -using partially_ordered = mp11::mp_rename< - mp11::mp_product<partially_ordered_impl, mp11::mp_list<T>, mp11::mp_list<Ts...> >, - mp11::mp_inherit>; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DETAIL_OPERATORS_HPP diff --git a/ThirdParty/boost/histogram/detail/optional_index.hpp b/ThirdParty/boost/histogram/detail/optional_index.hpp deleted file mode 100644 index e64df653e69a373ce3a7673567f39e6e1f63f84c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/optional_index.hpp +++ /dev/null @@ -1,55 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_OPTIONAL_INDEX_HPP -#define BOOST_HISTOGRAM_DETAIL_OPTIONAL_INDEX_HPP - -#include <boost/assert.hpp> -#include <cstdint> - -namespace boost { -namespace histogram { -namespace detail { - -constexpr auto invalid_index = ~static_cast<std::size_t>(0); - -// integer with a persistent invalid state, similar to NaN -struct optional_index { - std::size_t value; - - optional_index& operator=(std::size_t x) noexcept { - value = x; - return *this; - } - - optional_index& operator+=(std::intptr_t x) noexcept { - BOOST_ASSERT(x >= 0 || static_cast<std::size_t>(-x) <= value); - if (value != invalid_index) { value += x; } - return *this; - } - - optional_index& operator+=(const optional_index& x) noexcept { - if (value != invalid_index) return operator+=(x.value); - value = invalid_index; - return *this; - } - - operator std::size_t() const noexcept { return value; } - - friend bool operator<=(std::size_t x, optional_index idx) noexcept { - return x <= idx.value; - } -}; - -constexpr inline bool is_valid(const std::size_t) noexcept { return true; } - -inline bool is_valid(const optional_index x) noexcept { return x.value != invalid_index; } - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/priority.hpp b/ThirdParty/boost/histogram/detail/priority.hpp deleted file mode 100644 index 061f281e62aed76f9850036a5cc5f71362a4420d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/priority.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_PRIORITY_HPP -#define BOOST_HISTOGRAM_DETAIL_PRIORITY_HPP - -#include <cstdint> - -namespace boost { -namespace histogram { -namespace detail { - -// priority is used to priorise ambiguous overloads - -template <std::size_t N> -struct priority : priority<(N - 1)> {}; - -template <> -struct priority<0> {}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/reduce_command.hpp b/ThirdParty/boost/histogram/detail/reduce_command.hpp deleted file mode 100644 index a3262fe491be1ce32a48c8c26aa0e7c72dc08b5a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/reduce_command.hpp +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2020 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_REDUCE_COMMAND_HPP -#define BOOST_HISTOGRAM_DETAIL_REDUCE_COMMAND_HPP - -#include <boost/histogram/fwd.hpp> - -namespace boost { -namespace histogram { -namespace detail { - -struct reduce_command { - static constexpr unsigned unset = static_cast<unsigned>(-1); - unsigned iaxis; - enum class range_t : char { - none, - indices, - values, - } range = range_t::none; - union { - axis::index_type index; - double value; - } begin, end; - unsigned merge = 0; // default value indicates unset option - bool crop = false; - // for internal use by the reduce algorithm - bool is_ordered = true; - bool use_underflow_bin = true; - bool use_overflow_bin = true; -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/relaxed_equal.hpp b/ThirdParty/boost/histogram/detail/relaxed_equal.hpp deleted file mode 100644 index 123a05a20b40b54ec75ebc91661cf67b25aa45d7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/relaxed_equal.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_RELAXED_EQUAL_HPP -#define BOOST_HISTOGRAM_DETAIL_RELAXED_EQUAL_HPP - -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/static_if.hpp> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -constexpr bool relaxed_equal(const T& a, const T& b) noexcept { - return static_if<has_operator_equal<T>>( - [](const auto& a, const auto& b) { return a == b; }, - [](const auto&, const auto&) { return true; }, a, b); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/replace_type.hpp b/ThirdParty/boost/histogram/detail/replace_type.hpp deleted file mode 100644 index affe5b3d7b06f54b2d2e1670a75af0ee27abc043..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/replace_type.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_REPLACE_TYPE_HPP -#define BOOST_HISTOGRAM_DETAIL_REPLACE_TYPE_HPP - -#include <boost/core/use_default.hpp> -#include <string> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class From, class To> -using replace_type = std::conditional_t<std::is_same<T, From>::value, To, T>; - -template <class T, class Default> -using replace_default = replace_type<T, boost::use_default, Default>; - -template <class T> -using replace_cstring = replace_type<T, const char*, std::string>; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/safe_comparison.hpp b/ThirdParty/boost/histogram/detail/safe_comparison.hpp deleted file mode 100644 index 3ac793ba44bcd3e2d5118b653c321a4b21f748d2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/safe_comparison.hpp +++ /dev/null @@ -1,87 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_SAFE_COMPARISON_HPP -#define BOOST_HISTOGRAM_DETAIL_SAFE_COMPARISON_HPP - -#include <boost/mp11/utility.hpp> -#include <boost/type.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -auto make_unsigned(const T& t) noexcept { - static_assert(std::is_integral<T>::value, ""); - return static_cast<std::make_unsigned_t<T>>(t); -} - -template <class T> -using number_category = - mp11::mp_if<std::is_integral<T>, - mp11::mp_if<std::is_signed<T>, type<int>, type<unsigned>>, type<void>>; - -// version of std::equal_to<> which handles signed and unsigned integers correctly -struct safe_equal { - template <class T, class U> - bool operator()(const T& t, const U& u) const noexcept { - return impl(number_category<T>{}, number_category<U>{}, t, u); - } - - template <class C1, class C2, class T, class U> - bool impl(C1, C2, const T& t, const U& u) const noexcept { - return t == u; - } - - template <class T, class U> - bool impl(type<int>, type<unsigned>, const T& t, const U& u) const noexcept { - return t >= 0 && make_unsigned(t) == u; - } - - template <class T, class U> - bool impl(type<unsigned>, type<int>, const T& t, const U& u) const noexcept { - return impl(type<int>{}, type<unsigned>{}, u, t); - } -}; - -// version of std::less<> which handles signed and unsigned integers correctly -struct safe_less { - template <class T, class U> - bool operator()(const T& t, const U& u) const noexcept { - return impl(number_category<T>{}, number_category<U>{}, t, u); - } - - template <class C1, class C2, class T, class U> - bool impl(C1, C2, const T& t, const U& u) const noexcept { - return t < u; - } - - template <class T, class U> - bool impl(type<int>, type<unsigned>, const T& t, const U& u) const noexcept { - return t < 0 || make_unsigned(t) < u; - } - - template <class T, class U> - bool impl(type<unsigned>, type<int>, const T& t, const U& u) const noexcept { - return 0 < u && t < make_unsigned(u); - } -}; - -// version of std::greater<> which handles signed and unsigned integers correctly -struct safe_greater { - template <class T, class U> - bool operator()(const T& t, const U& u) const noexcept { - return safe_less()(u, t); - } -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/span.hpp b/ThirdParty/boost/histogram/detail/span.hpp deleted file mode 100644 index c0e70c806626f38b0b7005c63ca4e9bc85075b4d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/span.hpp +++ /dev/null @@ -1,274 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_SPAN_HPP -#define BOOST_HISTOGRAM_DETAIL_SPAN_HPP - -#ifdef __has_include -#if __has_include(<version>) -#include <version> -#ifdef __cpp_lib_span -#if __cpp_lib_span >= 201902 -#define BOOST_HISTOGRAM_DETAIL_HAS_STD_SPAN -#endif -#endif -#endif -#endif - -#ifdef BOOST_HISTOGRAM_DETAIL_HAS_STD_SPAN - -#include <span> - -namespace boost { -namespace histogram { -namespace detail { -using std::span; -} // namespace detail -} // namespace histogram -} // namespace boost - -#else // C++17 span not available, so we use our implementation - -// to be replaced by boost::span - -#include <array> -#include <boost/assert.hpp> -#include <boost/histogram/detail/non_member_container_access.hpp> -#include <initializer_list> -#include <iterator> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -namespace dtl = ::boost::histogram::detail; - -static constexpr std::size_t dynamic_extent = ~static_cast<std::size_t>(0); - -template <class T, std::size_t N> -class span_base { -public: - constexpr T* data() noexcept { return begin_; } - constexpr const T* data() const noexcept { return begin_; } - constexpr std::size_t size() const noexcept { return N; } - -protected: - constexpr span_base(T* b, std::size_t s) noexcept : begin_(b) { BOOST_ASSERT(N == s); } - constexpr void set(T* b, std::size_t s) noexcept { - begin_ = b; - BOOST_ASSERT(N == s); - } - -private: - T* begin_; -}; - -template <class T> -class span_base<T, dynamic_extent> { -public: - constexpr T* data() noexcept { return begin_; } - constexpr const T* data() const noexcept { return begin_; } - constexpr std::size_t size() const noexcept { return size_; } - -protected: - constexpr span_base(T* b, std::size_t s) noexcept : begin_(b), size_(s) {} - - constexpr void set(T* b, std::size_t s) noexcept { - begin_ = b; - size_ = s; - } - -private: - T* begin_; - std::size_t size_; -}; - -template <class T, std::size_t Extent = dynamic_extent> -class span : public span_base<T, Extent> { - using base = span_base<T, Extent>; - -public: - using element_type = T; - using value_type = std::remove_cv_t<T>; - using index_type = std::size_t; - using difference_type = std::ptrdiff_t; - using pointer = T*; - using const_pointer = const T*; - using reference = T&; - using const_reference = const T&; - using iterator = pointer; - using const_iterator = const_pointer; - using reverse_iterator = std::reverse_iterator<iterator>; - using const_reverse_iterator = std::reverse_iterator<const_iterator>; - - static constexpr std::size_t extent = Extent; - - template <std::size_t _ = extent, - class = std::enable_if_t<(_ == 0 || _ == dynamic_extent)> > - constexpr span() noexcept : base(nullptr, 0) {} - - constexpr span(pointer first, pointer last) - : span(first, static_cast<std::size_t>(last - first)) { - BOOST_ASSERT(extent == dynamic_extent || - static_cast<difference_type>(extent) == (last - first)); - } - - constexpr span(pointer ptr, index_type count) : base(ptr, count) {} - - template <std::size_t N> - constexpr span(element_type (&arr)[N]) noexcept : span(dtl::data(arr), N) { - static_assert(extent == dynamic_extent || extent == N, "static sizes do not match"); - } - - template <std::size_t N, - class = std::enable_if_t<(extent == dynamic_extent || extent == N)> > - constexpr span(std::array<value_type, N>& arr) noexcept : span(dtl::data(arr), N) {} - - template <std::size_t N, - class = std::enable_if_t<(extent == dynamic_extent || extent == N)> > - constexpr span(const std::array<value_type, N>& arr) noexcept - : span(dtl::data(arr), N) {} - - template <class Container, class = std::enable_if_t<std::is_convertible< - decltype(dtl::size(std::declval<Container>()), - dtl::data(std::declval<Container>())), - pointer>::value> > - constexpr span(const Container& cont) : span(dtl::data(cont), dtl::size(cont)) {} - - template <class Container, class = std::enable_if_t<std::is_convertible< - decltype(dtl::size(std::declval<Container>()), - dtl::data(std::declval<Container>())), - pointer>::value> > - constexpr span(Container& cont) : span(dtl::data(cont), dtl::size(cont)) {} - - template <class U, std::size_t N, - class = std::enable_if_t<((extent == dynamic_extent || extent == N) && - std::is_convertible<U, element_type>::value)> > - constexpr span(const span<U, N>& s) noexcept : span(s.data(), s.size()) {} - - template <class U, std::size_t N, - class = std::enable_if_t<((extent == dynamic_extent || extent == N) && - std::is_convertible<U, element_type>::value)> > - constexpr span(span<U, N>& s) noexcept : span(s.data(), s.size()) {} - - constexpr span(const span& other) noexcept = default; - - constexpr iterator begin() { return base::data(); } - constexpr const_iterator begin() const { return base::data(); } - constexpr const_iterator cbegin() const { return base::data(); } - - constexpr iterator end() { return base::data() + base::size(); } - constexpr const_iterator end() const { return base::data() + base::size(); } - constexpr const_iterator cend() const { return base::data() + base::size(); } - - reverse_iterator rbegin() { return reverse_iterator(end()); } - const_reverse_iterator rbegin() const { return reverse_iterator(end()); } - const_reverse_iterator crbegin() { return reverse_iterator(end()); } - - reverse_iterator rend() { return reverse_iterator(begin()); } - const_reverse_iterator rend() const { return reverse_iterator(begin()); } - const_reverse_iterator crend() { return reverse_iterator(begin()); } - - constexpr reference front() { *base::data(); } - constexpr reference back() { *(base::data() + base::size() - 1); } - - constexpr reference operator[](index_type idx) const { return base::data()[idx]; } - - constexpr std::size_t size_bytes() const noexcept { - return base::size() * sizeof(element_type); - } - - constexpr bool empty() const noexcept { return base::size() == 0; } - - template <std::size_t Count> - constexpr span<element_type, Count> first() const { - BOOST_ASSERT(Count <= base::size()); - return span<element_type, Count>(base::data(), Count); - } - - constexpr span<element_type, dynamic_extent> first(std::size_t count) const { - BOOST_ASSERT(count <= base::size()); - return span<element_type, dynamic_extent>(base::data(), count); - } - - template <std::size_t Count> - constexpr span<element_type, Count> last() const { - BOOST_ASSERT(Count <= base::size()); - return span<element_type, Count>(base::data() + base::size() - Count, Count); - } - - constexpr span<element_type, dynamic_extent> last(std::size_t count) const { - BOOST_ASSERT(count <= base::size()); - return span<element_type, dynamic_extent>(base::data() + base::size() - count, count); - } - - template <std::size_t Offset, std::size_t Count = dynamic_extent> - constexpr span<element_type, - (Count != dynamic_extent - ? Count - : (extent != dynamic_extent ? extent - Offset : dynamic_extent))> - subspan() const { - BOOST_ASSERT(Offset <= base::size()); - constexpr std::size_t E = - (Count != dynamic_extent - ? Count - : (extent != dynamic_extent ? extent - Offset : dynamic_extent)); - BOOST_ASSERT(E == dynamic_extent || E <= base::size()); - return span<element_type, E>(base::data() + Offset, - Count == dynamic_extent ? base::size() - Offset : Count); - } - - constexpr span<element_type, dynamic_extent> subspan( - std::size_t offset, std::size_t count = dynamic_extent) const { - BOOST_ASSERT(offset <= base::size()); - const std::size_t s = count == dynamic_extent ? base::size() - offset : count; - BOOST_ASSERT(s <= base::size()); - return span<element_type, dynamic_extent>(base::data() + offset, s); - } -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif - -#include <boost/histogram/detail/non_member_container_access.hpp> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -namespace dtl = ::boost::histogram::detail; - -template <class T> -auto make_span(T* begin, T* end) { - return dtl::span<T>{begin, end}; -} - -template <class T> -auto make_span(T* begin, std::size_t size) { - return dtl::span<T>{begin, size}; -} - -template <class Container, class = decltype(dtl::size(std::declval<Container>()), - dtl::data(std::declval<Container>()))> -auto make_span(const Container& cont) { - return make_span(dtl::data(cont), dtl::size(cont)); -} - -template <class T, std::size_t N> -auto make_span(T (&arr)[N]) { - return dtl::span<T, N>(arr, N); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/static_if.hpp b/ThirdParty/boost/histogram/detail/static_if.hpp deleted file mode 100644 index a7e8ba941576bb1a09b31d1368256410f86e27b2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/static_if.hpp +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2018-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_STATIC_IF_HPP -#define BOOST_HISTOGRAM_DETAIL_STATIC_IF_HPP - -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T, class F, class... Args> -constexpr decltype(auto) static_if_impl( - std::true_type, T&& t, F&&, - Args&&... args) noexcept(noexcept(std::declval<T>()(std::declval<Args>()...))) { - return std::forward<T>(t)(std::forward<Args>(args)...); -} - -template <class T, class F, class... Args> -constexpr decltype(auto) static_if_impl( - std::false_type, T&&, F&& f, - Args&&... args) noexcept(noexcept(std::declval<F>()(std::declval<Args>()...))) { - return std::forward<F>(f)(std::forward<Args>(args)...); -} - -template <bool B, class... Ts> -constexpr decltype(auto) static_if_c(Ts&&... ts) noexcept( - noexcept(static_if_impl(std::integral_constant<bool, B>{}, std::declval<Ts>()...))) { - return static_if_impl(std::integral_constant<bool, B>{}, std::forward<Ts>(ts)...); -} - -template <class Bool, class... Ts> -constexpr decltype(auto) static_if(Ts&&... ts) noexcept( - noexcept(static_if_impl(Bool{}, std::declval<Ts>()...))) { - return static_if_impl(Bool{}, std::forward<Ts>(ts)...); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/try_cast.hpp b/ThirdParty/boost/histogram/detail/try_cast.hpp deleted file mode 100644 index 1e8a7d27015203341185863a65d48ae095a7fb1b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/try_cast.hpp +++ /dev/null @@ -1,49 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_TRY_CAST_HPP -#define BOOST_HISTOGRAM_DETAIL_TRY_CAST_HPP - -#include <boost/config.hpp> -#include <boost/core/demangle.hpp> -#include <boost/histogram/detail/type_name.hpp> -#include <boost/mp11/integral.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <string> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { -template <class T, class E, class U> -BOOST_NORETURN T try_cast_impl(mp11::mp_int<0>, U&&) { - BOOST_THROW_EXCEPTION(E("cannot cast " + type_name<T>() + " to " + type_name<U>())); -} - -template <class T, class E, class U> -T try_cast_impl(mp11::mp_int<1>, U&& u) noexcept { - return static_cast<T>(u); -} - -template <class T, class E, class U> -decltype(auto) try_cast_impl(mp11::mp_int<2>, U&& u) noexcept { - return std::forward<U>(u); -} - -// cast fails at runtime with exception E instead of compile-time, T must be a value -template <class T, class E, class U> -decltype(auto) try_cast(U&& u) noexcept(std::is_convertible<U, T>::value) { - return try_cast_impl<T, E>(mp11::mp_int<(std::is_convertible<U, T>::value + - std::is_same<T, std::decay_t<U>>::value)>{}, - std::forward<U>(u)); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/tuple_slice.hpp b/ThirdParty/boost/histogram/detail/tuple_slice.hpp deleted file mode 100644 index a48a10598c1617e04f4ebc9ecb8efae1f04e8fbb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/tuple_slice.hpp +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_TUPLE_SLICE_HPP -#define BOOST_HISTOGRAM_DETAIL_TUPLE_SLICE_HPP - -#include <boost/mp11/integer_sequence.hpp> -#include <tuple> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <std::size_t I, class T, std::size_t... K> -decltype(auto) tuple_slice_impl(T&& t, mp11::index_sequence<K...>) { - return std::forward_as_tuple(std::get<(I + K)>(std::forward<T>(t))...); -} - -template <std::size_t I, std::size_t N, class Tuple> -decltype(auto) tuple_slice(Tuple&& t) { - constexpr auto S = std::tuple_size<std::decay_t<Tuple>>::value; - static_assert(I + N <= S, "I, N must be a valid subset"); - return tuple_slice_impl<I>(std::forward<Tuple>(t), mp11::make_index_sequence<N>{}); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/type_name.hpp b/ThirdParty/boost/histogram/detail/type_name.hpp deleted file mode 100644 index bea8f88a626f2048aaf7eb5d2042077dd2e418ee..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/type_name.hpp +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_TYPE_NAME_HPP -#define BOOST_HISTOGRAM_DETAIL_TYPE_NAME_HPP - -#include <boost/core/typeinfo.hpp> -#include <boost/type.hpp> -#include <string> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -std::string type_name_impl(boost::type<T>) { - return boost::core::demangled_name(BOOST_CORE_TYPEID(T)); -} - -template <class T> -std::string type_name_impl(boost::type<const T>) { - return type_name_impl(boost::type<T>{}) + " const"; -} - -template <class T> -std::string type_name_impl(boost::type<T&>) { - return type_name_impl(boost::type<T>{}) + " &"; -} - -template <class T> -std::string type_name_impl(boost::type<T&&>) { - return type_name_impl(boost::type<T>{}) + " &&"; -} - -template <class T> -std::string type_name() { - return type_name_impl(boost::type<T>{}); -} - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/detail/variant_proxy.hpp b/ThirdParty/boost/histogram/detail/variant_proxy.hpp deleted file mode 100644 index 6103a59ba6834e370816d7a603a43b4c158431d1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/detail/variant_proxy.hpp +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_DETAIL_VARIANT_PROXY_HPP -#define BOOST_HISTOGRAM_DETAIL_VARIANT_PROXY_HPP - -#include <boost/core/nvp.hpp> -#include <boost/histogram/axis/traits.hpp> // variant_access -#include <boost/histogram/detail/static_if.hpp> -#include <boost/mp11/algorithm.hpp> // mp_with_index, mp_find, mp_at -#include <boost/mp11/list.hpp> // mp_size -#include <boost/throw_exception.hpp> -#include <stdexcept> - -namespace boost { -namespace histogram { -namespace detail { - -// This is a workaround to remain backward compatible in the serialization format. The -// proxy uses only the public interface of axis::variant for serialization and works -// independently of the underlying variant implementation. -template <class Variant> -struct variant_proxy { - Variant& variant; - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - detail::static_if_c<Archive::is_loading::value>( - [this](auto& ar) { // loading - int which = 0; - ar >> make_nvp("which", which); - constexpr unsigned N = mp11::mp_size<Variant>::value; - if (which < 0 || static_cast<unsigned>(which) >= N) - // throw if which >= N, can happen if type was removed from variant - BOOST_THROW_EXCEPTION( - std::runtime_error("variant has fewer types than stored version")); - mp11::mp_with_index<N>(static_cast<unsigned>(which), [&ar, this](auto i) { - using T = mp11::mp_at_c<Variant, i>; - T value; - ar >> make_nvp("value", value); - this->variant = std::move(value); - T* new_address = variant_access::template get_if<T>(&this->variant); - ar.reset_object_address(new_address, &value); - }); - }, - [this](auto& ar) { // saving - visit( - [&ar](const auto& value) { - using T = std::decay_t<decltype(value)>; - const int which = static_cast<int>(mp11::mp_find<Variant, T>::value); - ar << make_nvp("which", which); - ar << make_nvp("value", value); - }, - this->variant); - }, - ar); - } -}; - -} // namespace detail -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/fwd.hpp b/ThirdParty/boost/histogram/fwd.hpp deleted file mode 100644 index 63e067dce6e07c01b0aaf2a15d4ecdcf07263834..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/fwd.hpp +++ /dev/null @@ -1,151 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_FWD_HPP -#define BOOST_HISTOGRAM_FWD_HPP - -/** - \file boost/histogram/fwd.hpp - Forward declarations, tag types and type aliases. -*/ - -#include <boost/config.hpp> // BOOST_ATTRIBUTE_NODISCARD -#include <boost/core/use_default.hpp> -#include <vector> - -namespace boost { -namespace histogram { - -/// Tag type to indicate use of a default type -using boost::use_default; - -namespace axis { - -/// Integral type for axis indices -using index_type = int; - -/// Real type for axis indices -using real_index_type = double; - -/// Empty metadata type -struct null_type { - template <class Archive> - void serialize(Archive&, unsigned /* version */) {} -}; - -/// Another alias for an empty metadata type -using empty_type = null_type; - -// some forward declarations must be hidden from doxygen to fix the reference docu :( -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -namespace transform { - -struct id; - -struct log; - -struct sqrt; - -struct pow; - -} // namespace transform - -template <class Value = double, class Transform = use_default, - class MetaData = use_default, class Options = use_default> -class regular; - -template <class Value = int, class MetaData = use_default, class Options = use_default> -class integer; - -template <class Value = double, class MetaData = use_default, class Options = use_default, - class Allocator = std::allocator<Value>> -class variable; - -template <class Value = int, class MetaData = use_default, class Options = use_default, - class Allocator = std::allocator<Value>> -class category; - -template <class... Ts> -class variant; - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -} // namespace axis - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -template <class T> -struct weight_type; - -template <class T> -struct sample_type; - -namespace accumulators { - -template <class ValueType = double> -class count; - -template <class ValueType = double> -class sum; - -template <class ValueType = double> -class weighted_sum; - -template <class ValueType = double> -class mean; - -template <class ValueType = double> -class weighted_mean; - -template <class T> -class thread_safe; - -template <class T> -struct is_thread_safe : std::false_type {}; -template <class T> -struct is_thread_safe<thread_safe<T>> : std::true_type {}; - -} // namespace accumulators - -struct unsafe_access; - -template <class Allocator = std::allocator<char>> -class unlimited_storage; - -template <class T> -class storage_adaptor; - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -/// Vector-like storage for fast zero-overhead access to cells. -template <class T, class A = std::allocator<T>> -using dense_storage = storage_adaptor<std::vector<T, A>>; - -/// Default storage, optimized for unweighted histograms -using default_storage = unlimited_storage<>; - -/// Dense storage which tracks sums of weights and a variance estimate. -using weight_storage = dense_storage<accumulators::weighted_sum<>>; - -/// Dense storage which tracks means of samples in each cell. -using profile_storage = dense_storage<accumulators::mean<>>; - -/// Dense storage which tracks means of weighted samples in each cell. -using weighted_profile_storage = dense_storage<accumulators::weighted_mean<>>; - -// some forward declarations must be hidden from doxygen to fix the reference docu :( -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -template <class Axes, class Storage = default_storage> -class BOOST_ATTRIBUTE_NODISCARD histogram; - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/histogram.hpp b/ThirdParty/boost/histogram/histogram.hpp deleted file mode 100644 index 19b5c260d2bf99848316adb5d411ce87cb5a5b13..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/histogram.hpp +++ /dev/null @@ -1,692 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_HISTOGRAM_HPP -#define BOOST_HISTOGRAM_HISTOGRAM_HPP - -#include <boost/histogram/detail/accumulator_traits.hpp> -#include <boost/histogram/detail/argument_traits.hpp> -#include <boost/histogram/detail/at.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/common_type.hpp> -#include <boost/histogram/detail/fill.hpp> -#include <boost/histogram/detail/fill_n.hpp> -#include <boost/histogram/detail/mutex_base.hpp> -#include <boost/histogram/detail/non_member_container_access.hpp> -#include <boost/histogram/detail/span.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/histogram/sample.hpp> -#include <boost/histogram/storage_adaptor.hpp> -#include <boost/histogram/unsafe_access.hpp> -#include <boost/histogram/weight.hpp> -#include <boost/mp11/integral.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/tuple.hpp> -#include <boost/throw_exception.hpp> -#include <mutex> -#include <stdexcept> -#include <tuple> -#include <type_traits> -#include <utility> -#include <vector> - -namespace boost { -namespace histogram { - -/** Central class of the histogram library. - - Histogram uses the call operator to insert data, like the - [Boost.Accumulators](https://www.boost.org/doc/libs/develop/doc/html/accumulators.html). - - Use factory functions (see - [make_histogram.hpp](histogram/reference.html#header.boost.histogram.make_histogram_hpp) - and - [make_profile.hpp](histogram/reference.html#header.boost.histogram.make_profile_hpp)) to - conveniently create histograms rather than calling the ctors directly. - - Use the [indexed](boost/histogram/indexed.html) range generator to iterate over filled - histograms, which is convenient and faster than hand-written loops for multi-dimensional - histograms. - - @tparam Axes std::tuple of axis types OR std::vector of an axis type or axis::variant - @tparam Storage class that implements the storage interface - */ -template <class Axes, class Storage> -class histogram : detail::mutex_base<Axes, Storage> { - static_assert(std::is_same<std::decay_t<Storage>, Storage>::value, - "Storage may not be a reference or const or volatile"); - static_assert(mp11::mp_size<Axes>::value > 0, "at least one axis required"); - -public: - using axes_type = Axes; - using storage_type = Storage; - using value_type = typename storage_type::value_type; - // typedefs for boost::range_iterator - using iterator = typename storage_type::iterator; - using const_iterator = typename storage_type::const_iterator; - -private: - using mutex_base = typename detail::mutex_base<axes_type, storage_type>; - -public: - histogram() = default; - - template <class A, class S> - explicit histogram(histogram<A, S>&& rhs) - : storage_(std::move(unsafe_access::storage(rhs))) - , offset_(unsafe_access::offset(rhs)) { - detail::axes_assign(axes_, std::move(unsafe_access::axes(rhs))); - detail::throw_if_axes_is_too_large(axes_); - } - - template <class A, class S> - explicit histogram(const histogram<A, S>& rhs) - : storage_(unsafe_access::storage(rhs)), offset_(unsafe_access::offset(rhs)) { - detail::axes_assign(axes_, unsafe_access::axes(rhs)); - detail::throw_if_axes_is_too_large(axes_); - } - - template <class A, class S> - histogram& operator=(histogram<A, S>&& rhs) { - detail::axes_assign(axes_, std::move(unsafe_access::axes(rhs))); - detail::throw_if_axes_is_too_large(axes_); - storage_ = std::move(unsafe_access::storage(rhs)); - offset_ = unsafe_access::offset(rhs); - return *this; - } - - template <class A, class S> - histogram& operator=(const histogram<A, S>& rhs) { - detail::axes_assign(axes_, unsafe_access::axes(rhs)); - detail::throw_if_axes_is_too_large(axes_); - storage_ = unsafe_access::storage(rhs); - offset_ = unsafe_access::offset(rhs); - return *this; - } - - template <class A, class = detail::requires_axes<A>> - histogram(A&& a, Storage s) - : axes_(std::forward<A>(a)) - , storage_(std::move(s)) - , offset_(detail::offset(axes_)) { - detail::throw_if_axes_is_too_large(axes_); - storage_.reset(detail::bincount(axes_)); - } - - explicit histogram(Axes axes) : histogram(axes, storage_type()) {} - - template <class... As, class = detail::requires_axes<std::tuple<std::decay_t<As>...>>> - explicit histogram(As&&... as) - : histogram(std::tuple<std::decay_t<As>...>(std::forward<As>(as)...), - storage_type()) {} - - /// Number of axes (dimensions). - constexpr unsigned rank() const noexcept { return detail::axes_rank(axes_); } - - /// Total number of bins (including underflow/overflow). - std::size_t size() const noexcept { return storage_.size(); } - - /// Reset all bins to default initialized values. - void reset() { storage_.reset(size()); } - - /// Get N-th axis using a compile-time number. - /// This version is more efficient than the one accepting a run-time number. - template <unsigned N = 0> - decltype(auto) axis(std::integral_constant<unsigned, N> = {}) const { - detail::axis_index_is_valid(axes_, N); - return detail::axis_get<N>(axes_); - } - - /// Get N-th axis with run-time number. - /// Prefer the version that accepts a compile-time number, if you can use it. - decltype(auto) axis(unsigned i) const { - detail::axis_index_is_valid(axes_, i); - return detail::axis_get(axes_, i); - } - - /// Apply unary functor/function to each axis. - template <class Unary> - auto for_each_axis(Unary&& unary) const { - return detail::for_each_axis(axes_, std::forward<Unary>(unary)); - } - - /** Fill histogram with values, an optional weight, and/or a sample. - - Returns iterator to located cell. - - Arguments are passed in order to the axis objects. Passing an argument type that is - not convertible to the value type accepted by the axis or passing the wrong number - of arguments causes a throw of `std::invalid_argument`. - - __Optional weight__ - - An optional weight can be passed as the first or last argument - with the [weight](boost/histogram/weight.html) helper function. Compilation fails if - the storage elements do not support weights. - - __Samples__ - - If the storage elements accept samples, pass them with the sample helper function - in addition to the axis arguments, which can be the first or last argument. The - [sample](boost/histogram/sample.html) helper function can pass one or more arguments - to the storage element. If samples and weights are used together, they can be passed - in any order at the beginning or end of the argument list. - - __Axis with multiple arguments__ - - If the histogram contains an axis which accepts a `std::tuple` of arguments, the - arguments for that axis need to be passed as a `std::tuple`, for example, - `std::make_tuple(1.2, 2.3)`. If the histogram contains only this axis and no other, - the arguments can be passed directly. - */ - template <class T0, class... Ts, - class = std::enable_if_t<(detail::is_tuple<T0>::value == false || - sizeof...(Ts) > 0)>> - iterator operator()(const T0& arg0, const Ts&... args) { - return operator()(std::forward_as_tuple(arg0, args...)); - } - - /// Fill histogram with values, an optional weight, and/or a sample from a `std::tuple`. - template <class... Ts> - iterator operator()(const std::tuple<Ts...>& args) { - using arg_traits = detail::argument_traits<std::decay_t<Ts>...>; - using acc_traits = detail::accumulator_traits<value_type>; - constexpr bool weight_valid = - arg_traits::wpos::value == -1 || acc_traits::weight_support; - static_assert(weight_valid, "error: accumulator does not support weights"); - detail::sample_args_passed_vs_expected<typename arg_traits::sargs, - typename acc_traits::args>(); - constexpr bool sample_valid = - std::is_convertible<typename arg_traits::sargs, typename acc_traits::args>::value; - std::lock_guard<typename mutex_base::type> guard{mutex_base::get()}; - return detail::fill(mp11::mp_bool<(weight_valid && sample_valid)>{}, arg_traits{}, - offset_, storage_, axes_, args); - } - - /** Fill histogram with several values at once. - - The argument must be an iterable with a size that matches the - rank of the histogram. The element of an iterable may be 1) a value or 2) an iterable - with contiguous storage over values or 3) a variant of 1) and 2). Sub-iterables must - have the same length. - - Values are passed to the corresponding histogram axis in order. If a single value is - passed together with an iterable of values, the single value is treated like an - iterable with matching length of copies of this value. - - If the histogram has only one axis, an iterable of values may be passed directly. - - @param args iterable as explained in the long description. - */ - template <class Iterable, class = detail::requires_iterable<Iterable>> - void fill(const Iterable& args) { - using acc_traits = detail::accumulator_traits<value_type>; - constexpr unsigned n_sample_args_expected = - std::tuple_size<typename acc_traits::args>::value; - static_assert(n_sample_args_expected == 0, - "sample argument is missing but required by accumulator"); - std::lock_guard<typename mutex_base::type> guard{mutex_base::get()}; - detail::fill_n(mp11::mp_bool<(n_sample_args_expected == 0)>{}, offset_, storage_, - axes_, detail::make_span(args)); - } - - /** Fill histogram with several values and weights at once. - - @param args iterable of values. - @param weights single weight or an iterable of weights. - */ - template <class Iterable, class T, class = detail::requires_iterable<Iterable>> - void fill(const Iterable& args, const weight_type<T>& weights) { - using acc_traits = detail::accumulator_traits<value_type>; - constexpr bool weight_valid = acc_traits::weight_support; - static_assert(weight_valid, "error: accumulator does not support weights"); - detail::sample_args_passed_vs_expected<std::tuple<>, typename acc_traits::args>(); - constexpr bool sample_valid = - std::is_convertible<std::tuple<>, typename acc_traits::args>::value; - std::lock_guard<typename mutex_base::type> guard{mutex_base::get()}; - detail::fill_n(mp11::mp_bool<(weight_valid && sample_valid)>{}, offset_, storage_, - axes_, detail::make_span(args), - weight(detail::to_ptr_size(weights.value))); - } - - /** Fill histogram with several values and weights at once. - - @param weights single weight or an iterable of weights. - @param args iterable of values. - */ - template <class Iterable, class T, class = detail::requires_iterable<Iterable>> - void fill(const weight_type<T>& weights, const Iterable& args) { - fill(args, weights); - } - - /** Fill histogram with several values and samples at once. - - @param args iterable of values. - @param samples single sample or an iterable of samples. - */ - template <class Iterable, class... Ts, class = detail::requires_iterable<Iterable>> - void fill(const Iterable& args, const sample_type<std::tuple<Ts...>>& samples) { - using acc_traits = detail::accumulator_traits<value_type>; - using sample_args_passed = - std::tuple<decltype(*detail::to_ptr_size(std::declval<Ts>()).first)...>; - detail::sample_args_passed_vs_expected<sample_args_passed, - typename acc_traits::args>(); - std::lock_guard<typename mutex_base::type> guard{mutex_base::get()}; - mp11::tuple_apply( - [&](const auto&... sargs) { - constexpr bool sample_valid = - std::is_convertible<sample_args_passed, typename acc_traits::args>::value; - detail::fill_n(mp11::mp_bool<(sample_valid)>{}, offset_, storage_, axes_, - detail::make_span(args), detail::to_ptr_size(sargs)...); - }, - samples.value); - } - - /** Fill histogram with several values and samples at once. - - @param samples single sample or an iterable of samples. - @param args iterable of values. - */ - template <class Iterable, class T, class = detail::requires_iterable<Iterable>> - void fill(const sample_type<T>& samples, const Iterable& args) { - fill(args, samples); - } - - template <class Iterable, class T, class... Ts, - class = detail::requires_iterable<Iterable>> - void fill(const Iterable& args, const weight_type<T>& weights, - const sample_type<std::tuple<Ts...>>& samples) { - using acc_traits = detail::accumulator_traits<value_type>; - using sample_args_passed = - std::tuple<decltype(*detail::to_ptr_size(std::declval<Ts>()).first)...>; - detail::sample_args_passed_vs_expected<sample_args_passed, - typename acc_traits::args>(); - std::lock_guard<typename mutex_base::type> guard{mutex_base::get()}; - mp11::tuple_apply( - [&](const auto&... sargs) { - constexpr bool weight_valid = acc_traits::weight_support; - static_assert(weight_valid, "error: accumulator does not support weights"); - constexpr bool sample_valid = - std::is_convertible<sample_args_passed, typename acc_traits::args>::value; - detail::fill_n(mp11::mp_bool<(weight_valid && sample_valid)>{}, offset_, - storage_, axes_, detail::make_span(args), - weight(detail::to_ptr_size(weights.value)), - detail::to_ptr_size(sargs)...); - }, - samples.value); - } - - template <class Iterable, class T, class U, class = detail::requires_iterable<Iterable>> - void fill(const sample_type<T>& samples, const weight_type<U>& weights, - const Iterable& args) { - fill(args, weights, samples); - } - - template <class Iterable, class T, class U, class = detail::requires_iterable<Iterable>> - void fill(const weight_type<T>& weights, const sample_type<U>& samples, - const Iterable& args) { - fill(args, weights, samples); - } - - template <class Iterable, class T, class U, class = detail::requires_iterable<Iterable>> - void fill(const Iterable& args, const sample_type<T>& samples, - const weight_type<U>& weights) { - fill(args, weights, samples); - } - - /** Access cell value at integral indices. - - You can pass indices as individual arguments, as a std::tuple of integers, or as an - interable range of integers. Passing the wrong number of arguments causes a throw of - std::invalid_argument. Passing an index which is out of bounds causes a throw of - std::out_of_range. - - @param i index of first axis. - @param is indices of second, third, ... axes. - @returns reference to cell value. - */ - template <class... Indices> - decltype(auto) at(axis::index_type i, Indices... is) { - return at(std::forward_as_tuple(i, is...)); - } - - /// Access cell value at integral indices (read-only). - template <class... Indices> - decltype(auto) at(axis::index_type i, Indices... is) const { - return at(std::forward_as_tuple(i, is...)); - } - - /// Access cell value at integral indices stored in `std::tuple`. - template <class... Indices> - decltype(auto) at(const std::tuple<Indices...>& is) { - if (rank() != sizeof...(Indices)) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments != histogram rank")); - const auto idx = detail::at(axes_, is); - if (!is_valid(idx)) - BOOST_THROW_EXCEPTION(std::out_of_range("at least one index out of bounds")); - BOOST_ASSERT(idx < storage_.size()); - return storage_[idx]; - } - - /// Access cell value at integral indices stored in `std::tuple` (read-only). - template <class... Indices> - decltype(auto) at(const std::tuple<Indices...>& is) const { - if (rank() != sizeof...(Indices)) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments != histogram rank")); - const auto idx = detail::at(axes_, is); - if (!is_valid(idx)) - BOOST_THROW_EXCEPTION(std::out_of_range("at least one index out of bounds")); - BOOST_ASSERT(idx < storage_.size()); - return storage_[idx]; - } - - /// Access cell value at integral indices stored in iterable. - template <class Iterable, class = detail::requires_iterable<Iterable>> - decltype(auto) at(const Iterable& is) { - if (rank() != detail::axes_rank(is)) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments != histogram rank")); - const auto idx = detail::at(axes_, is); - if (!is_valid(idx)) - BOOST_THROW_EXCEPTION(std::out_of_range("at least one index out of bounds")); - BOOST_ASSERT(idx < storage_.size()); - return storage_[idx]; - } - - /// Access cell value at integral indices stored in iterable (read-only). - template <class Iterable, class = detail::requires_iterable<Iterable>> - decltype(auto) at(const Iterable& is) const { - if (rank() != detail::axes_rank(is)) - BOOST_THROW_EXCEPTION( - std::invalid_argument("number of arguments != histogram rank")); - const auto idx = detail::at(axes_, is); - if (!is_valid(idx)) - BOOST_THROW_EXCEPTION(std::out_of_range("at least one index out of bounds")); - BOOST_ASSERT(idx < storage_.size()); - return storage_[idx]; - } - - /// Access value at index (number for rank = 1, else `std::tuple` or iterable). - template <class Indices> - decltype(auto) operator[](const Indices& is) { - return at(is); - } - - /// Access value at index (read-only). - template <class Indices> - decltype(auto) operator[](const Indices& is) const { - return at(is); - } - - /// Equality operator, tests equality for all axes and the storage. - template <class A, class S> - bool operator==(const histogram<A, S>& rhs) const noexcept { - // testing offset is redundant, but offers fast return if it fails - return offset_ == unsafe_access::offset(rhs) && - detail::axes_equal(axes_, unsafe_access::axes(rhs)) && - storage_ == unsafe_access::storage(rhs); - } - - /// Negation of the equality operator. - template <class A, class S> - bool operator!=(const histogram<A, S>& rhs) const noexcept { - return !operator==(rhs); - } - - /** Add values of another histogram. - - This operator is only available if the value_type supports operator+=. - */ - template <class A, class S> -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - std::enable_if_t< - detail::has_operator_radd<value_type, typename histogram<A, S>::value_type>::value, - histogram&> -#endif - operator+=(const histogram<A, S>& rhs) { - if (!detail::axes_equal(axes_, unsafe_access::axes(rhs))) - BOOST_THROW_EXCEPTION(std::invalid_argument("axes of histograms differ")); - auto rit = unsafe_access::storage(rhs).begin(); - for (auto&& x : storage_) x += *rit++; - return *this; - } - - /** Subtract values of another histogram. - - This operator is only available if the value_type supports operator-=. - */ - template <class A, class S> -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - std::enable_if_t< - detail::has_operator_rsub<value_type, typename histogram<A, S>::value_type>::value, - histogram&> -#endif - operator-=(const histogram<A, S>& rhs) { - if (!detail::axes_equal(axes_, unsafe_access::axes(rhs))) - BOOST_THROW_EXCEPTION(std::invalid_argument("axes of histograms differ")); - auto rit = unsafe_access::storage(rhs).begin(); - for (auto&& x : storage_) x -= *rit++; - return *this; - } - - /** Multiply by values of another histogram. - - This operator is only available if the value_type supports operator*=. - */ - template <class A, class S> -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - std::enable_if_t< - detail::has_operator_rmul<value_type, typename histogram<A, S>::value_type>::value, - histogram&> -#endif - operator*=(const histogram<A, S>& rhs) { - if (!detail::axes_equal(axes_, unsafe_access::axes(rhs))) - BOOST_THROW_EXCEPTION(std::invalid_argument("axes of histograms differ")); - auto rit = unsafe_access::storage(rhs).begin(); - for (auto&& x : storage_) x *= *rit++; - return *this; - } - - /** Divide by values of another histogram. - - This operator is only available if the value_type supports operator/=. - */ - template <class A, class S> -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - std::enable_if_t< - detail::has_operator_rdiv<value_type, typename histogram<A, S>::value_type>::value, - histogram&> -#endif - operator/=(const histogram<A, S>& rhs) { - if (!detail::axes_equal(axes_, unsafe_access::axes(rhs))) - BOOST_THROW_EXCEPTION(std::invalid_argument("axes of histograms differ")); - auto rit = unsafe_access::storage(rhs).begin(); - for (auto&& x : storage_) x /= *rit++; - return *this; - } - - /** Multiply all values with a scalar. - - This operator is only available if the value_type supports operator*=. - */ -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - template <class V = value_type> - std::enable_if_t<(detail::has_operator_rmul<V, double>::value), histogram&> -#endif - operator*=(const double x) { - // use special storage implementation of scaling if available, - // else fallback to scaling item by item - detail::static_if<detail::has_operator_rmul<storage_type, double>>( - [x](auto& s) { s *= x; }, - [x](auto& s) { - for (auto&& si : s) si *= x; - }, - storage_); - return *this; - } - - /** Divide all values by a scalar. - - This operator is only available if operator*= is available. - */ -#ifdef BOOST_HISTOGRAM_DOXYGEN_INVOKED - histogram& -#else - template <class H = histogram> - std::enable_if_t<(detail::has_operator_rmul<H, double>::value), histogram&> -#endif - operator/=(const double x) { - return operator*=(1.0 / x); - } - - /// Return value iterator to the beginning of the histogram. - iterator begin() noexcept { return storage_.begin(); } - - /// Return value iterator to the end in the histogram. - iterator end() noexcept { return storage_.end(); } - - /// Return value iterator to the beginning of the histogram (read-only). - const_iterator begin() const noexcept { return storage_.begin(); } - - /// Return value iterator to the end in the histogram (read-only). - const_iterator end() const noexcept { return storage_.end(); } - - /// Return value iterator to the beginning of the histogram (read-only). - const_iterator cbegin() const noexcept { return begin(); } - - /// Return value iterator to the end in the histogram (read-only). - const_iterator cend() const noexcept { return end(); } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - detail::axes_serialize(ar, axes_); - ar& make_nvp("storage", storage_); - if (Archive::is_loading::value) { - offset_ = detail::offset(axes_); - detail::throw_if_axes_is_too_large(axes_); - } - } - -private: - axes_type axes_; - storage_type storage_; - std::size_t offset_ = 0; - - friend struct unsafe_access; -}; - -/** - Pairwise add cells of two histograms and return histogram with the sum. - - The returned histogram type is the most efficient and safest one constructible from the - inputs, if they are not the same type. If one histogram has a tuple axis, the result has - a tuple axis. The chosen storage is the one with the larger dynamic range. -*/ -template <class A1, class S1, class A2, class S2> -auto operator+(const histogram<A1, S1>& a, const histogram<A2, S2>& b) { - auto r = histogram<detail::common_axes<A1, A2>, detail::common_storage<S1, S2>>(a); - return r += b; -} - -/** Pairwise multiply cells of two histograms and return histogram with the product. - - For notes on the returned histogram type, see operator+. -*/ -template <class A1, class S1, class A2, class S2> -auto operator*(const histogram<A1, S1>& a, const histogram<A2, S2>& b) { - auto r = histogram<detail::common_axes<A1, A2>, detail::common_storage<S1, S2>>(a); - return r *= b; -} - -/** Pairwise subtract cells of two histograms and return histogram with the difference. - - For notes on the returned histogram type, see operator+. -*/ -template <class A1, class S1, class A2, class S2> -auto operator-(const histogram<A1, S1>& a, const histogram<A2, S2>& b) { - auto r = histogram<detail::common_axes<A1, A2>, detail::common_storage<S1, S2>>(a); - return r -= b; -} - -/** Pairwise divide cells of two histograms and return histogram with the quotient. - - For notes on the returned histogram type, see operator+. -*/ -template <class A1, class S1, class A2, class S2> -auto operator/(const histogram<A1, S1>& a, const histogram<A2, S2>& b) { - auto r = histogram<detail::common_axes<A1, A2>, detail::common_storage<S1, S2>>(a); - return r /= b; -} - -/** Multiply all cells of the histogram by a number and return a new histogram. - - If the original histogram has integer cells, the result has double cells. -*/ -template <class A, class S> -auto operator*(const histogram<A, S>& h, double x) { - auto r = histogram<A, detail::common_storage<S, dense_storage<double>>>(h); - return r *= x; -} - -/** Multiply all cells of the histogram by a number and return a new histogram. - - If the original histogram has integer cells, the result has double cells. -*/ -template <class A, class S> -auto operator*(double x, const histogram<A, S>& h) { - return h * x; -} - -/** Divide all cells of the histogram by a number and return a new histogram. - - If the original histogram has integer cells, the result has double cells. -*/ -template <class A, class S> -auto operator/(const histogram<A, S>& h, double x) { - return h * (1.0 / x); -} - -#if __cpp_deduction_guides >= 201606 - -template <class... Axes, class = detail::requires_axes<std::tuple<std::decay_t<Axes>...>>> -histogram(Axes...)->histogram<std::tuple<std::decay_t<Axes>...>>; - -template <class... Axes, class S, class = detail::requires_storage_or_adaptible<S>> -histogram(std::tuple<Axes...>, S) - ->histogram<std::tuple<Axes...>, std::conditional_t<detail::is_adaptible<S>::value, - storage_adaptor<S>, S>>; - -template <class Iterable, class = detail::requires_iterable<Iterable>, - class = detail::requires_any_axis<typename Iterable::value_type>> -histogram(Iterable)->histogram<std::vector<typename Iterable::value_type>>; - -template <class Iterable, class S, class = detail::requires_iterable<Iterable>, - class = detail::requires_any_axis<typename Iterable::value_type>, - class = detail::requires_storage_or_adaptible<S>> -histogram(Iterable, S) - ->histogram< - std::vector<typename Iterable::value_type>, - std::conditional_t<detail::is_adaptible<S>::value, storage_adaptor<S>, S>>; - -#endif - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/indexed.hpp b/ThirdParty/boost/histogram/indexed.hpp deleted file mode 100644 index 5d95b616ad0fc847c3537f829931dd2df04ae64b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/indexed.hpp +++ /dev/null @@ -1,372 +0,0 @@ -// Copyright 2015-2016 Hans Dembinski -// -// 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_HISTOGRAM_INDEXED_HPP -#define BOOST_HISTOGRAM_INDEXED_HPP - -#include <array> -#include <boost/config.hpp> -#include <boost/histogram/axis/traits.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/iterator_adaptor.hpp> -#include <boost/histogram/detail/operators.hpp> -#include <boost/histogram/fwd.hpp> -#include <iterator> -#include <type_traits> -#include <utility> - -namespace boost { -namespace histogram { - -/** Coverage mode of the indexed range generator. - - Defines options for the iteration strategy. -*/ -enum class coverage { - inner, /*!< iterate over inner bins, exclude underflow and overflow */ - all, /*!< iterate over all bins, including underflow and overflow */ -}; - -/** Input iterator range over histogram bins with multi-dimensional index. - - The iterator returned by begin() can only be incremented. begin() may only be called - once, calling it a second time returns the end() iterator. If several copies of the - input iterators exist, the other copies become invalid if one of them is incremented. -*/ -template <class Histogram> -class BOOST_ATTRIBUTE_NODISCARD indexed_range { -private: - using histogram_type = Histogram; - static constexpr std::size_t buffer_size = - detail::buffer_size<typename std::remove_const_t<histogram_type>::axes_type>::value; - -public: - using value_iterator = std::conditional_t<std::is_const<histogram_type>::value, - typename histogram_type::const_iterator, - typename histogram_type::iterator>; - using value_reference = typename std::iterator_traits<value_iterator>::reference; - using value_type = typename std::iterator_traits<value_iterator>::value_type; - - class iterator; - using range_iterator [[deprecated("use iterator instead")]] = iterator; ///< deprecated - - /** Lightweight view to access value and index of current cell. - - The methods provide access to the current cell indices and bins. It acts like a - pointer to the cell value, and in a limited way also like a reference. To interoperate - with the algorithms of the standard library, the accessor is implicitly convertible to - a cell value. Assignments and comparisons are passed through to the cell. An accessor - is coupled to its parent indexed_range::iterator. Moving the parent iterator - forward also updates the linked accessor. Accessors are not copyable. They cannot be - stored in containers, but indexed_range::iterator can be stored. - */ - class BOOST_ATTRIBUTE_NODISCARD accessor : detail::mirrored<accessor, void> { - public: - /// Array-like view into the current multi-dimensional index. - class index_view { - using index_pointer = const typename iterator::index_data*; - - public: - using const_reference = const axis::index_type&; - using reference [[deprecated("use const_reference instead")]] = - const_reference; ///< deprecated - - /// implementation detail - class const_iterator - : public detail::iterator_adaptor<const_iterator, index_pointer, - const_reference> { - public: - const_reference operator*() const noexcept { return const_iterator::base()->idx; } - - private: - explicit const_iterator(index_pointer i) noexcept - : const_iterator::iterator_adaptor_(i) {} - - friend class index_view; - }; - - const_iterator begin() const noexcept { return const_iterator{begin_}; } - const_iterator end() const noexcept { return const_iterator{end_}; } - std::size_t size() const noexcept { - return static_cast<std::size_t>(end_ - begin_); - } - const_reference operator[](unsigned d) const noexcept { return begin_[d].idx; } - const_reference at(unsigned d) const { return begin_[d].idx; } - - private: - /// implementation detail - index_view(index_pointer b, index_pointer e) : begin_(b), end_(e) {} - - index_pointer begin_, end_; - friend class accessor; - }; - - // assignment is pass-through - accessor& operator=(const accessor& o) { - get() = o.get(); - return *this; - } - - // assignment is pass-through - template <class T> - accessor& operator=(const T& x) { - get() = x; - return *this; - } - - /// Returns the cell reference. - value_reference get() const noexcept { return *(iter_.iter_); } - /// @copydoc get() - value_reference operator*() const noexcept { return get(); } - /// Access fields and methods of the cell object. - value_iterator operator->() const noexcept { return iter_.iter_; } - - /// Access current index. - /// @param d axis dimension. - axis::index_type index(unsigned d = 0) const noexcept { - return iter_.indices_[d].idx; - } - - /// Access indices as an iterable range. - index_view indices() const noexcept { - BOOST_ASSERT(iter_.indices_.hist_); - return {iter_.indices_.begin(), iter_.indices_.end()}; - } - - /// Access current bin. - /// @tparam N axis dimension. - template <unsigned N = 0> - decltype(auto) bin(std::integral_constant<unsigned, N> = {}) const { - BOOST_ASSERT(iter_.indices_.hist_); - return iter_.indices_.hist_->axis(std::integral_constant<unsigned, N>()) - .bin(index(N)); - } - - /// Access current bin. - /// @param d axis dimension. - decltype(auto) bin(unsigned d) const { - BOOST_ASSERT(iter_.indices_.hist_); - return iter_.indices_.hist_->axis(d).bin(index(d)); - } - - /** Computes density in current cell. - - The density is computed as the cell value divided by the product of bin widths. Axes - without bin widths, like axis::category, are treated as having unit bin with. - */ - double density() const { - BOOST_ASSERT(iter_.indices_.hist_); - double x = 1; - unsigned d = 0; - iter_.indices_.hist_->for_each_axis([&](const auto& a) { - const auto w = axis::traits::width_as<double>(a, this->index(d++)); - x *= w ? w : 1; - }); - return get() / x; - } - - // forward all comparison operators to the value - bool operator<(const accessor& o) noexcept { return get() < o.get(); } - bool operator>(const accessor& o) noexcept { return get() > o.get(); } - bool operator==(const accessor& o) noexcept { return get() == o.get(); } - bool operator!=(const accessor& o) noexcept { return get() != o.get(); } - bool operator<=(const accessor& o) noexcept { return get() <= o.get(); } - bool operator>=(const accessor& o) noexcept { return get() >= o.get(); } - - template <class U> - bool operator<(const U& o) const noexcept { - return get() < o; - } - - template <class U> - bool operator>(const U& o) const noexcept { - return get() > o; - } - - template <class U> - bool operator==(const U& o) const noexcept { - return get() == o; - } - - template <class U> - bool operator!=(const U& o) const noexcept { - return get() != o; - } - - template <class U> - bool operator<=(const U& o) const noexcept { - return get() <= o; - } - - template <class U> - bool operator>=(const U& o) const noexcept { - return get() >= o; - } - - operator value_type() const noexcept { return get(); } - - private: - accessor(iterator& i) noexcept : iter_(i) {} - - accessor(const accessor&) = default; // only callable by indexed_range::iterator - - iterator& iter_; - - friend class iterator; - }; - - /// implementation detail - class iterator { - public: - using value_type = typename indexed_range::value_type; - using reference = accessor; - - private: - struct pointer_proxy { - reference* operator->() noexcept { return std::addressof(ref_); } - reference ref_; - }; - - public: - using pointer = pointer_proxy; - using difference_type = std::ptrdiff_t; - using iterator_category = std::forward_iterator_tag; - - reference operator*() noexcept { return *this; } - pointer operator->() noexcept { return pointer_proxy{operator*()}; } - - iterator& operator++() { - BOOST_ASSERT(iter_ < indices_.hist_->end()); - const auto cbeg = indices_.begin(); - auto c = cbeg; - ++iter_; - ++c->idx; - if (c->idx < c->end) return *this; - while (c->idx == c->end) { - iter_ += c->end_skip; - if (++c == indices_.end()) return *this; - ++c->idx; - } - while (c-- != cbeg) { - c->idx = c->begin; - iter_ += c->begin_skip; - } - return *this; - } - - iterator operator++(int) { - auto prev = *this; - operator++(); - return prev; - } - - bool operator==(const iterator& x) const noexcept { return iter_ == x.iter_; } - bool operator!=(const iterator& x) const noexcept { return !operator==(x); } - - // make iterator ready for C++17 sentinels - bool operator==(const value_iterator& x) const noexcept { return iter_ == x; } - bool operator!=(const value_iterator& x) const noexcept { return !operator==(x); } - - // useful for iterator debugging - std::size_t offset() const noexcept { return iter_ - indices_.hist_->begin(); } - - private: - iterator(value_iterator i, histogram_type& h) : iter_(i), indices_(&h) {} - - value_iterator iter_; - - struct index_data { - axis::index_type idx, begin, end; - std::size_t begin_skip, end_skip; - }; - - struct indices_t : private std::array<index_data, buffer_size> { - using base_type = std::array<index_data, buffer_size>; - using pointer = index_data*; - using const_pointer = const index_data*; - - indices_t(histogram_type* h) noexcept : hist_{h} {} - - using base_type::operator[]; - unsigned size() const noexcept { return hist_->rank(); } - pointer begin() noexcept { return base_type::data(); } - const_pointer begin() const noexcept { return base_type::data(); } - pointer end() noexcept { return begin() + size(); } - const_pointer end() const noexcept { return begin() + size(); } - - histogram_type* hist_; - } indices_; - - friend class indexed_range; - }; - - indexed_range(histogram_type& hist, coverage cov) - : begin_(hist.begin(), hist), end_(hist.end(), hist) { - begin_.indices_.hist_->for_each_axis([ca = begin_.indices_.begin(), cov, - stride = std::size_t{1}, - this](const auto& a) mutable { - using opt = axis::traits::get_options<std::decay_t<decltype(a)>>; - constexpr axis::index_type under = opt::test(axis::option::underflow); - constexpr axis::index_type over = opt::test(axis::option::overflow); - const auto size = a.size(); - - // -1 if underflow and cover all, else 0 - ca->begin = cov == coverage::all ? -under : 0; - // size + 1 if overflow and cover all, else size - ca->end = cov == coverage::all ? size + over : size; - ca->idx = ca->begin; - - // if axis has *flow and coverage::all OR axis has no *flow: - // begin + under == 0, size + over - end == 0 - // if axis has *flow and coverage::inner: - // begin + under == 1, size + over - end == 1 - ca->begin_skip = static_cast<std::size_t>(ca->begin + under) * stride; - ca->end_skip = static_cast<std::size_t>(size + over - ca->end) * stride; - begin_.iter_ += ca->begin_skip; - - stride *= size + under + over; - ++ca; - }); - } - - iterator begin() noexcept { return begin_; } - iterator end() noexcept { return end_; } - -private: - iterator begin_, end_; -}; - -/** Generates an indexed range of <a - href="https://en.cppreference.com/w/cpp/named_req/ForwardIterator">forward iterators</a> - over the histogram cells. - - Use this in a range-based for loop: - - ``` - for (auto&& x : indexed(hist)) { ... } - ``` - - This generates an optimized loop which is nearly always faster than a hand-written loop - over the histogram cells. The iterators dereference to an indexed_range::accessor, which - has methods to query the current indices and bins and acts like a pointer to the cell - value. The returned iterators are forward iterators. They can be stored in a container, - but may not be used after the life-time of the histogram ends. - - @returns indexed_range - - @param hist Reference to the histogram. - @param cov Iterate over all or only inner bins (optional, default: inner). - */ -template <class Histogram> -auto indexed(Histogram&& hist, coverage cov = coverage::inner) { - return indexed_range<std::remove_reference_t<Histogram>>{std::forward<Histogram>(hist), - cov}; -} - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/literals.hpp b/ThirdParty/boost/histogram/literals.hpp deleted file mode 100644 index b5d45967956f08c746f43fcf01d19fa5fc5bd288..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/literals.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2015-2017 Hans Dembinski -// -// 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_HISTOGRAM_LITERALS_HPP -#define BOOST_HISTOGRAM_LITERALS_HPP - -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { -constexpr unsigned parse_number(unsigned n) { return n; } - -template <class... Rest> -constexpr unsigned parse_number(unsigned n, char f, Rest... rest) { - return parse_number(10u * n + static_cast<unsigned>(f - '0'), rest...); -} -} // namespace detail - -namespace literals { -/// Suffix operator to generate literal compile-time numbers, 0_c, 12_c, etc. -template <char... digits> -auto operator"" _c() { - return std::integral_constant<unsigned, detail::parse_number(0, digits...)>(); -} -} // namespace literals -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/make_histogram.hpp b/ThirdParty/boost/histogram/make_histogram.hpp deleted file mode 100644 index a24d26a82b88e77bae503206e4d1affb631d81c7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/make_histogram.hpp +++ /dev/null @@ -1,138 +0,0 @@ -// Copyright 2015-2018 Hans Dembinski -// -// 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_HISTOGRAM_MAKE_HISTOGRAM_HPP -#define BOOST_HISTOGRAM_MAKE_HISTOGRAM_HPP - -/** - \file boost/histogram/make_histogram.hpp - Collection of factory functions to conveniently create histograms. -*/ - -#include <boost/histogram/accumulators/weighted_sum.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/histogram.hpp> -#include <boost/histogram/storage_adaptor.hpp> -#include <boost/histogram/unlimited_storage.hpp> // = default_storage -#include <boost/mp11/utility.hpp> -#include <tuple> -#include <vector> - -namespace boost { -namespace histogram { - -/** - Make histogram from compile-time axis configuration and custom storage. - @param storage Storage or container with standard interface (any vector, array, or map). - @param axis First axis instance. - @param axes Other axis instances. -*/ -template <class Storage, class Axis, class... Axes, - class = detail::requires_storage_or_adaptible<Storage>, - class = detail::requires_axis<Axis>> -auto make_histogram_with(Storage&& storage, Axis&& axis, Axes&&... axes) { - auto a = std::make_tuple(std::forward<Axis>(axis), std::forward<Axes>(axes)...); - using U = std::decay_t<Storage>; - using S = mp11::mp_if<detail::is_storage<U>, U, storage_adaptor<U>>; - return histogram<decltype(a), S>(std::move(a), S(std::forward<Storage>(storage))); -} - -/** - Make histogram from compile-time axis configuration and default storage. - @param axis First axis instance. - @param axes Other axis instances. -*/ -template <class Axis, class... Axes, class = detail::requires_axis<Axis>> -auto make_histogram(Axis&& axis, Axes&&... axes) { - return make_histogram_with(default_storage(), std::forward<Axis>(axis), - std::forward<Axes>(axes)...); -} - -/** - Make histogram from compile-time axis configuration and weight-counting storage. - @param axis First axis instance. - @param axes Other axis instances. -*/ -template <class Axis, class... Axes, class = detail::requires_axis<Axis>> -auto make_weighted_histogram(Axis&& axis, Axes&&... axes) { - return make_histogram_with(weight_storage(), std::forward<Axis>(axis), - std::forward<Axes>(axes)...); -} - -/** - Make histogram from iterable range and custom storage. - @param storage Storage or container with standard interface (any vector, array, or map). - @param iterable Iterable range of axis objects. -*/ -template <class Storage, class Iterable, - class = detail::requires_storage_or_adaptible<Storage>, - class = detail::requires_sequence_of_any_axis<Iterable>> -auto make_histogram_with(Storage&& storage, Iterable&& iterable) { - using U = std::decay_t<Storage>; - using S = mp11::mp_if<detail::is_storage<U>, U, storage_adaptor<U>>; - using It = std::decay_t<Iterable>; - using A = mp11::mp_if<detail::is_indexable_container<It>, It, - std::vector<mp11::mp_first<It>>>; - return histogram<A, S>(std::forward<Iterable>(iterable), - S(std::forward<Storage>(storage))); -} - -/** - Make histogram from iterable range and default storage. - @param iterable Iterable range of axis objects. -*/ -template <class Iterable, class = detail::requires_sequence_of_any_axis<Iterable>> -auto make_histogram(Iterable&& iterable) { - return make_histogram_with(default_storage(), std::forward<Iterable>(iterable)); -} - -/** - Make histogram from iterable range and weight-counting storage. - @param iterable Iterable range of axis objects. -*/ -template <class Iterable, class = detail::requires_sequence_of_any_axis<Iterable>> -auto make_weighted_histogram(Iterable&& iterable) { - return make_histogram_with(weight_storage(), std::forward<Iterable>(iterable)); -} - -/** - Make histogram from iterator interval and custom storage. - @param storage Storage or container with standard interface (any vector, array, or map). - @param begin Iterator to range of axis objects. - @param end Iterator to range of axis objects. -*/ -template <class Storage, class Iterator, - class = detail::requires_storage_or_adaptible<Storage>, - class = detail::requires_iterator<Iterator>> -auto make_histogram_with(Storage&& storage, Iterator begin, Iterator end) { - using T = std::decay_t<decltype(*begin)>; - return make_histogram_with(std::forward<Storage>(storage), std::vector<T>(begin, end)); -} - -/** - Make histogram from iterator interval and default storage. - @param begin Iterator to range of axis objects. - @param end Iterator to range of axis objects. -*/ -template <class Iterator, class = detail::requires_iterator<Iterator>> -auto make_histogram(Iterator begin, Iterator end) { - return make_histogram_with(default_storage(), begin, end); -} - -/** - Make histogram from iterator interval and weight-counting storage. - @param begin Iterator to range of axis objects. - @param end Iterator to range of axis objects. -*/ -template <class Iterator, class = detail::requires_iterator<Iterator>> -auto make_weighted_histogram(Iterator begin, Iterator end) { - return make_histogram_with(weight_storage(), begin, end); -} - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/make_profile.hpp b/ThirdParty/boost/histogram/make_profile.hpp deleted file mode 100644 index cef01d9edef8b9d830a7fde3e5c86ad7f130f2ef..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/make_profile.hpp +++ /dev/null @@ -1,90 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_MAKE_PROFILE_HPP -#define BOOST_HISTOGRAM_MAKE_PROFILE_HPP - -#include <boost/histogram/accumulators/mean.hpp> -#include <boost/histogram/accumulators/weighted_mean.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/histogram/make_histogram.hpp> - -/** - \file boost/histogram/make_profile.hpp - Collection of factory functions to conveniently create profiles. - - Profiles are histograms which accept an additional sample and compute the mean of the - sample in each cell. -*/ - -namespace boost { -namespace histogram { - -/** - Make profle from compile-time axis configuration. - @param axis First axis instance. - @param axes Other axis instances. -*/ -template <class Axis, class... Axes, class = detail::requires_axis<Axis>> -auto make_profile(Axis&& axis, Axes&&... axes) { - return make_histogram_with(profile_storage(), std::forward<Axis>(axis), - std::forward<Axes>(axes)...); -} - -/** - Make profle from compile-time axis configuration which accepts weights. - @param axis First axis instance. - @param axes Other axis instances. -*/ -template <class Axis, class... Axes, class = detail::requires_axis<Axis>> -auto make_weighted_profile(Axis&& axis, Axes&&... axes) { - return make_histogram_with(weighted_profile_storage(), std::forward<Axis>(axis), - std::forward<Axes>(axes)...); -} - -/** - Make profile from iterable range. - @param iterable Iterable range of axis objects. -*/ -template <class Iterable, class = detail::requires_sequence_of_any_axis<Iterable>> -auto make_profile(Iterable&& iterable) { - return make_histogram_with(profile_storage(), std::forward<Iterable>(iterable)); -} - -/** - Make profile from iterable range which accepts weights. - @param iterable Iterable range of axis objects. -*/ -template <class Iterable, class = detail::requires_sequence_of_any_axis<Iterable>> -auto make_weighted_profile(Iterable&& iterable) { - return make_histogram_with(weighted_profile_storage(), - std::forward<Iterable>(iterable)); -} - -/** - Make profile from iterator interval. - @param begin Iterator to range of axis objects. - @param end Iterator to range of axis objects. -*/ -template <class Iterator, class = detail::requires_iterator<Iterator>> -auto make_profile(Iterator begin, Iterator end) { - return make_histogram_with(profile_storage(), begin, end); -} - -/** - Make profile from iterator interval which accepts weights. - @param begin Iterator to range of axis objects. - @param end Iterator to range of axis objects. -*/ -template <class Iterator, class = detail::requires_iterator<Iterator>> -auto make_weighted_profile(Iterator begin, Iterator end) { - return make_histogram_with(weighted_profile_storage(), begin, end); -} - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/ostream.hpp b/ThirdParty/boost/histogram/ostream.hpp deleted file mode 100644 index 4a7437a485be6c6f55e9654e9d9511402fe82206..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/ostream.hpp +++ /dev/null @@ -1,310 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// Copyright 2019 Przemyslaw Bartosik -// -// 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_HISTOGRAM_OSTREAM_HPP -#define BOOST_HISTOGRAM_OSTREAM_HPP - -#include <boost/histogram/accumulators/ostream.hpp> -#include <boost/histogram/axis/ostream.hpp> -#include <boost/histogram/axis/variant.hpp> -#include <boost/histogram/detail/axes.hpp> -#include <boost/histogram/detail/counting_streambuf.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/static_if.hpp> -#include <boost/histogram/indexed.hpp> -#include <cmath> -#include <iomanip> -#include <ios> -#include <limits> -#include <numeric> -#include <ostream> -#include <streambuf> -#include <type_traits> - -/** - \file boost/histogram/ostream.hpp - - A simple streaming operator for the histogram type. The text representation is - rudimentary and not guaranteed to be stable between versions of Boost.Histogram. This - header is not included by any other header and must be explicitly included to use the - streaming operator. - - To you use your own, simply include your own implementation instead of this header. - */ - -namespace boost { -namespace histogram { -namespace detail { - -template <class OStream, unsigned N> -class tabular_ostream_wrapper : public std::array<int, N> { - using base_t = std::array<int, N>; - using char_type = typename OStream::char_type; - using traits_type = typename OStream::traits_type; - -public: - template <class T> - tabular_ostream_wrapper& operator<<(const T& t) { - if (collect_) { - if (static_cast<std::size_t>(iter_ - base_t::begin()) == size_) { - ++size_; - BOOST_ASSERT(size_ <= N); - BOOST_ASSERT(iter_ != end()); - *iter_ = 0; - } - cbuf_.count = 0; - os_ << t; - *iter_ = std::max(*iter_, static_cast<int>(cbuf_.count)); - } else { - BOOST_ASSERT(iter_ != end()); - os_ << std::setw(*iter_) << t; - } - ++iter_; - return *this; - } - - tabular_ostream_wrapper& operator<<(decltype(std::setprecision(0)) t) { - os_ << t; - return *this; - } - - tabular_ostream_wrapper& operator<<(decltype(std::fixed) t) { - os_ << t; - return *this; - } - - tabular_ostream_wrapper& row() { - iter_ = base_t::begin(); - return *this; - } - - explicit tabular_ostream_wrapper(OStream& os) : os_(os), orig_(os_.rdbuf(&cbuf_)) {} - - auto end() { return base_t::begin() + size_; } - auto end() const { return base_t::begin() + size_; } - auto cend() const { return base_t::cbegin() + size_; } - - void complete() { - BOOST_ASSERT(collect_); // only call this once - collect_ = false; - os_.rdbuf(orig_); - } - -private: - typename base_t::iterator iter_ = base_t::begin(); - std::size_t size_ = 0; - bool collect_ = true; - OStream& os_; - counting_streambuf<char_type, traits_type> cbuf_; - std::basic_streambuf<char_type, traits_type>* orig_; -}; - -template <class OStream, class T> -void ostream_value(OStream& os, const T& val) { - // a value from bin or histogram cell - os << std::left; - static_if_c<(std::is_convertible<T, double>::value && !std::is_integral<T>::value)>( - [](auto& os, const auto& val) { - const auto d = static_cast<double>(val); - if (std::isfinite(d)) { - const auto i = static_cast<std::int64_t>(d); - if (i == d) { - os << i; - return; - } - } - os << std::defaultfloat << std::setprecision(4) << d; - }, - [](auto& os, const auto& val) { os << val; }, os, val); -} - -template <class OStream, class Axis> -void ostream_bin(OStream& os, const Axis& ax, const int i) { - os << std::right; - static_if<has_method_value<Axis>>( - [&](const auto& ax) { - static_if<axis::traits::is_continuous<Axis>>( - [&](const auto& ax) { - os << std::defaultfloat << std::setprecision(4); - auto a = ax.value(i); - auto b = ax.value(i + 1); - // round bin edge to zero if deviation from zero is absolut and relatively - // small - const auto eps = 1e-8 * std::abs(b - a); - if (std::abs(a) < 1e-14 && std::abs(a) < eps) a = 0; - if (std::abs(b) < 1e-14 && std::abs(b) < eps) b = 0; - os << "[" << a << ", " << b << ")"; - }, - [&](const auto& ax) { os << ax.value(i); }, ax); - }, - [&](const auto&) { os << i; }, ax); -} - -template <class OStream, class... Ts> -void ostream_bin(OStream& os, const axis::category<Ts...>& ax, const int i) { - os << std::right; - if (i < ax.size()) - os << ax.value(i); - else - os << "other"; -} - -template <class CharT> -struct line_t { - CharT ch; - int size; -}; - -template <class CharT> -auto line(CharT c, int n) { - return line_t<CharT>{c, n}; -} - -template <class C, class T> -std::basic_ostream<C, T>& operator<<(std::basic_ostream<C, T>& os, line_t<C>&& l) { - for (int i = 0; i < l.size; ++i) os << l.ch; - return os; -} - -template <class OStream, class Axis, class T> -void stream_head(OStream& os, const Axis& ax, int index, const T& val) { - axis::visit( - [&](const auto& ax) { - ostream_bin(os, ax, index); - os << ' '; - ostream_value(os, val); - }, - ax); -} - -template <class OStream, class Histogram> -void ascii_plot(OStream& os, const Histogram& h, int w_total) { - if (w_total == 0) w_total = 78; // TODO detect actual width of terminal - - const auto& ax = h.axis(); - - // value range; can be integer or float, positive or negative - double vmin = 0; - double vmax = 0; - tabular_ostream_wrapper<OStream, 7> tos(os); - // first pass to get widths - for (auto&& v : indexed(h, coverage::all)) { - stream_head(tos.row(), ax, v.index(), *v); - vmin = std::min(vmin, static_cast<double>(*v)); - vmax = std::max(vmax, static_cast<double>(*v)); - } - tos.complete(); - if (vmax == 0) vmax = 1; - - // calculate width useable by bar (notice extra space at top) - // <-- head --> |<--- bar ---> | - // w_head + 2 + 2 - const int w_head = std::accumulate(tos.begin(), tos.end(), 0); - const int w_bar = w_total - 4 - w_head; - if (w_bar < 0) return; - - // draw upper line - os << '\n' << line(' ', w_head + 1) << '+' << line('-', w_bar + 1) << "+\n"; - - const int zero_offset = static_cast<int>(std::lround((-vmin) / (vmax - vmin) * w_bar)); - for (auto&& v : indexed(h, coverage::all)) { - stream_head(tos.row(), ax, v.index(), *v); - // rest uses os, not tos - os << " |"; - const int k = static_cast<int>(std::lround(*v / (vmax - vmin) * w_bar)); - if (k < 0) { - os << line(' ', zero_offset + k) << line('=', -k) << line(' ', w_bar - zero_offset); - } else { - os << line(' ', zero_offset) << line('=', k) << line(' ', w_bar - zero_offset - k); - } - os << " |\n"; - } - - // draw lower line - os << line(' ', w_head + 1) << '+' << line('-', w_bar + 1) << "+\n"; -} - -template <class OStream, class Histogram> -void ostream(OStream& os, const Histogram& h, const bool show_values = true) { - os << "histogram("; - - unsigned iaxis = 0; - const auto rank = h.rank(); - h.for_each_axis([&](const auto& ax) { - using A = std::decay_t<decltype(ax)>; - if ((show_values && rank > 0) || rank > 1) os << "\n "; - static_if<is_streamable<A>>([&](const auto& ax) { os << ax; }, - [&](const auto&) { os << "<unstreamable>"; }, ax); - }); - - if (show_values && rank > 0) { - tabular_ostream_wrapper<OStream, (BOOST_HISTOGRAM_DETAIL_AXES_LIMIT + 1)> tos(os); - for (auto&& v : indexed(h, coverage::all)) { - tos.row(); - for (auto i : v.indices()) tos << std::right << i; - ostream_value(tos, *v); - } - tos.complete(); - - const int w_item = std::accumulate(tos.begin(), tos.end(), 0) + 4 + h.rank(); - const int nrow = std::max(1, 65 / w_item); - int irow = 0; - for (auto&& v : indexed(h, coverage::all)) { - os << (irow == 0 ? "\n (" : " ("); - tos.row(); - iaxis = 0; - for (auto i : v.indices()) { - tos << std::right << i; - os << (++iaxis == h.rank() ? "):" : " "); - } - os << ' '; - ostream_value(tos, *v); - ++irow; - if (nrow > 0 && irow == nrow) irow = 0; - } - os << '\n'; - } - os << ')'; -} - -} // namespace detail - -#ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED - -template <class CharT, class Traits, class A, class S> -std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os, - const histogram<A, S>& h) { - // save fmt - const auto flags = os.flags(); - - os.flags(std::ios::dec | std::ios::left); - - const auto w = static_cast<int>(os.width()); - os.width(0); - - using value_type = typename histogram<A, S>::value_type; - detail::static_if<std::is_convertible<value_type, double>>( - [&os, w](const auto& h) { - if (h.rank() == 1) { - detail::ostream(os, h, false); - detail::ascii_plot(os, h, w); - } else - detail::ostream(os, h); - }, - [&os](const auto& h) { detail::ostream(os, h); }, h); - - // restore fmt - os.flags(flags); - return os; -} - -} // namespace histogram -} // namespace boost - -#endif // BOOST_HISTOGRAM_DOXYGEN_INVOKED - -#endif diff --git a/ThirdParty/boost/histogram/sample.hpp b/ThirdParty/boost/histogram/sample.hpp deleted file mode 100644 index 6289bd31a479d177ad0afbe864420508ddb11f83..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/sample.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_SAMPLE_HPP -#define BOOST_HISTOGRAM_SAMPLE_HPP - -#include <tuple> -#include <utility> - -namespace boost { -namespace histogram { - -template <class T> -struct sample_type { - T value; -}; - -/** Helper function to mark arguments as sample. - - @param ts arguments to be forwarded to the accumulator. -*/ -template <class... Ts> -auto sample(Ts&&... ts) noexcept { - return sample_type<std::tuple<Ts...>>{std::forward_as_tuple(std::forward<Ts>(ts)...)}; -} - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/serialization.hpp b/ThirdParty/boost/histogram/serialization.hpp deleted file mode 100644 index b43323764f9437daeb29dec26b6d77de385386d7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/serialization.hpp +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// -// 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_HISTOGRAM_SERIALIZATION_HPP -#define BOOST_HISTOGRAM_SERIALIZATION_HPP - -#include <boost/serialization/array.hpp> -#include <boost/serialization/map.hpp> -#include <boost/serialization/string.hpp> -#include <boost/serialization/vector.hpp> - -/** - \file boost/histogram/serialization.hpp - - Headers from - [Boost.Serialization](https://www.boost.org/doc/libs/develop/libs/serialization/doc/index.html) - needed to serialize STL types that are used internally by the Boost.Histogram classes. - */ - -#endif diff --git a/ThirdParty/boost/histogram/storage_adaptor.hpp b/ThirdParty/boost/histogram/storage_adaptor.hpp deleted file mode 100644 index b0d19ad193eadc3dcb6fee900482534672261606..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/storage_adaptor.hpp +++ /dev/null @@ -1,395 +0,0 @@ -// Copyright 2018-2019 Hans Dembinski -// -// 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_HISTOGRAM_STORAGE_ADAPTOR_HPP -#define BOOST_HISTOGRAM_STORAGE_ADAPTOR_HPP - -#include <algorithm> -#include <boost/core/nvp.hpp> -#include <boost/histogram/detail/array_wrapper.hpp> -#include <boost/histogram/detail/detect.hpp> -#include <boost/histogram/detail/iterator_adaptor.hpp> -#include <boost/histogram/detail/safe_comparison.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/throw_exception.hpp> -#include <stdexcept> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -struct vector_impl : T { - using allocator_type = typename T::allocator_type; - - static constexpr bool has_threading_support = - accumulators::is_thread_safe<typename T::value_type>::value; - - vector_impl(const allocator_type& a = {}) : T(a) {} - vector_impl(const vector_impl&) = default; - vector_impl& operator=(const vector_impl&) = default; - vector_impl(vector_impl&&) = default; - vector_impl& operator=(vector_impl&&) = default; - - explicit vector_impl(T&& t) : T(std::move(t)) {} - explicit vector_impl(const T& t) : T(t) {} - - template <class U, class = requires_iterable<U>> - explicit vector_impl(const U& u, const allocator_type& a = {}) - : T(std::begin(u), std::end(u), a) {} - - template <class U, class = requires_iterable<U>> - vector_impl& operator=(const U& u) { - T::resize(u.size()); - auto it = T::begin(); - for (auto&& x : u) *it++ = x; - return *this; - } - - void reset(std::size_t n) { - using value_type = typename T::value_type; - const auto old_size = T::size(); - T::resize(n, value_type()); - std::fill_n(T::begin(), (std::min)(n, old_size), value_type()); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("vector", static_cast<T&>(*this)); - } -}; - -template <class T> -struct array_impl : T { - static constexpr bool has_threading_support = - accumulators::is_thread_safe<typename T::value_type>::value; - - array_impl() = default; - array_impl(const array_impl& t) : T(t), size_(t.size_) {} - array_impl& operator=(const array_impl& t) { - T::operator=(t); - size_ = t.size_; - return *this; - } - - explicit array_impl(T&& t) : T(std::move(t)) {} - explicit array_impl(const T& t) : T(t) {} - - template <class U, class = requires_iterable<U>> - explicit array_impl(const U& u) : size_(u.size()) { - using std::begin; - using std::end; - std::copy(begin(u), end(u), this->begin()); - } - - template <class U, class = requires_iterable<U>> - array_impl& operator=(const U& u) { - if (u.size() > T::max_size()) // for std::arra - BOOST_THROW_EXCEPTION(std::length_error("argument size exceeds maximum capacity")); - size_ = u.size(); - using std::begin; - using std::end; - std::copy(begin(u), end(u), T::begin()); - return *this; - } - - void reset(std::size_t n) { - using value_type = typename T::value_type; - if (n > T::max_size()) // for std::array - BOOST_THROW_EXCEPTION(std::length_error("argument size exceeds maximum capacity")); - std::fill_n(T::begin(), n, value_type()); - size_ = n; - } - - typename T::iterator end() noexcept { return T::begin() + size_; } - typename T::const_iterator end() const noexcept { return T::begin() + size_; } - - std::size_t size() const noexcept { return size_; } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("size", size_); - auto w = detail::make_array_wrapper(T::data(), size_); - ar& make_nvp("array", w); - } - - std::size_t size_ = 0; -}; - -template <class T> -struct map_impl : T { - static_assert(std::is_same<typename T::key_type, std::size_t>::value, - "requires std::size_t as key_type"); - - using value_type = typename T::mapped_type; - using const_reference = const value_type&; - - static constexpr bool has_threading_support = false; - static_assert( - !accumulators::is_thread_safe<value_type>::value, - "std::map and std::unordered_map do not support thread-safe element access. " - "If you have a map with thread-safe element access, please file an issue and" - "support will be added."); - - struct reference { - reference(map_impl* m, std::size_t i) noexcept : map(m), idx(i) {} - - reference(const reference&) noexcept = default; - reference& operator=(const reference& o) { - if (this != &o) operator=(static_cast<const_reference>(o)); - return *this; - } - - operator const_reference() const noexcept { - return static_cast<const map_impl*>(map)->operator[](idx); - } - - reference& operator=(const_reference u) { - auto it = map->find(idx); - if (u == value_type{}) { - if (it != static_cast<T*>(map)->end()) { map->erase(it); } - } else { - if (it != static_cast<T*>(map)->end()) { - it->second = u; - } else { - map->emplace(idx, u); - } - } - return *this; - } - - template <class U, class V = value_type, - class = std::enable_if_t<has_operator_radd<V, U>::value>> - reference& operator+=(const U& u) { - auto it = map->find(idx); - if (it != static_cast<T*>(map)->end()) { - it->second += u; - } else { - map->emplace(idx, u); - } - return *this; - } - - template <class U, class V = value_type, - class = std::enable_if_t<has_operator_rsub<V, U>::value>> - reference& operator-=(const U& u) { - auto it = map->find(idx); - if (it != static_cast<T*>(map)->end()) { - it->second -= u; - } else { - map->emplace(idx, -u); - } - return *this; - } - - template <class U, class V = value_type, - class = std::enable_if_t<has_operator_rmul<V, U>::value>> - reference& operator*=(const U& u) { - auto it = map->find(idx); - if (it != static_cast<T*>(map)->end()) it->second *= u; - return *this; - } - - template <class U, class V = value_type, - class = std::enable_if_t<has_operator_rdiv<V, U>::value>> - reference& operator/=(const U& u) { - auto it = map->find(idx); - if (it != static_cast<T*>(map)->end()) { - it->second /= u; - } else if (!(value_type{} / u == value_type{})) { - map->emplace(idx, value_type{} / u); - } - return *this; - } - - template <class V = value_type, - class = std::enable_if_t<has_operator_preincrement<V>::value>> - reference operator++() { - auto it = map->find(idx); - if (it != static_cast<T*>(map)->end()) { - ++it->second; - } else { - value_type tmp{}; - ++tmp; - map->emplace(idx, tmp); - } - return *this; - } - - template <class V = value_type, - class = std::enable_if_t<has_operator_preincrement<V>::value>> - value_type operator++(int) { - const value_type tmp = *this; - operator++(); - return tmp; - } - - template <class U, class = std::enable_if_t<has_operator_equal<value_type, U>::value>> - bool operator==(const U& rhs) const { - return operator const_reference() == rhs; - } - - template <class U, class = std::enable_if_t<has_operator_equal<value_type, U>::value>> - bool operator!=(const U& rhs) const { - return !operator==(rhs); - } - - template <class CharT, class Traits> - friend std::basic_ostream<CharT, Traits>& operator<<( - std::basic_ostream<CharT, Traits>& os, reference x) { - os << static_cast<const_reference>(x); - return os; - } - - template <class... Ts> - auto operator()(const Ts&... args) -> decltype(std::declval<value_type>()(args...)) { - return (*map)[idx](args...); - } - - map_impl* map; - std::size_t idx; - }; - - template <class Value, class Reference, class MapPtr> - struct iterator_t - : iterator_adaptor<iterator_t<Value, Reference, MapPtr>, std::size_t, Reference> { - iterator_t() = default; - template <class V, class R, class M, class = requires_convertible<M, MapPtr>> - iterator_t(const iterator_t<V, R, M>& it) noexcept : iterator_t(it.map_, it.base()) {} - iterator_t(MapPtr m, std::size_t i) noexcept - : iterator_t::iterator_adaptor_(i), map_(m) {} - template <class V, class R, class M> - bool equal(const iterator_t<V, R, M>& rhs) const noexcept { - return map_ == rhs.map_ && iterator_t::base() == rhs.base(); - } - Reference operator*() const { return (*map_)[iterator_t::base()]; } - MapPtr map_ = nullptr; - }; - - using iterator = iterator_t<value_type, reference, map_impl*>; - using const_iterator = iterator_t<const value_type, const_reference, const map_impl*>; - - using allocator_type = typename T::allocator_type; - - map_impl(const allocator_type& a = {}) : T(a) {} - - map_impl(const map_impl&) = default; - map_impl& operator=(const map_impl&) = default; - map_impl(map_impl&&) = default; - map_impl& operator=(map_impl&&) = default; - - map_impl(const T& t) : T(t), size_(t.size()) {} - map_impl(T&& t) : T(std::move(t)), size_(t.size()) {} - - template <class U, class = requires_iterable<U>> - explicit map_impl(const U& u, const allocator_type& a = {}) : T(a), size_(u.size()) { - using std::begin; - using std::end; - std::copy(begin(u), end(u), this->begin()); - } - - template <class U, class = requires_iterable<U>> - map_impl& operator=(const U& u) { - if (u.size() < size_) - reset(u.size()); - else - size_ = u.size(); - using std::begin; - using std::end; - std::copy(begin(u), end(u), this->begin()); - return *this; - } - - void reset(std::size_t n) { - T::clear(); - size_ = n; - } - - reference operator[](std::size_t i) noexcept { return {this, i}; } - const_reference operator[](std::size_t i) const noexcept { - auto it = T::find(i); - static const value_type null = value_type{}; - if (it == T::end()) return null; - return it->second; - } - - iterator begin() noexcept { return {this, 0}; } - iterator end() noexcept { return {this, size_}; } - - const_iterator begin() const noexcept { return {this, 0}; } - const_iterator end() const noexcept { return {this, size_}; } - - std::size_t size() const noexcept { return size_; } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("size", size_); - ar& make_nvp("map", static_cast<T&>(*this)); - } - - std::size_t size_ = 0; -}; - -template <class T> -struct ERROR_type_passed_to_storage_adaptor_not_recognized; - -// clang-format off -template <class T> -using storage_adaptor_impl = - mp11::mp_cond< - is_vector_like<T>, vector_impl<T>, - is_array_like<T>, array_impl<T>, - is_map_like<T>, map_impl<T>, - std::true_type, ERROR_type_passed_to_storage_adaptor_not_recognized<T> - >; -// clang-format on -} // namespace detail - -/// Turns any vector-like, array-like, and map-like container into a storage type. -template <class T> -class storage_adaptor : public detail::storage_adaptor_impl<T> { - using impl_type = detail::storage_adaptor_impl<T>; - -public: - // standard copy, move, assign - storage_adaptor(storage_adaptor&&) = default; - storage_adaptor(const storage_adaptor&) = default; - storage_adaptor& operator=(storage_adaptor&&) = default; - storage_adaptor& operator=(const storage_adaptor&) = default; - - // forwarding constructor - template <class... Ts> - storage_adaptor(Ts&&... ts) : impl_type(std::forward<Ts>(ts)...) {} - - // forwarding assign - template <class U> - storage_adaptor& operator=(U&& u) { - impl_type::operator=(std::forward<U>(u)); - return *this; - } - - template <class U, class = detail::requires_iterable<U>> - bool operator==(const U& u) const { - using std::begin; - using std::end; - return std::equal(this->begin(), this->end(), begin(u), end(u), detail::safe_equal{}); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - ar& make_nvp("impl", static_cast<impl_type&>(*this)); - } - -private: - friend struct unsafe_access; -}; - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/unlimited_storage.hpp b/ThirdParty/boost/histogram/unlimited_storage.hpp deleted file mode 100644 index abedef74664f573a0c8b90e6503d979d531bd0a8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/unlimited_storage.hpp +++ /dev/null @@ -1,641 +0,0 @@ -// Copyright 2015-2019 Hans Dembinski -// Copyright 2019 Glen Joseph Fernandes (glenjofe@gmail.com) -// -// 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_HISTOGRAM_UNLIMTED_STORAGE_HPP -#define BOOST_HISTOGRAM_UNLIMTED_STORAGE_HPP - -#include <algorithm> -#include <boost/assert.hpp> -#include <boost/config.hpp> -#include <boost/core/alloc_construct.hpp> -#include <boost/core/exchange.hpp> -#include <boost/core/nvp.hpp> -#include <boost/histogram/detail/array_wrapper.hpp> -#include <boost/histogram/detail/iterator_adaptor.hpp> -#include <boost/histogram/detail/large_int.hpp> -#include <boost/histogram/detail/operators.hpp> -#include <boost/histogram/detail/safe_comparison.hpp> -#include <boost/histogram/fwd.hpp> -#include <boost/mp11/algorithm.hpp> -#include <boost/mp11/list.hpp> -#include <boost/mp11/utility.hpp> -#include <cmath> -#include <cstdint> -#include <functional> -#include <iterator> -#include <memory> -#include <type_traits> - -namespace boost { -namespace histogram { -namespace detail { - -template <class T> -struct is_large_int : std::false_type {}; - -template <class A> -struct is_large_int<large_int<A>> : std::true_type {}; - -template <class T, class ReturnType> -using if_arithmetic_or_large_int = - std::enable_if_t<(std::is_arithmetic<T>::value || is_large_int<T>::value), - ReturnType>; - -template <class L, class T> -using next_type = mp11::mp_at_c<L, (mp11::mp_find<L, T>::value + 1)>; - -template <class Allocator> -class construct_guard { -public: - using pointer = typename std::allocator_traits<Allocator>::pointer; - - construct_guard(Allocator& a, pointer p, std::size_t n) noexcept - : a_(a), p_(p), n_(n) {} - - ~construct_guard() { - if (p_) { a_.deallocate(p_, n_); } - } - - void release() { p_ = pointer(); } - - construct_guard(const construct_guard&) = delete; - construct_guard& operator=(const construct_guard&) = delete; - -private: - Allocator& a_; - pointer p_; - std::size_t n_; -}; - -template <class Allocator> -void* buffer_create(Allocator& a, std::size_t n) { - auto ptr = a.allocate(n); // may throw - static_assert(std::is_trivially_copyable<decltype(ptr)>::value, - "ptr must be trivially copyable"); - construct_guard<Allocator> guard(a, ptr, n); - boost::alloc_construct_n(a, ptr, n); - guard.release(); - return static_cast<void*>(ptr); -} - -template <class Allocator, class Iterator> -auto buffer_create(Allocator& a, std::size_t n, Iterator iter) { - BOOST_ASSERT(n > 0u); - auto ptr = a.allocate(n); // may throw - static_assert(std::is_trivially_copyable<decltype(ptr)>::value, - "ptr must be trivially copyable"); - construct_guard<Allocator> guard(a, ptr, n); - using T = typename std::allocator_traits<Allocator>::value_type; - struct casting_iterator { - void operator++() noexcept { ++iter_; } - T operator*() noexcept { - return static_cast<T>(*iter_); - } // silence conversion warnings - Iterator iter_; - }; - boost::alloc_construct_n(a, ptr, n, casting_iterator{iter}); - guard.release(); - return ptr; -} - -template <class Allocator> -void buffer_destroy(Allocator& a, typename std::allocator_traits<Allocator>::pointer p, - std::size_t n) { - BOOST_ASSERT(p); - BOOST_ASSERT(n > 0u); - boost::alloc_destroy_n(a, p, n); - a.deallocate(p, n); -} - -} // namespace detail - -/** - Memory-efficient storage for integral counters which cannot overflow. - - This storage provides a no-overflow-guarantee if the counters are incremented with - integer weights. It maintains a contiguous array of elemental counters, one for each - cell. If an operation is requested which would overflow a counter, the array is - replaced with another of a wider integral type, then the operation is executed. The - storage uses integers of 8, 16, 32, 64 bits, and then switches to a multiprecision - integral type, similar to those in - [Boost.Multiprecision](https://www.boost.org/doc/libs/develop/libs/multiprecision/doc/html/index.html). - - A scaling operation or adding a floating point number triggers a conversion of the - elemental counters into doubles, which voids the no-overflow-guarantee. -*/ -template <class Allocator> -class unlimited_storage { - static_assert( - std::is_same<typename std::allocator_traits<Allocator>::pointer, - typename std::allocator_traits<Allocator>::value_type*>::value, - "unlimited_storage requires allocator with trivial pointer type"); - using U8 = std::uint8_t; - using U16 = std::uint16_t; - using U32 = std::uint32_t; - using U64 = std::uint64_t; - -public: - static constexpr bool has_threading_support = false; - - using allocator_type = Allocator; - using value_type = double; - using large_int = detail::large_int< - typename std::allocator_traits<allocator_type>::template rebind_alloc<U64>>; - - struct buffer_type { - // cannot be moved outside of scope of unlimited_storage, large_int is dependent type - using types = mp11::mp_list<U8, U16, U32, U64, large_int, double>; - - template <class T> - static constexpr unsigned type_index() noexcept { - return static_cast<unsigned>(mp11::mp_find<types, T>::value); - } - - template <class F, class... Ts> - decltype(auto) visit(F&& f, Ts&&... ts) const { - // this is intentionally not a switch, the if-chain is faster in benchmarks - if (type == type_index<U8>()) - return f(static_cast<U8*>(ptr), std::forward<Ts>(ts)...); - if (type == type_index<U16>()) - return f(static_cast<U16*>(ptr), std::forward<Ts>(ts)...); - if (type == type_index<U32>()) - return f(static_cast<U32*>(ptr), std::forward<Ts>(ts)...); - if (type == type_index<U64>()) - return f(static_cast<U64*>(ptr), std::forward<Ts>(ts)...); - if (type == type_index<large_int>()) - return f(static_cast<large_int*>(ptr), std::forward<Ts>(ts)...); - return f(static_cast<double*>(ptr), std::forward<Ts>(ts)...); - } - - buffer_type(const allocator_type& a = {}) : alloc(a) {} - - buffer_type(buffer_type&& o) noexcept - : alloc(std::move(o.alloc)) - , size(boost::exchange(o.size, 0)) - , type(boost::exchange(o.type, 0)) - , ptr(boost::exchange(o.ptr, nullptr)) {} - - buffer_type& operator=(buffer_type&& o) noexcept { - using std::swap; - swap(alloc, o.alloc); - swap(size, o.size); - swap(type, o.type); - swap(ptr, o.ptr); - return *this; - } - - buffer_type(const buffer_type& x) : alloc(x.alloc) { - x.visit([this, n = x.size](const auto* xp) { - using T = std::decay_t<decltype(*xp)>; - this->template make<T>(n, xp); - }); - } - - buffer_type& operator=(const buffer_type& o) { - *this = buffer_type(o); - return *this; - } - - ~buffer_type() noexcept { destroy(); } - - void destroy() noexcept { - BOOST_ASSERT((ptr == nullptr) == (size == 0)); - if (ptr == nullptr) return; - visit([this](auto* p) { - using T = std::decay_t<decltype(*p)>; - using alloc_type = - typename std::allocator_traits<allocator_type>::template rebind_alloc<T>; - alloc_type a(alloc); // rebind allocator - detail::buffer_destroy(a, p, this->size); - }); - size = 0; - type = 0; - ptr = nullptr; - } - - template <class T> - void make(std::size_t n) { - // note: order of commands is to not leave buffer in invalid state upon throw - destroy(); - if (n > 0) { - // rebind allocator - using alloc_type = - typename std::allocator_traits<allocator_type>::template rebind_alloc<T>; - alloc_type a(alloc); - ptr = detail::buffer_create(a, n); // may throw - } - size = n; - type = type_index<T>(); - } - - template <class T, class U> - void make(std::size_t n, U iter) { - // note: iter may be current ptr, so create new buffer before deleting old buffer - void* new_ptr = nullptr; - const auto new_type = type_index<T>(); - if (n > 0) { - // rebind allocator - using alloc_type = - typename std::allocator_traits<allocator_type>::template rebind_alloc<T>; - alloc_type a(alloc); - new_ptr = detail::buffer_create(a, n, iter); // may throw - } - destroy(); - size = n; - type = new_type; - ptr = new_ptr; - } - - allocator_type alloc; - std::size_t size = 0; - unsigned type = 0; - mutable void* ptr = nullptr; - }; - - class reference; // forward declare to make friend of const_reference - - /// implementation detail - class const_reference - : detail::partially_ordered<const_reference, const_reference, void> { - public: - const_reference(buffer_type& b, std::size_t i) noexcept : bref_(b), idx_(i) { - BOOST_ASSERT(idx_ < bref_.size); - } - - const_reference(const const_reference&) noexcept = default; - - // no assignment for const_references - const_reference& operator=(const const_reference&) = delete; - const_reference& operator=(const_reference&&) = delete; - - operator double() const noexcept { - return bref_.visit( - [this](const auto* p) { return static_cast<double>(p[this->idx_]); }); - } - - bool operator<(const const_reference& o) const noexcept { - return apply_binary<detail::safe_less>(o); - } - - bool operator==(const const_reference& o) const noexcept { - return apply_binary<detail::safe_equal>(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator<(const U& o) const noexcept { - return apply_binary<detail::safe_less>(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator>(const U& o) const noexcept { - return apply_binary<detail::safe_greater>(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator==(const U& o) const noexcept { - return apply_binary<detail::safe_equal>(o); - } - - private: - template <class Binary> - bool apply_binary(const const_reference& x) const noexcept { - return x.bref_.visit([this, ix = x.idx_](const auto* xp) { - return this->apply_binary<Binary>(xp[ix]); - }); - } - - template <class Binary, class U> - bool apply_binary(const U& x) const noexcept { - return bref_.visit([i = idx_, &x](const auto* p) { return Binary()(p[i], x); }); - } - - protected: - buffer_type& bref_; - std::size_t idx_; - friend class reference; - }; - - /// implementation detail - class reference : public const_reference, - public detail::partially_ordered<reference, reference, void> { - public: - reference(buffer_type& b, std::size_t i) noexcept : const_reference(b, i) {} - - // references do copy-construct - reference(const reference& x) noexcept = default; - - // references do not rebind, assign through - reference& operator=(const reference& x) { - return operator=(static_cast<const_reference>(x)); - } - - // references do not rebind, assign through - reference& operator=(const const_reference& x) { - // safe for self-assignment, assigning matching type doesn't invalide buffer - x.bref_.visit([this, ix = x.idx_](const auto* xp) { this->operator=(xp[ix]); }); - return *this; - } - - template <class U> - detail::if_arithmetic_or_large_int<U, reference&> operator=(const U& x) { - this->bref_.visit([this, &x](auto* p) { - // gcc-8 optimizes the expression `p[this->idx_] = 0` away even at -O0, - // so we merge it into the next line which is properly counted - adder()((p[this->idx_] = 0, p), this->bref_, this->idx_, x); - }); - return *this; - } - - bool operator<(const reference& o) const noexcept { - return const_reference::operator<(o); - } - - bool operator==(const reference& o) const noexcept { - return const_reference::operator==(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator<(const U& o) const noexcept { - return const_reference::operator<(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator>(const U& o) const noexcept { - return const_reference::operator>(o); - } - - template <class U> - detail::if_arithmetic_or_large_int<U, bool> operator==(const U& o) const noexcept { - return const_reference::operator==(o); - } - - reference& operator+=(const const_reference& x) { - x.bref_.visit([this, ix = x.idx_](const auto* xp) { this->operator+=(xp[ix]); }); - return *this; - } - - template <class U> - detail::if_arithmetic_or_large_int<U, reference&> operator+=(const U& x) { - this->bref_.visit(adder(), this->bref_, this->idx_, x); - return *this; - } - - reference& operator-=(const double x) { return operator+=(-x); } - - reference& operator*=(const double x) { - this->bref_.visit(multiplier(), this->bref_, this->idx_, x); - return *this; - } - - reference& operator/=(const double x) { return operator*=(1.0 / x); } - - reference& operator++() { - this->bref_.visit(incrementor(), this->bref_, this->idx_); - return *this; - } - }; - -private: - template <class Value, class Reference> - class iterator_impl : public detail::iterator_adaptor<iterator_impl<Value, Reference>, - std::size_t, Reference, Value> { - public: - iterator_impl() = default; - template <class V, class R> - iterator_impl(const iterator_impl<V, R>& it) - : iterator_impl::iterator_adaptor_(it.base()), buffer_(it.buffer_) {} - iterator_impl(buffer_type* b, std::size_t i) noexcept - : iterator_impl::iterator_adaptor_(i), buffer_(b) {} - - Reference operator*() const noexcept { return {*buffer_, this->base()}; } - - template <class V, class R> - friend class iterator_impl; - - private: - mutable buffer_type* buffer_ = nullptr; - }; - -public: - using const_iterator = iterator_impl<const value_type, const_reference>; - using iterator = iterator_impl<value_type, reference>; - - explicit unlimited_storage(const allocator_type& a = {}) : buffer_(a) {} - unlimited_storage(const unlimited_storage&) = default; - unlimited_storage& operator=(const unlimited_storage&) = default; - unlimited_storage(unlimited_storage&&) = default; - unlimited_storage& operator=(unlimited_storage&&) = default; - - // TODO - // template <class Allocator> - // unlimited_storage(const unlimited_storage<Allocator>& s) - - template <class Iterable, class = detail::requires_iterable<Iterable>> - explicit unlimited_storage(const Iterable& s) { - using std::begin; - using std::end; - auto s_begin = begin(s); - auto s_end = end(s); - using V = typename std::iterator_traits<decltype(begin(s))>::value_type; - constexpr auto ti = buffer_type::template type_index<V>(); - constexpr auto nt = mp11::mp_size<typename buffer_type::types>::value; - const std::size_t size = static_cast<std::size_t>(std::distance(s_begin, s_end)); -#ifdef BOOST_NO_CXX17_IF_CONSTEXPR - if -#else - if constexpr -#endif - (ti < nt) - buffer_.template make<V>(size, s_begin); - else - buffer_.template make<double>(size, s_begin); - } - - template <class Iterable, class = detail::requires_iterable<Iterable>> - unlimited_storage& operator=(const Iterable& s) { - *this = unlimited_storage(s); - return *this; - } - - allocator_type get_allocator() const { return buffer_.alloc; } - - void reset(std::size_t n) { buffer_.template make<U8>(n); } - - std::size_t size() const noexcept { return buffer_.size; } - - reference operator[](std::size_t i) noexcept { return {buffer_, i}; } - const_reference operator[](std::size_t i) const noexcept { return {buffer_, i}; } - - bool operator==(const unlimited_storage& x) const noexcept { - if (size() != x.size()) return false; - return buffer_.visit([&x](const auto* p) { - return x.buffer_.visit([p, n = x.size()](const auto* xp) { - return std::equal(p, p + n, xp, detail::safe_equal{}); - }); - }); - } - - template <class Iterable> - bool operator==(const Iterable& iterable) const { - if (size() != iterable.size()) return false; - return buffer_.visit([&iterable](const auto* p) { - return std::equal(p, p + iterable.size(), std::begin(iterable), - detail::safe_equal{}); - }); - } - - unlimited_storage& operator*=(const double x) { - buffer_.visit(multiplier(), buffer_, x); - return *this; - } - - iterator begin() noexcept { return {&buffer_, 0}; } - iterator end() noexcept { return {&buffer_, size()}; } - const_iterator begin() const noexcept { return {&buffer_, 0}; } - const_iterator end() const noexcept { return {&buffer_, size()}; } - - /// implementation detail; used by unit tests, not part of generic storage interface - template <class T> - unlimited_storage(std::size_t s, const T* p, const allocator_type& a = {}) - : buffer_(std::move(a)) { - buffer_.template make<T>(s, p); - } - - template <class Archive> - void serialize(Archive& ar, unsigned /* version */) { - if (Archive::is_loading::value) { - buffer_type tmp(buffer_.alloc); - std::size_t size; - ar& make_nvp("type", tmp.type); - ar& make_nvp("size", size); - tmp.visit([this, size](auto* tp) { - BOOST_ASSERT(tp == nullptr); - using T = std::decay_t<decltype(*tp)>; - buffer_.template make<T>(size); - }); - } else { - ar& make_nvp("type", buffer_.type); - ar& make_nvp("size", buffer_.size); - } - buffer_.visit([this, &ar](auto* tp) { - auto w = detail::make_array_wrapper(tp, this->buffer_.size); - ar& make_nvp("buffer", w); - }); - } - -private: - struct incrementor { - template <class T> - void operator()(T* tp, buffer_type& b, std::size_t i) { - BOOST_ASSERT(tp && i < b.size); - if (!detail::safe_increment(tp[i])) { - using U = detail::next_type<typename buffer_type::types, T>; - b.template make<U>(b.size, tp); - ++static_cast<U*>(b.ptr)[i]; - } - } - - void operator()(large_int* tp, buffer_type&, std::size_t i) { ++tp[i]; } - - void operator()(double* tp, buffer_type&, std::size_t i) { ++tp[i]; } - }; - - struct adder { - template <class U> - void operator()(double* tp, buffer_type&, std::size_t i, const U& x) { - tp[i] += static_cast<double>(x); - } - - void operator()(large_int* tp, buffer_type&, std::size_t i, const large_int& x) { - tp[i] += x; // potentially adding large_int to itself is safe - } - - template <class T, class U> - void operator()(T* tp, buffer_type& b, std::size_t i, const U& x) { - is_x_integral(std::is_integral<U>{}, tp, b, i, x); - } - - template <class T, class U> - void is_x_integral(std::false_type, T* tp, buffer_type& b, std::size_t i, - const U& x) { - // x could be reference to buffer we manipulate, make copy before changing buffer - const auto v = static_cast<double>(x); - b.template make<double>(b.size, tp); - operator()(static_cast<double*>(b.ptr), b, i, v); - } - - template <class T> - void is_x_integral(std::false_type, T* tp, buffer_type& b, std::size_t i, - const large_int& x) { - // x could be reference to buffer we manipulate, make copy before changing buffer - const auto v = static_cast<large_int>(x); - b.template make<large_int>(b.size, tp); - operator()(static_cast<large_int*>(b.ptr), b, i, v); - } - - template <class T, class U> - void is_x_integral(std::true_type, T* tp, buffer_type& b, std::size_t i, const U& x) { - is_x_unsigned(std::is_unsigned<U>{}, tp, b, i, x); - } - - template <class T, class U> - void is_x_unsigned(std::false_type, T* tp, buffer_type& b, std::size_t i, - const U& x) { - if (x >= 0) - is_x_unsigned(std::true_type{}, tp, b, i, detail::make_unsigned(x)); - else - is_x_integral(std::false_type{}, tp, b, i, static_cast<double>(x)); - } - - template <class T, class U> - void is_x_unsigned(std::true_type, T* tp, buffer_type& b, std::size_t i, const U& x) { - if (detail::safe_radd(tp[i], x)) return; - // x could be reference to buffer we manipulate, need to convert to value - const auto y = x; - using TN = detail::next_type<typename buffer_type::types, T>; - b.template make<TN>(b.size, tp); - is_x_unsigned(std::true_type{}, static_cast<TN*>(b.ptr), b, i, y); - } - - template <class U> - void is_x_unsigned(std::true_type, large_int* tp, buffer_type&, std::size_t i, - const U& x) { - tp[i] += x; - } - }; - - struct multiplier { - template <class T> - void operator()(T* tp, buffer_type& b, const double x) { - // potential lossy conversion that cannot be avoided - b.template make<double>(b.size, tp); - operator()(static_cast<double*>(b.ptr), b, x); - } - - void operator()(double* tp, buffer_type& b, const double x) { - for (auto end = tp + b.size; tp != end; ++tp) *tp *= x; - } - - template <class T> - void operator()(T* tp, buffer_type& b, std::size_t i, const double x) { - b.template make<double>(b.size, tp); - operator()(static_cast<double*>(b.ptr), b, i, x); - } - - void operator()(double* tp, buffer_type&, std::size_t i, const double x) { - tp[i] *= static_cast<double>(x); - } - }; - - mutable buffer_type buffer_; - friend struct unsafe_access; -}; - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/unsafe_access.hpp b/ThirdParty/boost/histogram/unsafe_access.hpp deleted file mode 100644 index 568008245df1ed690105de2f0e6ca88bd23e249d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/unsafe_access.hpp +++ /dev/null @@ -1,118 +0,0 @@ -// Copyright 2018 Hans Dembinski -// -// 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_HISTOGRAM_UNSAFE_ACCESS_HPP -#define BOOST_HISTOGRAM_UNSAFE_ACCESS_HPP - -#include <boost/histogram/detail/axes.hpp> -#include <type_traits> - -namespace boost { -namespace histogram { - -/** Unsafe read/write access to private data that potentially breaks consistency. - - This struct enables access to private data of some classes. It is intended for library - developers who need this to implement algorithms efficiently, for example, - serialization. Users should not use this. If you are a user who absolutely needs this to - get a specific effect, please submit an issue on Github. Perhaps the public - interface is insufficient and should be extended for your use case. - - Unlike the normal interface, the unsafe_access interface may change between versions. - If your code relies on unsafe_access, it may or may not break when you update Boost. - This is another reason to not use it unless you are ok with these conditions. -*/ -struct unsafe_access { - /** - Get axes. - @param hist histogram. - */ - template <class Histogram> - static auto& axes(Histogram& hist) { - return hist.axes_; - } - - /// @copydoc axes() - template <class Histogram> - static const auto& axes(const Histogram& hist) { - return hist.axes_; - } - - /** - Get mutable axis reference with compile-time number. - @param hist histogram. - @tparam I axis index (optional, default: 0). - */ - template <class Histogram, unsigned I = 0> - static decltype(auto) axis(Histogram& hist, std::integral_constant<unsigned, I> = {}) { - detail::axis_index_is_valid(hist.axes_, I); - return detail::axis_get<I>(hist.axes_); - } - - /** - Get mutable axis reference with run-time number. - @param hist histogram. - @param i axis index. - */ - template <class Histogram> - static decltype(auto) axis(Histogram& hist, unsigned i) { - detail::axis_index_is_valid(hist.axes_, i); - return detail::axis_get(hist.axes_, i); - } - - /** - Get storage. - @param hist histogram. - */ - template <class Histogram> - static auto& storage(Histogram& hist) { - return hist.storage_; - } - - /// @copydoc storage() - template <class Histogram> - static const auto& storage(const Histogram& hist) { - return hist.storage_; - } - - /** - Get index offset. - @param hist histogram - */ - template <class Histogram> - static auto& offset(Histogram& hist) { - return hist.offset_; - } - - /// @copydoc offset() - template <class Histogram> - static const auto& offset(const Histogram& hist) { - return hist.offset_; - } - - /** - Get buffer of unlimited_storage. - @param storage instance of unlimited_storage. - */ - template <class Allocator> - static constexpr auto& unlimited_storage_buffer(unlimited_storage<Allocator>& storage) { - return storage.buffer_; - } - - /** - Get implementation of storage_adaptor. - @param storage instance of storage_adaptor. - */ - template <class T> - static constexpr auto& storage_adaptor_impl(storage_adaptor<T>& storage) { - return static_cast<typename storage_adaptor<T>::impl_type&>(storage); - } -}; - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/histogram/weight.hpp b/ThirdParty/boost/histogram/weight.hpp deleted file mode 100644 index 63efab1899158caedda24f36f6750a0f0b5d905a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/histogram/weight.hpp +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright 2019 Hans Dembinski -// -// 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_HISTOGRAM_WEIGHT_HPP -#define BOOST_HISTOGRAM_WEIGHT_HPP - -#include <utility> - -namespace boost { -namespace histogram { - -/** Weight holder and type envelope. - - You should not construct these directly, use the weight() helper function. - - @tparam Underlying arithmetic type. -*/ -template <class T> -struct weight_type { - /// Access underlying value. - T value; - - /// Allow implicit conversions of types when the underlying value type allows them. - template <class U> - operator weight_type<U>() const { - return weight_type<U>{static_cast<U>(value)}; - } -}; - -/** Helper function to mark argument as weight. - - @param t argument to be forward to the histogram. -*/ -template <class T> -auto weight(T&& t) noexcept { - return weight_type<T>{std::forward<T>(t)}; -} - -} // namespace histogram -} // namespace boost - -#endif diff --git a/ThirdParty/boost/implicit_cast.hpp b/ThirdParty/boost/implicit_cast.hpp deleted file mode 100644 index 03abe1d495e9b1f0301ba06e04234334e7ed8fbe..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/implicit_cast.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright David Abrahams 2003. -// 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_IMPLICIT_CAST_DWA200356_HPP -#define BOOST_IMPLICIT_CAST_DWA200356_HPP - -namespace boost { - -namespace detail { - -template<class T> struct icast_identity -{ - typedef T type; -}; - -} // namespace detail - -// implementation originally suggested by C. Green in -// http://lists.boost.org/MailArchives/boost/msg00886.php - -// The use of identity creates a non-deduced form, so that the -// explicit template argument must be supplied -template <typename T> -inline T implicit_cast (typename boost::detail::icast_identity<T>::type x) { - return x; -} - -} // namespace boost - - -#endif // BOOST_IMPLICIT_CAST_DWA200356_HPP diff --git a/ThirdParty/boost/intrusive/detail/workaround.hpp b/ThirdParty/boost/intrusive/detail/workaround.hpp deleted file mode 100644 index f0cfaf2b2d576bf8e5714d9c21512b731f11bbba..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/intrusive/detail/workaround.hpp +++ /dev/null @@ -1,58 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2013. 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) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_WORKAROUND_HPP -#define BOOST_INTRUSIVE_DETAIL_WORKAROUND_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#ifndef BOOST_CONFIG_HPP -#include <boost/config.hpp> -#endif - -// MSVC-12 ICEs when variadic templates are enabled. -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && (!defined(BOOST_MSVC) || BOOST_MSVC >= 1900) - #define BOOST_INTRUSIVE_VARIADIC_TEMPLATES -#endif - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - #define BOOST_INTRUSIVE_PERFECT_FORWARDING -#endif - -//Macros for documentation purposes. For code, expands to the argument -#define BOOST_INTRUSIVE_IMPDEF(TYPE) TYPE -#define BOOST_INTRUSIVE_SEEDOC(TYPE) TYPE -#define BOOST_INTRUSIVE_DOC1ST(TYPE1, TYPE2) TYPE2 -#define BOOST_INTRUSIVE_I , -#define BOOST_INTRUSIVE_DOCIGN(T1) T1 - -//#define BOOST_INTRUSIVE_DISABLE_FORCEINLINE - -#if defined(BOOST_INTRUSIVE_DISABLE_FORCEINLINE) - #define BOOST_INTRUSIVE_FORCEINLINE inline -#elif defined(BOOST_INTRUSIVE_FORCEINLINE_IS_BOOST_FORCELINE) - #define BOOST_INTRUSIVE_FORCEINLINE BOOST_FORCEINLINE -#elif defined(BOOST_MSVC) && defined(_DEBUG) - //"__forceinline" and MSVC seems to have some bugs in debug mode - #define BOOST_INTRUSIVE_FORCEINLINE inline -#elif defined(__GNUC__) && ((__GNUC__ < 4) || (__GNUC__ == 4 && (__GNUC_MINOR__ < 5))) - //Older GCCs have problems with forceinline - #define BOOST_INTRUSIVE_FORCEINLINE inline -#else - #define BOOST_INTRUSIVE_FORCEINLINE BOOST_FORCEINLINE -#endif - -#endif //#ifndef BOOST_INTRUSIVE_DETAIL_WORKAROUND_HPP diff --git a/ThirdParty/boost/intrusive/pack_options.hpp b/ThirdParty/boost/intrusive/pack_options.hpp deleted file mode 100644 index ff07678ffffe4b79b7918456bf8300cabe61a59b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/intrusive/pack_options.hpp +++ /dev/null @@ -1,380 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2013-2013 -// -// 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) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_PACK_OPTIONS_HPP -#define BOOST_INTRUSIVE_PACK_OPTIONS_HPP - -#include <boost/intrusive/detail/config_begin.hpp> - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -namespace boost { -namespace intrusive { - -#ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - -#if !defined(BOOST_INTRUSIVE_VARIADIC_TEMPLATES) - -template<class Prev, class Next> -struct do_pack -{ - //Use "pack" member template to pack options - typedef typename Next::template pack<Prev> type; -}; - -template<class Prev> -struct do_pack<Prev, void> -{ - //Avoid packing "void" to shorten template names - typedef Prev type; -}; - -template - < class DefaultOptions - , class O1 = void - , class O2 = void - , class O3 = void - , class O4 = void - , class O5 = void - , class O6 = void - , class O7 = void - , class O8 = void - , class O9 = void - , class O10 = void - , class O11 = void - > -struct pack_options -{ - // join options - typedef - typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < typename do_pack - < DefaultOptions - , O1 - >::type - , O2 - >::type - , O3 - >::type - , O4 - >::type - , O5 - >::type - , O6 - >::type - , O7 - >::type - , O8 - >::type - , O9 - >::type - , O10 - >::type - , O11 - >::type - type; -}; -#else - -//index_tuple -template<int... Indexes> -struct index_tuple{}; - -//build_number_seq -template<std::size_t Num, typename Tuple = index_tuple<> > -struct build_number_seq; - -template<std::size_t Num, int... Indexes> -struct build_number_seq<Num, index_tuple<Indexes...> > - : build_number_seq<Num - 1, index_tuple<Indexes..., sizeof...(Indexes)> > -{}; - -template<int... Indexes> -struct build_number_seq<0, index_tuple<Indexes...> > -{ typedef index_tuple<Indexes...> type; }; - -template<class ...Types> -struct typelist -{}; - -//invert_typelist -template<class T> -struct invert_typelist; - -template<int I, typename Tuple> -struct typelist_element; - -template<int I, typename Head, typename... Tail> -struct typelist_element<I, typelist<Head, Tail...> > -{ - typedef typename typelist_element<I-1, typelist<Tail...> >::type type; -}; - -template<typename Head, typename... Tail> -struct typelist_element<0, typelist<Head, Tail...> > -{ - typedef Head type; -}; - -template<int ...Ints, class ...Types> -typelist<typename typelist_element<(sizeof...(Types) - 1) - Ints, typelist<Types...> >::type...> - inverted_typelist(index_tuple<Ints...>, typelist<Types...>) -{ - return typelist<typename typelist_element<(sizeof...(Types) - 1) - Ints, typelist<Types...> >::type...>(); -} - -//sizeof_typelist -template<class Typelist> -struct sizeof_typelist; - -template<class ...Types> -struct sizeof_typelist< typelist<Types...> > -{ - static const std::size_t value = sizeof...(Types); -}; - -//invert_typelist_impl -template<class Typelist, class Indexes> -struct invert_typelist_impl; - - -template<class Typelist, int ...Ints> -struct invert_typelist_impl< Typelist, index_tuple<Ints...> > -{ - static const std::size_t last_idx = sizeof_typelist<Typelist>::value - 1; - typedef typelist - <typename typelist_element<last_idx - Ints, Typelist>::type...> type; -}; - -template<class Typelist, int Int> -struct invert_typelist_impl< Typelist, index_tuple<Int> > -{ - typedef Typelist type; -}; - -template<class Typelist> -struct invert_typelist_impl< Typelist, index_tuple<> > -{ - typedef Typelist type; -}; - -//invert_typelist -template<class Typelist> -struct invert_typelist; - -template<class ...Types> -struct invert_typelist< typelist<Types...> > -{ - typedef typelist<Types...> typelist_t; - typedef typename build_number_seq<sizeof...(Types)>::type indexes_t; - typedef typename invert_typelist_impl<typelist_t, indexes_t>::type type; -}; - -//Do pack -template<class Typelist> -struct do_pack; - -template<> -struct do_pack<typelist<> >; - -template<class Prev> -struct do_pack<typelist<Prev> > -{ - typedef Prev type; -}; - -template<class Prev, class Last> -struct do_pack<typelist<Prev, Last> > -{ - typedef typename Prev::template pack<Last> type; -}; - -template<class ...Others> -struct do_pack<typelist<void, Others...> > -{ - typedef typename do_pack<typelist<Others...> >::type type; -}; - -template<class Prev, class ...Others> -struct do_pack<typelist<Prev, Others...> > -{ - typedef typename Prev::template pack - <typename do_pack<typelist<Others...> >::type> type; -}; - - -template<class DefaultOptions, class ...Options> -struct pack_options -{ - typedef typelist<DefaultOptions, Options...> typelist_t; - typedef typename invert_typelist<typelist_t>::type inverted_typelist; - typedef typename do_pack<inverted_typelist>::type type; -}; - -#endif //!defined(BOOST_INTRUSIVE_VARIADIC_TEMPLATES) - -#define BOOST_INTRUSIVE_OPTION_TYPE(OPTION_NAME, TYPE, TYPEDEF_EXPR, TYPEDEF_NAME) \ -template< class TYPE> \ -struct OPTION_NAME \ -{ \ - template<class Base> \ - struct pack : Base \ - { \ - typedef TYPEDEF_EXPR TYPEDEF_NAME; \ - }; \ -}; \ -// - -#define BOOST_INTRUSIVE_OPTION_CONSTANT(OPTION_NAME, TYPE, VALUE, CONSTANT_NAME) \ -template< TYPE VALUE> \ -struct OPTION_NAME \ -{ \ - template<class Base> \ - struct pack : Base \ - { \ - static const TYPE CONSTANT_NAME = VALUE; \ - }; \ -}; \ -// - -#else //#ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - -//! This class is a utility that takes: -//! - a default options class defining initial static constant -//! and typedefs -//! - several options defined with BOOST_INTRUSIVE_OPTION_CONSTANT and -//! BOOST_INTRUSIVE_OPTION_TYPE -//! -//! and packs them together in a new type that defines all options as -//! member typedefs or static constant values. Given options of form: -//! -//! \code -//! BOOST_INTRUSIVE_OPTION_TYPE(my_pointer, VoidPointer, VoidPointer, my_pointer_type) -//! BOOST_INTRUSIVE_OPTION_CONSTANT(incremental, bool, Enabled, is_incremental) -//! \endcode -//! -//! the following expression -//! -//! \code -//! -//! struct default_options -//! { -//! typedef long int_type; -//! static const int int_constant = -1; -//! }; -//! -//! pack_options< default_options, my_pointer<void*>, incremental<true> >::type -//! \endcode -//! -//! will create a type that will contain the following typedefs/constants -//! -//! \code -//! struct unspecified_type -//! { -//! //Default options -//! typedef long int_type; -//! static const int int_constant = -1; -//! -//! //Packed options (will ovewrite any default option) -//! typedef void* my_pointer_type; -//! static const bool is_incremental = true; -//! }; -//! \endcode -//! -//! If an option is specified in the default options argument and later -//! redefined as an option, the last definition will prevail. -template<class DefaultOptions, class ...Options> -struct pack_options -{ - typedef unspecified_type type; -}; - -//! Defines an option class of name OPTION_NAME that can be used to specify a type -//! of type TYPE... -//! -//! \code -//! struct OPTION_NAME<class TYPE> -//! { unspecified_content }; -//! \endcode -//! -//! ...that after being combined with -//! <code>boost::intrusive::pack_options</code>, -//! will typedef TYPE as a typedef of name TYPEDEF_NAME. Example: -//! -//! \code -//! //[includes and namespaces omitted for brevity] -//! -//! //This macro will create the following class: -//! // template<class VoidPointer> -//! // struct my_pointer -//! // { unspecified_content }; -//! BOOST_INTRUSIVE_OPTION_TYPE(my_pointer, VoidPointer, boost::remove_pointer<VoidPointer>::type, my_pointer_type) -//! -//! struct empty_default{}; -//! -//! typedef pack_options< empty_default, typename my_pointer<void*> >::type::my_pointer_type type; -//! -//! BOOST_STATIC_ASSERT(( boost::is_same<type, void>::value )); -//! -//! \endcode -#define BOOST_INTRUSIVE_OPTION_TYPE(OPTION_NAME, TYPE, TYPEDEF_EXPR, TYPEDEF_NAME) - -//! Defines an option class of name OPTION_NAME that can be used to specify a constant -//! of type TYPE with value VALUE... -//! -//! \code -//! struct OPTION_NAME<TYPE VALUE> -//! { unspecified_content }; -//! \endcode -//! -//! ...that after being combined with -//! <code>boost::intrusive::pack_options</code>, -//! will contain a CONSTANT_NAME static constant of value VALUE. Example: -//! -//! \code -//! //[includes and namespaces omitted for brevity] -//! -//! //This macro will create the following class: -//! // template<bool Enabled> -//! // struct incremental -//! // { unspecified_content }; -//! BOOST_INTRUSIVE_OPTION_CONSTANT(incremental, bool, Enabled, is_incremental) -//! -//! struct empty_default{}; -//! -//! const bool is_incremental = pack_options< empty_default, incremental<true> >::type::is_incremental; -//! -//! BOOST_STATIC_ASSERT(( is_incremental == true )); -//! -//! \endcode -#define BOOST_INTRUSIVE_OPTION_CONSTANT(OPTION_NAME, TYPE, VALUE, CONSTANT_NAME) - -#endif //#ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - -} //namespace intrusive { -} //namespace boost { - -#include <boost/intrusive/detail/config_end.hpp> - -#endif //#ifndef BOOST_INTRUSIVE_PACK_OPTIONS_HPP diff --git a/ThirdParty/boost/io/detail/buffer_fill.hpp b/ThirdParty/boost/io/detail/buffer_fill.hpp deleted file mode 100644 index b25a884473a38086d7dfdb44aba07f8a9807b2d2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/io/detail/buffer_fill.hpp +++ /dev/null @@ -1,39 +0,0 @@ -/* -Copyright 2019-2020 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_IO_DETAIL_BUFFER_FILL_HPP -#define BOOST_IO_DETAIL_BUFFER_FILL_HPP - -#include <iosfwd> -#include <cstddef> - -namespace boost { -namespace io { -namespace detail { - -template<class charT, class traits> -inline bool -buffer_fill(std::basic_streambuf<charT, traits>& buf, charT ch, - std::size_t size) -{ - charT fill[] = { ch, ch, ch, ch, ch, ch, ch, ch }; - enum { - chunk = sizeof fill / sizeof(charT) - }; - for (; size > chunk; size -= chunk) { - if (static_cast<std::size_t>(buf.sputn(fill, chunk)) != chunk) { - return false; - } - } - return static_cast<std::size_t>(buf.sputn(fill, size)) == size; -} - -} /* detail */ -} /* io */ -} /* boost */ - -#endif diff --git a/ThirdParty/boost/io/detail/ostream_guard.hpp b/ThirdParty/boost/io/detail/ostream_guard.hpp deleted file mode 100644 index 6999d8134482edff95df6463ba7494e6068e056c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/io/detail/ostream_guard.hpp +++ /dev/null @@ -1,45 +0,0 @@ -/* -Copyright 2019-2020 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_IO_DETAIL_OSTREAM_GUARD_HPP -#define BOOST_IO_DETAIL_OSTREAM_GUARD_HPP - -#include <boost/config.hpp> -#include <iosfwd> - -namespace boost { -namespace io { -namespace detail { - -template<class Char, class Traits> -class ostream_guard { -public: - explicit ostream_guard(std::basic_ostream<Char, Traits>& os) BOOST_NOEXCEPT - : os_(&os) { } - - ~ostream_guard() BOOST_NOEXCEPT_IF(false) { - if (os_) { - os_->setstate(std::basic_ostream<Char, Traits>::badbit); - } - } - - void release() BOOST_NOEXCEPT { - os_ = 0; - } - -private: - ostream_guard(const ostream_guard&); - ostream_guard& operator=(const ostream_guard&); - - std::basic_ostream<Char, Traits>* os_; -}; - -} /* detail */ -} /* io */ -} /* boost */ - -#endif diff --git a/ThirdParty/boost/io/ios_state.hpp b/ThirdParty/boost/io/ios_state.hpp deleted file mode 100644 index 632a12202d2f36aaf32cda3eac9b4467e1e8aff0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/io/ios_state.hpp +++ /dev/null @@ -1,485 +0,0 @@ -/* -Copyright 2002, 2005 Daryle Walker - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_IO_IOS_STATE_HPP -#define BOOST_IO_IOS_STATE_HPP - -#include <boost/config.hpp> -#include <boost/io_fwd.hpp> -#include <ios> -#ifndef BOOST_NO_STD_LOCALE -#include <locale> -#endif -#include <ostream> -#include <streambuf> -#include <string> - -namespace boost { -namespace io { - -class ios_flags_saver { -public: - typedef std::ios_base state_type; - typedef std::ios_base::fmtflags aspect_type; - - explicit ios_flags_saver(state_type& s) - : s_save_(s) - , a_save_(s.flags()) { } - - ios_flags_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.flags(a)) { } - - ~ios_flags_saver() { - this->restore(); - } - - void restore() { - s_save_.flags(a_save_); - } - -private: - ios_flags_saver(const ios_flags_saver&); - ios_flags_saver& operator=(const ios_flags_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -class ios_precision_saver { -public: - typedef std::ios_base state_type; - typedef std::streamsize aspect_type; - - explicit ios_precision_saver(state_type& s) - : s_save_(s) - , a_save_(s.precision()) { } - - ios_precision_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.precision(a)) { } - - ~ios_precision_saver() { - this->restore(); - } - - void restore() { - s_save_.precision(a_save_); - } - -private: - ios_precision_saver(const ios_precision_saver&); - ios_precision_saver& operator=(const ios_precision_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -class ios_width_saver { -public: - typedef std::ios_base state_type; - typedef std::streamsize aspect_type; - - explicit ios_width_saver(state_type& s) - : s_save_(s) - , a_save_(s.width()) { } - - ios_width_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.width(a)) { } - - ~ios_width_saver() { - this->restore(); - } - - void restore() { - s_save_.width(a_save_); - } - -private: - ios_width_saver(const ios_width_saver&); - ios_width_saver& operator=(const ios_width_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -template<class Ch, class Tr> -class basic_ios_iostate_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef std::ios_base::iostate aspect_type; - - explicit basic_ios_iostate_saver(state_type& s) - : s_save_(s) - , a_save_(s.rdstate()) { } - - basic_ios_iostate_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.rdstate()) { - s.clear(a); - } - - ~basic_ios_iostate_saver() { - this->restore(); - } - - void restore() { - s_save_.clear(a_save_); - } - -private: - basic_ios_iostate_saver(const basic_ios_iostate_saver&); - basic_ios_iostate_saver& operator=(const basic_ios_iostate_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -template<class Ch, class Tr> -class basic_ios_exception_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef std::ios_base::iostate aspect_type; - - explicit basic_ios_exception_saver(state_type& s) - : s_save_(s) - , a_save_(s.exceptions()) { } - - basic_ios_exception_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.exceptions()) { - s.exceptions(a); - } - - ~basic_ios_exception_saver() { - this->restore(); - } - - void restore() { - s_save_.exceptions(a_save_); - } - -private: - basic_ios_exception_saver(const basic_ios_exception_saver&); - basic_ios_exception_saver& operator=(const basic_ios_exception_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -template<class Ch, class Tr> -class basic_ios_tie_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef std::basic_ostream<Ch, Tr>* aspect_type; - - explicit basic_ios_tie_saver(state_type& s) - : s_save_(s) - , a_save_(s.tie()) { } - - basic_ios_tie_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.tie(a)) { } - - ~basic_ios_tie_saver() { - this->restore(); - } - - void restore() { - s_save_.tie(a_save_); - } - -private: - basic_ios_tie_saver(const basic_ios_tie_saver&); - basic_ios_tie_saver& operator=(const basic_ios_tie_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -template<class Ch, class Tr> -class basic_ios_rdbuf_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef std::basic_streambuf<Ch, Tr>* aspect_type; - - explicit basic_ios_rdbuf_saver(state_type& s) - : s_save_(s) - , a_save_(s.rdbuf()) { } - - basic_ios_rdbuf_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.rdbuf(a)) { } - - ~basic_ios_rdbuf_saver() { - this->restore(); - } - - void restore() { - s_save_.rdbuf(a_save_); - } - -private: - basic_ios_rdbuf_saver(const basic_ios_rdbuf_saver&); - basic_ios_rdbuf_saver& operator=(const basic_ios_rdbuf_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -template<class Ch, class Tr> -class basic_ios_fill_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef typename state_type::char_type aspect_type; - - explicit basic_ios_fill_saver(state_type& s) - : s_save_(s) - , a_save_(s.fill()) { } - - basic_ios_fill_saver(state_type& s, aspect_type a) - : s_save_(s) - , a_save_(s.fill(a)) { } - - ~basic_ios_fill_saver() { - this->restore(); - } - - void restore() { - s_save_.fill(a_save_); - } - -private: - basic_ios_fill_saver(const basic_ios_fill_saver&); - basic_ios_fill_saver& operator=(const basic_ios_fill_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; - -#ifndef BOOST_NO_STD_LOCALE -template<class Ch, class Tr> -class basic_ios_locale_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - typedef std::locale aspect_type; - - explicit basic_ios_locale_saver(state_type& s) - : s_save_(s) - , a_save_(s.getloc()) { } - - basic_ios_locale_saver(state_type& s, const aspect_type& a) - : s_save_(s) - , a_save_(s.imbue(a)) { } - - ~basic_ios_locale_saver() { - this->restore(); - } - - void restore() { - s_save_.imbue(a_save_); - } - -private: - basic_ios_locale_saver(const basic_ios_locale_saver&); - basic_ios_locale_saver& operator=(const basic_ios_locale_saver&); - - state_type& s_save_; - aspect_type a_save_; -}; -#endif - -class ios_iword_saver { -public: - typedef std::ios_base state_type; - typedef int index_type; - typedef long aspect_type; - - explicit ios_iword_saver(state_type& s, index_type i) - : s_save_(s) - , a_save_(s.iword(i)) - , i_save_(i) { } - - ios_iword_saver(state_type& s, index_type i, aspect_type a) - : s_save_(s) - , a_save_(s.iword(i)) - , i_save_(i) { - s.iword(i) = a; - } - - ~ios_iword_saver() { - this->restore(); - } - - void restore() { - s_save_.iword(i_save_) = a_save_; - } - -private: - ios_iword_saver(const ios_iword_saver&); - ios_iword_saver& operator=(const ios_iword_saver&); - - state_type& s_save_; - aspect_type a_save_; - index_type i_save_; -}; - -class ios_pword_saver { -public: - typedef std::ios_base state_type; - typedef int index_type; - typedef void* aspect_type; - - explicit ios_pword_saver(state_type& s, index_type i) - : s_save_(s) - , a_save_(s.pword(i)) - , i_save_(i) { } - - ios_pword_saver(state_type& s, index_type i, aspect_type a) - : s_save_(s) - , a_save_(s.pword(i)) - , i_save_(i) { - s.pword(i) = a; - } - - ~ios_pword_saver() { - this->restore(); - } - - void restore() { - s_save_.pword(i_save_) = a_save_; - } - -private: - ios_pword_saver(const ios_pword_saver&); - ios_pword_saver operator=(const ios_pword_saver&); - - state_type& s_save_; - aspect_type a_save_; - index_type i_save_; -}; - -class ios_base_all_saver { -public: - typedef std::ios_base state_type; - - explicit ios_base_all_saver(state_type& s) - : s_save_(s) - , a1_save_(s.flags()) - , a2_save_(s.precision()) - , a3_save_(s.width()) { } - - ~ios_base_all_saver() { - this->restore(); - } - - void restore() { - s_save_.width(a3_save_); - s_save_.precision(a2_save_); - s_save_.flags(a1_save_); - } - -private: - ios_base_all_saver(const ios_base_all_saver&); - ios_base_all_saver& operator=(const ios_base_all_saver&); - - state_type& s_save_; - state_type::fmtflags a1_save_; - std::streamsize a2_save_; - std::streamsize a3_save_; -}; - -template<class Ch, class Tr> -class basic_ios_all_saver { -public: - typedef std::basic_ios<Ch, Tr> state_type; - - explicit basic_ios_all_saver(state_type& s) - : s_save_(s) - , a1_save_(s.flags()) - , a2_save_(s.precision()) - , a3_save_(s.width()) - , a4_save_(s.rdstate()) - , a5_save_(s.exceptions()) - , a6_save_(s.tie()) - , a7_save_(s.rdbuf()) - , a8_save_(s.fill()) -#ifndef BOOST_NO_STD_LOCALE - , a9_save_(s.getloc()) -#endif - { } - - ~basic_ios_all_saver() { - this->restore(); - } - - void restore() { -#ifndef BOOST_NO_STD_LOCALE - s_save_.imbue(a9_save_); -#endif - s_save_.fill(a8_save_); - s_save_.rdbuf(a7_save_); - s_save_.tie(a6_save_); - s_save_.exceptions(a5_save_); - s_save_.clear(a4_save_); - s_save_.width(a3_save_); - s_save_.precision(a2_save_); - s_save_.flags(a1_save_); - } - -private: - basic_ios_all_saver(const basic_ios_all_saver&); - basic_ios_all_saver& operator=(const basic_ios_all_saver&); - - state_type& s_save_; - typename state_type::fmtflags a1_save_; - std::streamsize a2_save_; - std::streamsize a3_save_; - typename state_type::iostate a4_save_; - typename state_type::iostate a5_save_; - std::basic_ostream<Ch, Tr>* a6_save_; - std::basic_streambuf<Ch, Tr>* a7_save_; - typename state_type::char_type a8_save_; -#ifndef BOOST_NO_STD_LOCALE - std::locale a9_save_; -#endif -}; - -class ios_all_word_saver { -public: - typedef std::ios_base state_type; - typedef int index_type; - - ios_all_word_saver(state_type& s, index_type i) - : s_save_(s) - , i_save_(i) - , a1_save_(s.iword(i)) - , a2_save_(s.pword(i)) { } - - ~ios_all_word_saver() { - this->restore(); - } - - void restore() { - s_save_.pword(i_save_) = a2_save_; - s_save_.iword(i_save_) = a1_save_; - } - -private: - ios_all_word_saver(const ios_all_word_saver&); - ios_all_word_saver& operator=(const ios_all_word_saver&); - - state_type& s_save_; - index_type i_save_; - long a1_save_; - void* a2_save_; -}; - -} /* io */ -} /* boost */ - -#endif diff --git a/ThirdParty/boost/io/quoted.hpp b/ThirdParty/boost/io/quoted.hpp deleted file mode 100644 index fc7d205e822adab4a9854132f837c38425d98d6d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/io/quoted.hpp +++ /dev/null @@ -1,217 +0,0 @@ -/* -Copyright 2010 Beman Dawes - -Copyright 2019-2020 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_IO_QUOTED_HPP -#define BOOST_IO_QUOTED_HPP - -#include <boost/io/detail/buffer_fill.hpp> -#include <boost/io/detail/ostream_guard.hpp> -#include <boost/io/ios_state.hpp> - -namespace boost { -namespace io { -namespace detail { - -template<class String, class Char> -struct quoted_proxy { - String string; - Char escape; - Char delim; -}; - -template<class Char> -struct quoted_state { - const Char* string; - std::size_t size; - std::size_t count; -}; - -template<class Char> -inline quoted_state<Char> -quoted_start(const Char* string, Char escape, Char delim) -{ - const Char* end = string; - std::size_t count = 2; - for (Char ch; (ch = *end) != 0; ++end) { - count += 1 + (ch == escape || ch == delim); - } - quoted_state<Char> state = { string, - static_cast<std::size_t>(end - string), count }; - return state; -} - -template<class Char, class String> -inline quoted_state<Char> -quoted_start(const String* string, Char escape, Char delim) -{ - const Char* begin = string->data(); - std::size_t size = string->size(); - std::size_t count = 2; - for (const Char *it = begin, *end = begin + size; it != end; ++it) { - Char ch = *it; - count += 1 + (ch == escape || ch == delim); - } - quoted_state<Char> state = { begin, size, count }; - return state; -} - -template<class Char, class Traits> -inline bool -quoted_put(std::basic_streambuf<Char, Traits>& buf, const Char* string, - std::size_t size, std::size_t count, Char escape, Char delim) -{ - if (buf.sputc(delim) == Traits::eof()) { - return false; - } - if (size == count) { - if (static_cast<std::size_t>(buf.sputn(string, size)) != size) { - return false; - } - } else { - for (const Char* end = string + size; string != end; ++string) { - Char ch = *string; - if ((ch == escape || ch == delim) && - buf.sputc(escape) == Traits::eof()) { - return false; - } - if (buf.sputc(ch) == Traits::eof()) { - return false; - } - } - } - return buf.sputc(delim) != Traits::eof(); -} - -template<class Char, class Traits, class String> -inline std::basic_ostream<Char, Traits>& -quoted_out(std::basic_ostream<Char, Traits>& os, String* string, Char escape, - Char delim) -{ - typedef std::basic_ostream<Char, Traits> stream; - ostream_guard<Char, Traits> guard(os); - typename stream::sentry entry(os); - if (entry) { - quoted_state<Char> state = boost::io::detail::quoted_start(string, - escape, delim); - std::basic_streambuf<Char, Traits>& buf = *os.rdbuf(); - std::size_t width = static_cast<std::size_t>(os.width()); - if (width <= state.count) { - if (!boost::io::detail::quoted_put(buf, state.string, state.size, - state.count, escape, delim)) { - return os; - } - } else if ((os.flags() & stream::adjustfield) == stream::left) { - if (!boost::io::detail::quoted_put(buf, state.string, state.size, - state.count, escape, delim) || - !boost::io::detail::buffer_fill(buf, os.fill(), - width - state.count)) { - return os; - } - } else if (!boost::io::detail::buffer_fill(buf, os.fill(), - width - state.count) || - !boost::io::detail::quoted_put(buf, state.string, state.size, - state.count, escape, delim)) { - return os; - } - os.width(0); - } - guard.release(); - return os; -} - -template<class Char, class Traits> -inline std::basic_ostream<Char, Traits>& -operator<<(std::basic_ostream<Char, Traits>& os, - const quoted_proxy<const Char*, Char>& proxy) -{ - return boost::io::detail::quoted_out(os, proxy.string, proxy.escape, - proxy.delim); -} - -template <class Char, class Traits, class Alloc> -inline std::basic_ostream<Char, Traits>& -operator<<(std::basic_ostream<Char, Traits>& os, - const quoted_proxy<const std::basic_string<Char, Traits, Alloc>*, - Char>& proxy) -{ - return boost::io::detail::quoted_out(os, proxy.string, proxy.escape, - proxy.delim); -} - -template<class Char, class Traits, class Alloc> -inline std::basic_ostream<Char, Traits>& -operator<<(std::basic_ostream<Char, Traits>& os, - const quoted_proxy<std::basic_string<Char, Traits, Alloc>*, Char>& proxy) -{ - return boost::io::detail::quoted_out(os, proxy.string, proxy.escape, - proxy.delim); -} - -template<class Char, class Traits, class Alloc> -inline std::basic_istream<Char, Traits>& -operator>>(std::basic_istream<Char, Traits>& is, - const quoted_proxy<std::basic_string<Char, Traits, Alloc>*, Char>& proxy) -{ - Char ch; - if (!(is >> ch)) { - return is; - } - if (ch != proxy.delim) { - is.unget(); - return is >> *proxy.string; - } - { - boost::io::ios_flags_saver ifs(is); - std::noskipws(is); - proxy.string->clear(); - while ((is >> ch) && ch != proxy.delim) { - if (ch == proxy.escape && !(is >> ch)) { - break; - } - proxy.string->push_back(ch); - } - } - return is; -} - -} /* detail */ - -template<class Char, class Traits, class Alloc> -inline detail::quoted_proxy<const std::basic_string<Char, Traits, Alloc>*, - Char> -quoted(const std::basic_string<Char, Traits, Alloc>& s, Char escape='\\', - Char delim='\"') -{ - detail::quoted_proxy<const std::basic_string<Char, Traits, Alloc>*, - Char> proxy = { &s, escape, delim }; - return proxy; -} - -template<class Char, class Traits, class Alloc> -inline detail::quoted_proxy<std::basic_string<Char, Traits, Alloc>*, Char> -quoted(std::basic_string<Char, Traits, Alloc>& s, Char escape='\\', - Char delim='\"') -{ - detail::quoted_proxy<std::basic_string<Char, Traits, Alloc>*, - Char> proxy = { &s, escape, delim }; - return proxy; -} - -template<class Char> -inline detail::quoted_proxy<const Char*, Char> -quoted(const Char* s, Char escape='\\', Char delim='\"') -{ - detail::quoted_proxy<const Char*, Char> proxy = { s, escape, delim }; - return proxy; -} - -} /* io */ -} /* boost */ - -#endif diff --git a/ThirdParty/boost/io_fwd.hpp b/ThirdParty/boost/io_fwd.hpp deleted file mode 100644 index 2594d4e8dd5d6dbbe507d932a4dacf346d916c92..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/io_fwd.hpp +++ /dev/null @@ -1,63 +0,0 @@ -/* -Copyright 2002 Daryle Walker - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_IO_FWD_HPP -#define BOOST_IO_FWD_HPP - -#include <iosfwd> - -namespace boost { -namespace io { - -class ios_flags_saver; -class ios_precision_saver; -class ios_width_saver; -class ios_base_all_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_iostate_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_exception_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_tie_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_rdbuf_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_fill_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_locale_saver; - -template<class Ch, class Tr = std::char_traits<Ch> > -class basic_ios_all_saver; - -typedef basic_ios_iostate_saver<char> ios_iostate_saver; -typedef basic_ios_iostate_saver<wchar_t> wios_iostate_saver; -typedef basic_ios_exception_saver<char> ios_exception_saver; -typedef basic_ios_exception_saver<wchar_t> wios_exception_saver; -typedef basic_ios_tie_saver<char> ios_tie_saver; -typedef basic_ios_tie_saver<wchar_t> wios_tie_saver; -typedef basic_ios_rdbuf_saver<char> ios_rdbuf_saver; -typedef basic_ios_rdbuf_saver<wchar_t> wios_rdbuf_saver; -typedef basic_ios_fill_saver<char> ios_fill_saver; -typedef basic_ios_fill_saver<wchar_t> wios_fill_saver; -typedef basic_ios_locale_saver<char> ios_locale_saver; -typedef basic_ios_locale_saver<wchar_t> wios_locale_saver; -typedef basic_ios_all_saver<char> ios_all_saver; -typedef basic_ios_all_saver<wchar_t> wios_all_saver; - -class ios_iword_saver; -class ios_pword_saver; -class ios_all_word_saver; - -} /* io */ -} /* boost */ - -#endif diff --git a/ThirdParty/boost/lexical_cast.hpp b/ThirdParty/boost/lexical_cast.hpp deleted file mode 100644 index 174883c0fc5fc03dd48672ed2ac2e1731a8c86c3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast.hpp +++ /dev/null @@ -1,105 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_INCLUDED -#define BOOST_LEXICAL_CAST_INCLUDED - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_WSTRING) -#define BOOST_LCAST_NO_WCHAR_T -#endif - -#include <boost/range/iterator_range_core.hpp> -#include <boost/lexical_cast/bad_lexical_cast.hpp> -#include <boost/lexical_cast/try_lexical_convert.hpp> - -namespace boost -{ - template <typename Target, typename Source> - inline Target lexical_cast(const Source &arg) - { - Target result = Target(); - - if (!boost::conversion::detail::try_lexical_convert(arg, result)) { - boost::conversion::detail::throw_bad_cast<Source, Target>(); - } - - return result; - } - - template <typename Target> - inline Target lexical_cast(const char* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const char*>(chars, chars + count) - ); - } - - template <typename Target> - inline Target lexical_cast(const unsigned char* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const unsigned char*>(chars, chars + count) - ); - } - - template <typename Target> - inline Target lexical_cast(const signed char* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const signed char*>(chars, chars + count) - ); - } - -#ifndef BOOST_LCAST_NO_WCHAR_T - template <typename Target> - inline Target lexical_cast(const wchar_t* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const wchar_t*>(chars, chars + count) - ); - } -#endif -#ifndef BOOST_NO_CXX11_CHAR16_T - template <typename Target> - inline Target lexical_cast(const char16_t* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const char16_t*>(chars, chars + count) - ); - } -#endif -#ifndef BOOST_NO_CXX11_CHAR32_T - template <typename Target> - inline Target lexical_cast(const char32_t* chars, std::size_t count) - { - return ::boost::lexical_cast<Target>( - ::boost::iterator_range<const char32_t*>(chars, chars + count) - ); - } -#endif - -} // namespace boost - -#undef BOOST_LCAST_NO_WCHAR_T - -#endif // BOOST_LEXICAL_CAST_INCLUDED - diff --git a/ThirdParty/boost/lexical_cast/bad_lexical_cast.hpp b/ThirdParty/boost/lexical_cast/bad_lexical_cast.hpp deleted file mode 100644 index 481c08a1aed7dcbbaa208314cd6eab98879966b2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/bad_lexical_cast.hpp +++ /dev/null @@ -1,108 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_BAD_LEXICAL_CAST_HPP -#define BOOST_LEXICAL_CAST_BAD_LEXICAL_CAST_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#include <typeinfo> -#include <exception> -#include <boost/throw_exception.hpp> - -namespace boost -{ - // exception used to indicate runtime lexical_cast failure - class BOOST_SYMBOL_VISIBLE bad_lexical_cast : - // workaround MSVC bug with std::bad_cast when _HAS_EXCEPTIONS == 0 -#if defined(BOOST_MSVC) && defined(_HAS_EXCEPTIONS) && !_HAS_EXCEPTIONS - public std::exception -#else - public std::bad_cast -#endif - -#if defined(__BORLANDC__) && BOOST_WORKAROUND( __BORLANDC__, < 0x560 ) - // under bcc32 5.5.1 bad_cast doesn't derive from exception - , public std::exception -#endif - - { - public: - bad_lexical_cast() BOOST_NOEXCEPT -#ifndef BOOST_NO_TYPEID - : source(&typeid(void)), target(&typeid(void)) -#endif - {} - - virtual const char *what() const BOOST_NOEXCEPT_OR_NOTHROW { - return "bad lexical cast: " - "source type value could not be interpreted as target"; - } - - virtual ~bad_lexical_cast() BOOST_NOEXCEPT_OR_NOTHROW - {} - -#ifndef BOOST_NO_TYPEID - private: -#ifdef BOOST_NO_STD_TYPEINFO - typedef ::type_info type_info_t; -#else - typedef ::std::type_info type_info_t; -#endif - public: - bad_lexical_cast( - const type_info_t &source_type_arg, - const type_info_t &target_type_arg) BOOST_NOEXCEPT - : source(&source_type_arg), target(&target_type_arg) - {} - - const type_info_t &source_type() const BOOST_NOEXCEPT { - return *source; - } - - const type_info_t &target_type() const BOOST_NOEXCEPT { - return *target; - } - - private: - const type_info_t *source; - const type_info_t *target; -#endif - }; - - namespace conversion { namespace detail { -#ifdef BOOST_NO_TYPEID - template <class S, class T> - inline void throw_bad_cast() { - boost::throw_exception(bad_lexical_cast()); - } -#else - template <class S, class T> - inline void throw_bad_cast() { - boost::throw_exception(bad_lexical_cast(typeid(S), typeid(T))); - } -#endif - }} // namespace conversion::detail - - -} // namespace boost - -#endif // BOOST_LEXICAL_CAST_BAD_LEXICAL_CAST_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/converter_lexical.hpp b/ThirdParty/boost/lexical_cast/detail/converter_lexical.hpp deleted file mode 100644 index 92e35c88b906840eb698d0e40b59ef40e456289b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/converter_lexical.hpp +++ /dev/null @@ -1,498 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_HPP -#define BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_WSTRING) -#define BOOST_LCAST_NO_WCHAR_T -#endif - -#include <cstddef> -#include <string> -#include <boost/limits.hpp> -#include <boost/type_traits/integral_constant.hpp> -#include <boost/type_traits/type_identity.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <boost/type_traits/is_float.hpp> -#include <boost/type_traits/has_left_shift.hpp> -#include <boost/type_traits/has_right_shift.hpp> -#include <boost/static_assert.hpp> -#include <boost/detail/lcast_precision.hpp> - -#include <boost/lexical_cast/detail/widest_char.hpp> -#include <boost/lexical_cast/detail/is_character.hpp> - -#ifndef BOOST_NO_CXX11_HDR_ARRAY -#include <array> -#endif - -#include <boost/array.hpp> -#include <boost/range/iterator_range_core.hpp> -#include <boost/container/container_fwd.hpp> - -#include <boost/lexical_cast/detail/converter_lexical_streams.hpp> - -namespace boost { - - namespace detail // normalize_single_byte_char<Char> - { - // Converts signed/unsigned char to char - template < class Char > - struct normalize_single_byte_char - { - typedef Char type; - }; - - template <> - struct normalize_single_byte_char< signed char > - { - typedef char type; - }; - - template <> - struct normalize_single_byte_char< unsigned char > - { - typedef char type; - }; - } - - namespace detail // deduce_character_type_later<T> - { - // Helper type, meaning that stram character for T must be deduced - // at Stage 2 (See deduce_source_char<T> and deduce_target_char<T>) - template < class T > struct deduce_character_type_later {}; - } - - namespace detail // stream_char_common<T> - { - // Selectors to choose stream character type (common for Source and Target) - // Returns one of char, wchar_t, char16_t, char32_t or deduce_character_type_later<T> types - // Executed on Stage 1 (See deduce_source_char<T> and deduce_target_char<T>) - template < typename Type > - struct stream_char_common: public boost::conditional< - boost::detail::is_character< Type >::value, - Type, - boost::detail::deduce_character_type_later< Type > - > {}; - - template < typename Char > - struct stream_char_common< Char* >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< Char* > - > {}; - - template < typename Char > - struct stream_char_common< const Char* >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< const Char* > - > {}; - - template < typename Char > - struct stream_char_common< boost::iterator_range< Char* > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< boost::iterator_range< Char* > > - > {}; - - template < typename Char > - struct stream_char_common< boost::iterator_range< const Char* > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< boost::iterator_range< const Char* > > - > {}; - - template < class Char, class Traits, class Alloc > - struct stream_char_common< std::basic_string< Char, Traits, Alloc > > - { - typedef Char type; - }; - - template < class Char, class Traits, class Alloc > - struct stream_char_common< boost::container::basic_string< Char, Traits, Alloc > > - { - typedef Char type; - }; - - template < typename Char, std::size_t N > - struct stream_char_common< boost::array< Char, N > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< boost::array< Char, N > > - > {}; - - template < typename Char, std::size_t N > - struct stream_char_common< boost::array< const Char, N > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< boost::array< const Char, N > > - > {}; - -#ifndef BOOST_NO_CXX11_HDR_ARRAY - template < typename Char, std::size_t N > - struct stream_char_common< std::array<Char, N > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< std::array< Char, N > > - > {}; - - template < typename Char, std::size_t N > - struct stream_char_common< std::array< const Char, N > >: public boost::conditional< - boost::detail::is_character< Char >::value, - Char, - boost::detail::deduce_character_type_later< std::array< const Char, N > > - > {}; -#endif - -#ifdef BOOST_HAS_INT128 - template <> struct stream_char_common< boost::int128_type >: public boost::type_identity< char > {}; - template <> struct stream_char_common< boost::uint128_type >: public boost::type_identity< char > {}; -#endif - -#if !defined(BOOST_LCAST_NO_WCHAR_T) && defined(BOOST_NO_INTRINSIC_WCHAR_T) - template <> - struct stream_char_common< wchar_t > - { - typedef char type; - }; -#endif - } - - namespace detail // deduce_source_char_impl<T> - { - // If type T is `deduce_character_type_later` type, then tries to deduce - // character type using boost::has_left_shift<T> metafunction. - // Otherwise supplied type T is a character type, that must be normalized - // using normalize_single_byte_char<Char>. - // Executed at Stage 2 (See deduce_source_char<T> and deduce_target_char<T>) - template < class Char > - struct deduce_source_char_impl - { - typedef BOOST_DEDUCED_TYPENAME boost::detail::normalize_single_byte_char< Char >::type type; - }; - - template < class T > - struct deduce_source_char_impl< deduce_character_type_later< T > > - { - typedef boost::has_left_shift< std::basic_ostream< char >, T > result_t; - -#if defined(BOOST_LCAST_NO_WCHAR_T) - BOOST_STATIC_ASSERT_MSG((result_t::value), - "Source type is not std::ostream`able and std::wostream`s are not supported by your STL implementation"); - typedef char type; -#else - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - result_t::value, char, wchar_t - >::type type; - - BOOST_STATIC_ASSERT_MSG((result_t::value || boost::has_left_shift< std::basic_ostream< type >, T >::value), - "Source type is neither std::ostream`able nor std::wostream`able"); -#endif - }; - } - - namespace detail // deduce_target_char_impl<T> - { - // If type T is `deduce_character_type_later` type, then tries to deduce - // character type using boost::has_right_shift<T> metafunction. - // Otherwise supplied type T is a character type, that must be normalized - // using normalize_single_byte_char<Char>. - // Executed at Stage 2 (See deduce_source_char<T> and deduce_target_char<T>) - template < class Char > - struct deduce_target_char_impl - { - typedef BOOST_DEDUCED_TYPENAME normalize_single_byte_char< Char >::type type; - }; - - template < class T > - struct deduce_target_char_impl< deduce_character_type_later<T> > - { - typedef boost::has_right_shift<std::basic_istream<char>, T > result_t; - -#if defined(BOOST_LCAST_NO_WCHAR_T) - BOOST_STATIC_ASSERT_MSG((result_t::value), - "Target type is not std::istream`able and std::wistream`s are not supported by your STL implementation"); - typedef char type; -#else - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - result_t::value, char, wchar_t - >::type type; - - BOOST_STATIC_ASSERT_MSG((result_t::value || boost::has_right_shift<std::basic_istream<wchar_t>, T >::value), - "Target type is neither std::istream`able nor std::wistream`able"); -#endif - }; - } - - namespace detail // deduce_target_char<T> and deduce_source_char<T> - { - // We deduce stream character types in two stages. - // - // Stage 1 is common for Target and Source. At Stage 1 we get - // non normalized character type (may contain unsigned/signed char) - // or deduce_character_type_later<T> where T is the original type. - // Stage 1 is executed by stream_char_common<T> - // - // At Stage 2 we normalize character types or try to deduce character - // type using metafunctions. - // Stage 2 is executed by deduce_target_char_impl<T> and - // deduce_source_char_impl<T> - // - // deduce_target_char<T> and deduce_source_char<T> functions combine - // both stages - - template < class T > - struct deduce_target_char - { - typedef BOOST_DEDUCED_TYPENAME stream_char_common< T >::type stage1_type; - typedef BOOST_DEDUCED_TYPENAME deduce_target_char_impl< stage1_type >::type stage2_type; - - typedef stage2_type type; - }; - - template < class T > - struct deduce_source_char - { - typedef BOOST_DEDUCED_TYPENAME stream_char_common< T >::type stage1_type; - typedef BOOST_DEDUCED_TYPENAME deduce_source_char_impl< stage1_type >::type stage2_type; - - typedef stage2_type type; - }; - } - - namespace detail // extract_char_traits template - { - // We are attempting to get char_traits<> from T - // template parameter. Otherwise we'll be using std::char_traits<Char> - template < class Char, class T > - struct extract_char_traits - : boost::false_type - { - typedef std::char_traits< Char > trait_t; - }; - - template < class Char, class Traits, class Alloc > - struct extract_char_traits< Char, std::basic_string< Char, Traits, Alloc > > - : boost::true_type - { - typedef Traits trait_t; - }; - - template < class Char, class Traits, class Alloc> - struct extract_char_traits< Char, boost::container::basic_string< Char, Traits, Alloc > > - : boost::true_type - { - typedef Traits trait_t; - }; - } - - namespace detail // array_to_pointer_decay<T> - { - template<class T> - struct array_to_pointer_decay - { - typedef T type; - }; - - template<class T, std::size_t N> - struct array_to_pointer_decay<T[N]> - { - typedef const T * type; - }; - } - - namespace detail // lcast_src_length - { - // Return max. length of string representation of Source; - template< class Source, // Source type of lexical_cast. - class Enable = void // helper type - > - struct lcast_src_length - { - BOOST_STATIC_CONSTANT(std::size_t, value = 1); - }; - - // Helper for integral types. - // Notes on length calculation: - // Max length for 32bit int with grouping "\1" and thousands_sep ',': - // "-2,1,4,7,4,8,3,6,4,7" - // ^ - is_signed - // ^ - 1 digit not counted by digits10 - // ^^^^^^^^^^^^^^^^^^ - digits10 * 2 - // - // Constant is_specialized is used instead of constant 1 - // to prevent buffer overflow in a rare case when - // <boost/limits.hpp> doesn't add missing specialization for - // numeric_limits<T> for some integral type T. - // When is_specialized is false, the whole expression is 0. - template <class Source> - struct lcast_src_length< - Source, BOOST_DEDUCED_TYPENAME boost::enable_if<boost::is_integral<Source> >::type - > - { -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - BOOST_STATIC_CONSTANT(std::size_t, value = - std::numeric_limits<Source>::is_signed + - std::numeric_limits<Source>::is_specialized + /* == 1 */ - std::numeric_limits<Source>::digits10 * 2 - ); -#else - BOOST_STATIC_CONSTANT(std::size_t, value = 156); - BOOST_STATIC_ASSERT(sizeof(Source) * CHAR_BIT <= 256); -#endif - }; - - // Helper for floating point types. - // -1.23456789e-123456 - // ^ sign - // ^ leading digit - // ^ decimal point - // ^^^^^^^^ lcast_precision<Source>::value - // ^ "e" - // ^ exponent sign - // ^^^^^^ exponent (assumed 6 or less digits) - // sign + leading digit + decimal point + "e" + exponent sign == 5 - template<class Source> - struct lcast_src_length< - Source, BOOST_DEDUCED_TYPENAME boost::enable_if<boost::is_float<Source> >::type - > - { - -#ifndef BOOST_LCAST_NO_COMPILE_TIME_PRECISION - BOOST_STATIC_ASSERT( - std::numeric_limits<Source>::max_exponent10 <= 999999L && - std::numeric_limits<Source>::min_exponent10 >= -999999L - ); - - BOOST_STATIC_CONSTANT(std::size_t, value = - 5 + lcast_precision<Source>::value + 6 - ); -#else // #ifndef BOOST_LCAST_NO_COMPILE_TIME_PRECISION - BOOST_STATIC_CONSTANT(std::size_t, value = 156); -#endif // #ifndef BOOST_LCAST_NO_COMPILE_TIME_PRECISION - }; - } - - namespace detail // lexical_cast_stream_traits<Source, Target> - { - template <class Source, class Target> - struct lexical_cast_stream_traits { - typedef BOOST_DEDUCED_TYPENAME boost::detail::array_to_pointer_decay<Source>::type src; - typedef BOOST_DEDUCED_TYPENAME boost::remove_cv<src>::type no_cv_src; - - typedef boost::detail::deduce_source_char<no_cv_src> deduce_src_char_metafunc; - typedef BOOST_DEDUCED_TYPENAME deduce_src_char_metafunc::type src_char_t; - typedef BOOST_DEDUCED_TYPENAME boost::detail::deduce_target_char<Target>::type target_char_t; - - typedef BOOST_DEDUCED_TYPENAME boost::detail::widest_char< - target_char_t, src_char_t - >::type char_type; - -#if !defined(BOOST_NO_CXX11_CHAR16_T) && defined(BOOST_NO_CXX11_UNICODE_LITERALS) - BOOST_STATIC_ASSERT_MSG(( !boost::is_same<char16_t, src_char_t>::value - && !boost::is_same<char16_t, target_char_t>::value), - "Your compiler does not have full support for char16_t" ); -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) && defined(BOOST_NO_CXX11_UNICODE_LITERALS) - BOOST_STATIC_ASSERT_MSG(( !boost::is_same<char32_t, src_char_t>::value - && !boost::is_same<char32_t, target_char_t>::value), - "Your compiler does not have full support for char32_t" ); -#endif - - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::detail::extract_char_traits<char_type, Target>::value, - BOOST_DEDUCED_TYPENAME boost::detail::extract_char_traits<char_type, Target>, - BOOST_DEDUCED_TYPENAME boost::detail::extract_char_traits<char_type, no_cv_src> - >::type::trait_t traits; - - typedef boost::integral_constant< - bool, - boost::is_same<char, src_char_t>::value && // source is not a wide character based type - (sizeof(char) != sizeof(target_char_t)) && // target type is based on wide character - (!(boost::detail::is_character<no_cv_src>::value)) - > is_string_widening_required_t; - - typedef boost::integral_constant< - bool, - !(boost::is_integral<no_cv_src>::value || - boost::detail::is_character< - BOOST_DEDUCED_TYPENAME deduce_src_char_metafunc::stage1_type // if we did not get character type at stage1 - >::value // then we have no optimization for that type - ) - > is_source_input_not_optimized_t; - - // If we have an optimized conversion for - // Source, we do not need to construct stringbuf. - BOOST_STATIC_CONSTANT(bool, requires_stringbuf = - (is_string_widening_required_t::value || is_source_input_not_optimized_t::value) - ); - - typedef boost::detail::lcast_src_length<no_cv_src> len_t; - }; - } - - namespace detail - { - template<typename Target, typename Source> - struct lexical_converter_impl - { - typedef lexical_cast_stream_traits<Source, Target> stream_trait; - - typedef detail::lexical_istream_limited_src< - BOOST_DEDUCED_TYPENAME stream_trait::char_type, - BOOST_DEDUCED_TYPENAME stream_trait::traits, - stream_trait::requires_stringbuf, - stream_trait::len_t::value + 1 - > i_interpreter_type; - - typedef detail::lexical_ostream_limited_src< - BOOST_DEDUCED_TYPENAME stream_trait::char_type, - BOOST_DEDUCED_TYPENAME stream_trait::traits - > o_interpreter_type; - - static inline bool try_convert(const Source& arg, Target& result) { - i_interpreter_type i_interpreter; - - // Disabling ADL, by directly specifying operators. - if (!(i_interpreter.operator <<(arg))) - return false; - - o_interpreter_type out(i_interpreter.cbegin(), i_interpreter.cend()); - - // Disabling ADL, by directly specifying operators. - if(!(out.operator >>(result))) - return false; - - return true; - } - }; - } - -} // namespace boost - -#undef BOOST_LCAST_NO_WCHAR_T - -#endif // BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/converter_lexical_streams.hpp b/ThirdParty/boost/lexical_cast/detail/converter_lexical_streams.hpp deleted file mode 100644 index ffc308967c9bb8291a07c8af7fa5289a7b6931b7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/converter_lexical_streams.hpp +++ /dev/null @@ -1,786 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014, Nowember 2016 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_STREAMS_HPP -#define BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_STREAMS_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - - -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_WSTRING) -#define BOOST_LCAST_NO_WCHAR_T -#endif - -#include <cstddef> -#include <string> -#include <cstring> -#include <cstdio> -#include <boost/limits.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/is_pointer.hpp> -#include <boost/static_assert.hpp> -#include <boost/detail/workaround.hpp> - - -#ifndef BOOST_NO_STD_LOCALE -# include <locale> -#else -# ifndef BOOST_LEXICAL_CAST_ASSUME_C_LOCALE - // Getting error at this point means, that your STL library is old/lame/misconfigured. - // If nothing can be done with STL library, define BOOST_LEXICAL_CAST_ASSUME_C_LOCALE, - // but beware: lexical_cast will understand only 'C' locale delimeters and thousands - // separators. -# error "Unable to use <locale> header. Define BOOST_LEXICAL_CAST_ASSUME_C_LOCALE to force " -# error "boost::lexical_cast to use only 'C' locale during conversions." -# endif -#endif - -#ifdef BOOST_NO_STRINGSTREAM -#include <strstream> -#else -#include <sstream> -#endif - -#include <boost/lexical_cast/detail/lcast_char_constants.hpp> -#include <boost/lexical_cast/detail/lcast_unsigned_converters.hpp> -#include <boost/lexical_cast/detail/inf_nan.hpp> - -#include <istream> - -#ifndef BOOST_NO_CXX11_HDR_ARRAY -#include <array> -#endif - -#include <boost/array.hpp> -#include <boost/type_traits/make_unsigned.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <boost/type_traits/is_float.hpp> -#include <boost/range/iterator_range_core.hpp> -#include <boost/container/container_fwd.hpp> -#include <boost/integer.hpp> -#include <boost/detail/basic_pointerbuf.hpp> -#include <boost/noncopyable.hpp> -#ifndef BOOST_NO_CWCHAR -# include <cwchar> -#endif - -namespace boost { - - namespace detail // basic_unlockedbuf - { - // acts as a stream buffer which wraps around a pair of pointers - // and gives acces to internals - template <class BufferType, class CharT> - class basic_unlockedbuf : public basic_pointerbuf<CharT, BufferType> { - public: - typedef basic_pointerbuf<CharT, BufferType> base_type; - typedef BOOST_DEDUCED_TYPENAME base_type::streamsize streamsize; - -#ifndef BOOST_NO_USING_TEMPLATE - using base_type::pptr; - using base_type::pbase; - using base_type::setbuf; -#else - charT* pptr() const { return base_type::pptr(); } - charT* pbase() const { return base_type::pbase(); } - BufferType* setbuf(char_type* s, streamsize n) { return base_type::setbuf(s, n); } -#endif - }; - } - - namespace detail - { - struct do_not_construct_out_buffer_t{}; - struct do_not_construct_out_stream_t{ - do_not_construct_out_stream_t(do_not_construct_out_buffer_t*){} - }; - - template <class CharT, class Traits> - struct out_stream_helper_trait { -#if defined(BOOST_NO_STRINGSTREAM) - typedef std::ostream out_stream_t; - typedef basic_unlockedbuf<std::strstreambuf, char> stringbuffer_t; -#elif defined(BOOST_NO_STD_LOCALE) - typedef std::ostream out_stream_t; - typedef basic_unlockedbuf<std::stringbuf, char> stringbuffer_t; - typedef basic_unlockedbuf<std::streambuf, char> buffer_t; -#else - typedef std::basic_ostream<CharT, Traits> out_stream_t; - typedef basic_unlockedbuf<std::basic_stringbuf<CharT, Traits>, CharT> stringbuffer_t; - typedef basic_unlockedbuf<std::basic_streambuf<CharT, Traits>, CharT> buffer_t; -#endif - }; - } - - namespace detail // optimized stream wrappers - { - template< class CharT // a result of widest_char transformation - , class Traits - , bool RequiresStringbuffer - , std::size_t CharacterBufferSize - > - class lexical_istream_limited_src: boost::noncopyable { - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - RequiresStringbuffer, - BOOST_DEDUCED_TYPENAME out_stream_helper_trait<CharT, Traits>::out_stream_t, - do_not_construct_out_stream_t - >::type deduced_out_stream_t; - - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - RequiresStringbuffer, - BOOST_DEDUCED_TYPENAME out_stream_helper_trait<CharT, Traits>::stringbuffer_t, - do_not_construct_out_buffer_t - >::type deduced_out_buffer_t; - - deduced_out_buffer_t out_buffer; - deduced_out_stream_t out_stream; - CharT buffer[CharacterBufferSize]; - - // After the `operator <<` finishes, `[start, finish)` is - // the range to output by `operator >>` - const CharT* start; - const CharT* finish; - - public: - lexical_istream_limited_src() BOOST_NOEXCEPT - : out_buffer() - , out_stream(&out_buffer) - , start(buffer) - , finish(buffer + CharacterBufferSize) - {} - - const CharT* cbegin() const BOOST_NOEXCEPT { - return start; - } - - const CharT* cend() const BOOST_NOEXCEPT { - return finish; - } - - private: -/************************************ HELPER FUNCTIONS FOR OPERATORS << ( ... ) ********************************/ - bool shl_char(CharT ch) BOOST_NOEXCEPT { - Traits::assign(buffer[0], ch); - finish = start + 1; - return true; - } - -#ifndef BOOST_LCAST_NO_WCHAR_T - template <class T> - bool shl_char(T ch) { - BOOST_STATIC_ASSERT_MSG(( sizeof(T) <= sizeof(CharT)) , - "boost::lexical_cast does not support narrowing of char types." - "Use boost::locale instead" ); -#ifndef BOOST_LEXICAL_CAST_ASSUME_C_LOCALE - std::locale loc; - CharT const w = BOOST_USE_FACET(std::ctype<CharT>, loc).widen(ch); -#else - CharT const w = static_cast<CharT>(ch); -#endif - Traits::assign(buffer[0], w); - finish = start + 1; - return true; - } -#endif - - bool shl_char_array(CharT const* str_value) BOOST_NOEXCEPT { - start = str_value; - finish = start + Traits::length(str_value); - return true; - } - - template <class T> - bool shl_char_array(T const* str_value) { - BOOST_STATIC_ASSERT_MSG(( sizeof(T) <= sizeof(CharT)), - "boost::lexical_cast does not support narrowing of char types." - "Use boost::locale instead" ); - return shl_input_streamable(str_value); - } - - bool shl_char_array_limited(CharT const* str, std::size_t max_size) BOOST_NOEXCEPT { - start = str; - finish = std::find(start, start + max_size, Traits::to_char_type(0)); - return true; - } - - template<typename InputStreamable> - bool shl_input_streamable(InputStreamable& input) { -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_LOCALE) - // If you have compilation error at this point, than your STL library - // does not support such conversions. Try updating it. - BOOST_STATIC_ASSERT((boost::is_same<char, CharT>::value)); -#endif - -#ifndef BOOST_NO_EXCEPTIONS - out_stream.exceptions(std::ios::badbit); - try { -#endif - bool const result = !(out_stream << input).fail(); - const deduced_out_buffer_t* const p = static_cast<deduced_out_buffer_t*>( - out_stream.rdbuf() - ); - start = p->pbase(); - finish = p->pptr(); - return result; -#ifndef BOOST_NO_EXCEPTIONS - } catch (const ::std::ios_base::failure& /*f*/) { - return false; - } -#endif - } - - template <class T> - inline bool shl_unsigned(const T n) { - CharT* tmp_finish = buffer + CharacterBufferSize; - start = lcast_put_unsigned<Traits, T, CharT>(n, tmp_finish).convert(); - finish = tmp_finish; - return true; - } - - template <class T> - inline bool shl_signed(const T n) { - CharT* tmp_finish = buffer + CharacterBufferSize; - typedef BOOST_DEDUCED_TYPENAME boost::make_unsigned<T>::type utype; - CharT* tmp_start = lcast_put_unsigned<Traits, utype, CharT>(lcast_to_unsigned(n), tmp_finish).convert(); - if (n < 0) { - --tmp_start; - CharT const minus = lcast_char_constants<CharT>::minus; - Traits::assign(*tmp_start, minus); - } - start = tmp_start; - finish = tmp_finish; - return true; - } - - template <class T, class SomeCharT> - bool shl_real_type(const T& val, SomeCharT* /*begin*/) { - lcast_set_precision(out_stream, &val); - return shl_input_streamable(val); - } - - bool shl_real_type(float val, char* begin) { - using namespace std; - const double val_as_double = val; - finish = start + -#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - sprintf_s(begin, CharacterBufferSize, -#else - sprintf(begin, -#endif - "%.*g", static_cast<int>(boost::detail::lcast_get_precision<float>()), val_as_double); - return finish > start; - } - - bool shl_real_type(double val, char* begin) { - using namespace std; - finish = start + -#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - sprintf_s(begin, CharacterBufferSize, -#else - sprintf(begin, -#endif - "%.*g", static_cast<int>(boost::detail::lcast_get_precision<double>()), val); - return finish > start; - } - -#ifndef __MINGW32__ - bool shl_real_type(long double val, char* begin) { - using namespace std; - finish = start + -#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - sprintf_s(begin, CharacterBufferSize, -#else - sprintf(begin, -#endif - "%.*Lg", static_cast<int>(boost::detail::lcast_get_precision<long double>()), val ); - return finish > start; - } -#endif - - -#if !defined(BOOST_LCAST_NO_WCHAR_T) && !defined(BOOST_NO_SWPRINTF) && !defined(__MINGW32__) - bool shl_real_type(float val, wchar_t* begin) { - using namespace std; - const double val_as_double = val; - finish = start + swprintf(begin, CharacterBufferSize, - L"%.*g", - static_cast<int>(boost::detail::lcast_get_precision<float >()), - val_as_double ); - return finish > start; - } - - bool shl_real_type(double val, wchar_t* begin) { - using namespace std; - finish = start + swprintf(begin, CharacterBufferSize, - L"%.*g", static_cast<int>(boost::detail::lcast_get_precision<double >()), val ); - return finish > start; - } - - bool shl_real_type(long double val, wchar_t* begin) { - using namespace std; - finish = start + swprintf(begin, CharacterBufferSize, - L"%.*Lg", static_cast<int>(boost::detail::lcast_get_precision<long double >()), val ); - return finish > start; - } -#endif - template <class T> - bool shl_real(T val) { - CharT* tmp_finish = buffer + CharacterBufferSize; - if (put_inf_nan(buffer, tmp_finish, val)) { - finish = tmp_finish; - return true; - } - - return shl_real_type(val, static_cast<CharT*>(buffer)); - } - -/************************************ OPERATORS << ( ... ) ********************************/ - public: - template<class Alloc> - bool operator<<(std::basic_string<CharT,Traits,Alloc> const& str) BOOST_NOEXCEPT { - start = str.data(); - finish = start + str.length(); - return true; - } - - template<class Alloc> - bool operator<<(boost::container::basic_string<CharT,Traits,Alloc> const& str) BOOST_NOEXCEPT { - start = str.data(); - finish = start + str.length(); - return true; - } - - bool operator<<(bool value) BOOST_NOEXCEPT { - CharT const czero = lcast_char_constants<CharT>::zero; - Traits::assign(buffer[0], Traits::to_char_type(czero + value)); - finish = start + 1; - return true; - } - - template <class C> - BOOST_DEDUCED_TYPENAME boost::disable_if<boost::is_const<C>, bool>::type - operator<<(const iterator_range<C*>& rng) BOOST_NOEXCEPT { - return (*this) << iterator_range<const C*>(rng.begin(), rng.end()); - } - - bool operator<<(const iterator_range<const CharT*>& rng) BOOST_NOEXCEPT { - start = rng.begin(); - finish = rng.end(); - return true; - } - - bool operator<<(const iterator_range<const signed char*>& rng) BOOST_NOEXCEPT { - return (*this) << iterator_range<const char*>( - reinterpret_cast<const char*>(rng.begin()), - reinterpret_cast<const char*>(rng.end()) - ); - } - - bool operator<<(const iterator_range<const unsigned char*>& rng) BOOST_NOEXCEPT { - return (*this) << iterator_range<const char*>( - reinterpret_cast<const char*>(rng.begin()), - reinterpret_cast<const char*>(rng.end()) - ); - } - - bool operator<<(char ch) { return shl_char(ch); } - bool operator<<(unsigned char ch) { return ((*this) << static_cast<char>(ch)); } - bool operator<<(signed char ch) { return ((*this) << static_cast<char>(ch)); } -#if !defined(BOOST_LCAST_NO_WCHAR_T) - bool operator<<(wchar_t const* str) { return shl_char_array(str); } - bool operator<<(wchar_t * str) { return shl_char_array(str); } -#ifndef BOOST_NO_INTRINSIC_WCHAR_T - bool operator<<(wchar_t ch) { return shl_char(ch); } -#endif -#endif -#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - bool operator<<(char16_t ch) { return shl_char(ch); } - bool operator<<(char16_t * str) { return shl_char_array(str); } - bool operator<<(char16_t const * str) { return shl_char_array(str); } -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - bool operator<<(char32_t ch) { return shl_char(ch); } - bool operator<<(char32_t * str) { return shl_char_array(str); } - bool operator<<(char32_t const * str) { return shl_char_array(str); } -#endif - bool operator<<(unsigned char const* ch) { return ((*this) << reinterpret_cast<char const*>(ch)); } - bool operator<<(unsigned char * ch) { return ((*this) << reinterpret_cast<char *>(ch)); } - bool operator<<(signed char const* ch) { return ((*this) << reinterpret_cast<char const*>(ch)); } - bool operator<<(signed char * ch) { return ((*this) << reinterpret_cast<char *>(ch)); } - bool operator<<(char const* str_value) { return shl_char_array(str_value); } - bool operator<<(char* str_value) { return shl_char_array(str_value); } - bool operator<<(short n) { return shl_signed(n); } - bool operator<<(int n) { return shl_signed(n); } - bool operator<<(long n) { return shl_signed(n); } - bool operator<<(unsigned short n) { return shl_unsigned(n); } - bool operator<<(unsigned int n) { return shl_unsigned(n); } - bool operator<<(unsigned long n) { return shl_unsigned(n); } - -#if defined(BOOST_HAS_LONG_LONG) - bool operator<<(boost::ulong_long_type n) { return shl_unsigned(n); } - bool operator<<(boost::long_long_type n) { return shl_signed(n); } -#elif defined(BOOST_HAS_MS_INT64) - bool operator<<(unsigned __int64 n) { return shl_unsigned(n); } - bool operator<<( __int64 n) { return shl_signed(n); } -#endif - -#ifdef BOOST_HAS_INT128 - bool operator<<(const boost::uint128_type& n) { return shl_unsigned(n); } - bool operator<<(const boost::int128_type& n) { return shl_signed(n); } -#endif - bool operator<<(float val) { return shl_real(val); } - bool operator<<(double val) { return shl_real(val); } - bool operator<<(long double val) { -#ifndef __MINGW32__ - return shl_real(val); -#else - return shl_real(static_cast<double>(val)); -#endif - } - - // Adding constness to characters. Constness does not change layout - template <class C, std::size_t N> - BOOST_DEDUCED_TYPENAME boost::disable_if<boost::is_const<C>, bool>::type - operator<<(boost::array<C, N> const& input) BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG( - (sizeof(boost::array<const C, N>) == sizeof(boost::array<C, N>)), - "boost::array<C, N> and boost::array<const C, N> must have exactly the same layout." - ); - return ((*this) << reinterpret_cast<boost::array<const C, N> const& >(input)); - } - - template <std::size_t N> - bool operator<<(boost::array<const CharT, N> const& input) BOOST_NOEXCEPT { - return shl_char_array_limited(input.data(), N); - } - - template <std::size_t N> - bool operator<<(boost::array<const unsigned char, N> const& input) BOOST_NOEXCEPT { - return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); - } - - template <std::size_t N> - bool operator<<(boost::array<const signed char, N> const& input) BOOST_NOEXCEPT { - return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); - } - -#ifndef BOOST_NO_CXX11_HDR_ARRAY - // Making a Boost.Array from std::array - template <class C, std::size_t N> - bool operator<<(std::array<C, N> const& input) BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG( - (sizeof(std::array<C, N>) == sizeof(boost::array<C, N>)), - "std::array and boost::array must have exactly the same layout. " - "Bug in implementation of std::array or boost::array." - ); - return ((*this) << reinterpret_cast<boost::array<C, N> const& >(input)); - } -#endif - template <class InStreamable> - bool operator<<(const InStreamable& input) { return shl_input_streamable(input); } - }; - - - template <class CharT, class Traits> - class lexical_ostream_limited_src: boost::noncopyable { - //`[start, finish)` is the range to output by `operator >>` - const CharT* start; - const CharT* const finish; - - public: - lexical_ostream_limited_src(const CharT* begin, const CharT* end) BOOST_NOEXCEPT - : start(begin) - , finish(end) - {} - -/************************************ HELPER FUNCTIONS FOR OPERATORS >> ( ... ) ********************************/ - private: - template <typename Type> - bool shr_unsigned(Type& output) { - if (start == finish) return false; - CharT const minus = lcast_char_constants<CharT>::minus; - CharT const plus = lcast_char_constants<CharT>::plus; - bool const has_minus = Traits::eq(minus, *start); - - /* We won`t use `start' any more, so no need in decrementing it after */ - if (has_minus || Traits::eq(plus, *start)) { - ++start; - } - - bool const succeed = lcast_ret_unsigned<Traits, Type, CharT>(output, start, finish).convert(); - - if (has_minus) { - output = static_cast<Type>(0u - output); - } - - return succeed; - } - - template <typename Type> - bool shr_signed(Type& output) { - if (start == finish) return false; - CharT const minus = lcast_char_constants<CharT>::minus; - CharT const plus = lcast_char_constants<CharT>::plus; - typedef BOOST_DEDUCED_TYPENAME make_unsigned<Type>::type utype; - utype out_tmp = 0; - bool const has_minus = Traits::eq(minus, *start); - - /* We won`t use `start' any more, so no need in decrementing it after */ - if (has_minus || Traits::eq(plus, *start)) { - ++start; - } - - bool succeed = lcast_ret_unsigned<Traits, utype, CharT>(out_tmp, start, finish).convert(); - if (has_minus) { - utype const comp_val = (static_cast<utype>(1) << std::numeric_limits<Type>::digits); - succeed = succeed && out_tmp<=comp_val; - output = static_cast<Type>(0u - out_tmp); - } else { - utype const comp_val = static_cast<utype>((std::numeric_limits<Type>::max)()); - succeed = succeed && out_tmp<=comp_val; - output = static_cast<Type>(out_tmp); - } - return succeed; - } - - template<typename InputStreamable> - bool shr_using_base_class(InputStreamable& output) - { - BOOST_STATIC_ASSERT_MSG( - (!boost::is_pointer<InputStreamable>::value), - "boost::lexical_cast can not convert to pointers" - ); - -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_LOCALE) - BOOST_STATIC_ASSERT_MSG((boost::is_same<char, CharT>::value), - "boost::lexical_cast can not convert, because your STL library does not " - "support such conversions. Try updating it." - ); -#endif - -#if defined(BOOST_NO_STRINGSTREAM) - std::istrstream stream(start, static_cast<std::istrstream::streamsize>(finish - start)); -#else - typedef BOOST_DEDUCED_TYPENAME out_stream_helper_trait<CharT, Traits>::buffer_t buffer_t; - buffer_t buf; - // Usually `istream` and `basic_istream` do not modify - // content of buffer; `buffer_t` assures that this is true - buf.setbuf(const_cast<CharT*>(start), static_cast<typename buffer_t::streamsize>(finish - start)); -#if defined(BOOST_NO_STD_LOCALE) - std::istream stream(&buf); -#else - std::basic_istream<CharT, Traits> stream(&buf); -#endif // BOOST_NO_STD_LOCALE -#endif // BOOST_NO_STRINGSTREAM - -#ifndef BOOST_NO_EXCEPTIONS - stream.exceptions(std::ios::badbit); - try { -#endif - stream.unsetf(std::ios::skipws); - lcast_set_precision(stream, static_cast<InputStreamable*>(0)); - - return (stream >> output) - && (stream.get() == Traits::eof()); - -#ifndef BOOST_NO_EXCEPTIONS - } catch (const ::std::ios_base::failure& /*f*/) { - return false; - } -#endif - } - - template<class T> - inline bool shr_xchar(T& output) BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG(( sizeof(CharT) == sizeof(T) ), - "boost::lexical_cast does not support narrowing of character types." - "Use boost::locale instead" ); - bool const ok = (finish - start == 1); - if (ok) { - CharT out; - Traits::assign(out, *start); - output = static_cast<T>(out); - } - return ok; - } - - template <std::size_t N, class ArrayT> - bool shr_std_array(ArrayT& output) BOOST_NOEXCEPT { - using namespace std; - const std::size_t size = static_cast<std::size_t>(finish - start); - if (size > N - 1) { // `-1` because we need to store \0 at the end - return false; - } - - memcpy(&output[0], start, size * sizeof(CharT)); - output[size] = Traits::to_char_type(0); - return true; - } - -/************************************ OPERATORS >> ( ... ) ********************************/ - public: - bool operator>>(unsigned short& output) { return shr_unsigned(output); } - bool operator>>(unsigned int& output) { return shr_unsigned(output); } - bool operator>>(unsigned long int& output) { return shr_unsigned(output); } - bool operator>>(short& output) { return shr_signed(output); } - bool operator>>(int& output) { return shr_signed(output); } - bool operator>>(long int& output) { return shr_signed(output); } -#if defined(BOOST_HAS_LONG_LONG) - bool operator>>(boost::ulong_long_type& output) { return shr_unsigned(output); } - bool operator>>(boost::long_long_type& output) { return shr_signed(output); } -#elif defined(BOOST_HAS_MS_INT64) - bool operator>>(unsigned __int64& output) { return shr_unsigned(output); } - bool operator>>(__int64& output) { return shr_signed(output); } -#endif - -#ifdef BOOST_HAS_INT128 - bool operator>>(boost::uint128_type& output) { return shr_unsigned(output); } - bool operator>>(boost::int128_type& output) { return shr_signed(output); } -#endif - - bool operator>>(char& output) { return shr_xchar(output); } - bool operator>>(unsigned char& output) { return shr_xchar(output); } - bool operator>>(signed char& output) { return shr_xchar(output); } -#if !defined(BOOST_LCAST_NO_WCHAR_T) && !defined(BOOST_NO_INTRINSIC_WCHAR_T) - bool operator>>(wchar_t& output) { return shr_xchar(output); } -#endif -#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - bool operator>>(char16_t& output) { return shr_xchar(output); } -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - bool operator>>(char32_t& output) { return shr_xchar(output); } -#endif - template<class Alloc> - bool operator>>(std::basic_string<CharT,Traits,Alloc>& str) { - str.assign(start, finish); return true; - } - - template<class Alloc> - bool operator>>(boost::container::basic_string<CharT,Traits,Alloc>& str) { - str.assign(start, finish); return true; - } - - template <std::size_t N> - bool operator>>(boost::array<CharT, N>& output) BOOST_NOEXCEPT { - return shr_std_array<N>(output); - } - - template <std::size_t N> - bool operator>>(boost::array<unsigned char, N>& output) BOOST_NOEXCEPT { - return ((*this) >> reinterpret_cast<boost::array<char, N>& >(output)); - } - - template <std::size_t N> - bool operator>>(boost::array<signed char, N>& output) BOOST_NOEXCEPT { - return ((*this) >> reinterpret_cast<boost::array<char, N>& >(output)); - } - -#ifndef BOOST_NO_CXX11_HDR_ARRAY - template <class C, std::size_t N> - bool operator>>(std::array<C, N>& output) BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG( - (sizeof(std::array<C, N>) == sizeof(boost::array<C, N>)), - "std::array<C, N> and boost::array<C, N> must have exactly the same layout." - ); - return ((*this) >> reinterpret_cast<boost::array<C, N>& >(output)); - } -#endif - - bool operator>>(bool& output) BOOST_NOEXCEPT { - output = false; // Suppress warning about uninitalized variable - - if (start == finish) return false; - CharT const zero = lcast_char_constants<CharT>::zero; - CharT const plus = lcast_char_constants<CharT>::plus; - CharT const minus = lcast_char_constants<CharT>::minus; - - const CharT* const dec_finish = finish - 1; - output = Traits::eq(*dec_finish, zero + 1); - if (!output && !Traits::eq(*dec_finish, zero)) { - return false; // Does not ends on '0' or '1' - } - - if (start == dec_finish) return true; - - // We may have sign at the beginning - if (Traits::eq(plus, *start) || (Traits::eq(minus, *start) && !output)) { - ++ start; - } - - // Skipping zeros - while (start != dec_finish) { - if (!Traits::eq(zero, *start)) { - return false; // Not a zero => error - } - - ++ start; - } - - return true; - } - - private: - // Not optimised converter - template <class T> - bool float_types_converter_internal(T& output) { - if (parse_inf_nan(start, finish, output)) return true; - bool const return_value = shr_using_base_class(output); - - /* Some compilers and libraries successfully - * parse 'inf', 'INFINITY', '1.0E', '1.0E-'... - * We are trying to provide a unified behaviour, - * so we just forbid such conversions (as some - * of the most popular compilers/libraries do) - * */ - CharT const minus = lcast_char_constants<CharT>::minus; - CharT const plus = lcast_char_constants<CharT>::plus; - CharT const capital_e = lcast_char_constants<CharT>::capital_e; - CharT const lowercase_e = lcast_char_constants<CharT>::lowercase_e; - if ( return_value && - ( - Traits::eq(*(finish-1), lowercase_e) // 1.0e - || Traits::eq(*(finish-1), capital_e) // 1.0E - || Traits::eq(*(finish-1), minus) // 1.0e- or 1.0E- - || Traits::eq(*(finish-1), plus) // 1.0e+ or 1.0E+ - ) - ) return false; - - return return_value; - } - - public: - bool operator>>(float& output) { return float_types_converter_internal(output); } - bool operator>>(double& output) { return float_types_converter_internal(output); } - bool operator>>(long double& output) { return float_types_converter_internal(output); } - - // Generic istream-based algorithm. - // lcast_streambuf_for_target<InputStreamable>::value is true. - template <typename InputStreamable> - bool operator>>(InputStreamable& output) { - return shr_using_base_class(output); - } - }; - } -} // namespace boost - -#undef BOOST_LCAST_NO_WCHAR_T - -#endif // BOOST_LEXICAL_CAST_DETAIL_CONVERTER_LEXICAL_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/converter_numeric.hpp b/ThirdParty/boost/lexical_cast/detail/converter_numeric.hpp deleted file mode 100644 index 111613d2c7563bb3f4208a081cf13d886d85560d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/converter_numeric.hpp +++ /dev/null @@ -1,172 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2016 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_CONVERTER_NUMERIC_HPP -#define BOOST_LEXICAL_CAST_DETAIL_CONVERTER_NUMERIC_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#include <boost/limits.hpp> -#include <boost/type_traits/type_identity.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/make_unsigned.hpp> -#include <boost/type_traits/is_signed.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <boost/type_traits/is_arithmetic.hpp> -#include <boost/type_traits/is_base_of.hpp> -#include <boost/type_traits/is_float.hpp> - -#include <boost/numeric/conversion/cast.hpp> - -namespace boost { namespace detail { - -template <class Source > -struct detect_precision_loss -{ - typedef Source source_type; - typedef boost::numeric::Trunc<Source> Rounder; - typedef BOOST_DEDUCED_TYPENAME conditional< - boost::is_arithmetic<Source>::value, Source, Source const& - >::type argument_type ; - - static inline source_type nearbyint(argument_type s, bool& is_ok) BOOST_NOEXCEPT { - const source_type near_int = Rounder::nearbyint(s); - if (near_int && is_ok) { - const source_type orig_div_round = s / near_int; - const source_type eps = std::numeric_limits<source_type>::epsilon(); - - is_ok = !((orig_div_round > 1 ? orig_div_round - 1 : 1 - orig_div_round) > eps); - } - - return s; - } - - typedef typename Rounder::round_style round_style; -}; - -template <typename Base, class Source> -struct fake_precision_loss: public Base -{ - typedef Source source_type ; - typedef BOOST_DEDUCED_TYPENAME conditional< - boost::is_arithmetic<Source>::value, Source, Source const& - >::type argument_type ; - - static inline source_type nearbyint(argument_type s, bool& /*is_ok*/) BOOST_NOEXCEPT { - return s; - } -}; - -struct nothrow_overflow_handler -{ - inline bool operator() ( boost::numeric::range_check_result r ) const BOOST_NOEXCEPT { - return (r == boost::numeric::cInRange); - } -}; - -template <typename Target, typename Source> -inline bool noexcept_numeric_convert(const Source& arg, Target& result) BOOST_NOEXCEPT { - typedef boost::numeric::converter< - Target, - Source, - boost::numeric::conversion_traits<Target, Source >, - nothrow_overflow_handler, - detect_precision_loss<Source > - > converter_orig_t; - - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_base_of< detect_precision_loss<Source >, converter_orig_t >::value, - converter_orig_t, - fake_precision_loss<converter_orig_t, Source> - >::type converter_t; - - bool res = nothrow_overflow_handler()(converter_t::out_of_range(arg)); - result = converter_t::low_level_convert(converter_t::nearbyint(arg, res)); - return res; -} - -template <typename Target, typename Source> -struct lexical_cast_dynamic_num_not_ignoring_minus -{ - static inline bool try_convert(const Source &arg, Target& result) BOOST_NOEXCEPT { - return noexcept_numeric_convert<Target, Source >(arg, result); - } -}; - -template <typename Target, typename Source> -struct lexical_cast_dynamic_num_ignoring_minus -{ - static inline bool try_convert(const Source &arg, Target& result) BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_float<Source>::value, - boost::type_identity<Source>, - boost::make_unsigned<Source> - >::type usource_lazy_t; - typedef BOOST_DEDUCED_TYPENAME usource_lazy_t::type usource_t; - - if (arg < 0) { - const bool res = noexcept_numeric_convert<Target, usource_t>(0u - arg, result); - result = static_cast<Target>(0u - result); - return res; - } else { - return noexcept_numeric_convert<Target, usource_t>(arg, result); - } - } -}; - -/* - * lexical_cast_dynamic_num follows the rules: - * 1) If Source can be converted to Target without precision loss and - * without overflows, then assign Source to Target and return - * - * 2) If Source is less than 0 and Target is an unsigned integer, - * then negate Source, check the requirements of rule 1) and if - * successful, assign static_casted Source to Target and return - * - * 3) Otherwise throw a bad_lexical_cast exception - * - * - * Rule 2) required because boost::lexical_cast has the behavior of - * stringstream, which uses the rules of scanf for conversions. And - * in the C99 standard for unsigned input value minus sign is - * optional, so if a negative number is read, no errors will arise - * and the result will be the two's complement. - */ -template <typename Target, typename Source> -struct dynamic_num_converter_impl -{ - static inline bool try_convert(const Source &arg, Target& result) BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_unsigned<Target>::value && - (boost::is_signed<Source>::value || boost::is_float<Source>::value) && - !(boost::is_same<Source, bool>::value) && - !(boost::is_same<Target, bool>::value), - lexical_cast_dynamic_num_ignoring_minus<Target, Source>, - lexical_cast_dynamic_num_not_ignoring_minus<Target, Source> - >::type caster_type; - - return caster_type::try_convert(arg, result); - } -}; - -}} // namespace boost::detail - -#endif // BOOST_LEXICAL_CAST_DETAIL_CONVERTER_NUMERIC_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/inf_nan.hpp b/ThirdParty/boost/lexical_cast/detail/inf_nan.hpp deleted file mode 100644 index 296688c0027393327d9a0b064ebdeeb810aee0c1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/inf_nan.hpp +++ /dev/null @@ -1,197 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_INF_NAN_HPP -#define BOOST_LEXICAL_CAST_DETAIL_INF_NAN_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#if defined(BOOST_NO_STRINGSTREAM) || defined(BOOST_NO_STD_WSTRING) -#define BOOST_LCAST_NO_WCHAR_T -#endif - -#include <cstddef> -#include <cstring> -#include <boost/limits.hpp> -#include <boost/detail/workaround.hpp> -#include <boost/math/special_functions/sign.hpp> -#include <boost/math/special_functions/fpclassify.hpp> - -#include <boost/lexical_cast/detail/lcast_char_constants.hpp> - -namespace boost { - namespace detail - { - template <class CharT> - bool lc_iequal(const CharT* val, const CharT* lcase, const CharT* ucase, unsigned int len) BOOST_NOEXCEPT { - for( unsigned int i=0; i < len; ++i ) { - if ( val[i] != lcase[i] && val[i] != ucase[i] ) return false; - } - - return true; - } - - /* Returns true and sets the correct value if found NaN or Inf. */ - template <class CharT, class T> - inline bool parse_inf_nan_impl(const CharT* begin, const CharT* end, T& value - , const CharT* lc_NAN, const CharT* lc_nan - , const CharT* lc_INFINITY, const CharT* lc_infinity - , const CharT opening_brace, const CharT closing_brace) BOOST_NOEXCEPT - { - using namespace std; - if (begin == end) return false; - const CharT minus = lcast_char_constants<CharT>::minus; - const CharT plus = lcast_char_constants<CharT>::plus; - const int inifinity_size = 8; // == sizeof("infinity") - 1 - - /* Parsing +/- */ - bool const has_minus = (*begin == minus); - if (has_minus || *begin == plus) { - ++ begin; - } - - if (end - begin < 3) return false; - if (lc_iequal(begin, lc_nan, lc_NAN, 3)) { - begin += 3; - if (end != begin) { - /* It is 'nan(...)' or some bad input*/ - - if (end - begin < 2) return false; // bad input - -- end; - if (*begin != opening_brace || *end != closing_brace) return false; // bad input - } - - if( !has_minus ) value = std::numeric_limits<T>::quiet_NaN(); - else value = (boost::math::changesign) (std::numeric_limits<T>::quiet_NaN()); - return true; - } else if ( - ( /* 'INF' or 'inf' */ - end - begin == 3 // 3 == sizeof('inf') - 1 - && lc_iequal(begin, lc_infinity, lc_INFINITY, 3) - ) - || - ( /* 'INFINITY' or 'infinity' */ - end - begin == inifinity_size - && lc_iequal(begin, lc_infinity, lc_INFINITY, inifinity_size) - ) - ) - { - if( !has_minus ) value = std::numeric_limits<T>::infinity(); - else value = (boost::math::changesign) (std::numeric_limits<T>::infinity()); - return true; - } - - return false; - } - - template <class CharT, class T> - bool put_inf_nan_impl(CharT* begin, CharT*& end, const T& value - , const CharT* lc_nan - , const CharT* lc_infinity) BOOST_NOEXCEPT - { - using namespace std; - const CharT minus = lcast_char_constants<CharT>::minus; - if ((boost::math::isnan)(value)) { - if ((boost::math::signbit)(value)) { - *begin = minus; - ++ begin; - } - - memcpy(begin, lc_nan, 3 * sizeof(CharT)); - end = begin + 3; - return true; - } else if ((boost::math::isinf)(value)) { - if ((boost::math::signbit)(value)) { - *begin = minus; - ++ begin; - } - - memcpy(begin, lc_infinity, 3 * sizeof(CharT)); - end = begin + 3; - return true; - } - - return false; - } - - -#ifndef BOOST_LCAST_NO_WCHAR_T - template <class T> - bool parse_inf_nan(const wchar_t* begin, const wchar_t* end, T& value) BOOST_NOEXCEPT { - return parse_inf_nan_impl(begin, end, value - , L"NAN", L"nan" - , L"INFINITY", L"infinity" - , L'(', L')'); - } - - template <class T> - bool put_inf_nan(wchar_t* begin, wchar_t*& end, const T& value) BOOST_NOEXCEPT { - return put_inf_nan_impl(begin, end, value, L"nan", L"infinity"); - } - -#endif -#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - template <class T> - bool parse_inf_nan(const char16_t* begin, const char16_t* end, T& value) BOOST_NOEXCEPT { - return parse_inf_nan_impl(begin, end, value - , u"NAN", u"nan" - , u"INFINITY", u"infinity" - , u'(', u')'); - } - - template <class T> - bool put_inf_nan(char16_t* begin, char16_t*& end, const T& value) BOOST_NOEXCEPT { - return put_inf_nan_impl(begin, end, value, u"nan", u"infinity"); - } -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) - template <class T> - bool parse_inf_nan(const char32_t* begin, const char32_t* end, T& value) BOOST_NOEXCEPT { - return parse_inf_nan_impl(begin, end, value - , U"NAN", U"nan" - , U"INFINITY", U"infinity" - , U'(', U')'); - } - - template <class T> - bool put_inf_nan(char32_t* begin, char32_t*& end, const T& value) BOOST_NOEXCEPT { - return put_inf_nan_impl(begin, end, value, U"nan", U"infinity"); - } -#endif - - template <class CharT, class T> - bool parse_inf_nan(const CharT* begin, const CharT* end, T& value) BOOST_NOEXCEPT { - return parse_inf_nan_impl(begin, end, value - , "NAN", "nan" - , "INFINITY", "infinity" - , '(', ')'); - } - - template <class CharT, class T> - bool put_inf_nan(CharT* begin, CharT*& end, const T& value) BOOST_NOEXCEPT { - return put_inf_nan_impl(begin, end, value, "nan", "infinity"); - } - } -} // namespace boost - -#undef BOOST_LCAST_NO_WCHAR_T - -#endif // BOOST_LEXICAL_CAST_DETAIL_INF_NAN_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/is_character.hpp b/ThirdParty/boost/lexical_cast/detail/is_character.hpp deleted file mode 100644 index 3f02232df564ea02180c10b8ded70f88a0eefcea..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/is_character.hpp +++ /dev/null @@ -1,59 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_IS_CHARACTER_HPP -#define BOOST_LEXICAL_CAST_DETAIL_IS_CHARACTER_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#include <boost/type_traits/integral_constant.hpp> -#include <boost/type_traits/is_same.hpp> - -namespace boost { - - namespace detail // is_character<...> - { - // returns true, if T is one of the character types - template < typename T > - struct is_character - { - typedef BOOST_DEDUCED_TYPENAME boost::integral_constant< - bool, - boost::is_same< T, char >::value || - #if !defined(BOOST_NO_STRINGSTREAM) && !defined(BOOST_NO_STD_WSTRING) - boost::is_same< T, wchar_t >::value || - #endif - #ifndef BOOST_NO_CXX11_CHAR16_T - boost::is_same< T, char16_t >::value || - #endif - #ifndef BOOST_NO_CXX11_CHAR32_T - boost::is_same< T, char32_t >::value || - #endif - boost::is_same< T, unsigned char >::value || - boost::is_same< T, signed char >::value - > type; - - BOOST_STATIC_CONSTANT(bool, value = (type::value) ); - }; - } -} - -#endif // BOOST_LEXICAL_CAST_DETAIL_IS_CHARACTER_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/lcast_char_constants.hpp b/ThirdParty/boost/lexical_cast/detail/lcast_char_constants.hpp deleted file mode 100644 index 9805da00b3a025e500c9cdb8b0b1033ce66c5fb1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/lcast_char_constants.hpp +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_LCAST_CHAR_CONSTANTS_HPP -#define BOOST_LEXICAL_CAST_DETAIL_LCAST_CHAR_CONSTANTS_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost -{ - namespace detail // '0', '-', '+', 'e', 'E' and '.' constants - { - template < typename Char > - struct lcast_char_constants { - // We check in tests assumption that static casted character is - // equal to correctly written C++ literal: U'0' == static_cast<char32_t>('0') - BOOST_STATIC_CONSTANT(Char, zero = static_cast<Char>('0')); - BOOST_STATIC_CONSTANT(Char, minus = static_cast<Char>('-')); - BOOST_STATIC_CONSTANT(Char, plus = static_cast<Char>('+')); - BOOST_STATIC_CONSTANT(Char, lowercase_e = static_cast<Char>('e')); - BOOST_STATIC_CONSTANT(Char, capital_e = static_cast<Char>('E')); - BOOST_STATIC_CONSTANT(Char, c_decimal_separator = static_cast<Char>('.')); - }; - } -} // namespace boost - - -#endif // BOOST_LEXICAL_CAST_DETAIL_LCAST_CHAR_CONSTANTS_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/lcast_unsigned_converters.hpp b/ThirdParty/boost/lexical_cast/detail/lcast_unsigned_converters.hpp deleted file mode 100644 index bbfdc3f090240399aa3da2de6ca364080c7d28f6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/lcast_unsigned_converters.hpp +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_LCAST_UNSIGNED_CONVERTERS_HPP -#define BOOST_LEXICAL_CAST_DETAIL_LCAST_UNSIGNED_CONVERTERS_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#include <climits> -#include <cstddef> -#include <string> -#include <cstring> -#include <cstdio> -#include <boost/limits.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/static_assert.hpp> -#include <boost/detail/workaround.hpp> - - -#ifndef BOOST_NO_STD_LOCALE -# include <locale> -#else -# ifndef BOOST_LEXICAL_CAST_ASSUME_C_LOCALE - // Getting error at this point means, that your STL library is old/lame/misconfigured. - // If nothing can be done with STL library, define BOOST_LEXICAL_CAST_ASSUME_C_LOCALE, - // but beware: lexical_cast will understand only 'C' locale delimeters and thousands - // separators. -# error "Unable to use <locale> header. Define BOOST_LEXICAL_CAST_ASSUME_C_LOCALE to force " -# error "boost::lexical_cast to use only 'C' locale during conversions." -# endif -#endif - -#include <boost/lexical_cast/detail/lcast_char_constants.hpp> -#include <boost/type_traits/make_unsigned.hpp> -#include <boost/type_traits/is_signed.hpp> -#include <boost/noncopyable.hpp> - -namespace boost -{ - namespace detail // lcast_to_unsigned - { - template<class T> - inline - BOOST_DEDUCED_TYPENAME boost::make_unsigned<T>::type lcast_to_unsigned(const T value) BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::make_unsigned<T>::type result_type; - return value < 0 - ? static_cast<result_type>(0u - static_cast<result_type>(value)) - : static_cast<result_type>(value); - } - } - - namespace detail // lcast_put_unsigned - { - template <class Traits, class T, class CharT> - class lcast_put_unsigned: boost::noncopyable { - typedef BOOST_DEDUCED_TYPENAME Traits::int_type int_type; - BOOST_DEDUCED_TYPENAME boost::conditional< - (sizeof(unsigned) > sizeof(T)) - , unsigned - , T - >::type m_value; - CharT* m_finish; - CharT const m_czero; - int_type const m_zero; - - public: - lcast_put_unsigned(const T n_param, CharT* finish) BOOST_NOEXCEPT - : m_value(n_param), m_finish(finish) - , m_czero(lcast_char_constants<CharT>::zero), m_zero(Traits::to_int_type(m_czero)) - { -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - BOOST_STATIC_ASSERT(!std::numeric_limits<T>::is_signed); -#endif - } - - CharT* convert() { -#ifndef BOOST_LEXICAL_CAST_ASSUME_C_LOCALE - std::locale loc; - if (loc == std::locale::classic()) { - return main_convert_loop(); - } - - typedef std::numpunct<CharT> numpunct; - numpunct const& np = BOOST_USE_FACET(numpunct, loc); - std::string const grouping = np.grouping(); - std::string::size_type const grouping_size = grouping.size(); - - if (!grouping_size || grouping[0] <= 0) { - return main_convert_loop(); - } - -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - // Check that ulimited group is unreachable: - BOOST_STATIC_ASSERT(std::numeric_limits<T>::digits10 < CHAR_MAX); -#endif - CharT const thousands_sep = np.thousands_sep(); - std::string::size_type group = 0; // current group number - char last_grp_size = grouping[0]; - char left = last_grp_size; - - do { - if (left == 0) { - ++group; - if (group < grouping_size) { - char const grp_size = grouping[group]; - last_grp_size = (grp_size <= 0 ? static_cast<char>(CHAR_MAX) : grp_size); - } - - left = last_grp_size; - --m_finish; - Traits::assign(*m_finish, thousands_sep); - } - - --left; - } while (main_convert_iteration()); - - return m_finish; -#else - return main_convert_loop(); -#endif - } - - private: - inline bool main_convert_iteration() BOOST_NOEXCEPT { - --m_finish; - int_type const digit = static_cast<int_type>(m_value % 10U); - Traits::assign(*m_finish, Traits::to_char_type(m_zero + digit)); - m_value /= 10; - return !!m_value; // suppressing warnings - } - - inline CharT* main_convert_loop() BOOST_NOEXCEPT { - while (main_convert_iteration()); - return m_finish; - } - }; - } - - namespace detail // lcast_ret_unsigned - { - template <class Traits, class T, class CharT> - class lcast_ret_unsigned: boost::noncopyable { - bool m_multiplier_overflowed; - T m_multiplier; - T& m_value; - const CharT* const m_begin; - const CharT* m_end; - - public: - lcast_ret_unsigned(T& value, const CharT* const begin, const CharT* end) BOOST_NOEXCEPT - : m_multiplier_overflowed(false), m_multiplier(1), m_value(value), m_begin(begin), m_end(end) - { -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - BOOST_STATIC_ASSERT(!std::numeric_limits<T>::is_signed); - - // GCC when used with flag -std=c++0x may not have std::numeric_limits - // specializations for __int128 and unsigned __int128 types. - // Try compilation with -std=gnu++0x or -std=gnu++11. - // - // http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40856 - BOOST_STATIC_ASSERT_MSG(std::numeric_limits<T>::is_specialized, - "std::numeric_limits are not specialized for integral type passed to boost::lexical_cast" - ); -#endif - } - - inline bool convert() { - CharT const czero = lcast_char_constants<CharT>::zero; - --m_end; - m_value = static_cast<T>(0); - - if (m_begin > m_end || *m_end < czero || *m_end >= czero + 10) - return false; - m_value = static_cast<T>(*m_end - czero); - --m_end; - -#ifdef BOOST_LEXICAL_CAST_ASSUME_C_LOCALE - return main_convert_loop(); -#else - std::locale loc; - if (loc == std::locale::classic()) { - return main_convert_loop(); - } - - typedef std::numpunct<CharT> numpunct; - numpunct const& np = BOOST_USE_FACET(numpunct, loc); - std::string const& grouping = np.grouping(); - std::string::size_type const grouping_size = grouping.size(); - - /* According to Programming languages - C++ - * we MUST check for correct grouping - */ - if (!grouping_size || grouping[0] <= 0) { - return main_convert_loop(); - } - - unsigned char current_grouping = 0; - CharT const thousands_sep = np.thousands_sep(); - char remained = static_cast<char>(grouping[current_grouping] - 1); - - for (;m_end >= m_begin; --m_end) - { - if (remained) { - if (!main_convert_iteration()) { - return false; - } - --remained; - } else { - if ( !Traits::eq(*m_end, thousands_sep) ) //|| begin == end ) return false; - { - /* - * According to Programming languages - C++ - * Digit grouping is checked. That is, the positions of discarded - * separators is examined for consistency with - * use_facet<numpunct<charT> >(loc ).grouping() - * - * BUT what if there is no separators at all and grouping() - * is not empty? Well, we have no extraced separators, so we - * won`t check them for consistency. This will allow us to - * work with "C" locale from other locales - */ - return main_convert_loop(); - } else { - if (m_begin == m_end) return false; - if (current_grouping < grouping_size - 1) ++current_grouping; - remained = grouping[current_grouping]; - } - } - } /*for*/ - - return true; -#endif - } - - private: - // Iteration that does not care about grouping/separators and assumes that all - // input characters are digits - inline bool main_convert_iteration() BOOST_NOEXCEPT { - CharT const czero = lcast_char_constants<CharT>::zero; - T const maxv = (std::numeric_limits<T>::max)(); - - m_multiplier_overflowed = m_multiplier_overflowed || (maxv/10 < m_multiplier); - m_multiplier = static_cast<T>(m_multiplier * 10); - - T const dig_value = static_cast<T>(*m_end - czero); - T const new_sub_value = static_cast<T>(m_multiplier * dig_value); - - // We must correctly handle situations like `000000000000000000000000000001`. - // So we take care of overflow only if `dig_value` is not '0'. - if (*m_end < czero || *m_end >= czero + 10 // checking for correct digit - || (dig_value && ( // checking for overflow of ... - m_multiplier_overflowed // ... multiplier - || static_cast<T>(maxv / dig_value) < m_multiplier // ... subvalue - || static_cast<T>(maxv - new_sub_value) < m_value // ... whole expression - )) - ) return false; - - m_value = static_cast<T>(m_value + new_sub_value); - - return true; - } - - bool main_convert_loop() BOOST_NOEXCEPT { - for ( ; m_end >= m_begin; --m_end) { - if (!main_convert_iteration()) { - return false; - } - } - - return true; - } - }; - } -} // namespace boost - -#endif // BOOST_LEXICAL_CAST_DETAIL_LCAST_UNSIGNED_CONVERTERS_HPP - diff --git a/ThirdParty/boost/lexical_cast/detail/widest_char.hpp b/ThirdParty/boost/lexical_cast/detail/widest_char.hpp deleted file mode 100644 index ba172f38819dd6504b1c0302a3c53bec7e0d6320..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/detail/widest_char.hpp +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_DETAIL_WIDEST_CHAR_HPP -#define BOOST_LEXICAL_CAST_DETAIL_WIDEST_CHAR_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - - -#include <boost/type_traits/conditional.hpp> - -namespace boost { namespace detail { - - template <typename TargetChar, typename SourceChar> - struct widest_char { - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - (sizeof(TargetChar) > sizeof(SourceChar)) - , TargetChar - , SourceChar - >::type type; - }; - -}} // namespace boost::detail - -#endif // BOOST_LEXICAL_CAST_DETAIL_WIDEST_CHAR_HPP - diff --git a/ThirdParty/boost/lexical_cast/try_lexical_convert.hpp b/ThirdParty/boost/lexical_cast/try_lexical_convert.hpp deleted file mode 100644 index 1e2e44a7f1a03b659bbb9bf753ca2c51067ef648..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/lexical_cast/try_lexical_convert.hpp +++ /dev/null @@ -1,232 +0,0 @@ -// Copyright Kevlin Henney, 2000-2005. -// Copyright Alexander Nasonov, 2006-2010. -// Copyright Antony Polukhin, 2011-2020. -// -// 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) -// -// what: lexical_cast custom keyword cast -// who: contributed by Kevlin Henney, -// enhanced with contributions from Terje Slettebo, -// with additional fixes and suggestions from Gennaro Prota, -// Beman Dawes, Dave Abrahams, Daryle Walker, Peter Dimov, -// Alexander Nasonov, Antony Polukhin, Justin Viiret, Michael Hofmann, -// Cheng Yang, Matthew Bradbury, David W. Birdsall, Pavel Korzh and other Boosters -// when: November 2000, March 2003, June 2005, June 2006, March 2011 - 2014 - -#ifndef BOOST_LEXICAL_CAST_TRY_LEXICAL_CONVERT_HPP -#define BOOST_LEXICAL_CAST_TRY_LEXICAL_CONVERT_HPP - -#include <boost/config.hpp> -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#if defined(__clang__) || (defined(__GNUC__) && \ - !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) && \ - (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wuninitialized" -#pragma GCC diagnostic ignored "-Wsign-conversion" -#endif - - -#include <string> -#include <boost/type_traits/is_integral.hpp> -#include <boost/type_traits/type_identity.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/is_arithmetic.hpp> - -#include <boost/lexical_cast/detail/is_character.hpp> -#include <boost/lexical_cast/detail/converter_numeric.hpp> -#include <boost/lexical_cast/detail/converter_lexical.hpp> - -#include <boost/range/iterator_range_core.hpp> -#include <boost/container/container_fwd.hpp> - -namespace boost { - namespace detail - { - template<typename T> - struct is_stdstring - : boost::false_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_stdstring< std::basic_string<CharT, Traits, Alloc> > - : boost::true_type - {}; - - // Sun Studio has problem with partial specialization of templates differing only in namespace. - // We workaround that by making `is_booststring` trait, instead of specializing `is_stdstring` for `boost::container::basic_string`. - template<typename T> - struct is_booststring - : boost::false_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_booststring< boost::container::basic_string<CharT, Traits, Alloc> > - : boost::true_type - {}; - - template<typename Target, typename Source> - struct is_arithmetic_and_not_xchars - { - typedef boost::integral_constant< - bool, - !(boost::detail::is_character<Target>::value) && - !(boost::detail::is_character<Source>::value) && - boost::is_arithmetic<Source>::value && - boost::is_arithmetic<Target>::value - > type; - - BOOST_STATIC_CONSTANT(bool, value = ( - type::value - )); - }; - - /* - * is_xchar_to_xchar<Target, Source>::value is true, - * Target and Souce are char types of the same size 1 (char, signed char, unsigned char). - */ - template<typename Target, typename Source> - struct is_xchar_to_xchar - { - typedef boost::integral_constant< - bool, - sizeof(Source) == sizeof(Target) && - sizeof(Source) == sizeof(char) && - boost::detail::is_character<Target>::value && - boost::detail::is_character<Source>::value - > type; - - BOOST_STATIC_CONSTANT(bool, value = ( - type::value - )); - }; - - template<typename Target, typename Source> - struct is_char_array_to_stdstring - : boost::false_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_char_array_to_stdstring< std::basic_string<CharT, Traits, Alloc>, CharT* > - : boost::true_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_char_array_to_stdstring< std::basic_string<CharT, Traits, Alloc>, const CharT* > - : boost::true_type - {}; - - // Sun Studio has problem with partial specialization of templates differing only in namespace. - // We workaround that by making `is_char_array_to_booststring` trait, instead of specializing `is_char_array_to_stdstring` for `boost::container::basic_string`. - template<typename Target, typename Source> - struct is_char_array_to_booststring - : boost::false_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_char_array_to_booststring< boost::container::basic_string<CharT, Traits, Alloc>, CharT* > - : boost::true_type - {}; - - template<typename CharT, typename Traits, typename Alloc> - struct is_char_array_to_booststring< boost::container::basic_string<CharT, Traits, Alloc>, const CharT* > - : boost::true_type - {}; - - template <typename Target, typename Source> - struct copy_converter_impl - { -// MSVC fail to forward an array (DevDiv#555157 "SILENT BAD CODEGEN triggered by perfect forwarding", -// fixed in 2013 RTM). -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && (!defined(BOOST_MSVC) || BOOST_MSVC >= 1800) - template <class T> - static inline bool try_convert(T&& arg, Target& result) { - result = static_cast<T&&>(arg); // eqaul to `result = std::forward<T>(arg);` - return true; - } -#else - static inline bool try_convert(const Source& arg, Target& result) { - result = arg; - return true; - } -#endif - }; - } - - namespace conversion { namespace detail { - - template <typename Target, typename Source> - inline bool try_lexical_convert(const Source& arg, Target& result) - { - typedef BOOST_DEDUCED_TYPENAME boost::detail::array_to_pointer_decay<Source>::type src; - - typedef boost::integral_constant< - bool, - boost::detail::is_xchar_to_xchar<Target, src >::value || - boost::detail::is_char_array_to_stdstring<Target, src >::value || - boost::detail::is_char_array_to_booststring<Target, src >::value || - ( - boost::is_same<Target, src >::value && - (boost::detail::is_stdstring<Target >::value || boost::detail::is_booststring<Target >::value) - ) || - ( - boost::is_same<Target, src >::value && - boost::detail::is_character<Target >::value - ) - > shall_we_copy_t; - - typedef boost::detail::is_arithmetic_and_not_xchars<Target, src > - shall_we_copy_with_dynamic_check_t; - - // We do evaluate second `if_` lazily to avoid unnecessary instantiations - // of `shall_we_copy_with_dynamic_check_t` and improve compilation times. - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - shall_we_copy_t::value, - boost::type_identity<boost::detail::copy_converter_impl<Target, src > >, - boost::conditional< - shall_we_copy_with_dynamic_check_t::value, - boost::detail::dynamic_num_converter_impl<Target, src >, - boost::detail::lexical_converter_impl<Target, src > - > - >::type caster_type_lazy; - - typedef BOOST_DEDUCED_TYPENAME caster_type_lazy::type caster_type; - - return caster_type::try_convert(arg, result); - } - - template <typename Target, typename CharacterT> - inline bool try_lexical_convert(const CharacterT* chars, std::size_t count, Target& result) - { - BOOST_STATIC_ASSERT_MSG( - boost::detail::is_character<CharacterT>::value, - "This overload of try_lexical_convert is meant to be used only with arrays of characters." - ); - return ::boost::conversion::detail::try_lexical_convert( - ::boost::iterator_range<const CharacterT*>(chars, chars + count), result - ); - } - - }} // namespace conversion::detail - - namespace conversion { - // ADL barrier - using ::boost::conversion::detail::try_lexical_convert; - } - -} // namespace boost - -#if defined(__clang__) || (defined(__GNUC__) && \ - !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) && \ - (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))) -#pragma GCC diagnostic pop -#endif - -#endif // BOOST_LEXICAL_CAST_TRY_LEXICAL_CONVERT_HPP - diff --git a/ThirdParty/boost/math/policies/policy.hpp b/ThirdParty/boost/math/policies/policy.hpp deleted file mode 100644 index 559c960310e64e83b7b7919e508bee8681837bb9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/math/policies/policy.hpp +++ /dev/null @@ -1,1038 +0,0 @@ -// Copyright John Maddock 2007. -// Use, modification and distribution are subject to 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_MATH_POLICY_HPP -#define BOOST_MATH_POLICY_HPP - -#include <boost/mpl/list.hpp> -#include <boost/mpl/contains.hpp> -#include <boost/mpl/if.hpp> -#include <boost/mpl/find_if.hpp> -#include <boost/mpl/remove_if.hpp> -#include <boost/mpl/vector.hpp> -#include <boost/mpl/push_back.hpp> -#include <boost/mpl/at.hpp> -#include <boost/mpl/size.hpp> -#include <boost/mpl/comparison.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/static_assert.hpp> -#include <boost/assert.hpp> -#include <boost/math/tools/config.hpp> -#include <limits> -// Sadly we do need the .h versions of these to be sure of getting -// FLT_MANT_DIG etc. -#include <limits.h> -#include <stdlib.h> -#include <stddef.h> -#include <math.h> - -namespace boost{ namespace math{ - -namespace tools{ - -template <class T> -BOOST_MATH_CONSTEXPR int digits(BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(T)) BOOST_NOEXCEPT; -template <class T> -BOOST_MATH_CONSTEXPR T epsilon(BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(T)) BOOST_MATH_NOEXCEPT(T); - -} - -namespace policies{ - -// -// Define macros for our default policies, if they're not defined already: -// -// Special cases for exceptions disabled first: -// -#ifdef BOOST_NO_EXCEPTIONS -# ifndef BOOST_MATH_DOMAIN_ERROR_POLICY -# define BOOST_MATH_DOMAIN_ERROR_POLICY errno_on_error -# endif -# ifndef BOOST_MATH_POLE_ERROR_POLICY -# define BOOST_MATH_POLE_ERROR_POLICY errno_on_error -# endif -# ifndef BOOST_MATH_OVERFLOW_ERROR_POLICY -# define BOOST_MATH_OVERFLOW_ERROR_POLICY errno_on_error -# endif -# ifndef BOOST_MATH_EVALUATION_ERROR_POLICY -# define BOOST_MATH_EVALUATION_ERROR_POLICY errno_on_error -# endif -# ifndef BOOST_MATH_ROUNDING_ERROR_POLICY -# define BOOST_MATH_ROUNDING_ERROR_POLICY errno_on_error -# endif -#endif -// -// Then the regular cases: -// -#ifndef BOOST_MATH_DOMAIN_ERROR_POLICY -#define BOOST_MATH_DOMAIN_ERROR_POLICY throw_on_error -#endif -#ifndef BOOST_MATH_POLE_ERROR_POLICY -#define BOOST_MATH_POLE_ERROR_POLICY throw_on_error -#endif -#ifndef BOOST_MATH_OVERFLOW_ERROR_POLICY -#define BOOST_MATH_OVERFLOW_ERROR_POLICY throw_on_error -#endif -#ifndef BOOST_MATH_EVALUATION_ERROR_POLICY -#define BOOST_MATH_EVALUATION_ERROR_POLICY throw_on_error -#endif -#ifndef BOOST_MATH_ROUNDING_ERROR_POLICY -#define BOOST_MATH_ROUNDING_ERROR_POLICY throw_on_error -#endif -#ifndef BOOST_MATH_UNDERFLOW_ERROR_POLICY -#define BOOST_MATH_UNDERFLOW_ERROR_POLICY ignore_error -#endif -#ifndef BOOST_MATH_DENORM_ERROR_POLICY -#define BOOST_MATH_DENORM_ERROR_POLICY ignore_error -#endif -#ifndef BOOST_MATH_INDETERMINATE_RESULT_ERROR_POLICY -#define BOOST_MATH_INDETERMINATE_RESULT_ERROR_POLICY ignore_error -#endif -#ifndef BOOST_MATH_DIGITS10_POLICY -#define BOOST_MATH_DIGITS10_POLICY 0 -#endif -#ifndef BOOST_MATH_PROMOTE_FLOAT_POLICY -#define BOOST_MATH_PROMOTE_FLOAT_POLICY true -#endif -#ifndef BOOST_MATH_PROMOTE_DOUBLE_POLICY -#ifdef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#define BOOST_MATH_PROMOTE_DOUBLE_POLICY false -#else -#define BOOST_MATH_PROMOTE_DOUBLE_POLICY true -#endif -#endif -#ifndef BOOST_MATH_DISCRETE_QUANTILE_POLICY -#define BOOST_MATH_DISCRETE_QUANTILE_POLICY integer_round_outwards -#endif -#ifndef BOOST_MATH_ASSERT_UNDEFINED_POLICY -#define BOOST_MATH_ASSERT_UNDEFINED_POLICY true -#endif -#ifndef BOOST_MATH_MAX_SERIES_ITERATION_POLICY -#define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 1000000 -#endif -#ifndef BOOST_MATH_MAX_ROOT_ITERATION_POLICY -#define BOOST_MATH_MAX_ROOT_ITERATION_POLICY 200 -#endif - -#if !defined(__BORLANDC__) -#define BOOST_MATH_META_INT(type, name, Default)\ - template <type N = Default> struct name : public boost::integral_constant<int, N>{};\ - namespace detail{\ - template <type N>\ - char test_is_valid_arg(const name<N>*);\ - char test_is_default_arg(const name<Default>*);\ - template <class T> struct is_##name##_imp\ - {\ - template <type N> static char test(const name<N>*);\ - static double test(...);\ - BOOST_STATIC_CONSTANT(bool, value = sizeof(test(static_cast<T*>(0))) == 1);\ - };\ - }\ - template <class T> struct is_##name : public boost::integral_constant<bool, ::boost::math::policies::detail::is_##name##_imp<T>::value>{}; - -#define BOOST_MATH_META_BOOL(name, Default)\ - template <bool N = Default> struct name : public boost::integral_constant<bool, N>{};\ - namespace detail{\ - template <bool N>\ - char test_is_valid_arg(const name<N>*);\ - char test_is_default_arg(const name<Default>*);\ - template <class T> struct is_##name##_imp\ - {\ - template <bool N> static char test(const name<N>*);\ - static double test(...);\ - BOOST_STATIC_CONSTANT(bool, value = sizeof(test(static_cast<T*>(0))) == 1);\ - };\ - }\ - template <class T> struct is_##name : public boost::integral_constant<bool, ::boost::math::policies::detail::is_##name##_imp<T>::value>{}; -#else -#define BOOST_MATH_META_INT(Type, name, Default)\ - template <Type N = Default> struct name : public boost::integral_constant<int, N>{};\ - namespace detail{\ - template <Type N>\ - char test_is_valid_arg(const name<N>*);\ - char test_is_default_arg(const name<Default>*);\ - template <class T> struct is_##name##_tester\ - {\ - template <Type N> static char test(const name<N>&);\ - static double test(...);\ - };\ - template <class T> struct is_##name##_imp\ - {\ - static T inst;\ - BOOST_STATIC_CONSTANT(bool, value = sizeof( ::boost::math::policies::detail::is_##name##_tester<T>::test(inst)) == 1);\ - };\ - }\ - template <class T> struct is_##name : public boost::integral_constant<bool, ::boost::math::policies::detail::is_##name##_imp<T>::value>\ - {\ - template <class U> struct apply{ typedef is_##name<U> type; };\ - }; - -#define BOOST_MATH_META_BOOL(name, Default)\ - template <bool N = Default> struct name : public boost::integral_constant<bool, N>{};\ - namespace detail{\ - template <bool N>\ - char test_is_valid_arg(const name<N>*);\ - char test_is_default_arg(const name<Default>*);\ - template <class T> struct is_##name##_tester\ - {\ - template <bool N> static char test(const name<N>&);\ - static double test(...);\ - };\ - template <class T> struct is_##name##_imp\ - {\ - static T inst;\ - BOOST_STATIC_CONSTANT(bool, value = sizeof( ::boost::math::policies::detail::is_##name##_tester<T>::test(inst)) == 1);\ - };\ - }\ - template <class T> struct is_##name : public boost::integral_constant<bool, ::boost::math::policies::detail::is_##name##_imp<T>::value>\ - {\ - template <class U> struct apply{ typedef is_##name<U> type; };\ - }; -#endif -// -// Begin by defining policy types for error handling: -// -enum error_policy_type -{ - throw_on_error = 0, - errno_on_error = 1, - ignore_error = 2, - user_error = 3 -}; - -BOOST_MATH_META_INT(error_policy_type, domain_error, BOOST_MATH_DOMAIN_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, pole_error, BOOST_MATH_POLE_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, overflow_error, BOOST_MATH_OVERFLOW_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, underflow_error, BOOST_MATH_UNDERFLOW_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, denorm_error, BOOST_MATH_DENORM_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, evaluation_error, BOOST_MATH_EVALUATION_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, rounding_error, BOOST_MATH_ROUNDING_ERROR_POLICY) -BOOST_MATH_META_INT(error_policy_type, indeterminate_result_error, BOOST_MATH_INDETERMINATE_RESULT_ERROR_POLICY) - -// -// Policy types for internal promotion: -// -BOOST_MATH_META_BOOL(promote_float, BOOST_MATH_PROMOTE_FLOAT_POLICY) -BOOST_MATH_META_BOOL(promote_double, BOOST_MATH_PROMOTE_DOUBLE_POLICY) -BOOST_MATH_META_BOOL(assert_undefined, BOOST_MATH_ASSERT_UNDEFINED_POLICY) -// -// Policy types for discrete quantiles: -// -enum discrete_quantile_policy_type -{ - real, - integer_round_outwards, - integer_round_inwards, - integer_round_down, - integer_round_up, - integer_round_nearest -}; - -BOOST_MATH_META_INT(discrete_quantile_policy_type, discrete_quantile, BOOST_MATH_DISCRETE_QUANTILE_POLICY) -// -// Precision: -// -BOOST_MATH_META_INT(int, digits10, BOOST_MATH_DIGITS10_POLICY) -BOOST_MATH_META_INT(int, digits2, 0) -// -// Iterations: -// -BOOST_MATH_META_INT(unsigned long, max_series_iterations, BOOST_MATH_MAX_SERIES_ITERATION_POLICY) -BOOST_MATH_META_INT(unsigned long, max_root_iterations, BOOST_MATH_MAX_ROOT_ITERATION_POLICY) -// -// Define the names for each possible policy: -// -#define BOOST_MATH_PARAMETER(name)\ - BOOST_PARAMETER_TEMPLATE_KEYWORD(name##_name)\ - BOOST_PARAMETER_NAME(name##_name) - -struct default_policy{}; - -namespace detail{ -// -// Trait to work out bits precision from digits10 and digits2: -// -template <class Digits10, class Digits2> -struct precision -{ - // - // Now work out the precision: - // - typedef typename mpl::if_c< - (Digits10::value == 0), - digits2<0>, - digits2<((Digits10::value + 1) * 1000L) / 301L> - >::type digits2_type; -public: -#ifdef __BORLANDC__ - typedef typename mpl::if_c< - (Digits2::value > ::boost::math::policies::detail::precision<Digits10,Digits2>::digits2_type::value), - Digits2, digits2_type>::type type; -#else - typedef typename mpl::if_c< - (Digits2::value > digits2_type::value), - Digits2, digits2_type>::type type; -#endif -}; - -template <class A, class B, bool b> -struct select_result -{ - typedef A type; -}; -template <class A, class B> -struct select_result<A, B, false> -{ - typedef typename mpl::deref<B>::type type; -}; - -template <class Seq, class Pred, class DefaultType> -struct find_arg -{ -private: - typedef typename mpl::find_if<Seq, Pred>::type iter; - typedef typename mpl::end<Seq>::type end_type; -public: - typedef typename select_result< - DefaultType, iter, - ::boost::is_same<iter, end_type>::value>::type type; -}; - -double test_is_valid_arg(...); -double test_is_default_arg(...); -char test_is_valid_arg(const default_policy*); -char test_is_default_arg(const default_policy*); - -template <class T> -struct is_valid_policy_imp -{ - BOOST_STATIC_CONSTANT(bool, value = sizeof(::boost::math::policies::detail::test_is_valid_arg(static_cast<T*>(0))) == 1); -}; - -template <class T> -struct is_default_policy_imp -{ - BOOST_STATIC_CONSTANT(bool, value = sizeof(::boost::math::policies::detail::test_is_default_arg(static_cast<T*>(0))) == 1); -}; - -template <class T> struct is_valid_policy -: public boost::integral_constant<bool, ::boost::math::policies::detail::is_valid_policy_imp<T>::value> -{}; - -template <class T> struct is_default_policy -: public boost::integral_constant<bool, ::boost::math::policies::detail::is_default_policy_imp<T>::value> -{ - template <class U> - struct apply - { - typedef is_default_policy<U> type; - }; -}; - -template <class Seq, class T, int N> -struct append_N -{ - typedef typename mpl::push_back<Seq, T>::type new_seq; - typedef typename append_N<new_seq, T, N-1>::type type; -}; - -template <class Seq, class T> -struct append_N<Seq, T, 0> -{ - typedef Seq type; -}; - -// -// Traits class to work out what template parameters our default -// policy<> class will have when modified for forwarding: -// -template <bool f, bool d> -struct default_args -{ - typedef promote_float<false> arg1; - typedef promote_double<false> arg2; -}; - -template <> -struct default_args<false, false> -{ - typedef default_policy arg1; - typedef default_policy arg2; -}; - -template <> -struct default_args<true, false> -{ - typedef promote_float<false> arg1; - typedef default_policy arg2; -}; - -template <> -struct default_args<false, true> -{ - typedef promote_double<false> arg1; - typedef default_policy arg2; -}; - -typedef default_args<BOOST_MATH_PROMOTE_FLOAT_POLICY, BOOST_MATH_PROMOTE_DOUBLE_POLICY>::arg1 forwarding_arg1; -typedef default_args<BOOST_MATH_PROMOTE_FLOAT_POLICY, BOOST_MATH_PROMOTE_DOUBLE_POLICY>::arg2 forwarding_arg2; - -} // detail -// -// Now define the policy type with enough arguments to handle all -// the policies: -// -template <class A1 = default_policy, - class A2 = default_policy, - class A3 = default_policy, - class A4 = default_policy, - class A5 = default_policy, - class A6 = default_policy, - class A7 = default_policy, - class A8 = default_policy, - class A9 = default_policy, - class A10 = default_policy, - class A11 = default_policy, - class A12 = default_policy, - class A13 = default_policy> -struct policy -{ -private: - // - // Validate all our arguments: - // - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A1>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A2>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A3>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A4>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A5>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A6>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A7>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A8>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A9>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A10>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A11>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A12>::value); - BOOST_STATIC_ASSERT(::boost::math::policies::detail::is_valid_policy<A13>::value); - // - // Typelist of the arguments: - // - typedef mpl::list<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11,A12,A13> arg_list; - -public: - typedef typename detail::find_arg<arg_list, is_domain_error<mpl::_1>, domain_error<> >::type domain_error_type; - typedef typename detail::find_arg<arg_list, is_pole_error<mpl::_1>, pole_error<> >::type pole_error_type; - typedef typename detail::find_arg<arg_list, is_overflow_error<mpl::_1>, overflow_error<> >::type overflow_error_type; - typedef typename detail::find_arg<arg_list, is_underflow_error<mpl::_1>, underflow_error<> >::type underflow_error_type; - typedef typename detail::find_arg<arg_list, is_denorm_error<mpl::_1>, denorm_error<> >::type denorm_error_type; - typedef typename detail::find_arg<arg_list, is_evaluation_error<mpl::_1>, evaluation_error<> >::type evaluation_error_type; - typedef typename detail::find_arg<arg_list, is_rounding_error<mpl::_1>, rounding_error<> >::type rounding_error_type; - typedef typename detail::find_arg<arg_list, is_indeterminate_result_error<mpl::_1>, indeterminate_result_error<> >::type indeterminate_result_error_type; -private: - // - // Now work out the precision: - // - typedef typename detail::find_arg<arg_list, is_digits10<mpl::_1>, digits10<> >::type digits10_type; - typedef typename detail::find_arg<arg_list, is_digits2<mpl::_1>, digits2<> >::type bits_precision_type; -public: - typedef typename detail::precision<digits10_type, bits_precision_type>::type precision_type; - // - // Internal promotion: - // - typedef typename detail::find_arg<arg_list, is_promote_float<mpl::_1>, promote_float<> >::type promote_float_type; - typedef typename detail::find_arg<arg_list, is_promote_double<mpl::_1>, promote_double<> >::type promote_double_type; - // - // Discrete quantiles: - // - typedef typename detail::find_arg<arg_list, is_discrete_quantile<mpl::_1>, discrete_quantile<> >::type discrete_quantile_type; - // - // Mathematically undefined properties: - // - typedef typename detail::find_arg<arg_list, is_assert_undefined<mpl::_1>, assert_undefined<> >::type assert_undefined_type; - // - // Max iterations: - // - typedef typename detail::find_arg<arg_list, is_max_series_iterations<mpl::_1>, max_series_iterations<> >::type max_series_iterations_type; - typedef typename detail::find_arg<arg_list, is_max_root_iterations<mpl::_1>, max_root_iterations<> >::type max_root_iterations_type; -}; -// -// These full specializations are defined to reduce the amount of -// template instantiations that have to take place when using the default -// policies, they have quite a large impact on compile times: -// -template <> -struct policy<default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy> -{ -public: - typedef domain_error<> domain_error_type; - typedef pole_error<> pole_error_type; - typedef overflow_error<> overflow_error_type; - typedef underflow_error<> underflow_error_type; - typedef denorm_error<> denorm_error_type; - typedef evaluation_error<> evaluation_error_type; - typedef rounding_error<> rounding_error_type; - typedef indeterminate_result_error<> indeterminate_result_error_type; -#if BOOST_MATH_DIGITS10_POLICY == 0 - typedef digits2<> precision_type; -#else - typedef detail::precision<digits10<>, digits2<> >::type precision_type; -#endif - typedef promote_float<> promote_float_type; - typedef promote_double<> promote_double_type; - typedef discrete_quantile<> discrete_quantile_type; - typedef assert_undefined<> assert_undefined_type; - typedef max_series_iterations<> max_series_iterations_type; - typedef max_root_iterations<> max_root_iterations_type; -}; - -template <> -struct policy<detail::forwarding_arg1, detail::forwarding_arg2, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy> -{ -public: - typedef domain_error<> domain_error_type; - typedef pole_error<> pole_error_type; - typedef overflow_error<> overflow_error_type; - typedef underflow_error<> underflow_error_type; - typedef denorm_error<> denorm_error_type; - typedef evaluation_error<> evaluation_error_type; - typedef rounding_error<> rounding_error_type; - typedef indeterminate_result_error<> indeterminate_result_error_type; -#if BOOST_MATH_DIGITS10_POLICY == 0 - typedef digits2<> precision_type; -#else - typedef detail::precision<digits10<>, digits2<> >::type precision_type; -#endif - typedef promote_float<false> promote_float_type; - typedef promote_double<false> promote_double_type; - typedef discrete_quantile<> discrete_quantile_type; - typedef assert_undefined<> assert_undefined_type; - typedef max_series_iterations<> max_series_iterations_type; - typedef max_root_iterations<> max_root_iterations_type; -}; - -template <class Policy, - class A1 = default_policy, - class A2 = default_policy, - class A3 = default_policy, - class A4 = default_policy, - class A5 = default_policy, - class A6 = default_policy, - class A7 = default_policy, - class A8 = default_policy, - class A9 = default_policy, - class A10 = default_policy, - class A11 = default_policy, - class A12 = default_policy, - class A13 = default_policy> -struct normalise -{ -private: - typedef mpl::list<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11,A12,A13> arg_list; - typedef typename detail::find_arg<arg_list, is_domain_error<mpl::_1>, typename Policy::domain_error_type >::type domain_error_type; - typedef typename detail::find_arg<arg_list, is_pole_error<mpl::_1>, typename Policy::pole_error_type >::type pole_error_type; - typedef typename detail::find_arg<arg_list, is_overflow_error<mpl::_1>, typename Policy::overflow_error_type >::type overflow_error_type; - typedef typename detail::find_arg<arg_list, is_underflow_error<mpl::_1>, typename Policy::underflow_error_type >::type underflow_error_type; - typedef typename detail::find_arg<arg_list, is_denorm_error<mpl::_1>, typename Policy::denorm_error_type >::type denorm_error_type; - typedef typename detail::find_arg<arg_list, is_evaluation_error<mpl::_1>, typename Policy::evaluation_error_type >::type evaluation_error_type; - typedef typename detail::find_arg<arg_list, is_rounding_error<mpl::_1>, typename Policy::rounding_error_type >::type rounding_error_type; - typedef typename detail::find_arg<arg_list, is_indeterminate_result_error<mpl::_1>, typename Policy::indeterminate_result_error_type >::type indeterminate_result_error_type; - // - // Now work out the precision: - // - typedef typename detail::find_arg<arg_list, is_digits10<mpl::_1>, digits10<> >::type digits10_type; - typedef typename detail::find_arg<arg_list, is_digits2<mpl::_1>, typename Policy::precision_type >::type bits_precision_type; - typedef typename detail::precision<digits10_type, bits_precision_type>::type precision_type; - // - // Internal promotion: - // - typedef typename detail::find_arg<arg_list, is_promote_float<mpl::_1>, typename Policy::promote_float_type >::type promote_float_type; - typedef typename detail::find_arg<arg_list, is_promote_double<mpl::_1>, typename Policy::promote_double_type >::type promote_double_type; - // - // Discrete quantiles: - // - typedef typename detail::find_arg<arg_list, is_discrete_quantile<mpl::_1>, typename Policy::discrete_quantile_type >::type discrete_quantile_type; - // - // Mathematically undefined properties: - // - typedef typename detail::find_arg<arg_list, is_assert_undefined<mpl::_1>, typename Policy::assert_undefined_type >::type assert_undefined_type; - // - // Max iterations: - // - typedef typename detail::find_arg<arg_list, is_max_series_iterations<mpl::_1>, typename Policy::max_series_iterations_type>::type max_series_iterations_type; - typedef typename detail::find_arg<arg_list, is_max_root_iterations<mpl::_1>, typename Policy::max_root_iterations_type>::type max_root_iterations_type; - // - // Define a typelist of the policies: - // - typedef mpl::vector< - domain_error_type, - pole_error_type, - overflow_error_type, - underflow_error_type, - denorm_error_type, - evaluation_error_type, - rounding_error_type, - indeterminate_result_error_type, - precision_type, - promote_float_type, - promote_double_type, - discrete_quantile_type, - assert_undefined_type, - max_series_iterations_type, - max_root_iterations_type> result_list; - // - // Remove all the policies that are the same as the default: - // - typedef typename mpl::remove_if<result_list, detail::is_default_policy<mpl::_> >::type reduced_list; - // - // Pad out the list with defaults: - // - typedef typename detail::append_N<reduced_list, default_policy, (14 - ::boost::mpl::size<reduced_list>::value)>::type result_type; -public: - typedef policy< - typename mpl::at<result_type, boost::integral_constant<int, 0> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 1> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 2> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 3> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 4> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 5> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 6> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 7> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 8> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 9> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 10> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 11> >::type, - typename mpl::at<result_type, boost::integral_constant<int, 12> >::type > type; -}; -// -// Full specialisation to speed up compilation of the common case: -// -template <> -struct normalise<policy<>, - promote_float<false>, - promote_double<false>, - discrete_quantile<>, - assert_undefined<>, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy> -{ - typedef policy<detail::forwarding_arg1, detail::forwarding_arg2> type; -}; - -template <> -struct normalise<policy<detail::forwarding_arg1, detail::forwarding_arg2>, - promote_float<false>, - promote_double<false>, - discrete_quantile<>, - assert_undefined<>, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy, - default_policy> -{ - typedef policy<detail::forwarding_arg1, detail::forwarding_arg2> type; -}; - -inline BOOST_MATH_CONSTEXPR policy<> make_policy() BOOST_NOEXCEPT -{ return policy<>(); } - -template <class A1> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1>::type make_policy(const A1&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1>::type result_type; - return result_type(); -} - -template <class A1, class A2> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2>::type make_policy(const A1&, const A2&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3>::type make_policy(const A1&, const A2&, const A3&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4>::type make_policy(const A1&, const A2&, const A3&, const A4&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6, class A7> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9, class A10> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&, const A10&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10>::type result_type; - return result_type(); -} - -template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9, class A10, class A11> -inline BOOST_MATH_CONSTEXPR typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&, const A10&, const A11&) BOOST_NOEXCEPT -{ - typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11>::type result_type; - return result_type(); -} - -// -// Traits class to handle internal promotion: -// -template <class Real, class Policy> -struct evaluation -{ - typedef Real type; -}; - -template <class Policy> -struct evaluation<float, Policy> -{ - typedef typename mpl::if_<typename Policy::promote_float_type, double, float>::type type; -}; - -template <class Policy> -struct evaluation<double, Policy> -{ - typedef typename mpl::if_<typename Policy::promote_double_type, long double, double>::type type; -}; - -#ifdef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - -template <class Real> -struct basic_digits : public boost::integral_constant<int, 0>{ }; -template <> -struct basic_digits<float> : public boost::integral_constant<int, FLT_MANT_DIG>{ }; -template <> -struct basic_digits<double> : public boost::integral_constant<int, DBL_MANT_DIG>{ }; -template <> -struct basic_digits<long double> : public boost::integral_constant<int, LDBL_MANT_DIG>{ }; - -template <class Real, class Policy> -struct precision -{ - BOOST_STATIC_ASSERT( ::std::numeric_limits<Real>::radix == 2); - typedef typename Policy::precision_type precision_type; - typedef basic_digits<Real> digits_t; - typedef typename mpl::if_< - mpl::equal_to<digits_t, boost::integral_constant<int, 0> >, - // Possibly unknown precision: - precision_type, - typename mpl::if_< - mpl::or_<mpl::less_equal<digits_t, precision_type>, mpl::less_equal<precision_type, boost::integral_constant<int, 0> > >, - // Default case, full precision for RealType: - digits2< ::std::numeric_limits<Real>::digits>, - // User customised precision: - precision_type - >::type - >::type type; -}; - -template <class Policy> -struct precision<float, Policy> -{ - typedef digits2<FLT_MANT_DIG> type; -}; -template <class Policy> -struct precision<double, Policy> -{ - typedef digits2<DBL_MANT_DIG> type; -}; -template <class Policy> -struct precision<long double, Policy> -{ - typedef digits2<LDBL_MANT_DIG> type; -}; - -#else - -template <class Real, class Policy> -struct precision -{ - BOOST_STATIC_ASSERT((::std::numeric_limits<Real>::radix == 2) || ((::std::numeric_limits<Real>::is_specialized == 0) || (::std::numeric_limits<Real>::digits == 0))); -#ifndef __BORLANDC__ - typedef typename Policy::precision_type precision_type; - typedef typename mpl::if_c< - ((::std::numeric_limits<Real>::is_specialized == 0) || (::std::numeric_limits<Real>::digits == 0)), - // Possibly unknown precision: - precision_type, - typename mpl::if_c< - ((::std::numeric_limits<Real>::digits <= precision_type::value) - || (Policy::precision_type::value <= 0)), - // Default case, full precision for RealType: - digits2< ::std::numeric_limits<Real>::digits>, - // User customised precision: - precision_type - >::type - >::type type; -#else - typedef typename Policy::precision_type precision_type; - typedef boost::integral_constant<int, ::std::numeric_limits<Real>::digits> digits_t; - typedef boost::integral_constant<bool, ::std::numeric_limits<Real>::is_specialized> spec_t; - typedef typename mpl::if_< - mpl::or_<mpl::equal_to<spec_t, boost::true_type>, mpl::equal_to<digits_t, boost::integral_constant<int, 0> > >, - // Possibly unknown precision: - precision_type, - typename mpl::if_< - mpl::or_<mpl::less_equal<digits_t, precision_type>, mpl::less_equal<precision_type, boost::integral_constant<int, 0> > >, - // Default case, full precision for RealType: - digits2< ::std::numeric_limits<Real>::digits>, - // User customised precision: - precision_type - >::type - >::type type; -#endif -}; - -#endif - -#ifdef BOOST_MATH_USE_FLOAT128 - -template <class Policy> -struct precision<BOOST_MATH_FLOAT128_TYPE, Policy> -{ - typedef boost::integral_constant<int, 113> type; -}; - -#endif - -namespace detail{ - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR int digits_imp(boost::true_type const&) BOOST_NOEXCEPT -{ -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - BOOST_STATIC_ASSERT( ::std::numeric_limits<T>::is_specialized); -#else - BOOST_ASSERT(::std::numeric_limits<T>::is_specialized); -#endif - typedef typename boost::math::policies::precision<T, Policy>::type p_t; - return p_t::value; -} - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR int digits_imp(boost::false_type const&) BOOST_NOEXCEPT -{ - return tools::digits<T>(); -} - -} // namespace detail - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR int digits(BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(T)) BOOST_NOEXCEPT -{ - typedef boost::integral_constant<bool, std::numeric_limits<T>::is_specialized > tag_type; - return detail::digits_imp<T, Policy>(tag_type()); -} -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR int digits_base10(BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(T)) BOOST_NOEXCEPT -{ - return boost::math::policies::digits<T, Policy>() * 301 / 1000L; -} - -template <class Policy> -inline BOOST_MATH_CONSTEXPR unsigned long get_max_series_iterations() BOOST_NOEXCEPT -{ - typedef typename Policy::max_series_iterations_type iter_type; - return iter_type::value; -} - -template <class Policy> -inline BOOST_MATH_CONSTEXPR unsigned long get_max_root_iterations() BOOST_NOEXCEPT -{ - typedef typename Policy::max_root_iterations_type iter_type; - return iter_type::value; -} - -namespace detail{ - -template <class T, class Digits, class Small, class Default> -struct series_factor_calc -{ - static T get() BOOST_MATH_NOEXCEPT(T) - { - return ldexp(T(1.0), 1 - Digits::value); - } -}; - -template <class T, class Digits> -struct series_factor_calc<T, Digits, boost::true_type, boost::true_type> -{ - static BOOST_MATH_CONSTEXPR T get() BOOST_MATH_NOEXCEPT(T) - { - return boost::math::tools::epsilon<T>(); - } -}; -template <class T, class Digits> -struct series_factor_calc<T, Digits, boost::true_type, boost::false_type> -{ - static BOOST_MATH_CONSTEXPR T get() BOOST_MATH_NOEXCEPT(T) - { - return 1 / static_cast<T>(static_cast<boost::uintmax_t>(1u) << (Digits::value - 1)); - } -}; -template <class T, class Digits> -struct series_factor_calc<T, Digits, boost::false_type, boost::true_type> -{ - static BOOST_MATH_CONSTEXPR T get() BOOST_MATH_NOEXCEPT(T) - { - return boost::math::tools::epsilon<T>(); - } -}; - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR T get_epsilon_imp(boost::true_type const&) BOOST_MATH_NOEXCEPT(T) -{ -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - BOOST_STATIC_ASSERT( ::std::numeric_limits<T>::is_specialized); - BOOST_STATIC_ASSERT( ::std::numeric_limits<T>::radix == 2); -#else - BOOST_ASSERT(::std::numeric_limits<T>::is_specialized); - BOOST_ASSERT(::std::numeric_limits<T>::radix == 2); -#endif - typedef typename boost::math::policies::precision<T, Policy>::type p_t; - typedef boost::integral_constant<bool, p_t::value <= std::numeric_limits<boost::uintmax_t>::digits> is_small_int; - typedef boost::integral_constant<bool, p_t::value >= std::numeric_limits<T>::digits> is_default_value; - return series_factor_calc<T, p_t, is_small_int, is_default_value>::get(); -} - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR T get_epsilon_imp(boost::false_type const&) BOOST_MATH_NOEXCEPT(T) -{ - return tools::epsilon<T>(); -} - -} // namespace detail - -template <class T, class Policy> -inline BOOST_MATH_CONSTEXPR T get_epsilon(BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(T)) BOOST_MATH_NOEXCEPT(T) -{ - typedef boost::integral_constant<bool, (std::numeric_limits<T>::is_specialized && (std::numeric_limits<T>::radix == 2)) > tag_type; - return detail::get_epsilon_imp<T, Policy>(tag_type()); -} - -namespace detail{ - -template <class A1, - class A2, - class A3, - class A4, - class A5, - class A6, - class A7, - class A8, - class A9, - class A10, - class A11> -char test_is_policy(const policy<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11>*); -double test_is_policy(...); - -template <class P> -struct is_policy_imp -{ - BOOST_STATIC_CONSTANT(bool, value = (sizeof(::boost::math::policies::detail::test_is_policy(static_cast<P*>(0))) == 1)); -}; - -} - -template <class P> -struct is_policy : public boost::integral_constant<bool, ::boost::math::policies::detail::is_policy_imp<P>::value> {}; - -// -// Helper traits class for distribution error handling: -// -template <class Policy> -struct constructor_error_check -{ - typedef typename Policy::domain_error_type domain_error_type; - typedef typename mpl::if_c< - (domain_error_type::value == throw_on_error) || (domain_error_type::value == user_error) || (domain_error_type::value == errno_on_error), - boost::true_type, - boost::false_type>::type type; -}; - -template <class Policy> -struct method_error_check -{ - typedef typename Policy::domain_error_type domain_error_type; - typedef typename mpl::if_c< - (domain_error_type::value == throw_on_error) && (domain_error_type::value != user_error), - boost::false_type, - boost::true_type>::type type; -}; -// -// Does the Policy ever throw on error? -// -template <class Policy> -struct is_noexcept_error_policy -{ - typedef typename Policy::domain_error_type t1; - typedef typename Policy::pole_error_type t2; - typedef typename Policy::overflow_error_type t3; - typedef typename Policy::underflow_error_type t4; - typedef typename Policy::denorm_error_type t5; - typedef typename Policy::evaluation_error_type t6; - typedef typename Policy::rounding_error_type t7; - typedef typename Policy::indeterminate_result_error_type t8; - - BOOST_STATIC_CONSTANT(bool, value = - ((t1::value != throw_on_error) && (t1::value != user_error) - && (t2::value != throw_on_error) && (t2::value != user_error) - && (t3::value != throw_on_error) && (t3::value != user_error) - && (t4::value != throw_on_error) && (t4::value != user_error) - && (t5::value != throw_on_error) && (t5::value != user_error) - && (t6::value != throw_on_error) && (t6::value != user_error) - && (t7::value != throw_on_error) && (t7::value != user_error) - && (t8::value != throw_on_error) && (t8::value != user_error))); -}; - -}}} // namespaces - -#endif // BOOST_MATH_POLICY_HPP - diff --git a/ThirdParty/boost/math/special_functions/math_fwd.hpp b/ThirdParty/boost/math/special_functions/math_fwd.hpp deleted file mode 100644 index f143c08bcedac20392a1ada48c7483da41f285d9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/math/special_functions/math_fwd.hpp +++ /dev/null @@ -1,1712 +0,0 @@ -// math_fwd.hpp - -// TODO revise completely for new distribution classes. - -// Copyright Paul A. Bristow 2006. -// Copyright John Maddock 2006. - -// Use, modification and distribution are subject to 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) - -// Omnibus list of forward declarations of math special functions. - -// IT = Integer type. -// RT = Real type (built-in floating-point types, float, double, long double) & User Defined Types -// AT = Integer or Real type - -#ifndef BOOST_MATH_SPECIAL_MATH_FWD_HPP -#define BOOST_MATH_SPECIAL_MATH_FWD_HPP - -#ifdef _MSC_VER -#pragma once -#endif - -#include <vector> -#include <boost/math/special_functions/detail/round_fwd.hpp> -#include <boost/math/tools/promotion.hpp> // for argument promotion. -#include <boost/math/policies/policy.hpp> -#include <boost/mpl/comparison.hpp> -#include <boost/utility/enable_if.hpp> -#include <boost/config/no_tr1/complex.hpp> - -#define BOOST_NO_MACRO_EXPAND /**/ - -namespace boost -{ - namespace math - { // Math functions (in roughly alphabetic order). - - // Beta functions. - template <class RT1, class RT2> - typename tools::promote_args<RT1, RT2>::type - beta(RT1 a, RT2 b); // Beta function (2 arguments). - - template <class RT1, class RT2, class A> - typename tools::promote_args<RT1, RT2, A>::type - beta(RT1 a, RT2 b, A x); // Beta function (3 arguments). - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - beta(RT1 a, RT2 b, RT3 x, const Policy& pol); // Beta function (3 arguments). - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - betac(RT1 a, RT2 b, RT3 x); - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - betac(RT1 a, RT2 b, RT3 x, const Policy& pol); - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta(RT1 a, RT2 b, RT3 x); // Incomplete beta function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta(RT1 a, RT2 b, RT3 x, const Policy& pol); // Incomplete beta function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac(RT1 a, RT2 b, RT3 x); // Incomplete beta complement function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac(RT1 a, RT2 b, RT3 x, const Policy& pol); // Incomplete beta complement function. - - template <class T1, class T2, class T3, class T4> - typename tools::promote_args<T1, T2, T3, T4>::type - ibeta_inv(T1 a, T2 b, T3 p, T4* py); - - template <class T1, class T2, class T3, class T4, class Policy> - typename tools::promote_args<T1, T2, T3, T4>::type - ibeta_inv(T1 a, T2 b, T3 p, T4* py, const Policy& pol); - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_inv(RT1 a, RT2 b, RT3 p); // Incomplete beta inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_inv(RT1 a, RT2 b, RT3 p, const Policy&); // Incomplete beta inverse function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_inva(RT1 a, RT2 b, RT3 p); // Incomplete beta inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_inva(RT1 a, RT2 b, RT3 p, const Policy&); // Incomplete beta inverse function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_invb(RT1 a, RT2 b, RT3 p); // Incomplete beta inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_invb(RT1 a, RT2 b, RT3 p, const Policy&); // Incomplete beta inverse function. - - template <class T1, class T2, class T3, class T4> - typename tools::promote_args<T1, T2, T3, T4>::type - ibetac_inv(T1 a, T2 b, T3 q, T4* py); - - template <class T1, class T2, class T3, class T4, class Policy> - typename tools::promote_args<T1, T2, T3, T4>::type - ibetac_inv(T1 a, T2 b, T3 q, T4* py, const Policy& pol); - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_inv(RT1 a, RT2 b, RT3 q); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_inv(RT1 a, RT2 b, RT3 q, const Policy&); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_inva(RT1 a, RT2 b, RT3 q); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_inva(RT1 a, RT2 b, RT3 q, const Policy&); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_invb(RT1 a, RT2 b, RT3 q); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibetac_invb(RT1 a, RT2 b, RT3 q, const Policy&); // Incomplete beta complement inverse function. - - template <class RT1, class RT2, class RT3> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_derivative(RT1 a, RT2 b, RT3 x); // derivative of incomplete beta - - template <class RT1, class RT2, class RT3, class Policy> - typename tools::promote_args<RT1, RT2, RT3>::type - ibeta_derivative(RT1 a, RT2 b, RT3 x, const Policy& pol); // derivative of incomplete beta - - // Binomial: - template <class T, class Policy> - T binomial_coefficient(unsigned n, unsigned k, const Policy& pol); - template <class T> - T binomial_coefficient(unsigned n, unsigned k); - - // erf & erfc error functions. - template <class RT> // Error function. - typename tools::promote_args<RT>::type erf(RT z); - template <class RT, class Policy> // Error function. - typename tools::promote_args<RT>::type erf(RT z, const Policy&); - - template <class RT>// Error function complement. - typename tools::promote_args<RT>::type erfc(RT z); - template <class RT, class Policy>// Error function complement. - typename tools::promote_args<RT>::type erfc(RT z, const Policy&); - - template <class RT>// Error function inverse. - typename tools::promote_args<RT>::type erf_inv(RT z); - template <class RT, class Policy>// Error function inverse. - typename tools::promote_args<RT>::type erf_inv(RT z, const Policy& pol); - - template <class RT>// Error function complement inverse. - typename tools::promote_args<RT>::type erfc_inv(RT z); - template <class RT, class Policy>// Error function complement inverse. - typename tools::promote_args<RT>::type erfc_inv(RT z, const Policy& pol); - - // Polynomials: - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - legendre_next(unsigned l, T1 x, T2 Pl, T3 Plm1); - - template <class T> - typename tools::promote_args<T>::type - legendre_p(int l, T x); - template <class T> - typename tools::promote_args<T>::type - legendre_p_prime(int l, T x); - - - template <class T, class Policy> - inline std::vector<T> legendre_p_zeros(int l, const Policy& pol); - - template <class T> - inline std::vector<T> legendre_p_zeros(int l); - -#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1310) - template <class T, class Policy> - typename boost::enable_if_c<policies::is_policy<Policy>::value, typename tools::promote_args<T>::type>::type - legendre_p(int l, T x, const Policy& pol); - template <class T, class Policy> - inline typename boost::enable_if_c<policies::is_policy<Policy>::value, typename tools::promote_args<T>::type>::type - legendre_p_prime(int l, T x, const Policy& pol); -#endif - template <class T> - typename tools::promote_args<T>::type - legendre_q(unsigned l, T x); -#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1310) - template <class T, class Policy> - typename boost::enable_if_c<policies::is_policy<Policy>::value, typename tools::promote_args<T>::type>::type - legendre_q(unsigned l, T x, const Policy& pol); -#endif - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - legendre_next(unsigned l, unsigned m, T1 x, T2 Pl, T3 Plm1); - - template <class T> - typename tools::promote_args<T>::type - legendre_p(int l, int m, T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type - legendre_p(int l, int m, T x, const Policy& pol); - - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - laguerre_next(unsigned n, T1 x, T2 Ln, T3 Lnm1); - - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - laguerre_next(unsigned n, unsigned l, T1 x, T2 Pl, T3 Plm1); - - template <class T> - typename tools::promote_args<T>::type - laguerre(unsigned n, T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type - laguerre(unsigned n, unsigned m, T x, const Policy& pol); - - template <class T1, class T2> - struct laguerre_result - { - typedef typename mpl::if_< - policies::is_policy<T2>, - typename tools::promote_args<T1>::type, - typename tools::promote_args<T2>::type - >::type type; - }; - - template <class T1, class T2> - typename laguerre_result<T1, T2>::type - laguerre(unsigned n, T1 m, T2 x); - - template <class T> - typename tools::promote_args<T>::type - hermite(unsigned n, T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type - hermite(unsigned n, T x, const Policy& pol); - - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - hermite_next(unsigned n, T1 x, T2 Hn, T3 Hnm1); - - template<class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type chebyshev_next(T1 const & x, T2 const & Tn, T3 const & Tn_1); - - template <class Real, class Policy> - typename tools::promote_args<Real>::type - chebyshev_t(unsigned n, Real const & x, const Policy&); - template<class Real> - typename tools::promote_args<Real>::type chebyshev_t(unsigned n, Real const & x); - - template <class Real, class Policy> - typename tools::promote_args<Real>::type - chebyshev_u(unsigned n, Real const & x, const Policy&); - template<class Real> - typename tools::promote_args<Real>::type chebyshev_u(unsigned n, Real const & x); - - template <class Real, class Policy> - typename tools::promote_args<Real>::type - chebyshev_t_prime(unsigned n, Real const & x, const Policy&); - template<class Real> - typename tools::promote_args<Real>::type chebyshev_t_prime(unsigned n, Real const & x); - - template<class Real, class T2> - Real chebyshev_clenshaw_recurrence(const Real* const c, size_t length, const T2& x); - - template <class T1, class T2> - std::complex<typename tools::promote_args<T1, T2>::type> - spherical_harmonic(unsigned n, int m, T1 theta, T2 phi); - - template <class T1, class T2, class Policy> - std::complex<typename tools::promote_args<T1, T2>::type> - spherical_harmonic(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type - spherical_harmonic_r(unsigned n, int m, T1 theta, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type - spherical_harmonic_r(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type - spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type - spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); - - // Elliptic integrals: - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - ellint_rf(T1 x, T2 y, T3 z); - - template <class T1, class T2, class T3, class Policy> - typename tools::promote_args<T1, T2, T3>::type - ellint_rf(T1 x, T2 y, T3 z, const Policy& pol); - - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - ellint_rd(T1 x, T2 y, T3 z); - - template <class T1, class T2, class T3, class Policy> - typename tools::promote_args<T1, T2, T3>::type - ellint_rd(T1 x, T2 y, T3 z, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type - ellint_rc(T1 x, T2 y); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type - ellint_rc(T1 x, T2 y, const Policy& pol); - - template <class T1, class T2, class T3, class T4> - typename tools::promote_args<T1, T2, T3, T4>::type - ellint_rj(T1 x, T2 y, T3 z, T4 p); - - template <class T1, class T2, class T3, class T4, class Policy> - typename tools::promote_args<T1, T2, T3, T4>::type - ellint_rj(T1 x, T2 y, T3 z, T4 p, const Policy& pol); - - template <class T1, class T2, class T3> - typename tools::promote_args<T1, T2, T3>::type - ellint_rg(T1 x, T2 y, T3 z); - - template <class T1, class T2, class T3, class Policy> - typename tools::promote_args<T1, T2, T3>::type - ellint_rg(T1 x, T2 y, T3 z, const Policy& pol); - - template <typename T> - typename tools::promote_args<T>::type ellint_2(T k); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type ellint_2(T1 k, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type ellint_2(T1 k, T2 phi, const Policy& pol); - - template <typename T> - typename tools::promote_args<T>::type ellint_1(T k); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type ellint_1(T1 k, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type ellint_1(T1 k, T2 phi, const Policy& pol); - - template <typename T> - typename tools::promote_args<T>::type ellint_d(T k); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type ellint_d(T1 k, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type ellint_d(T1 k, T2 phi, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type jacobi_zeta(T1 k, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type jacobi_zeta(T1 k, T2 phi, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type heuman_lambda(T1 k, T2 phi); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type heuman_lambda(T1 k, T2 phi, const Policy& pol); - - namespace detail{ - - template <class T, class U, class V> - struct ellint_3_result - { - typedef typename mpl::if_< - policies::is_policy<V>, - typename tools::promote_args<T, U>::type, - typename tools::promote_args<T, U, V>::type - >::type type; - }; - - } // namespace detail - - - template <class T1, class T2, class T3> - typename detail::ellint_3_result<T1, T2, T3>::type ellint_3(T1 k, T2 v, T3 phi); - - template <class T1, class T2, class T3, class Policy> - typename tools::promote_args<T1, T2, T3>::type ellint_3(T1 k, T2 v, T3 phi, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type ellint_3(T1 k, T2 v); - - // Factorial functions. - // Note: not for integral types, at present. - template <class RT> - struct max_factorial; - template <class RT> - RT factorial(unsigned int); - template <class RT, class Policy> - RT factorial(unsigned int, const Policy& pol); - template <class RT> - RT unchecked_factorial(unsigned int BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_TYPE(RT)); - template <class RT> - RT double_factorial(unsigned i); - template <class RT, class Policy> - RT double_factorial(unsigned i, const Policy& pol); - - template <class RT> - typename tools::promote_args<RT>::type falling_factorial(RT x, unsigned n); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type falling_factorial(RT x, unsigned n, const Policy& pol); - - template <class RT> - typename tools::promote_args<RT>::type rising_factorial(RT x, int n); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type rising_factorial(RT x, int n, const Policy& pol); - - // Gamma functions. - template <class RT> - typename tools::promote_args<RT>::type tgamma(RT z); - - template <class RT> - typename tools::promote_args<RT>::type tgamma1pm1(RT z); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type tgamma1pm1(RT z, const Policy& pol); - - template <class RT1, class RT2> - typename tools::promote_args<RT1, RT2>::type tgamma(RT1 a, RT2 z); - - template <class RT1, class RT2, class Policy> - typename tools::promote_args<RT1, RT2>::type tgamma(RT1 a, RT2 z, const Policy& pol); - - template <class RT> - typename tools::promote_args<RT>::type lgamma(RT z, int* sign); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type lgamma(RT z, int* sign, const Policy& pol); - - template <class RT> - typename tools::promote_args<RT>::type lgamma(RT x); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type lgamma(RT x, const Policy& pol); - - template <class RT1, class RT2> - typename tools::promote_args<RT1, RT2>::type tgamma_lower(RT1 a, RT2 z); - - template <class RT1, class RT2, class Policy> - typename tools::promote_args<RT1, RT2>::type tgamma_lower(RT1 a, RT2 z, const Policy&); - - template <class RT1, class RT2> - typename tools::promote_args<RT1, RT2>::type gamma_q(RT1 a, RT2 z); - - template <class RT1, class RT2, class Policy> - typename tools::promote_args<RT1, RT2>::type gamma_q(RT1 a, RT2 z, const Policy&); - - template <class RT1, class RT2> - typename tools::promote_args<RT1, RT2>::type gamma_p(RT1 a, RT2 z); - - template <class RT1, class RT2, class Policy> - typename tools::promote_args<RT1, RT2>::type gamma_p(RT1 a, RT2 z, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type tgamma_delta_ratio(T1 z, T2 delta); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type tgamma_delta_ratio(T1 z, T2 delta, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type tgamma_ratio(T1 a, T2 b); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type tgamma_ratio(T1 a, T2 b, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type gamma_p_derivative(T1 a, T2 x); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type gamma_p_derivative(T1 a, T2 x, const Policy&); - - // gamma inverse. - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type gamma_p_inv(T1 a, T2 p); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type gamma_p_inva(T1 a, T2 p, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type gamma_p_inva(T1 a, T2 p); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type gamma_p_inv(T1 a, T2 p, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type gamma_q_inv(T1 a, T2 q); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type gamma_q_inv(T1 a, T2 q, const Policy&); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type gamma_q_inva(T1 a, T2 q); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type gamma_q_inva(T1 a, T2 q, const Policy&); - - // digamma: - template <class T> - typename tools::promote_args<T>::type digamma(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type digamma(T x, const Policy&); - - // trigamma: - template <class T> - typename tools::promote_args<T>::type trigamma(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type trigamma(T x, const Policy&); - - // polygamma: - template <class T> - typename tools::promote_args<T>::type polygamma(int n, T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type polygamma(int n, T x, const Policy&); - - // Hypotenuse function sqrt(x ^ 2 + y ^ 2). - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type - hypot(T1 x, T2 y); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type - hypot(T1 x, T2 y, const Policy&); - - // cbrt - cube root. - template <class RT> - typename tools::promote_args<RT>::type cbrt(RT z); - - template <class RT, class Policy> - typename tools::promote_args<RT>::type cbrt(RT z, const Policy&); - - // log1p is log(x + 1) - template <class T> - typename tools::promote_args<T>::type log1p(T); - - template <class T, class Policy> - typename tools::promote_args<T>::type log1p(T, const Policy&); - - // log1pmx is log(x + 1) - x - template <class T> - typename tools::promote_args<T>::type log1pmx(T); - - template <class T, class Policy> - typename tools::promote_args<T>::type log1pmx(T, const Policy&); - - // Exp (x) minus 1 functions. - template <class T> - typename tools::promote_args<T>::type expm1(T); - - template <class T, class Policy> - typename tools::promote_args<T>::type expm1(T, const Policy&); - - // Power - 1 - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type - powm1(const T1 a, const T2 z); - - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type - powm1(const T1 a, const T2 z, const Policy&); - - // sqrt(1+x) - 1 - template <class T> - typename tools::promote_args<T>::type sqrt1pm1(const T& val); - - template <class T, class Policy> - typename tools::promote_args<T>::type sqrt1pm1(const T& val, const Policy&); - - // sinus cardinals: - template <class T> - typename tools::promote_args<T>::type sinc_pi(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type sinc_pi(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type sinhc_pi(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type sinhc_pi(T x, const Policy&); - - // inverse hyperbolics: - template<typename T> - typename tools::promote_args<T>::type asinh(T x); - - template<typename T, class Policy> - typename tools::promote_args<T>::type asinh(T x, const Policy&); - - template<typename T> - typename tools::promote_args<T>::type acosh(T x); - - template<typename T, class Policy> - typename tools::promote_args<T>::type acosh(T x, const Policy&); - - template<typename T> - typename tools::promote_args<T>::type atanh(T x); - - template<typename T, class Policy> - typename tools::promote_args<T>::type atanh(T x, const Policy&); - - namespace detail{ - - typedef boost::integral_constant<int, 0> bessel_no_int_tag; // No integer optimisation possible. - typedef boost::integral_constant<int, 1> bessel_maybe_int_tag; // Maybe integer optimisation. - typedef boost::integral_constant<int, 2> bessel_int_tag; // Definite integer optimisation. - - template <class T1, class T2, class Policy> - struct bessel_traits - { - typedef typename mpl::if_< - is_integral<T1>, - typename tools::promote_args<T2>::type, - typename tools::promote_args<T1, T2>::type - >::type result_type; - - typedef typename policies::precision<result_type, Policy>::type precision_type; - - typedef typename mpl::if_< - mpl::or_< - mpl::less_equal<precision_type, boost::integral_constant<int, 0> >, - mpl::greater<precision_type, boost::integral_constant<int, 64> > >, - bessel_no_int_tag, - typename mpl::if_< - is_integral<T1>, - bessel_int_tag, - bessel_maybe_int_tag - >::type - >::type optimisation_tag; - typedef typename mpl::if_< - mpl::or_< - mpl::less_equal<precision_type, boost::integral_constant<int, 0> >, - mpl::greater<precision_type, boost::integral_constant<int, 113> > >, - bessel_no_int_tag, - typename mpl::if_< - is_integral<T1>, - bessel_int_tag, - bessel_maybe_int_tag - >::type - >::type optimisation_tag128; - }; - } // detail - - // Bessel functions: - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_j(T1 v, T2 x, const Policy& pol); - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_j_prime(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_j(T1 v, T2 x); - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_j_prime(T1 v, T2 x); - - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type sph_bessel(unsigned v, T x, const Policy& pol); - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type sph_bessel_prime(unsigned v, T x, const Policy& pol); - - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_bessel(unsigned v, T x); - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_bessel_prime(unsigned v, T x); - - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_i(T1 v, T2 x, const Policy& pol); - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_i_prime(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_i(T1 v, T2 x); - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_i_prime(T1 v, T2 x); - - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_k(T1 v, T2 x, const Policy& pol); - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_k_prime(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_k(T1 v, T2 x); - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_k_prime(T1 v, T2 x); - - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_neumann(T1 v, T2 x, const Policy& pol); - template <class T1, class T2, class Policy> - typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_neumann_prime(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_neumann(T1 v, T2 x); - template <class T1, class T2> - typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_neumann_prime(T1 v, T2 x); - - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type sph_neumann(unsigned v, T x, const Policy& pol); - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type sph_neumann_prime(unsigned v, T x, const Policy& pol); - - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_neumann(unsigned v, T x); - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_neumann_prime(unsigned v, T x); - - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type cyl_bessel_j_zero(T v, int m, const Policy& pol); - - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type cyl_bessel_j_zero(T v, int m); - - template <class T, class OutputIterator> - OutputIterator cyl_bessel_j_zero(T v, - int start_index, - unsigned number_of_zeros, - OutputIterator out_it); - - template <class T, class OutputIterator, class Policy> - OutputIterator cyl_bessel_j_zero(T v, - int start_index, - unsigned number_of_zeros, - OutputIterator out_it, - const Policy&); - - template <class T, class Policy> - typename detail::bessel_traits<T, T, Policy>::result_type cyl_neumann_zero(T v, int m, const Policy& pol); - - template <class T> - typename detail::bessel_traits<T, T, policies::policy<> >::result_type cyl_neumann_zero(T v, int m); - - template <class T, class OutputIterator> - OutputIterator cyl_neumann_zero(T v, - int start_index, - unsigned number_of_zeros, - OutputIterator out_it); - - template <class T, class OutputIterator, class Policy> - OutputIterator cyl_neumann_zero(T v, - int start_index, - unsigned number_of_zeros, - OutputIterator out_it, - const Policy&); - - template <class T1, class T2> - std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> cyl_hankel_1(T1 v, T2 x); - - template <class T1, class T2, class Policy> - std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> cyl_hankel_1(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2, class Policy> - std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> cyl_hankel_2(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> cyl_hankel_2(T1 v, T2 x); - - template <class T1, class T2, class Policy> - std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> sph_hankel_1(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> sph_hankel_1(T1 v, T2 x); - - template <class T1, class T2, class Policy> - std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> sph_hankel_2(T1 v, T2 x, const Policy& pol); - - template <class T1, class T2> - std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> sph_hankel_2(T1 v, T2 x); - - template <class T, class Policy> - typename tools::promote_args<T>::type airy_ai(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type airy_ai(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type airy_bi(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type airy_bi(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type airy_ai_prime(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type airy_ai_prime(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type airy_bi_prime(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type airy_bi_prime(T x); - - template <class T> - T airy_ai_zero(int m); - template <class T, class Policy> - T airy_ai_zero(int m, const Policy&); - - template <class OutputIterator> - OutputIterator airy_ai_zero( - int start_index, - unsigned number_of_zeros, - OutputIterator out_it); - template <class OutputIterator, class Policy> - OutputIterator airy_ai_zero( - int start_index, - unsigned number_of_zeros, - OutputIterator out_it, - const Policy&); - - template <class T> - T airy_bi_zero(int m); - template <class T, class Policy> - T airy_bi_zero(int m, const Policy&); - - template <class OutputIterator> - OutputIterator airy_bi_zero( - int start_index, - unsigned number_of_zeros, - OutputIterator out_it); - template <class OutputIterator, class Policy> - OutputIterator airy_bi_zero( - int start_index, - unsigned number_of_zeros, - OutputIterator out_it, - const Policy&); - - template <class T, class Policy> - typename tools::promote_args<T>::type sin_pi(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type sin_pi(T x); - - template <class T, class Policy> - typename tools::promote_args<T>::type cos_pi(T x, const Policy&); - - template <class T> - typename tools::promote_args<T>::type cos_pi(T x); - - template <class T> - int fpclassify BOOST_NO_MACRO_EXPAND(T t); - - template <class T> - bool isfinite BOOST_NO_MACRO_EXPAND(T z); - - template <class T> - bool isinf BOOST_NO_MACRO_EXPAND(T t); - - template <class T> - bool isnan BOOST_NO_MACRO_EXPAND(T t); - - template <class T> - bool isnormal BOOST_NO_MACRO_EXPAND(T t); - - template<class T> - int signbit BOOST_NO_MACRO_EXPAND(T x); - - template <class T> - int sign BOOST_NO_MACRO_EXPAND(const T& z); - - template <class T, class U> - typename tools::promote_args_permissive<T, U>::type copysign BOOST_NO_MACRO_EXPAND(const T& x, const U& y); - - template <class T> - typename tools::promote_args_permissive<T>::type changesign BOOST_NO_MACRO_EXPAND(const T& z); - - // Exponential integrals: - namespace detail{ - - template <class T, class U> - struct expint_result - { - typedef typename mpl::if_< - policies::is_policy<U>, - typename tools::promote_args<T>::type, - typename tools::promote_args<U>::type - >::type type; - }; - - } // namespace detail - - template <class T, class Policy> - typename tools::promote_args<T>::type expint(unsigned n, T z, const Policy&); - - template <class T, class U> - typename detail::expint_result<T, U>::type expint(T const z, U const u); - - template <class T> - typename tools::promote_args<T>::type expint(T z); - - // Zeta: - template <class T, class Policy> - typename tools::promote_args<T>::type zeta(T s, const Policy&); - - // Owen's T function: - template <class T1, class T2, class Policy> - typename tools::promote_args<T1, T2>::type owens_t(T1 h, T2 a, const Policy& pol); - - template <class T1, class T2> - typename tools::promote_args<T1, T2>::type owens_t(T1 h, T2 a); - - // Jacobi Functions: - template <class T, class U, class V, class Policy> - typename tools::promote_args<T, U, V>::type jacobi_elliptic(T k, U theta, V* pcn, V* pdn, const Policy&); - - template <class T, class U, class V> - typename tools::promote_args<T, U, V>::type jacobi_elliptic(T k, U theta, V* pcn = 0, V* pdn = 0); - - template <class U, class T, class Policy> - typename tools::promote_args<T, U>::type jacobi_sn(U k, T theta, const Policy& pol); - - template <class U, class T> - typename tools::promote_args<T, U>::type jacobi_sn(U k, T theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_cn(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_cn(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_dn(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_dn(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_cd(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_cd(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_dc(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_dc(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_ns(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_ns(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_sd(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_sd(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_ds(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_ds(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_nc(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_nc(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_nd(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_nd(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_sc(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_sc(T k, U theta); - - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type jacobi_cs(T k, U theta, const Policy& pol); - - template <class T, class U> - typename tools::promote_args<T, U>::type jacobi_cs(T k, U theta); - - - template <class T> - typename tools::promote_args<T>::type zeta(T s); - - // pow: - template <int N, typename T, class Policy> - typename tools::promote_args<T>::type pow(T base, const Policy& policy); - - template <int N, typename T> - typename tools::promote_args<T>::type pow(T base); - - // next: - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type nextafter(const T&, const U&, const Policy&); - template <class T, class U> - typename tools::promote_args<T, U>::type nextafter(const T&, const U&); - template <class T, class Policy> - typename tools::promote_args<T>::type float_next(const T&, const Policy&); - template <class T> - typename tools::promote_args<T>::type float_next(const T&); - template <class T, class Policy> - typename tools::promote_args<T>::type float_prior(const T&, const Policy&); - template <class T> - typename tools::promote_args<T>::type float_prior(const T&); - template <class T, class U, class Policy> - typename tools::promote_args<T, U>::type float_distance(const T&, const U&, const Policy&); - template <class T, class U> - typename tools::promote_args<T, U>::type float_distance(const T&, const U&); - template <class T, class Policy> - typename tools::promote_args<T>::type float_advance(T val, int distance, const Policy& pol); - template <class T> - typename tools::promote_args<T>::type float_advance(const T& val, int distance); - - template <class T, class Policy> - typename tools::promote_args<T>::type ulp(const T& val, const Policy& pol); - template <class T> - typename tools::promote_args<T>::type ulp(const T& val); - - template <class T, class U> - typename tools::promote_args<T, U>::type relative_difference(const T&, const U&); - template <class T, class U> - typename tools::promote_args<T, U>::type epsilon_difference(const T&, const U&); - - template<class T> - BOOST_MATH_CONSTEXPR_TABLE_FUNCTION T unchecked_bernoulli_b2n(const std::size_t n); - template <class T, class Policy> - T bernoulli_b2n(const int i, const Policy &pol); - template <class T> - T bernoulli_b2n(const int i); - template <class T, class OutputIterator, class Policy> - OutputIterator bernoulli_b2n(const int start_index, - const unsigned number_of_bernoullis_b2n, - OutputIterator out_it, - const Policy& pol); - template <class T, class OutputIterator> - OutputIterator bernoulli_b2n(const int start_index, - const unsigned number_of_bernoullis_b2n, - OutputIterator out_it); - template <class T, class Policy> - T tangent_t2n(const int i, const Policy &pol); - template <class T> - T tangent_t2n(const int i); - template <class T, class OutputIterator, class Policy> - OutputIterator tangent_t2n(const int start_index, - const unsigned number_of_bernoullis_b2n, - OutputIterator out_it, - const Policy& pol); - template <class T, class OutputIterator> - OutputIterator tangent_t2n(const int start_index, - const unsigned number_of_bernoullis_b2n, - OutputIterator out_it); - - // Lambert W: - template <class T, class Policy> - typename boost::math::tools::promote_args<T>::type lambert_w0(T z, const Policy& pol); - template <class T> - typename boost::math::tools::promote_args<T>::type lambert_w0(T z); - template <class T, class Policy> - typename boost::math::tools::promote_args<T>::type lambert_wm1(T z, const Policy& pol); - template <class T> - typename boost::math::tools::promote_args<T>::type lambert_wm1(T z); - template <class T, class Policy> - typename boost::math::tools::promote_args<T>::type lambert_w0_prime(T z, const Policy& pol); - template <class T> - typename boost::math::tools::promote_args<T>::type lambert_w0_prime(T z); - template <class T, class Policy> - typename boost::math::tools::promote_args<T>::type lambert_wm1_prime(T z, const Policy& pol); - template <class T> - typename boost::math::tools::promote_args<T>::type lambert_wm1_prime(T z); - - // Hypergeometrics: - template <class T1, class T2> typename tools::promote_args<T1, T2>::type hypergeometric_1F0(T1 a, T2 z); - template <class T1, class T2, class Policy> typename tools::promote_args<T1, T2>::type hypergeometric_1F0(T1 a, T2 z, const Policy&); - - template <class T1, class T2> typename tools::promote_args<T1, T2>::type hypergeometric_0F1(T1 b, T2 z); - template <class T1, class T2, class Policy> typename tools::promote_args<T1, T2>::type hypergeometric_0F1(T1 b, T2 z, const Policy&); - - template <class T1, class T2, class T3> typename tools::promote_args<T1, T2, T3>::type hypergeometric_2F0(T1 a1, T2 a2, T3 z); - template <class T1, class T2, class T3, class Policy> typename tools::promote_args<T1, T2, T3>::type hypergeometric_2F0(T1 a1, T2 a2, T3 z, const Policy&); - - template <class T1, class T2, class T3> typename tools::promote_args<T1, T2, T3>::type hypergeometric_1F1(T1 a, T2 b, T3 z); - template <class T1, class T2, class T3, class Policy> typename tools::promote_args<T1, T2, T3>::type hypergeometric_1F1(T1 a, T2 b, T3 z, const Policy&); - - - } // namespace math -} // namespace boost - -#ifdef BOOST_HAS_LONG_LONG -#define BOOST_MATH_DETAIL_LL_FUNC(Policy)\ - \ - template <class T>\ - inline T modf(const T& v, boost::long_long_type* ipart){ using boost::math::modf; return modf(v, ipart, Policy()); }\ - \ - template <class T>\ - inline boost::long_long_type lltrunc(const T& v){ using boost::math::lltrunc; return lltrunc(v, Policy()); }\ - \ - template <class T>\ - inline boost::long_long_type llround(const T& v){ using boost::math::llround; return llround(v, Policy()); }\ - -#else -#define BOOST_MATH_DETAIL_LL_FUNC(Policy) -#endif - -#if !defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && !defined(BOOST_NO_CXX11_HDR_ARRAY) -# define BOOST_MATH_DETAIL_11_FUNC(Policy)\ - template <class T, class U, class V>\ - inline typename boost::math::tools::promote_args<T, U>::type hypergeometric_1F1(const T& a, const U& b, const V& z)\ - { return boost::math::hypergeometric_1F1(a, b, z, Policy()); }\ - -#else -# define BOOST_MATH_DETAIL_11_FUNC(Policy) -#endif - -#define BOOST_MATH_DECLARE_SPECIAL_FUNCTIONS(Policy)\ - \ - BOOST_MATH_DETAIL_LL_FUNC(Policy)\ - BOOST_MATH_DETAIL_11_FUNC(Policy)\ - \ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type \ - beta(RT1 a, RT2 b) { return ::boost::math::beta(a, b, Policy()); }\ -\ - template <class RT1, class RT2, class A>\ - inline typename boost::math::tools::promote_args<RT1, RT2, A>::type \ - beta(RT1 a, RT2 b, A x){ return ::boost::math::beta(a, b, x, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - betac(RT1 a, RT2 b, RT3 x) { return ::boost::math::betac(a, b, x, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibeta(RT1 a, RT2 b, RT3 x){ return ::boost::math::ibeta(a, b, x, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibetac(RT1 a, RT2 b, RT3 x){ return ::boost::math::ibetac(a, b, x, Policy()); }\ -\ - template <class T1, class T2, class T3, class T4>\ - inline typename boost::math::tools::promote_args<T1, T2, T3, T4>::type \ - ibeta_inv(T1 a, T2 b, T3 p, T4* py){ return ::boost::math::ibeta_inv(a, b, p, py, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibeta_inv(RT1 a, RT2 b, RT3 p){ return ::boost::math::ibeta_inv(a, b, p, Policy()); }\ -\ - template <class T1, class T2, class T3, class T4>\ - inline typename boost::math::tools::promote_args<T1, T2, T3, T4>::type \ - ibetac_inv(T1 a, T2 b, T3 q, T4* py){ return ::boost::math::ibetac_inv(a, b, q, py, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibeta_inva(RT1 a, RT2 b, RT3 p){ return ::boost::math::ibeta_inva(a, b, p, Policy()); }\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type \ - ibetac_inva(T1 a, T2 b, T3 q){ return ::boost::math::ibetac_inva(a, b, q, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibeta_invb(RT1 a, RT2 b, RT3 p){ return ::boost::math::ibeta_invb(a, b, p, Policy()); }\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type \ - ibetac_invb(T1 a, T2 b, T3 q){ return ::boost::math::ibetac_invb(a, b, q, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibetac_inv(RT1 a, RT2 b, RT3 q){ return ::boost::math::ibetac_inv(a, b, q, Policy()); }\ -\ - template <class RT1, class RT2, class RT3>\ - inline typename boost::math::tools::promote_args<RT1, RT2, RT3>::type \ - ibeta_derivative(RT1 a, RT2 b, RT3 x){ return ::boost::math::ibeta_derivative(a, b, x, Policy()); }\ -\ - template <class T> T binomial_coefficient(unsigned n, unsigned k){ return ::boost::math::binomial_coefficient<T, Policy>(n, k, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type erf(RT z) { return ::boost::math::erf(z, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type erfc(RT z){ return ::boost::math::erfc(z, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type erf_inv(RT z) { return ::boost::math::erf_inv(z, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type erfc_inv(RT z){ return ::boost::math::erfc_inv(z, Policy()); }\ -\ - using boost::math::legendre_next;\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - legendre_p(int l, T x){ return ::boost::math::legendre_p(l, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - legendre_p_prime(int l, T x){ return ::boost::math::legendre_p(l, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - legendre_q(unsigned l, T x){ return ::boost::math::legendre_q(l, x, Policy()); }\ -\ - using ::boost::math::legendre_next;\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - legendre_p(int l, int m, T x){ return ::boost::math::legendre_p(l, m, x, Policy()); }\ -\ - using ::boost::math::laguerre_next;\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - laguerre(unsigned n, T x){ return ::boost::math::laguerre(n, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::laguerre_result<T1, T2>::type \ - laguerre(unsigned n, T1 m, T2 x) { return ::boost::math::laguerre(n, m, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type \ - hermite(unsigned n, T x){ return ::boost::math::hermite(n, x, Policy()); }\ -\ - using boost::math::hermite_next;\ -\ - using boost::math::chebyshev_next;\ -\ - template<class Real>\ - Real chebyshev_t(unsigned n, Real const & x){ return ::boost::math::chebyshev_t(n, x, Policy()); }\ -\ - template<class Real>\ - Real chebyshev_u(unsigned n, Real const & x){ return ::boost::math::chebyshev_u(n, x, Policy()); }\ -\ - template<class Real>\ - Real chebyshev_t_prime(unsigned n, Real const & x){ return ::boost::math::chebyshev_t_prime(n, x, Policy()); }\ -\ - using ::boost::math::chebyshev_clenshaw_recurrence;\ -\ - template <class T1, class T2>\ - inline std::complex<typename boost::math::tools::promote_args<T1, T2>::type> \ - spherical_harmonic(unsigned n, int m, T1 theta, T2 phi){ return boost::math::spherical_harmonic(n, m, theta, phi, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - spherical_harmonic_r(unsigned n, int m, T1 theta, T2 phi){ return ::boost::math::spherical_harmonic_r(n, m, theta, phi, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi){ return boost::math::spherical_harmonic_i(n, m, theta, phi, Policy()); }\ -\ - template <class T1, class T2, class Policy>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi, const Policy& pol);\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type \ - ellint_rf(T1 x, T2 y, T3 z){ return ::boost::math::ellint_rf(x, y, z, Policy()); }\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type \ - ellint_rd(T1 x, T2 y, T3 z){ return ::boost::math::ellint_rd(x, y, z, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - ellint_rc(T1 x, T2 y){ return ::boost::math::ellint_rc(x, y, Policy()); }\ -\ - template <class T1, class T2, class T3, class T4>\ - inline typename boost::math::tools::promote_args<T1, T2, T3, T4>::type \ - ellint_rj(T1 x, T2 y, T3 z, T4 p){ return boost::math::ellint_rj(x, y, z, p, Policy()); }\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type \ - ellint_rg(T1 x, T2 y, T3 z){ return ::boost::math::ellint_rg(x, y, z, Policy()); }\ - \ - template <typename T>\ - inline typename boost::math::tools::promote_args<T>::type ellint_2(T k){ return boost::math::ellint_2(k, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type ellint_2(T1 k, T2 phi){ return boost::math::ellint_2(k, phi, Policy()); }\ -\ - template <typename T>\ - inline typename boost::math::tools::promote_args<T>::type ellint_d(T k){ return boost::math::ellint_d(k, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type ellint_d(T1 k, T2 phi){ return boost::math::ellint_d(k, phi, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type jacobi_zeta(T1 k, T2 phi){ return boost::math::jacobi_zeta(k, phi, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type heuman_lambda(T1 k, T2 phi){ return boost::math::heuman_lambda(k, phi, Policy()); }\ -\ - template <typename T>\ - inline typename boost::math::tools::promote_args<T>::type ellint_1(T k){ return boost::math::ellint_1(k, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type ellint_1(T1 k, T2 phi){ return boost::math::ellint_1(k, phi, Policy()); }\ -\ - template <class T1, class T2, class T3>\ - inline typename boost::math::tools::promote_args<T1, T2, T3>::type ellint_3(T1 k, T2 v, T3 phi){ return boost::math::ellint_3(k, v, phi, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type ellint_3(T1 k, T2 v){ return boost::math::ellint_3(k, v, Policy()); }\ -\ - using boost::math::max_factorial;\ - template <class RT>\ - inline RT factorial(unsigned int i) { return boost::math::factorial<RT>(i, Policy()); }\ - using boost::math::unchecked_factorial;\ - template <class RT>\ - inline RT double_factorial(unsigned i){ return boost::math::double_factorial<RT>(i, Policy()); }\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type falling_factorial(RT x, unsigned n){ return boost::math::falling_factorial(x, n, Policy()); }\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type rising_factorial(RT x, unsigned n){ return boost::math::rising_factorial(x, n, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type tgamma(RT z){ return boost::math::tgamma(z, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type tgamma1pm1(RT z){ return boost::math::tgamma1pm1(z, Policy()); }\ -\ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type tgamma(RT1 a, RT2 z){ return boost::math::tgamma(a, z, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type lgamma(RT z, int* sign){ return boost::math::lgamma(z, sign, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type lgamma(RT x){ return boost::math::lgamma(x, Policy()); }\ -\ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type tgamma_lower(RT1 a, RT2 z){ return boost::math::tgamma_lower(a, z, Policy()); }\ -\ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type gamma_q(RT1 a, RT2 z){ return boost::math::gamma_q(a, z, Policy()); }\ -\ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type gamma_p(RT1 a, RT2 z){ return boost::math::gamma_p(a, z, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type tgamma_delta_ratio(T1 z, T2 delta){ return boost::math::tgamma_delta_ratio(z, delta, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type tgamma_ratio(T1 a, T2 b) { return boost::math::tgamma_ratio(a, b, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type gamma_p_derivative(T1 a, T2 x){ return boost::math::gamma_p_derivative(a, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type gamma_p_inv(T1 a, T2 p){ return boost::math::gamma_p_inv(a, p, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type gamma_p_inva(T1 a, T2 p){ return boost::math::gamma_p_inva(a, p, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type gamma_q_inv(T1 a, T2 q){ return boost::math::gamma_q_inv(a, q, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type gamma_q_inva(T1 a, T2 q){ return boost::math::gamma_q_inva(a, q, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type digamma(T x){ return boost::math::digamma(x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type trigamma(T x){ return boost::math::trigamma(x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type polygamma(int n, T x){ return boost::math::polygamma(n, x, Policy()); }\ - \ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - hypot(T1 x, T2 y){ return boost::math::hypot(x, y, Policy()); }\ -\ - template <class RT>\ - inline typename boost::math::tools::promote_args<RT>::type cbrt(RT z){ return boost::math::cbrt(z, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type log1p(T x){ return boost::math::log1p(x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type log1pmx(T x){ return boost::math::log1pmx(x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type expm1(T x){ return boost::math::expm1(x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::tools::promote_args<T1, T2>::type \ - powm1(const T1 a, const T2 z){ return boost::math::powm1(a, z, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type sqrt1pm1(const T& val){ return boost::math::sqrt1pm1(val, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type sinc_pi(T x){ return boost::math::sinc_pi(x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type sinhc_pi(T x){ return boost::math::sinhc_pi(x, Policy()); }\ -\ - template<typename T>\ - inline typename boost::math::tools::promote_args<T>::type asinh(const T x){ return boost::math::asinh(x, Policy()); }\ -\ - template<typename T>\ - inline typename boost::math::tools::promote_args<T>::type acosh(const T x){ return boost::math::acosh(x, Policy()); }\ -\ - template<typename T>\ - inline typename boost::math::tools::promote_args<T>::type atanh(const T x){ return boost::math::atanh(x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type cyl_bessel_j(T1 v, T2 x)\ - { return boost::math::cyl_bessel_j(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type cyl_bessel_j_prime(T1 v, T2 x)\ - { return boost::math::cyl_bessel_j_prime(v, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type sph_bessel(unsigned v, T x)\ - { return boost::math::sph_bessel(v, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type sph_bessel_prime(unsigned v, T x)\ - { return boost::math::sph_bessel_prime(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_bessel_i(T1 v, T2 x) { return boost::math::cyl_bessel_i(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_bessel_i_prime(T1 v, T2 x) { return boost::math::cyl_bessel_i_prime(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_bessel_k(T1 v, T2 x) { return boost::math::cyl_bessel_k(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_bessel_k_prime(T1 v, T2 x) { return boost::math::cyl_bessel_k_prime(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_neumann(T1 v, T2 x){ return boost::math::cyl_neumann(v, x, Policy()); }\ -\ - template <class T1, class T2>\ - inline typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type \ - cyl_neumann_prime(T1 v, T2 x){ return boost::math::cyl_neumann_prime(v, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type \ - sph_neumann(unsigned v, T x){ return boost::math::sph_neumann(v, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type \ - sph_neumann_prime(unsigned v, T x){ return boost::math::sph_neumann_prime(v, x, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type cyl_bessel_j_zero(T v, int m)\ - { return boost::math::cyl_bessel_j_zero(v, m, Policy()); }\ -\ -template <class OutputIterator, class T>\ - inline void cyl_bessel_j_zero(T v,\ - int start_index,\ - unsigned number_of_zeros,\ - OutputIterator out_it)\ - { boost::math::cyl_bessel_j_zero(v, start_index, number_of_zeros, out_it, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::detail::bessel_traits<T, T, Policy >::result_type cyl_neumann_zero(T v, int m)\ - { return boost::math::cyl_neumann_zero(v, m, Policy()); }\ -\ -template <class OutputIterator, class T>\ - inline void cyl_neumann_zero(T v,\ - int start_index,\ - unsigned number_of_zeros,\ - OutputIterator out_it)\ - { boost::math::cyl_neumann_zero(v, start_index, number_of_zeros, out_it, Policy()); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type sin_pi(T x){ return boost::math::sin_pi(x); }\ -\ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type cos_pi(T x){ return boost::math::cos_pi(x); }\ -\ - using boost::math::fpclassify;\ - using boost::math::isfinite;\ - using boost::math::isinf;\ - using boost::math::isnan;\ - using boost::math::isnormal;\ - using boost::math::signbit;\ - using boost::math::sign;\ - using boost::math::copysign;\ - using boost::math::changesign;\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T,U>::type expint(T const& z, U const& u)\ - { return boost::math::expint(z, u, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type expint(T z){ return boost::math::expint(z, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type zeta(T s){ return boost::math::zeta(s, Policy()); }\ - \ - template <class T>\ - inline T round(const T& v){ using boost::math::round; return round(v, Policy()); }\ - \ - template <class T>\ - inline int iround(const T& v){ using boost::math::iround; return iround(v, Policy()); }\ - \ - template <class T>\ - inline long lround(const T& v){ using boost::math::lround; return lround(v, Policy()); }\ - \ - template <class T>\ - inline T trunc(const T& v){ using boost::math::trunc; return trunc(v, Policy()); }\ - \ - template <class T>\ - inline int itrunc(const T& v){ using boost::math::itrunc; return itrunc(v, Policy()); }\ - \ - template <class T>\ - inline long ltrunc(const T& v){ using boost::math::ltrunc; return ltrunc(v, Policy()); }\ - \ - template <class T>\ - inline T modf(const T& v, T* ipart){ using boost::math::modf; return modf(v, ipart, Policy()); }\ - \ - template <class T>\ - inline T modf(const T& v, int* ipart){ using boost::math::modf; return modf(v, ipart, Policy()); }\ - \ - template <class T>\ - inline T modf(const T& v, long* ipart){ using boost::math::modf; return modf(v, ipart, Policy()); }\ - \ - template <int N, class T>\ - inline typename boost::math::tools::promote_args<T>::type pow(T v){ return boost::math::pow<N>(v, Policy()); }\ - \ - template <class T> T nextafter(const T& a, const T& b){ return boost::math::nextafter(a, b, Policy()); }\ - template <class T> T float_next(const T& a){ return boost::math::float_next(a, Policy()); }\ - template <class T> T float_prior(const T& a){ return boost::math::float_prior(a, Policy()); }\ - template <class T> T float_distance(const T& a, const T& b){ return boost::math::float_distance(a, b, Policy()); }\ - template <class T> T ulp(const T& a){ return boost::math::ulp(a, Policy()); }\ - \ - template <class RT1, class RT2>\ - inline typename boost::math::tools::promote_args<RT1, RT2>::type owens_t(RT1 a, RT2 z){ return boost::math::owens_t(a, z, Policy()); }\ - \ - template <class T1, class T2>\ - inline std::complex<typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type> cyl_hankel_1(T1 v, T2 x)\ - { return boost::math::cyl_hankel_1(v, x, Policy()); }\ - \ - template <class T1, class T2>\ - inline std::complex<typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type> cyl_hankel_2(T1 v, T2 x)\ - { return boost::math::cyl_hankel_2(v, x, Policy()); }\ - \ - template <class T1, class T2>\ - inline std::complex<typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type> sph_hankel_1(T1 v, T2 x)\ - { return boost::math::sph_hankel_1(v, x, Policy()); }\ - \ - template <class T1, class T2>\ - inline std::complex<typename boost::math::detail::bessel_traits<T1, T2, Policy >::result_type> sph_hankel_2(T1 v, T2 x)\ - { return boost::math::sph_hankel_2(v, x, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type jacobi_elliptic(T k, T theta, T* pcn, T* pdn)\ - { return boost::math::jacobi_elliptic(k, theta, pcn, pdn, Policy()); }\ - \ - template <class U, class T>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_sn(U k, T theta)\ - { return boost::math::jacobi_sn(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_cn(T k, U theta)\ - { return boost::math::jacobi_cn(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_dn(T k, U theta)\ - { return boost::math::jacobi_dn(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_cd(T k, U theta)\ - { return boost::math::jacobi_cd(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_dc(T k, U theta)\ - { return boost::math::jacobi_dc(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_ns(T k, U theta)\ - { return boost::math::jacobi_ns(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_sd(T k, U theta)\ - { return boost::math::jacobi_sd(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_ds(T k, U theta)\ - { return boost::math::jacobi_ds(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_nc(T k, U theta)\ - { return boost::math::jacobi_nc(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_nd(T k, U theta)\ - { return boost::math::jacobi_nd(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_sc(T k, U theta)\ - { return boost::math::jacobi_sc(k, theta, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type jacobi_cs(T k, U theta)\ - { return boost::math::jacobi_cs(k, theta, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type airy_ai(T x)\ - { return boost::math::airy_ai(x, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type airy_bi(T x)\ - { return boost::math::airy_bi(x, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type airy_ai_prime(T x)\ - { return boost::math::airy_ai_prime(x, Policy()); }\ - \ - template <class T>\ - inline typename boost::math::tools::promote_args<T>::type airy_bi_prime(T x)\ - { return boost::math::airy_bi_prime(x, Policy()); }\ - \ - template <class T>\ - inline T airy_ai_zero(int m)\ - { return boost::math::airy_ai_zero<T>(m, Policy()); }\ - template <class T, class OutputIterator>\ - OutputIterator airy_ai_zero(int start_index, unsigned number_of_zeros, OutputIterator out_it)\ - { return boost::math::airy_ai_zero<T>(start_index, number_of_zeros, out_it, Policy()); }\ - \ - template <class T>\ - inline T airy_bi_zero(int m)\ - { return boost::math::airy_bi_zero<T>(m, Policy()); }\ - template <class T, class OutputIterator>\ - OutputIterator airy_bi_zero(int start_index, unsigned number_of_zeros, OutputIterator out_it)\ - { return boost::math::airy_bi_zero<T>(start_index, number_of_zeros, out_it, Policy()); }\ - \ - template <class T>\ - T bernoulli_b2n(const int i)\ - { return boost::math::bernoulli_b2n<T>(i, Policy()); }\ - template <class T, class OutputIterator>\ - OutputIterator bernoulli_b2n(int start_index, unsigned number_of_bernoullis_b2n, OutputIterator out_it)\ - { return boost::math::bernoulli_b2n<T>(start_index, number_of_bernoullis_b2n, out_it, Policy()); }\ - \ - template <class T>\ - T tangent_t2n(const int i)\ - { return boost::math::tangent_t2n<T>(i, Policy()); }\ - template <class T, class OutputIterator>\ - OutputIterator tangent_t2n(int start_index, unsigned number_of_bernoullis_b2n, OutputIterator out_it)\ - { return boost::math::tangent_t2n<T>(start_index, number_of_bernoullis_b2n, out_it, Policy()); }\ - \ - template <class T> inline typename boost::math::tools::promote_args<T>::type lambert_w0(T z) { return boost::math::lambert_w0(z, Policy()); }\ - template <class T> inline typename boost::math::tools::promote_args<T>::type lambert_wm1(T z) { return boost::math::lambert_w0(z, Policy()); }\ - template <class T> inline typename boost::math::tools::promote_args<T>::type lambert_w0_prime(T z) { return boost::math::lambert_w0(z, Policy()); }\ - template <class T> inline typename boost::math::tools::promote_args<T>::type lambert_wm1_prime(T z) { return boost::math::lambert_w0(z, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type hypergeometric_1F0(const T& a, const U& z)\ - { return boost::math::hypergeometric_1F0(a, z, Policy()); }\ - \ - template <class T, class U>\ - inline typename boost::math::tools::promote_args<T, U>::type hypergeometric_0F1(const T& a, const U& z)\ - { return boost::math::hypergeometric_0F1(a, z, Policy()); }\ - \ - template <class T, class U, class V>\ - inline typename boost::math::tools::promote_args<T, U>::type hypergeometric_2F0(const T& a1, const U& a2, const V& z)\ - { return boost::math::hypergeometric_2F0(a1, a2, z, Policy()); }\ - \ - - - - - - -#endif // BOOST_MATH_SPECIAL_MATH_FWD_HPP diff --git a/ThirdParty/boost/math/tools/config.hpp b/ThirdParty/boost/math/tools/config.hpp deleted file mode 100644 index cb36fcf0816dac30123ecd923a385e06ec5ce32a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/math/tools/config.hpp +++ /dev/null @@ -1,489 +0,0 @@ -// Copyright (c) 2006-7 John Maddock -// Use, modification and distribution are subject to 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_MATH_TOOLS_CONFIG_HPP -#define BOOST_MATH_TOOLS_CONFIG_HPP - -#ifdef _MSC_VER -#pragma once -#endif - -#include <boost/config.hpp> -#include <boost/predef/architecture/x86.h> -#include <boost/cstdint.hpp> // for boost::uintmax_t -#include <boost/detail/workaround.hpp> -#include <boost/type_traits/is_integral.hpp> -#include <algorithm> // for min and max -#include <boost/config/no_tr1/cmath.hpp> -#include <climits> -#include <cfloat> -#if (defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) -# include <math.h> -#endif -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# include <limits> -#endif - -#include <boost/math/tools/user.hpp> - -#if (defined(__CYGWIN__) || defined(__FreeBSD__) || defined(__NetBSD__) \ - || (defined(__hppa) && !defined(__OpenBSD__)) || (defined(__NO_LONG_DOUBLE_MATH) && (DBL_MANT_DIG != LDBL_MANT_DIG))) \ - && !defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) -# define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#endif -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x582)) -// -// Borland post 5.8.2 uses Dinkumware's std C lib which -// doesn't have true long double precision. Earlier -// versions are problematic too: -// -# define BOOST_MATH_NO_REAL_CONCEPT_TESTS -# define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -# define BOOST_MATH_CONTROL_FP _control87(MCW_EM,MCW_EM) -# include <float.h> -#endif -#ifdef __IBMCPP__ -// -// For reasons I don't understand, the tests with IMB's compiler all -// pass at long double precision, but fail with real_concept, those tests -// are disabled for now. (JM 2012). -# define BOOST_MATH_NO_REAL_CONCEPT_TESTS -#endif -#ifdef sun -// Any use of __float128 in program startup code causes a segfault (tested JM 2015, Solaris 11). -# define BOOST_MATH_DISABLE_FLOAT128 -#endif -#ifdef __HAIKU__ -// -// Not sure what's up with the math detection on Haiku, but linking fails with -// float128 code enabled, and we don't have an implementation of __expl, so -// disabling long double functions for now as well. -# define BOOST_MATH_DISABLE_FLOAT128 -# define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#endif -#if (defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) && ((LDBL_MANT_DIG == 106) || (__LDBL_MANT_DIG__ == 106)) && !defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) -// -// Darwin's rather strange "double double" is rather hard to -// support, it should be possible given enough effort though... -// -# define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#endif -#if defined(unix) && defined(__INTEL_COMPILER) && (__INTEL_COMPILER <= 1000) && !defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) -// -// Intel compiler prior to version 10 has sporadic problems -// calling the long double overloads of the std lib math functions: -// calling ::powl is OK, but std::pow(long double, long double) -// may segfault depending upon the value of the arguments passed -// and the specific Linux distribution. -// -// We'll be conservative and disable long double support for this compiler. -// -// Comment out this #define and try building the tests to determine whether -// your Intel compiler version has this issue or not. -// -# define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#endif -#if defined(unix) && defined(__INTEL_COMPILER) -// -// Intel compiler has sporadic issues compiling std::fpclassify depending on -// the exact OS version used. Use our own code for this as we know it works -// well on Intel processors: -// -#define BOOST_MATH_DISABLE_STD_FPCLASSIFY -#endif - -#if defined(BOOST_MSVC) && !defined(_WIN32_WCE) - // Better safe than sorry, our tests don't support hardware exceptions: -# define BOOST_MATH_CONTROL_FP _control87(MCW_EM,MCW_EM) -#endif - -#ifdef __IBMCPP__ -# define BOOST_MATH_NO_DEDUCED_FUNCTION_POINTERS -#endif - -#if (defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901)) -# define BOOST_MATH_USE_C99 -#endif - -#if (defined(__hpux) && !defined(__hppa)) -# define BOOST_MATH_USE_C99 -#endif - -#if defined(__GNUC__) && defined(_GLIBCXX_USE_C99) -# define BOOST_MATH_USE_C99 -#endif - -#if defined(_LIBCPP_VERSION) && !defined(_MSC_VER) -# define BOOST_MATH_USE_C99 -#endif - -#if defined(__CYGWIN__) || defined(__HP_aCC) || defined(BOOST_INTEL) \ - || defined(BOOST_NO_NATIVE_LONG_DOUBLE_FP_CLASSIFY) \ - || (defined(__GNUC__) && !defined(BOOST_MATH_USE_C99))\ - || defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) -# define BOOST_MATH_NO_NATIVE_LONG_DOUBLE_FP_CLASSIFY -#endif - -#if BOOST_WORKAROUND(__SUNPRO_CC, <= 0x590) - -# include "boost/type.hpp" -# include "boost/non_type.hpp" - -# define BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(t) boost::type<t>* = 0 -# define BOOST_MATH_EXPLICIT_TEMPLATE_TYPE_SPEC(t) boost::type<t>* -# define BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE(t, v) boost::non_type<t, v>* = 0 -# define BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) boost::non_type<t, v>* - -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_TYPE(t) \ - , BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_TYPE_SPEC(t) \ - , BOOST_MATH_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_NON_TYPE(t, v) \ - , BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) \ - , BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -#else - -// no workaround needed: expand to nothing - -# define BOOST_MATH_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_MATH_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_MATH_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_MATH_APPEND_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - - -#endif // __SUNPRO_CC - -#if (defined(__SUNPRO_CC) || defined(__hppa) || defined(__GNUC__)) && !defined(BOOST_MATH_SMALL_CONSTANT) -// Sun's compiler emits a hard error if a constant underflows, -// as does aCC on PA-RISC, while gcc issues a large number of warnings: -# define BOOST_MATH_SMALL_CONSTANT(x) 0.0 -#else -# define BOOST_MATH_SMALL_CONSTANT(x) x -#endif - - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1400) -// -// Define if constants too large for a float cause "bad" -// values to be stored in the data, rather than infinity -// or a suitably large value. -// -# define BOOST_MATH_BUGGY_LARGE_FLOAT_CONSTANTS -#endif -// -// Tune performance options for specific compilers: -// -#ifdef BOOST_MSVC -# define BOOST_MATH_POLY_METHOD 2 -#if BOOST_MSVC <= 1900 -# define BOOST_MATH_RATIONAL_METHOD 1 -#else -# define BOOST_MATH_RATIONAL_METHOD 2 -#endif -#if BOOST_MSVC > 1900 -# define BOOST_MATH_INT_TABLE_TYPE(RT, IT) RT -# define BOOST_MATH_INT_VALUE_SUFFIX(RV, SUF) RV##.0L -#endif - -#elif defined(BOOST_INTEL) -# define BOOST_MATH_POLY_METHOD 2 -# define BOOST_MATH_RATIONAL_METHOD 1 - -#elif defined(__GNUC__) -#if __GNUC__ < 4 -# define BOOST_MATH_POLY_METHOD 3 -# define BOOST_MATH_RATIONAL_METHOD 3 -# define BOOST_MATH_INT_TABLE_TYPE(RT, IT) RT -# define BOOST_MATH_INT_VALUE_SUFFIX(RV, SUF) RV##.0L -#else -# define BOOST_MATH_POLY_METHOD 3 -# define BOOST_MATH_RATIONAL_METHOD 3 -#endif - -#elif defined(__clang__) - -#if __clang__ > 6 -# define BOOST_MATH_POLY_METHOD 3 -# define BOOST_MATH_RATIONAL_METHOD 3 -# define BOOST_MATH_INT_TABLE_TYPE(RT, IT) RT -# define BOOST_MATH_INT_VALUE_SUFFIX(RV, SUF) RV##.0L -#endif - -#endif - -#if defined(BOOST_NO_LONG_LONG) && !defined(BOOST_MATH_INT_TABLE_TYPE) -# define BOOST_MATH_INT_TABLE_TYPE(RT, IT) RT -# define BOOST_MATH_INT_VALUE_SUFFIX(RV, SUF) RV##.0L -#endif - -// -// constexpr support, early GCC implementations can't cope so disable -// constexpr for them: -// -#if !defined(__clang__) && defined(__GNUC__) -#if (__GNUC__ * 100 + __GNUC_MINOR__) < 490 -# define BOOST_MATH_DISABLE_CONSTEXPR -#endif -#endif - -#ifdef BOOST_MATH_DISABLE_CONSTEXPR -# define BOOST_MATH_CONSTEXPR -#else -# define BOOST_MATH_CONSTEXPR BOOST_CONSTEXPR -#endif - -// -// noexcept support: -// -#ifndef BOOST_NO_CXX11_NOEXCEPT -#ifndef BOOST_NO_CXX11_HDR_TYPE_TRAITS -#include <type_traits> -# define BOOST_MATH_NOEXCEPT(T) noexcept(std::is_floating_point<T>::value) -# define BOOST_MATH_IS_FLOAT(T) (std::is_floating_point<T>::value) -#else -#include <boost/type_traits/is_floating_point.hpp> -# define BOOST_MATH_NOEXCEPT(T) noexcept(boost::is_floating_point<T>::value) -# define BOOST_MATH_IS_FLOAT(T) (boost::is_floating_point<T>::value) -#endif -#else -# define BOOST_MATH_NOEXCEPT(T) -# define BOOST_MATH_IS_FLOAT(T) false -#endif - -// -// The maximum order of polynomial that will be evaluated -// via an unrolled specialisation: -// -#ifndef BOOST_MATH_MAX_POLY_ORDER -# define BOOST_MATH_MAX_POLY_ORDER 20 -#endif -// -// Set the method used to evaluate polynomials and rationals: -// -#ifndef BOOST_MATH_POLY_METHOD -# define BOOST_MATH_POLY_METHOD 2 -#endif -#ifndef BOOST_MATH_RATIONAL_METHOD -# define BOOST_MATH_RATIONAL_METHOD 1 -#endif -// -// decide whether to store constants as integers or reals: -// -#ifndef BOOST_MATH_INT_TABLE_TYPE -# define BOOST_MATH_INT_TABLE_TYPE(RT, IT) IT -#endif -#ifndef BOOST_MATH_INT_VALUE_SUFFIX -# define BOOST_MATH_INT_VALUE_SUFFIX(RV, SUF) RV##SUF -#endif -// -// And then the actual configuration: -// -#if defined(_GLIBCXX_USE_FLOAT128) && defined(BOOST_GCC) && !defined(__STRICT_ANSI__) \ - && !defined(BOOST_MATH_DISABLE_FLOAT128) || defined(BOOST_MATH_USE_FLOAT128) -// -// Only enable this when the compiler really is GCC as clang and probably -// intel too don't support __float128 yet :-( -// -#ifndef BOOST_MATH_USE_FLOAT128 -# define BOOST_MATH_USE_FLOAT128 -#endif - -# if defined(BOOST_INTEL) && defined(BOOST_INTEL_CXX_VERSION) && (BOOST_INTEL_CXX_VERSION >= 1310) && defined(__GNUC__) -# if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 6)) -# define BOOST_MATH_FLOAT128_TYPE __float128 -# endif -# elif defined(__GNUC__) -# define BOOST_MATH_FLOAT128_TYPE __float128 -# endif - -# ifndef BOOST_MATH_FLOAT128_TYPE -# define BOOST_MATH_FLOAT128_TYPE _Quad -# endif -#endif -// -// Check for WinCE with no iostream support: -// -#if defined(_WIN32_WCE) && !defined(__SGI_STL_PORT) -# define BOOST_MATH_NO_LEXICAL_CAST -#endif - -// -// Helper macro for controlling the FP behaviour: -// -#ifndef BOOST_MATH_CONTROL_FP -# define BOOST_MATH_CONTROL_FP -#endif -// -// Helper macro for using statements: -// -#define BOOST_MATH_STD_USING_CORE \ - using std::abs;\ - using std::acos;\ - using std::cos;\ - using std::fmod;\ - using std::modf;\ - using std::tan;\ - using std::asin;\ - using std::cosh;\ - using std::frexp;\ - using std::pow;\ - using std::tanh;\ - using std::atan;\ - using std::exp;\ - using std::ldexp;\ - using std::sin;\ - using std::atan2;\ - using std::fabs;\ - using std::log;\ - using std::sinh;\ - using std::ceil;\ - using std::floor;\ - using std::log10;\ - using std::sqrt; - -#define BOOST_MATH_STD_USING BOOST_MATH_STD_USING_CORE - -namespace boost{ namespace math{ -namespace tools -{ - -template <class T> -inline T max BOOST_PREVENT_MACRO_SUBSTITUTION(T a, T b, T c) BOOST_MATH_NOEXCEPT(T) -{ - return (std::max)((std::max)(a, b), c); -} - -template <class T> -inline T max BOOST_PREVENT_MACRO_SUBSTITUTION(T a, T b, T c, T d) BOOST_MATH_NOEXCEPT(T) -{ - return (std::max)((std::max)(a, b), (std::max)(c, d)); -} - -} // namespace tools - -template <class T> -void suppress_unused_variable_warning(const T&) BOOST_MATH_NOEXCEPT(T) -{ -} - -namespace detail{ - -template <class T> -struct is_integer_for_rounding -{ - static const bool value = boost::is_integral<T>::value -#ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - || (std::numeric_limits<T>::is_specialized && std::numeric_limits<T>::is_integer) -#endif - ; -}; - -} - -}} // namespace boost namespace math - -#ifdef __GLIBC_PREREQ -# if __GLIBC_PREREQ(2,14) -# define BOOST_MATH_HAVE_FIXED_GLIBC -# endif -#endif - -#if ((defined(__linux__) && !defined(__UCLIBC__) && !defined(BOOST_MATH_HAVE_FIXED_GLIBC)) || defined(__QNX__) || defined(__IBMCPP__)) && !defined(BOOST_NO_FENV_H) -// -// This code was introduced in response to this glibc bug: http://sourceware.org/bugzilla/show_bug.cgi?id=2445 -// Basically powl and expl can return garbage when the result is small and certain exception flags are set -// on entrance to these functions. This appears to have been fixed in Glibc 2.14 (May 2011). -// Much more information in this message thread: https://groups.google.com/forum/#!topic/boost-list/ZT99wtIFlb4 -// - - #include <boost/detail/fenv.hpp> - -# ifdef FE_ALL_EXCEPT - -namespace boost{ namespace math{ - namespace detail - { - struct fpu_guard - { - fpu_guard() - { - fegetexceptflag(&m_flags, FE_ALL_EXCEPT); - feclearexcept(FE_ALL_EXCEPT); - } - ~fpu_guard() - { - fesetexceptflag(&m_flags, FE_ALL_EXCEPT); - } - private: - fexcept_t m_flags; - }; - - } // namespace detail - }} // namespaces - -# define BOOST_FPU_EXCEPTION_GUARD boost::math::detail::fpu_guard local_guard_object; -# define BOOST_MATH_INSTRUMENT_FPU do{ fexcept_t cpu_flags; fegetexceptflag(&cpu_flags, FE_ALL_EXCEPT); BOOST_MATH_INSTRUMENT_VARIABLE(cpu_flags); } while(0); - -# else - -# define BOOST_FPU_EXCEPTION_GUARD -# define BOOST_MATH_INSTRUMENT_FPU - -# endif - -#else // All other platforms. -# define BOOST_FPU_EXCEPTION_GUARD -# define BOOST_MATH_INSTRUMENT_FPU -#endif - -#ifdef BOOST_MATH_INSTRUMENT - -# include <iostream> -# include <iomanip> -# include <typeinfo> - -# define BOOST_MATH_INSTRUMENT_CODE(x) \ - std::cout << std::setprecision(35) << __FILE__ << ":" << __LINE__ << " " << x << std::endl; -# define BOOST_MATH_INSTRUMENT_VARIABLE(name) BOOST_MATH_INSTRUMENT_CODE(BOOST_STRINGIZE(name) << " = " << name) - -#else - -# define BOOST_MATH_INSTRUMENT_CODE(x) -# define BOOST_MATH_INSTRUMENT_VARIABLE(name) - -#endif - -// -// Thread local storage: -// -#if !defined(BOOST_NO_CXX11_THREAD_LOCAL) && !defined(BOOST_INTEL) -# define BOOST_MATH_THREAD_LOCAL thread_local -#else -# define BOOST_MATH_THREAD_LOCAL -#endif - -// -// Can we have constexpr tables? -// -#if (!defined(BOOST_NO_CXX11_HDR_ARRAY) && !defined(BOOST_NO_CXX14_CONSTEXPR)) || BOOST_WORKAROUND(BOOST_MSVC, >= 1910) -#define BOOST_MATH_HAVE_CONSTEXPR_TABLES -#define BOOST_MATH_CONSTEXPR_TABLE_FUNCTION constexpr -#else -#define BOOST_MATH_CONSTEXPR_TABLE_FUNCTION -#endif - - -#endif // BOOST_MATH_TOOLS_CONFIG_HPP - - - - diff --git a/ThirdParty/boost/math/tools/promotion.hpp b/ThirdParty/boost/math/tools/promotion.hpp deleted file mode 100644 index 212bc3a6e413fff4a893bce1e0972d3408f62bae..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/math/tools/promotion.hpp +++ /dev/null @@ -1,182 +0,0 @@ -// boost\math\tools\promotion.hpp - -// Copyright John Maddock 2006. -// Copyright Paul A. Bristow 2006. - -// Use, modification and distribution are subject to 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) - -// Promote arguments functions to allow math functions to have arguments -// provided as integer OR real (floating-point, built-in or UDT) -// (called ArithmeticType in functions that use promotion) -// that help to reduce the risk of creating multiple instantiations. -// Allows creation of an inline wrapper that forwards to a foo(RT, RT) function, -// so you never get to instantiate any mixed foo(RT, IT) functions. - -#ifndef BOOST_MATH_PROMOTION_HPP -#define BOOST_MATH_PROMOTION_HPP - -#ifdef _MSC_VER -#pragma once -#endif - -// Boost type traits: -#include <boost/math/tools/config.hpp> -#include <boost/type_traits/is_floating_point.hpp> // for boost::is_floating_point; -#include <boost/type_traits/is_integral.hpp> // for boost::is_integral -#include <boost/type_traits/is_convertible.hpp> // for boost::is_convertible -#include <boost/type_traits/is_same.hpp>// for boost::is_same -#include <boost/type_traits/remove_cv.hpp>// for boost::remove_cv -// Boost Template meta programming: -#include <boost/mpl/if.hpp> // for boost::mpl::if_c. -#include <boost/mpl/and.hpp> // for boost::mpl::if_c. -#include <boost/mpl/or.hpp> // for boost::mpl::if_c. -#include <boost/mpl/not.hpp> // for boost::mpl::if_c. - -#ifdef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -#include <boost/static_assert.hpp> -#endif - -namespace boost -{ - namespace math - { - namespace tools - { - // If either T1 or T2 is an integer type, - // pretend it was a double (for the purposes of further analysis). - // Then pick the wider of the two floating-point types - // as the actual signature to forward to. - // For example: - // foo(int, short) -> double foo(double, double); - // foo(int, float) -> double foo(double, double); - // Note: NOT float foo(float, float) - // foo(int, double) -> foo(double, double); - // foo(double, float) -> double foo(double, double); - // foo(double, float) -> double foo(double, double); - // foo(any-int-or-float-type, long double) -> foo(long double, long double); - // but ONLY float foo(float, float) is unchanged. - // So the only way to get an entirely float version is to call foo(1.F, 2.F), - // But since most (all?) the math functions convert to double internally, - // probably there would not be the hoped-for gain by using float here. - - // This follows the C-compatible conversion rules of pow, etc - // where pow(int, float) is converted to pow(double, double). - - template <class T> - struct promote_arg - { // If T is integral type, then promote to double. - typedef typename mpl::if_<is_integral<T>, double, T>::type type; - }; - // These full specialisations reduce mpl::if_ usage and speed up - // compilation: - template <> struct promote_arg<float> { typedef float type; }; - template <> struct promote_arg<double>{ typedef double type; }; - template <> struct promote_arg<long double> { typedef long double type; }; - template <> struct promote_arg<int> { typedef double type; }; - - template <class T1, class T2> - struct promote_args_2 - { // Promote, if necessary, & pick the wider of the two floating-point types. - // for both parameter types, if integral promote to double. - typedef typename promote_arg<T1>::type T1P; // T1 perhaps promoted. - typedef typename promote_arg<T2>::type T2P; // T2 perhaps promoted. - - typedef typename mpl::if_c< - is_floating_point<T1P>::value && is_floating_point<T2P>::value, // both T1P and T2P are floating-point? -#ifdef BOOST_MATH_USE_FLOAT128 - typename mpl::if_c<is_same<__float128, T1P>::value || is_same<__float128, T2P>::value, // either long double? - __float128, -#endif - typename mpl::if_c<is_same<long double, T1P>::value || is_same<long double, T2P>::value, // either long double? - long double, // then result type is long double. - typename mpl::if_c<is_same<double, T1P>::value || is_same<double, T2P>::value, // either double? - double, // result type is double. - float // else result type is float. - >::type -#ifdef BOOST_MATH_USE_FLOAT128 - >::type -#endif - >::type, - // else one or the other is a user-defined type: - typename mpl::if_c<!is_floating_point<T2P>::value && ::boost::is_convertible<T1P, T2P>::value, T2P, T1P>::type>::type type; - }; // promote_arg2 - // These full specialisations reduce mpl::if_ usage and speed up - // compilation: - template <> struct promote_args_2<float, float> { typedef float type; }; - template <> struct promote_args_2<double, double>{ typedef double type; }; - template <> struct promote_args_2<long double, long double> { typedef long double type; }; - template <> struct promote_args_2<int, int> { typedef double type; }; - template <> struct promote_args_2<int, float> { typedef double type; }; - template <> struct promote_args_2<float, int> { typedef double type; }; - template <> struct promote_args_2<int, double> { typedef double type; }; - template <> struct promote_args_2<double, int> { typedef double type; }; - template <> struct promote_args_2<int, long double> { typedef long double type; }; - template <> struct promote_args_2<long double, int> { typedef long double type; }; - template <> struct promote_args_2<float, double> { typedef double type; }; - template <> struct promote_args_2<double, float> { typedef double type; }; - template <> struct promote_args_2<float, long double> { typedef long double type; }; - template <> struct promote_args_2<long double, float> { typedef long double type; }; - template <> struct promote_args_2<double, long double> { typedef long double type; }; - template <> struct promote_args_2<long double, double> { typedef long double type; }; - - template <class T1, class T2=float, class T3=float, class T4=float, class T5=float, class T6=float> - struct promote_args - { - typedef typename promote_args_2< - typename remove_cv<T1>::type, - typename promote_args_2< - typename remove_cv<T2>::type, - typename promote_args_2< - typename remove_cv<T3>::type, - typename promote_args_2< - typename remove_cv<T4>::type, - typename promote_args_2< - typename remove_cv<T5>::type, typename remove_cv<T6>::type - >::type - >::type - >::type - >::type - >::type type; - -#ifdef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS - // - // Guard against use of long double if it's not supported: - // - BOOST_STATIC_ASSERT_MSG((0 == ::boost::is_same<type, long double>::value), "Sorry, but this platform does not have sufficient long double support for the special functions to be reliably implemented."); -#endif - }; - - // - // This struct is the same as above, but has no static assert on long double usage, - // it should be used only on functions that can be implemented for long double - // even when std lib support is missing or broken for that type. - // - template <class T1, class T2=float, class T3=float, class T4=float, class T5=float, class T6=float> - struct promote_args_permissive - { - typedef typename promote_args_2< - typename remove_cv<T1>::type, - typename promote_args_2< - typename remove_cv<T2>::type, - typename promote_args_2< - typename remove_cv<T3>::type, - typename promote_args_2< - typename remove_cv<T4>::type, - typename promote_args_2< - typename remove_cv<T5>::type, typename remove_cv<T6>::type - >::type - >::type - >::type - >::type - >::type type; - }; - - } // namespace tools - } // namespace math -} // namespace boost - -#endif // BOOST_MATH_PROMOTION_HPP - diff --git a/ThirdParty/boost/math/tools/user.hpp b/ThirdParty/boost/math/tools/user.hpp deleted file mode 100644 index 6d3df000c00558036536f05d163521236de7ef34..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/math/tools/user.hpp +++ /dev/null @@ -1,105 +0,0 @@ -// Copyright John Maddock 2007. -// Copyright Paul A. Bristow 2007. - -// Use, modification and distribution are subject to 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_MATH_TOOLS_USER_HPP -#define BOOST_MATH_TOOLS_USER_HPP - -#ifdef _MSC_VER -#pragma once -#endif - -// This file can be modified by the user to change the default policies. -// See "Changing the Policy Defaults" in documentation. - -// define this if the platform has no long double functions, -// or if the long double versions have only double precision: -// -// #define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS -// -// Performance tuning options: -// -// #define BOOST_MATH_POLY_METHOD 3 -// #define BOOST_MATH_RATIONAL_METHOD 3 -// -// The maximum order of polynomial that will be evaluated -// via an unrolled specialisation: -// -// #define BOOST_MATH_MAX_POLY_ORDER 17 -// -// decide whether to store constants as integers or reals: -// -// #define BOOST_MATH_INT_TABLE_TYPE(RT, IT) IT - -// -// Default policies follow: -// -// Domain errors: -// -// #define BOOST_MATH_DOMAIN_ERROR_POLICY throw_on_error -// -// Pole errors: -// -// #define BOOST_MATH_POLE_ERROR_POLICY throw_on_error -// -// Overflow Errors: -// -// #define BOOST_MATH_OVERFLOW_ERROR_POLICY throw_on_error -// -// Internal Evaluation Errors: -// -// #define BOOST_MATH_EVALUATION_ERROR_POLICY throw_on_error -// -// Underflow: -// -// #define BOOST_MATH_UNDERFLOW_ERROR_POLICY ignore_error -// -// Denorms: -// -// #define BOOST_MATH_DENORM_ERROR_POLICY ignore_error -// -// Max digits to use for internal calculations: -// -// #define BOOST_MATH_DIGITS10_POLICY 0 -// -// Promote floats to doubles internally? -// -// #define BOOST_MATH_PROMOTE_FLOAT_POLICY true -// -// Promote doubles to long double internally: -// -// #define BOOST_MATH_PROMOTE_DOUBLE_POLICY true -// -// What do discrete quantiles return? -// -// #define BOOST_MATH_DISCRETE_QUANTILE_POLICY integer_round_outwards -// -// If a function is mathematically undefined -// (for example the Cauchy distribution has no mean), -// then do we stop the code from compiling? -// -// #define BOOST_MATH_ASSERT_UNDEFINED_POLICY true -// -// Maximum series iterations permitted: -// -// #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 1000000 -// -// Maximum root finding steps permitted: -// -// define BOOST_MATH_MAX_ROOT_ITERATION_POLICY 200 -// -// Enable use of __float128 in numeric constants: -// -// #define BOOST_MATH_USE_FLOAT128 -// -// Disable use of __float128 in numeric_constants even if the compiler looks to support it: -// -// #define BOOST_MATH_DISABLE_FLOAT128 - -#endif // BOOST_MATH_TOOLS_USER_HPP - - diff --git a/ThirdParty/boost/move/algo/move.hpp b/ThirdParty/boost/move/algo/move.hpp deleted file mode 100644 index 5d5ba19ea0f46700fa3478d1bbdad9c8b876d5ac..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/move/algo/move.hpp +++ /dev/null @@ -1,156 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-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) -// -// See http://www.boost.org/libs/move for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -//! \file - -#ifndef BOOST_MOVE_ALGO_MOVE_HPP -#define BOOST_MOVE_ALGO_MOVE_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif -# -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/move/detail/config_begin.hpp> - -#include <boost/move/utility_core.hpp> -#include <boost/move/detail/iterator_traits.hpp> -#include <boost/move/detail/iterator_to_raw_pointer.hpp> -#include <boost/core/no_exceptions_support.hpp> - -namespace boost { - -////////////////////////////////////////////////////////////////////////////// -// -// move -// -////////////////////////////////////////////////////////////////////////////// - -#if !defined(BOOST_MOVE_USE_STANDARD_LIBRARY_MOVE) - - //! <b>Effects</b>: Moves elements in the range [first,last) into the range [result,result + (last - - //! first)) starting from first and proceeding to last. For each non-negative integer n < (last-first), - //! performs *(result + n) = ::boost::move (*(first + n)). - //! - //! <b>Effects</b>: result + (last - first). - //! - //! <b>Requires</b>: result shall not be in the range [first,last). - //! - //! <b>Complexity</b>: Exactly last - first move assignments. - template <typename I, // I models InputIterator - typename O> // O models OutputIterator - O move(I f, I l, O result) - { - while (f != l) { - *result = ::boost::move(*f); - ++f; ++result; - } - return result; - } - - ////////////////////////////////////////////////////////////////////////////// - // - // move_backward - // - ////////////////////////////////////////////////////////////////////////////// - - //! <b>Effects</b>: Moves elements in the range [first,last) into the range - //! [result - (last-first),result) starting from last - 1 and proceeding to - //! first. For each positive integer n <= (last - first), - //! performs *(result - n) = ::boost::move(*(last - n)). - //! - //! <b>Requires</b>: result shall not be in the range [first,last). - //! - //! <b>Returns</b>: result - (last - first). - //! - //! <b>Complexity</b>: Exactly last - first assignments. - template <typename I, // I models BidirectionalIterator - typename O> // O models BidirectionalIterator - O move_backward(I f, I l, O result) - { - while (f != l) { - --l; --result; - *result = ::boost::move(*l); - } - return result; - } - -#else - - using ::std::move_backward; - -#endif //!defined(BOOST_MOVE_USE_STANDARD_LIBRARY_MOVE) - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_move -// -////////////////////////////////////////////////////////////////////////////// - -//! <b>Effects</b>: -//! \code -//! for (; first != last; ++result, ++first) -//! new (static_cast<void*>(&*result)) -//! typename iterator_traits<ForwardIterator>::value_type(boost::move(*first)); -//! \endcode -//! -//! <b>Returns</b>: result -template - <typename I, // I models InputIterator - typename F> // F models ForwardIterator -F uninitialized_move(I f, I l, F r - /// @cond -// ,typename ::boost::move_detail::enable_if<has_move_emulation_enabled<typename boost::movelib::iterator_traits<I>::value_type> >::type* = 0 - /// @endcond - ) -{ - typedef typename boost::movelib::iterator_traits<I>::value_type input_value_type; - - F back = r; - BOOST_TRY{ - while (f != l) { - void * const addr = static_cast<void*>(::boost::move_detail::addressof(*r)); - ::new(addr) input_value_type(::boost::move(*f)); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - boost::movelib::iterator_to_raw_pointer(back)->~input_value_type(); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -/// @cond -/* -template - <typename I, // I models InputIterator - typename F> // F models ForwardIterator -F uninitialized_move(I f, I l, F r, - typename ::boost::move_detail::disable_if<has_move_emulation_enabled<typename boost::movelib::iterator_traits<I>::value_type> >::type* = 0) -{ - return std::uninitialized_copy(f, l, r); -} -*/ - -/// @endcond - -} //namespace boost { - -#include <boost/move/detail/config_end.hpp> - -#endif //#ifndef BOOST_MOVE_ALGO_MOVE_HPP diff --git a/ThirdParty/boost/move/algorithm.hpp b/ThirdParty/boost/move/algorithm.hpp deleted file mode 100644 index 880d661e7dd82dada16715fb4108db52438ccf58..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/move/algorithm.hpp +++ /dev/null @@ -1,167 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-2012. -// 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) -// -// See http://www.boost.org/libs/move for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -//! \file - -#ifndef BOOST_MOVE_ALGORITHM_HPP -#define BOOST_MOVE_ALGORITHM_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif -# -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/move/detail/config_begin.hpp> - -#include <boost/move/utility_core.hpp> -#include <boost/move/iterator.hpp> -#include <boost/move/algo/move.hpp> -#include <boost/core/no_exceptions_support.hpp> - -#include <algorithm> //copy, copy_backward -#include <memory> //uninitialized_copy - -namespace boost { - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_copy_or_move -// -////////////////////////////////////////////////////////////////////////////// - -namespace move_detail { - -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F uninitialized_move_move_iterator(I f, I l, F r -// ,typename ::boost::move_detail::enable_if< has_move_emulation_enabled<typename I::value_type> >::type* = 0 -) -{ - return ::boost::uninitialized_move(f, l, r); -} -/* -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -F uninitialized_move_move_iterator(I f, I l, F r, - typename ::boost::move_detail::disable_if< has_move_emulation_enabled<typename I::value_type> >::type* = 0) -{ - return std::uninitialized_copy(f.base(), l.base(), r); -} -*/ -} //namespace move_detail { - -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F uninitialized_copy_or_move(I f, I l, F r, - typename ::boost::move_detail::enable_if< move_detail::is_move_iterator<I> >::type* = 0) -{ - return ::boost::move_detail::uninitialized_move_move_iterator(f, l, r); -} - -////////////////////////////////////////////////////////////////////////////// -// -// copy_or_move -// -////////////////////////////////////////////////////////////////////////////// - -namespace move_detail { - -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F move_move_iterator(I f, I l, F r -// ,typename ::boost::move_detail::enable_if< has_move_emulation_enabled<typename I::value_type> >::type* = 0 -) -{ - return ::boost::move(f, l, r); -} -/* -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -F move_move_iterator(I f, I l, F r, - typename ::boost::move_detail::disable_if< has_move_emulation_enabled<typename I::value_type> >::type* = 0) -{ - return std::copy(f.base(), l.base(), r); -} -*/ - -} //namespace move_detail { - -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F copy_or_move(I f, I l, F r, - typename ::boost::move_detail::enable_if< move_detail::is_move_iterator<I> >::type* = 0) -{ - return ::boost::move_detail::move_move_iterator(f, l, r); -} - -/// @endcond - -//! <b>Effects</b>: -//! \code -//! for (; first != last; ++result, ++first) -//! new (static_cast<void*>(&*result)) -//! typename iterator_traits<ForwardIterator>::value_type(*first); -//! \endcode -//! -//! <b>Returns</b>: result -//! -//! <b>Note</b>: This function is provided because -//! <i>std::uninitialized_copy</i> from some STL implementations -//! is not compatible with <i>move_iterator</i> -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F uninitialized_copy_or_move(I f, I l, F r - /// @cond - ,typename ::boost::move_detail::disable_if< move_detail::is_move_iterator<I> >::type* = 0 - /// @endcond - ) -{ - return std::uninitialized_copy(f, l, r); -} - -//! <b>Effects</b>: -//! \code -//! for (; first != last; ++result, ++first) -//! *result = *first; -//! \endcode -//! -//! <b>Returns</b>: result -//! -//! <b>Note</b>: This function is provided because -//! <i>std::uninitialized_copy</i> from some STL implementations -//! is not compatible with <i>move_iterator</i> -template -<typename I, // I models InputIterator -typename F> // F models ForwardIterator -inline F copy_or_move(I f, I l, F r - /// @cond - ,typename ::boost::move_detail::disable_if< move_detail::is_move_iterator<I> >::type* = 0 - /// @endcond - ) -{ - return std::copy(f, l, r); -} - -} //namespace boost { - -#include <boost/move/detail/config_end.hpp> - -#endif //#ifndef BOOST_MOVE_ALGORITHM_HPP diff --git a/ThirdParty/boost/move/move.hpp b/ThirdParty/boost/move/move.hpp deleted file mode 100644 index 62dddbc954813d17b1b71f1d2a1bceb8f30cbc2b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/move/move.hpp +++ /dev/null @@ -1,35 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright David Abrahams, Vicente Botet 2009. -// (C) Copyright Ion Gaztanaga 2009-2012. -// 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) -// -// See http://www.boost.org/libs/move for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -//! \file -//! A general library header that includes -//! the rest of top-level headers. - -#ifndef BOOST_MOVE_MOVE_HPP -#define BOOST_MOVE_MOVE_HPP - -#ifndef BOOST_CONFIG_HPP -# include <boost/config.hpp> -#endif -# -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include <boost/move/detail/config_begin.hpp> -#include <boost/move/utility.hpp> -#include <boost/move/iterator.hpp> -#include <boost/move/traits.hpp> -#include <boost/move/algorithm.hpp> -#include <boost/move/detail/config_end.hpp> - -#endif //#ifndef BOOST_MOVE_MOVE_HPP diff --git a/ThirdParty/boost/mp11/algorithm.hpp b/ThirdParty/boost/mp11/algorithm.hpp deleted file mode 100644 index f0a700d68dd1fec6b28eb551386ea44bd0d9e74e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/algorithm.hpp +++ /dev/null @@ -1,1226 +0,0 @@ -#ifndef BOOST_MP11_ALGORITHM_HPP_INCLUDED -#define BOOST_MP11_ALGORITHM_HPP_INCLUDED - -// Copyright 2015-2019 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/mp11/list.hpp> -#include <boost/mp11/set.hpp> -#include <boost/mp11/integral.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/mp11/function.hpp> -#include <boost/mp11/detail/mp_count.hpp> -#include <boost/mp11/detail/mp_plus.hpp> -#include <boost/mp11/detail/mp_map_find.hpp> -#include <boost/mp11/detail/mp_with_index.hpp> -#include <boost/mp11/detail/mp_fold.hpp> -#include <boost/mp11/detail/mp_min_element.hpp> -#include <boost/mp11/detail/mp_copy_if.hpp> -#include <boost/mp11/detail/mp_remove_if.hpp> -#include <boost/mp11/detail/config.hpp> -#include <boost/mp11/integer_sequence.hpp> -#include <type_traits> -#include <utility> - -namespace boost -{ -namespace mp11 -{ - -// mp_transform<F, L...> -namespace detail -{ - -template<template<class...> class F, class... L> struct mp_transform_impl -{ -}; - -template<template<class...> class F, template<class...> class L, class... T> struct mp_transform_impl<F, L<T...>> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - - template<class... U> struct f { using type = F<U...>; }; - - using type = L<typename f<T>::type...>; - -#else - - using type = L<F<T>...>; - -#endif -}; - -template<template<class...> class F, template<class...> class L1, class... T1, template<class...> class L2, class... T2> struct mp_transform_impl<F, L1<T1...>, L2<T2...>> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - - template<class... U> struct f { using type = F<U...>; }; - - using type = L1<typename f<T1, T2>::type...>; - -#else - - using type = L1<F<T1,T2>...>; - -#endif -}; - -template<template<class...> class F, template<class...> class L1, class... T1, template<class...> class L2, class... T2, template<class...> class L3, class... T3> struct mp_transform_impl<F, L1<T1...>, L2<T2...>, L3<T3...>> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - - template<class... U> struct f { using type = F<U...>; }; - - using type = L1<typename f<T1, T2, T3>::type...>; - -#else - - using type = L1<F<T1,T2,T3>...>; - -#endif -}; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, == 1900 ) || BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, < 40800 ) - -template<class... L> using mp_same_size_1 = mp_same<mp_size<L>...>; -template<class... L> struct mp_same_size_2: mp_defer<mp_same_size_1, L...> {}; - -#endif - -struct list_size_mismatch -{ -}; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<template<class...> class F, class... L> struct mp_transform_cuda_workaround -{ - using type = mp_if<mp_same<mp_size<L>...>, detail::mp_transform_impl<F, L...>, detail::list_size_mismatch>; -}; - -#endif - -} // namespace detail - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, == 1900 ) || BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, < 40800 ) - -template<template<class...> class F, class... L> using mp_transform = typename mp_if<typename detail::mp_same_size_2<L...>::type, detail::mp_transform_impl<F, L...>, detail::list_size_mismatch>::type; - -#else - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<template<class...> class F, class... L> using mp_transform = typename detail::mp_transform_cuda_workaround< F, L...>::type::type; - -#else - -template<template<class...> class F, class... L> using mp_transform = typename mp_if<mp_same<mp_size<L>...>, detail::mp_transform_impl<F, L...>, detail::list_size_mismatch>::type; - -#endif - -#endif - -template<class Q, class... L> using mp_transform_q = mp_transform<Q::template fn, L...>; - -namespace detail -{ - -template<template<class...> class F, template<class...> class L1, class... T1, template<class...> class L2, class... T2, template<class...> class L3, class... T3, template<class...> class L4, class... T4, class... L> struct mp_transform_impl<F, L1<T1...>, L2<T2...>, L3<T3...>, L4<T4...>, L...> -{ - using A1 = L1<mp_list<T1, T2, T3, T4>...>; - - template<class V, class T> using _f = mp_transform<mp_push_back, V, T>; - - using A2 = mp_fold<mp_list<L...>, A1, _f>; - - template<class T> using _g = mp_apply<F, T>; - - using type = mp_transform<_g, A2>; -}; - -} // namespace detail - -// mp_transform_if<P, F, L...> -namespace detail -{ - -template<template<class...> class P, template<class...> class F, class... L> struct mp_transform_if_impl -{ - // the stupid quote-unquote dance avoids "pack expansion used as argument for non-pack parameter of alias template" - - using Qp = mp_quote<P>; - using Qf = mp_quote<F>; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - - template<class... U> struct _f_ { using type = mp_eval_if_q<mp_not<mp_invoke_q<Qp, U...>>, mp_first<mp_list<U...>>, Qf, U...>; }; - template<class... U> using _f = typename _f_<U...>::type; - -#else - - template<class... U> using _f = mp_eval_if_q<mp_not<mp_invoke_q<Qp, U...>>, mp_first<mp_list<U...>>, Qf, U...>; - -#endif - - using type = mp_transform<_f, L...>; -}; - -} // namespace detail - -template<template<class...> class P, template<class...> class F, class... L> using mp_transform_if = typename detail::mp_transform_if_impl<P, F, L...>::type; -template<class Qp, class Qf, class... L> using mp_transform_if_q = typename detail::mp_transform_if_impl<Qp::template fn, Qf::template fn, L...>::type; - -// mp_filter<P, L...> -namespace detail -{ - -template<template<class...> class P, class L1, class... L> struct mp_filter_impl -{ - using Qp = mp_quote<P>; - - template<class T1, class... T> using _f = mp_if< mp_invoke_q<Qp, T1, T...>, mp_list<T1>, mp_list<> >; - - using _t1 = mp_transform<_f, L1, L...>; - using _t2 = mp_apply<mp_append, _t1>; - - using type = mp_assign<L1, _t2>; -}; - -} // namespace detail - -template<template<class...> class P, class... L> using mp_filter = typename detail::mp_filter_impl<P, L...>::type; -template<class Q, class... L> using mp_filter_q = typename detail::mp_filter_impl<Q::template fn, L...>::type; - -// mp_fill<L, V> -namespace detail -{ - -template<class L, class V> struct mp_fill_impl; - -template<template<class...> class L, class... T, class V> struct mp_fill_impl<L<T...>, V> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1900 ) - - template<class...> struct _f { using type = V; }; - using type = L<typename _f<T>::type...>; - -#else - - template<class...> using _f = V; - using type = L<_f<T>...>; - -#endif -}; - -} // namespace detail - -template<class L, class V> using mp_fill = typename detail::mp_fill_impl<L, V>::type; - -// mp_contains<L, V> -template<class L, class V> using mp_contains = mp_to_bool<mp_count<L, V>>; - -// mp_repeat(_c)<L, N> -namespace detail -{ - -template<class L, std::size_t N> struct mp_repeat_c_impl -{ - using _l1 = typename mp_repeat_c_impl<L, N/2>::type; - using _l2 = typename mp_repeat_c_impl<L, N%2>::type; - - using type = mp_append<_l1, _l1, _l2>; -}; - -template<class L> struct mp_repeat_c_impl<L, 0> -{ - using type = mp_clear<L>; -}; - -template<class L> struct mp_repeat_c_impl<L, 1> -{ - using type = L; -}; - -} // namespace detail - -template<class L, std::size_t N> using mp_repeat_c = typename detail::mp_repeat_c_impl<L, N>::type; -template<class L, class N> using mp_repeat = typename detail::mp_repeat_c_impl<L, std::size_t{ N::value }>::type; - -// mp_product<F, L...> -namespace detail -{ - -template<template<class...> class F, class P, class... L> struct mp_product_impl_2; - -template<template<class...> class F, class P> struct mp_product_impl_2<F, P> -{ - using type = mp_list<mp_rename<P, F>>; -}; - -template<template<class...> class F, class P, template<class...> class L1, class... T1, class... L> struct mp_product_impl_2<F, P, L1<T1...>, L...> -{ - using type = mp_append<typename mp_product_impl_2<F, mp_push_back<P, T1>, L...>::type...>; -}; - -template<template<class...> class F, class... L> struct mp_product_impl; - -template<template<class...> class F, class L1, class... L> struct mp_product_impl<F, L1, L...> -{ - using type = mp_assign<L1, typename mp_product_impl_2<F, mp_list<>, L1, L...>::type>; -}; - -} // namespace detail - -template<template<class...> class F, class... L> using mp_product = typename detail::mp_product_impl<F, L...>::type; -template<class Q, class... L> using mp_product_q = typename detail::mp_product_impl<Q::template fn, L...>::type; - -// mp_drop(_c)<L, N> -namespace detail -{ - -template<class L, class L2> struct mp_drop_impl; - -template<template<class...> class L, class... T, template<class...> class L2, class... U> struct mp_drop_impl<L<T...>, L2<U...>> -{ - template<class... W> static mp_identity<L<W...>> f( U*..., mp_identity<W>*... ); - - using R = decltype( f( (mp_identity<T>*)0 ... ) ); - - using type = typename R::type; -}; - -} // namespace detail - -template<class L, std::size_t N> using mp_drop_c = typename detail::mp_drop_impl<L, mp_repeat_c<mp_list<void>, N>>::type; - -template<class L, class N> using mp_drop = typename detail::mp_drop_impl<L, mp_repeat<mp_list<void>, N>>::type; - -// mp_from_sequence<S> -namespace detail -{ - -template<class S> struct mp_from_sequence_impl; - -template<template<class T, T... I> class S, class U, U... J> struct mp_from_sequence_impl<S<U, J...>> -{ - using type = mp_list<std::integral_constant<U, J>...>; -}; - -} // namespace detail - -template<class S> using mp_from_sequence = typename detail::mp_from_sequence_impl<S>::type; - -// mp_iota(_c)<N> -template<std::size_t N> using mp_iota_c = mp_from_sequence<make_index_sequence<N>>; -template<class N> using mp_iota = mp_from_sequence<make_integer_sequence<typename std::remove_const<decltype(N::value)>::type, N::value>>; - -// mp_at(_c)<L, I> -namespace detail -{ - -template<class L, std::size_t I> struct mp_at_c_impl; - -#if defined(BOOST_MP11_HAS_TYPE_PACK_ELEMENT) - -template<template<class...> class L, class... T, std::size_t I> struct mp_at_c_impl<L<T...>, I> -{ - using type = __type_pack_element<I, T...>; -}; - -#else - -template<class L, std::size_t I> struct mp_at_c_impl -{ - using _map = mp_transform<mp_list, mp_iota<mp_size<L> >, L>; - using type = mp_second<mp_map_find<_map, mp_size_t<I> > >; -}; - -#endif - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<class L, std::size_t I> struct mp_at_c_cuda_workaround -{ - using type = mp_if_c<(I < mp_size<L>::value), detail::mp_at_c_impl<L, I>, void>; -}; - -#endif - -} // namespace detail - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<class L, std::size_t I> using mp_at_c = typename detail::mp_at_c_cuda_workaround< L, I >::type::type; - -#else - -template<class L, std::size_t I> using mp_at_c = typename mp_if_c<(I < mp_size<L>::value), detail::mp_at_c_impl<L, I>, void>::type; - -#endif - -template<class L, class I> using mp_at = mp_at_c<L, std::size_t{ I::value }>; - -// mp_take(_c)<L, N> -namespace detail -{ - -template<std::size_t N, class L, class E = void> struct mp_take_c_impl -{ -}; - -template<template<class...> class L, class... T> -struct mp_take_c_impl<0, L<T...>> -{ - using type = L<>; -}; - -template<template<class...> class L, class T1, class... T> -struct mp_take_c_impl<1, L<T1, T...>> -{ - using type = L<T1>; -}; - -template<template<class...> class L, class T1, class T2, class... T> -struct mp_take_c_impl<2, L<T1, T2, T...>> -{ - using type = L<T1, T2>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class... T> -struct mp_take_c_impl<3, L<T1, T2, T3, T...>> -{ - using type = L<T1, T2, T3>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class... T> -struct mp_take_c_impl<4, L<T1, T2, T3, T4, T...>> -{ - using type = L<T1, T2, T3, T4>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class... T> -struct mp_take_c_impl<5, L<T1, T2, T3, T4, T5, T...>> -{ - using type = L<T1, T2, T3, T4, T5>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class... T> -struct mp_take_c_impl<6, L<T1, T2, T3, T4, T5, T6, T...>> -{ - using type = L<T1, T2, T3, T4, T5, T6>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class... T> -struct mp_take_c_impl<7, L<T1, T2, T3, T4, T5, T6, T7, T...>> -{ - using type = L<T1, T2, T3, T4, T5, T6, T7>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class... T> -struct mp_take_c_impl<8, L<T1, T2, T3, T4, T5, T6, T7, T8, T...>> -{ - using type = L<T1, T2, T3, T4, T5, T6, T7, T8>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class... T> -struct mp_take_c_impl<9, L<T1, T2, T3, T4, T5, T6, T7, T8, T9, T...>> -{ - using type = L<T1, T2, T3, T4, T5, T6, T7, T8, T9>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class T10, class... T, std::size_t N> -struct mp_take_c_impl<N, L<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T...>, typename std::enable_if<N >= 10>::type> -{ - using type = mp_append<L<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>, typename mp_take_c_impl<N-10, L<T...>>::type>; -}; - -} // namespace detail - -template<class L, std::size_t N> using mp_take_c = typename detail::mp_take_c_impl<N, L>::type; -template<class L, class N> using mp_take = typename detail::mp_take_c_impl<std::size_t{ N::value }, L>::type; - -// mp_back<L> -template<class L> using mp_back = mp_at_c<L, mp_size<L>::value - 1>; - -// mp_pop_back<L> -template<class L> using mp_pop_back = mp_take_c<L, mp_size<L>::value - 1>; - -// mp_replace<L, V, W> -namespace detail -{ - -template<class L, class V, class W> struct mp_replace_impl; - -template<template<class...> class L, class... T, class V, class W> struct mp_replace_impl<L<T...>, V, W> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - template<class A> struct _f { using type = mp_if<std::is_same<A, V>, W, A>; }; - using type = L<typename _f<T>::type...>; -#else - template<class A> using _f = mp_if<std::is_same<A, V>, W, A>; - using type = L<_f<T>...>; -#endif -}; - -} // namespace detail - -template<class L, class V, class W> using mp_replace = typename detail::mp_replace_impl<L, V, W>::type; - -// mp_replace_if<L, P, W> -namespace detail -{ - -template<class L, template<class...> class P, class W> struct mp_replace_if_impl; - -template<template<class...> class L, class... T, template<class...> class P, class W> struct mp_replace_if_impl<L<T...>, P, W> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - template<class U> struct _f { using type = mp_if<P<U>, W, U>; }; - using type = L<typename _f<T>::type...>; -#else - template<class U> using _f = mp_if<P<U>, W, U>; - using type = L<_f<T>...>; -#endif -}; - -} // namespace detail - -template<class L, template<class...> class P, class W> using mp_replace_if = typename detail::mp_replace_if_impl<L, P, W>::type; -template<class L, class Q, class W> using mp_replace_if_q = mp_replace_if<L, Q::template fn, W>; - -// mp_copy_if<L, P> -// in detail/mp_copy_if.hpp - -// mp_remove<L, V> -namespace detail -{ - -template<class L, class V> struct mp_remove_impl; - -template<template<class...> class L, class... T, class V> struct mp_remove_impl<L<T...>, V> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - template<class U> struct _f { using type = mp_if<std::is_same<U, V>, mp_list<>, mp_list<U>>; }; - using type = mp_append<L<>, typename _f<T>::type...>; -#else - template<class U> using _f = mp_if<std::is_same<U, V>, mp_list<>, mp_list<U>>; - using type = mp_append<L<>, _f<T>...>; -#endif -}; - -} // namespace detail - -template<class L, class V> using mp_remove = typename detail::mp_remove_impl<L, V>::type; - -// mp_remove_if<L, P> -// in detail/mp_remove_if.hpp - -// mp_flatten<L, L2 = mp_clear<L>> -namespace detail -{ - -template<class L2> struct mp_flatten_impl -{ - template<class T> using fn = mp_if<mp_similar<L2, T>, T, mp_list<T>>; -}; - -} // namespace detail - -template<class L, class L2 = mp_clear<L>> using mp_flatten = mp_apply<mp_append, mp_push_front<mp_transform_q<detail::mp_flatten_impl<L2>, L>, mp_clear<L>>>; - -// mp_partition<L, P> -namespace detail -{ - -template<class L, template<class...> class P> struct mp_partition_impl; - -template<template<class...> class L, class... T, template<class...> class P> struct mp_partition_impl<L<T...>, P> -{ - using type = L<mp_copy_if<L<T...>, P>, mp_remove_if<L<T...>, P>>; -}; - -} // namespace detail - -template<class L, template<class...> class P> using mp_partition = typename detail::mp_partition_impl<L, P>::type; -template<class L, class Q> using mp_partition_q = mp_partition<L, Q::template fn>; - -// mp_sort<L, P> -namespace detail -{ - -template<class L, template<class...> class P> struct mp_sort_impl; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T, template<class...> class P> struct mp_sort_impl<L<T...>, P> -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = L<>; -}; - -#else - -template<template<class...> class L, template<class...> class P> struct mp_sort_impl<L<>, P> -{ - using type = L<>; -}; - -#endif - -template<template<class...> class L, class T1, template<class...> class P> struct mp_sort_impl<L<T1>, P> -{ - using type = L<T1>; -}; - -template<template<class...> class L, class T1, class... T, template<class...> class P> struct mp_sort_impl<L<T1, T...>, P> -{ - template<class U> using F = P<U, T1>; - - using part = mp_partition<L<T...>, F>; - - using S1 = typename mp_sort_impl<mp_first<part>, P>::type; - using S2 = typename mp_sort_impl<mp_second<part>, P>::type; - - using type = mp_append<mp_push_back<S1, T1>, S2>; -}; - -} // namespace detail - -template<class L, template<class...> class P> using mp_sort = typename detail::mp_sort_impl<L, P>::type; -template<class L, class Q> using mp_sort_q = mp_sort<L, Q::template fn>; - -// mp_nth_element(_c)<L, I, P> -namespace detail -{ - -template<class L, std::size_t I, template<class...> class P> struct mp_nth_element_impl; - -template<template<class...> class L, class T1, std::size_t I, template<class...> class P> struct mp_nth_element_impl<L<T1>, I, P> -{ - static_assert( I == 0, "mp_nth_element index out of range" ); - using type = T1; -}; - -template<template<class...> class L, class T1, class... T, std::size_t I, template<class...> class P> struct mp_nth_element_impl<L<T1, T...>, I, P> -{ - static_assert( I < 1 + sizeof...(T), "mp_nth_element index out of range" ); - - template<class U> using F = P<U, T1>; - - using part = mp_partition<L<T...>, F>; - - using L1 = mp_first<part>; - static std::size_t const N1 = mp_size<L1>::value; - - using L2 = mp_second<part>; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - - struct detail - { - struct mp_nth_element_impl_cuda_workaround - { - using type = mp_cond< - - mp_bool<(I < N1)>, mp_nth_element_impl<L1, I, P>, - mp_bool<(I == N1)>, mp_identity<T1>, - mp_true, mp_nth_element_impl<L2, I - N1 - 1, P> - - >; - }; - }; - - using type = typename detail::mp_nth_element_impl_cuda_workaround::type::type; - -#else - - using type = typename mp_cond< - - mp_bool<(I < N1)>, mp_nth_element_impl<L1, I, P>, - mp_bool<(I == N1)>, mp_identity<T1>, - mp_true, mp_nth_element_impl<L2, I - N1 - 1, P> - - >::type; - -#endif -}; - -} // namespace detail - -template<class L, std::size_t I, template<class...> class P> using mp_nth_element_c = typename detail::mp_nth_element_impl<L, I, P>::type; -template<class L, class I, template<class...> class P> using mp_nth_element = typename detail::mp_nth_element_impl<L, std::size_t{ I::value }, P>::type; -template<class L, class I, class Q> using mp_nth_element_q = mp_nth_element<L, I, Q::template fn>; - -// mp_find<L, V> -namespace detail -{ - -template<class L, class V> struct mp_find_impl; - -#if BOOST_MP11_CLANG && defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) - -struct mp_index_holder -{ - std::size_t i_; - bool f_; -}; - -constexpr inline mp_index_holder operator+( mp_index_holder const & v, bool f ) -{ - if( v.f_ ) - { - return v; - } - else if( f ) - { - return { v.i_, true }; - } - else - { - return { v.i_ + 1, false }; - } -} - -template<template<class...> class L, class... T, class V> struct mp_find_impl<L<T...>, V> -{ - static constexpr mp_index_holder _v{ 0, false }; - using type = mp_size_t< (_v + ... + std::is_same<T, V>::value).i_ >; -}; - -#elif !defined( BOOST_MP11_NO_CONSTEXPR ) - -template<template<class...> class L, class V> struct mp_find_impl<L<>, V> -{ - using type = mp_size_t<0>; -}; - -#if defined( BOOST_MP11_HAS_CXX14_CONSTEXPR ) - -constexpr std::size_t cx_find_index( bool const * first, bool const * last ) -{ - std::size_t m = 0; - - while( first != last && !*first ) - { - ++m; - ++first; - } - - return m; -} - -#else - -constexpr std::size_t cx_find_index( bool const * first, bool const * last ) -{ - return first == last || *first? 0: 1 + cx_find_index( first + 1, last ); -} - -#endif - -template<template<class...> class L, class... T, class V> struct mp_find_impl<L<T...>, V> -{ - static constexpr bool _v[] = { std::is_same<T, V>::value... }; - using type = mp_size_t< cx_find_index( _v, _v + sizeof...(T) ) >; -}; - -#else - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T, class V> struct mp_find_impl<L<T...>, V> -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = mp_size_t<0>; -}; - -#else - -template<template<class...> class L, class V> struct mp_find_impl<L<>, V> -{ - using type = mp_size_t<0>; -}; - -#endif - -template<template<class...> class L, class... T, class V> struct mp_find_impl<L<V, T...>, V> -{ - using type = mp_size_t<0>; -}; - -template<template<class...> class L, class T1, class... T, class V> struct mp_find_impl<L<T1, T...>, V> -{ - using _r = typename mp_find_impl<mp_list<T...>, V>::type; - using type = mp_size_t<1 + _r::value>; -}; - -#endif - -} // namespace detail - -template<class L, class V> using mp_find = typename detail::mp_find_impl<L, V>::type; - -// mp_find_if<L, P> -namespace detail -{ - -template<class L, template<class...> class P> struct mp_find_if_impl; - -#if BOOST_MP11_CLANG && defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) - -template<template<class...> class L, class... T, template<class...> class P> struct mp_find_if_impl<L<T...>, P> -{ - static constexpr mp_index_holder _v{ 0, false }; - using type = mp_size_t< (_v + ... + P<T>::value).i_ >; -}; - -#elif !defined( BOOST_MP11_NO_CONSTEXPR ) - -template<template<class...> class L, template<class...> class P> struct mp_find_if_impl<L<>, P> -{ - using type = mp_size_t<0>; -}; - -template<template<class...> class L, class... T, template<class...> class P> struct mp_find_if_impl<L<T...>, P> -{ - static constexpr bool _v[] = { P<T>::value... }; - using type = mp_size_t< cx_find_index( _v, _v + sizeof...(T) ) >; -}; - -#else - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T, template<class...> class P> struct mp_find_if_impl<L<T...>, P> -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = mp_size_t<0>; -}; - -#else - -template<template<class...> class L, template<class...> class P> struct mp_find_if_impl<L<>, P> -{ - using type = mp_size_t<0>; -}; - -#endif - -template<class L, template<class...> class P> struct mp_find_if_impl_2 -{ - using _r = typename mp_find_if_impl<L, P>::type; - using type = mp_size_t<1 + _r::value>; -}; - -template<template<class...> class L, class T1, class... T, template<class...> class P> struct mp_find_if_impl<L<T1, T...>, P> -{ - using type = typename mp_if<P<T1>, mp_identity<mp_size_t<0>>, mp_find_if_impl_2<mp_list<T...>, P>>::type; -}; - -#endif - -} // namespace detail - -template<class L, template<class...> class P> using mp_find_if = typename detail::mp_find_if_impl<L, P>::type; -template<class L, class Q> using mp_find_if_q = mp_find_if<L, Q::template fn>; - -// mp_reverse<L> -namespace detail -{ - -template<class L> struct mp_reverse_impl; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T> struct mp_reverse_impl<L<T...>> -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = L<>; -}; - -#else - -template<template<class...> class L> struct mp_reverse_impl<L<>> -{ - using type = L<>; -}; - -#endif - -template<template<class...> class L, class T1> struct mp_reverse_impl<L<T1>> -{ - using type = L<T1>; -}; - -template<template<class...> class L, class T1, class T2> struct mp_reverse_impl<L<T1, T2>> -{ - using type = L<T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3> struct mp_reverse_impl<L<T1, T2, T3>> -{ - using type = L<T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4> struct mp_reverse_impl<L<T1, T2, T3, T4>> -{ - using type = L<T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5> struct mp_reverse_impl<L<T1, T2, T3, T4, T5>> -{ - using type = L<T5, T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6> struct mp_reverse_impl<L<T1, T2, T3, T4, T5, T6>> -{ - using type = L<T6, T5, T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7> struct mp_reverse_impl<L<T1, T2, T3, T4, T5, T6, T7>> -{ - using type = L<T7, T6, T5, T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8> struct mp_reverse_impl<L<T1, T2, T3, T4, T5, T6, T7, T8>> -{ - using type = L<T8, T7, T6, T5, T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9> struct mp_reverse_impl<L<T1, T2, T3, T4, T5, T6, T7, T8, T9>> -{ - using type = L<T9, T8, T7, T6, T5, T4, T3, T2, T1>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class T10, class... T> struct mp_reverse_impl<L<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T...>> -{ - using type = mp_push_back<typename mp_reverse_impl<L<T...>>::type, T10, T9, T8, T7, T6, T5, T4, T3, T2, T1>; -}; - -} // namespace detail - -template<class L> using mp_reverse = typename detail::mp_reverse_impl<L>::type; - -// mp_fold<L, V, F> -// in detail/mp_fold.hpp - -// mp_reverse_fold<L, V, F> -namespace detail -{ - -template<class L, class V, template<class...> class F> struct mp_reverse_fold_impl; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T, class V, template<class...> class F> struct mp_reverse_fold_impl<L<T...>, V, F> -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = V; -}; - -#else - -template<template<class...> class L, class V, template<class...> class F> struct mp_reverse_fold_impl<L<>, V, F> -{ - using type = V; -}; - -#endif - -template<template<class...> class L, class T1, class... T, class V, template<class...> class F> struct mp_reverse_fold_impl<L<T1, T...>, V, F> -{ - using rest = typename mp_reverse_fold_impl<L<T...>, V, F>::type; - using type = F<T1, rest>; -}; - -template<template<class...> class L, class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class T10, class... T, class V, template<class...> class F> struct mp_reverse_fold_impl<L<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T...>, V, F> -{ - using rest = typename mp_reverse_fold_impl<L<T...>, V, F>::type; - using type = F<T1, F<T2, F<T3, F<T4, F<T5, F<T6, F<T7, F<T8, F<T9, F<T10, rest> > > > > > > > > >; -}; - -} // namespace detail - -template<class L, class V, template<class...> class F> using mp_reverse_fold = typename detail::mp_reverse_fold_impl<L, V, F>::type; -template<class L, class V, class Q> using mp_reverse_fold_q = mp_reverse_fold<L, V, Q::template fn>; - -// mp_unique<L> -namespace detail -{ - -template<class L> struct mp_unique_impl; - -template<template<class...> class L, class... T> struct mp_unique_impl<L<T...>> -{ - using type = mp_set_push_back<L<>, T...>; -}; - -} // namespace detail - -template<class L> using mp_unique = typename detail::mp_unique_impl<L>::type; - -// mp_unique_if<L, P> -namespace detail -{ - -template<template<class...> class P> struct mp_unique_if_push_back -{ - template<class...> struct impl - { - }; - - template<template<class...> class L, class... Ts, class T> - struct impl<L<Ts...>, T> - { - using type = mp_if<mp_any<P<Ts, T>...>, L<Ts...>, L<Ts..., T>>; - }; - - template<class... T> using fn = typename impl<T...>::type; -}; - -} // namespace detail - -template<class L, template<class...> class P> -using mp_unique_if = mp_fold_q<L, mp_clear<L>, detail::mp_unique_if_push_back<P>>; - -template<class L, class Q> using mp_unique_if_q = mp_unique_if<L, Q::template fn>; - -// mp_all_of<L, P> -template<class L, template<class...> class P> using mp_all_of = mp_bool< mp_count_if<L, P>::value == mp_size<L>::value >; -template<class L, class Q> using mp_all_of_q = mp_all_of<L, Q::template fn>; - -// mp_none_of<L, P> -template<class L, template<class...> class P> using mp_none_of = mp_bool< mp_count_if<L, P>::value == 0 >; -template<class L, class Q> using mp_none_of_q = mp_none_of<L, Q::template fn>; - -// mp_any_of<L, P> -template<class L, template<class...> class P> using mp_any_of = mp_bool< mp_count_if<L, P>::value != 0 >; -template<class L, class Q> using mp_any_of_q = mp_any_of<L, Q::template fn>; - -// mp_replace_at_c<L, I, W> -namespace detail -{ - -template<class L, class I, class W> struct mp_replace_at_impl -{ - static_assert( I::value >= 0, "mp_replace_at<L, I, W>: I must not be negative" ); - - template<class T1, class T2> using _p = std::is_same<T2, mp_size_t<I::value>>; - template<class T1, class T2> using _f = W; - - using type = mp_transform_if<_p, _f, L, mp_iota<mp_size<L> > >; -}; - -} // namespace detail - -template<class L, class I, class W> using mp_replace_at = typename detail::mp_replace_at_impl<L, I, W>::type; -template<class L, std::size_t I, class W> using mp_replace_at_c = typename detail::mp_replace_at_impl<L, mp_size_t<I>, W>::type; - -//mp_for_each<L>(f) -namespace detail -{ - -template<class... T, class F> BOOST_MP11_CONSTEXPR F mp_for_each_impl( mp_list<T...>, F && f ) -{ - using A = int[sizeof...(T)]; - return (void)A{ ((void)f(T()), 0)... }, std::forward<F>(f); -} - -template<class F> BOOST_MP11_CONSTEXPR F mp_for_each_impl( mp_list<>, F && f ) -{ - return std::forward<F>(f); -} - -} // namespace detail - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, >= 1900 ) - -// msvc has a limit of 1024 - -template<class L, class F> BOOST_MP11_CONSTEXPR mp_if_c<mp_size<L>::value <= 1024, F> mp_for_each( F && f ) -{ - return detail::mp_for_each_impl( mp_rename<L, mp_list>(), std::forward<F>(f) ); -} - -template<class L, class F> BOOST_MP11_CONSTEXPR mp_if_c<mp_size<L>::value >= 1025, F> mp_for_each( F && f ) -{ - using L2 = mp_rename<L, mp_list>; - - using L3 = mp_take_c<L2, 1024>; - using L4 = mp_drop_c<L2, 1024>; - - return mp_for_each<L4>( mp_for_each<L3>( std::forward<F>(f) ) ); -} - -#else - -template<class L, class F> BOOST_MP11_CONSTEXPR F mp_for_each( F && f ) -{ - return detail::mp_for_each_impl( mp_rename<L, mp_list>(), std::forward<F>(f) ); -} - -#endif - -// mp_insert<L, I, T...> -template<class L, class I, class... T> using mp_insert = mp_append<mp_take<L, I>, mp_push_front<mp_drop<L, I>, T...>>; - -// mp_insert_c<L, I, T...> -template<class L, std::size_t I, class... T> using mp_insert_c = mp_append<mp_take_c<L, I>, mp_push_front<mp_drop_c<L, I>, T...>>; - -// mp_erase<L, I, J> -template<class L, class I, class J> using mp_erase = mp_append<mp_take<L, I>, mp_drop<L, J>>; - -// mp_erase_c<L, I, J> -template<class L, std::size_t I, std::size_t J> using mp_erase_c = mp_append<mp_take_c<L, I>, mp_drop_c<L, J>>; - -// mp_starts_with<L1, L2> -// contributed by Glen Joseph Fernandes (glenjofe@gmail.com) -namespace detail { - -template<class L1, class L2> -struct mp_starts_with_impl { }; - -template<template<class...> class L1, class... T1, template<class...> class L2, - class... T2> -struct mp_starts_with_impl<L1<T1...>, L2<T2...> > { - template<class L> - static mp_false check(L); - - template<class... T> - static mp_true check(mp_list<T2..., T...>); - - using type = decltype(check(mp_list<T1...>())); -}; - -} // namespace detail - -template<class L1, class L2> -using mp_starts_with = typename detail::mp_starts_with_impl<L1, L2>::type; - -// mp_rotate_left(_c)<L, N> -namespace detail -{ - -// limit divisor to 1 to avoid division by 0 and give a rotation of 0 for lists containing 0 or 1 elements -template<std::size_t Ln, std::size_t N> using canonical_left_rotation = mp_size_t<N % (Ln == 0? 1: Ln)>; - -// perform right rotation as a left rotation by inverting the number of elements to rotate -template<std::size_t Ln, std::size_t N> using canonical_right_rotation = mp_size_t<Ln - N % (Ln == 0? 1: Ln)>; - -// avoid errors when rotating fixed-sized lists by using mp_list for the transformation -template<class L, class N, class L2 = mp_rename<L, mp_list>> using mp_rotate_impl = mp_assign<L, mp_append< mp_drop<L2, N>, mp_take<L2, N> >>; - -} // namespace detail - -template<class L, std::size_t N> using mp_rotate_left_c = detail::mp_rotate_impl<L, detail::canonical_left_rotation<mp_size<L>::value, N>>; -template<class L, class N> using mp_rotate_left = mp_rotate_left_c<L, std::size_t{ N::value }>; - -// mp_rotate_right(_c)<L, N> -template<class L, std::size_t N> using mp_rotate_right_c = mp_rotate_left<L, detail::canonical_right_rotation<mp_size<L>::value, N>>; -template<class L, class N> using mp_rotate_right = mp_rotate_right_c<L, std::size_t{ N::value }>; - -// mp_min_element<L, P> -// mp_max_element<L, P> -// in detail/mp_min_element.hpp - -// mp_power_set<L> -namespace detail -{ - -template<class L> struct mp_power_set_impl; - -} // namespace detail - -template<class L> using mp_power_set = typename detail::mp_power_set_impl<L>::type; - -namespace detail -{ - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1800 ) - -template<template<class...> class L, class... T> struct mp_power_set_impl< L<T...> > -{ - static_assert( sizeof...(T) == 0, "T... must be empty" ); - using type = L< L<> >; -}; - -#else - -template<template<class...> class L> struct mp_power_set_impl< L<> > -{ - using type = L< L<> >; -}; - -#endif - -template<template<class...> class L, class T1, class... T> struct mp_power_set_impl< L<T1, T...> > -{ - using S1 = mp_power_set< L<T...> >; - - template<class L2> using _f = mp_push_front<L2, T1>; - - using S2 = mp_transform<_f, S1>; - - using type = mp_append< S1, S2 >; -}; - -} // namespace detail - -// mp_partial_sum<L, V, F> -namespace detail -{ - -template<template<class...> class F> struct mp_partial_sum_impl_f -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, <= 1900 ) - - template<class V, class T> using fn = mp_list<F<mp_first<V>, T>, mp_push_back<mp_second<V>, F<mp_first<V>, T>> >; - -#else - - template<class V, class T, class N = F<mp_first<V>, T>> using fn = mp_list<N, mp_push_back<mp_second<V>, N>>; - -#endif -}; - -} // namespace detail - -template<class L, class V, template<class...> class F> using mp_partial_sum = mp_second<mp_fold_q<L, mp_list<V, mp_clear<L>>, detail::mp_partial_sum_impl_f<F>> >; -template<class L, class V, class Q> using mp_partial_sum_q = mp_partial_sum<L, V, Q::template fn>; - -// mp_iterate<V, F, R> -namespace detail -{ - -template<class V, template<class...> class F, template<class...> class R, class N> struct mp_iterate_impl; - -} // namespace detail - -template<class V, template<class...> class F, template<class...> class R> using mp_iterate = typename detail::mp_iterate_impl<V, F, R, mp_valid<R, V>>::type; - -namespace detail -{ - -template<class V, template<class...> class F, template<class...> class R> struct mp_iterate_impl<V, F, R, mp_false> -{ - template<class X> using _f = mp_list<F<X>>; - using type = mp_eval_or<mp_list<>, _f, V>; -}; - -template<class V, template<class...> class F, template<class...> class R> struct mp_iterate_impl<V, F, R, mp_true> -{ - using type = mp_push_front<mp_iterate<R<V>, F, R>, F<V>>; -}; - -} // namespace detail - -template<class V, class Qf, class Qr> using mp_iterate_q = mp_iterate<V, Qf::template fn, Qr::template fn>; - -} // namespace mp11 -} // namespace boost - -#endif // #ifndef BOOST_MP11_ALGORITHM_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/detail/config.hpp b/ThirdParty/boost/mp11/detail/config.hpp deleted file mode 100644 index 0a9ded50b521383dddd22fce02be7109c8ec8337..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/detail/config.hpp +++ /dev/null @@ -1,136 +0,0 @@ -#ifndef BOOST_MP11_DETAIL_CONFIG_HPP_INCLUDED -#define BOOST_MP11_DETAIL_CONFIG_HPP_INCLUDED - -// Copyright 2016, 2018, 2019 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_MP11_WORKAROUND - -#if defined( BOOST_STRICT_CONFIG ) || defined( BOOST_MP11_NO_WORKAROUNDS ) - -# define BOOST_MP11_WORKAROUND( symbol, test ) 0 - -#else - -# define BOOST_MP11_WORKAROUND( symbol, test ) ((symbol) != 0 && ((symbol) test)) - -#endif - -// - -#define BOOST_MP11_CUDA 0 -#define BOOST_MP11_CLANG 0 -#define BOOST_MP11_INTEL 0 -#define BOOST_MP11_GCC 0 -#define BOOST_MP11_MSVC 0 - -#define BOOST_MP11_CONSTEXPR constexpr - -#if defined( __CUDACC__ ) - -// nvcc - -# undef BOOST_MP11_CUDA -# define BOOST_MP11_CUDA (__CUDACC_VER_MAJOR__ * 1000000 + __CUDACC_VER_MINOR__ * 10000 + __CUDACC_VER_BUILD__) - -// CUDA (8.0) has no constexpr support in msvc mode: -# if defined(_MSC_VER) && (BOOST_MP11_CUDA < 9000000) - -# define BOOST_MP11_NO_CONSTEXPR - -# undef BOOST_MP11_CONSTEXPR -# define BOOST_MP11_CONSTEXPR - -# endif - -#elif defined(__clang__) - -// Clang - -# undef BOOST_MP11_CLANG -# define BOOST_MP11_CLANG (__clang_major__ * 100 + __clang_minor__) - -# if defined(__has_cpp_attribute) -# if __has_cpp_attribute(fallthrough) && __cplusplus >= 201406L // Clang 3.9+ in c++1z mode -# define BOOST_MP11_HAS_FOLD_EXPRESSIONS -# endif -# endif - -#if BOOST_MP11_CLANG < 400 && __cplusplus >= 201402L \ - && defined( __GLIBCXX__ ) && !__has_include(<shared_mutex>) - -// Clang pre-4 in C++14 mode, libstdc++ pre-4.9, ::gets is not defined, -// but Clang tries to import it into std - - extern "C" char *gets (char *__s); -#endif - -#elif defined(__INTEL_COMPILER) - -// Intel C++ - -# undef BOOST_MP11_INTEL -# define BOOST_MP11_INTEL __INTEL_COMPILER - -#elif defined(__GNUC__) - -// g++ - -# undef BOOST_MP11_GCC -# define BOOST_MP11_GCC (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) - -#elif defined(_MSC_VER) - -// MS Visual C++ - -# undef BOOST_MP11_MSVC -# define BOOST_MP11_MSVC _MSC_VER - -# if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) -# define BOOST_MP11_NO_CONSTEXPR -# endif - -#if _MSC_FULL_VER < 190024210 // 2015u3 -# undef BOOST_MP11_CONSTEXPR -# define BOOST_MP11_CONSTEXPR -#endif - -#endif - -// BOOST_MP11_HAS_CXX14_CONSTEXPR - -#if !defined(BOOST_MP11_NO_CONSTEXPR) && defined(__cpp_constexpr) && __cpp_constexpr >= 201304 -# define BOOST_MP11_HAS_CXX14_CONSTEXPR -#endif - -// BOOST_MP11_HAS_FOLD_EXPRESSIONS - -#if !defined(BOOST_MP11_HAS_FOLD_EXPRESSIONS) && defined(__cpp_fold_expressions) && __cpp_fold_expressions >= 201603 -# define BOOST_MP11_HAS_FOLD_EXPRESSIONS -#endif - -// BOOST_MP11_HAS_TYPE_PACK_ELEMENT - -#if defined(__has_builtin) -# if __has_builtin(__type_pack_element) -# define BOOST_MP11_HAS_TYPE_PACK_ELEMENT -# endif -#endif - -// BOOST_MP11_DEPRECATED(msg) - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CLANG, < 304 ) -# define BOOST_MP11_DEPRECATED(msg) -#elif defined(__GNUC__) || defined(__clang__) -# define BOOST_MP11_DEPRECATED(msg) __attribute__((deprecated(msg))) -#elif defined(_MSC_VER) && _MSC_VER >= 1900 -# define BOOST_MP11_DEPRECATED(msg) [[deprecated(msg)]] -#else -# define BOOST_MP11_DEPRECATED(msg) -#endif - -#endif // #ifndef BOOST_MP11_DETAIL_CONFIG_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/detail/mp_count.hpp b/ThirdParty/boost/mp11/detail/mp_count.hpp deleted file mode 100644 index 1e221ca355d1c584990b64d8457ab6c9068b6877..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/detail/mp_count.hpp +++ /dev/null @@ -1,115 +0,0 @@ -#ifndef BOOST_MP11_DETAIL_MP_COUNT_HPP_INCLUDED -#define BOOST_MP11_DETAIL_MP_COUNT_HPP_INCLUDED - -// Copyright 2015, 2016 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/mp11/integral.hpp> -#include <boost/mp11/detail/mp_plus.hpp> -#include <boost/mp11/detail/config.hpp> - -namespace boost -{ -namespace mp11 -{ - -// mp_count<L, V> -namespace detail -{ - -template<class L, class V> struct mp_count_impl; - -#if defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) - -template<template<class...> class L, class... T, class V> struct mp_count_impl<L<T...>, V> -{ - using type = mp_size_t<(std::is_same<T, V>::value + ... + 0)>; -}; - -#elif !defined( BOOST_MP11_NO_CONSTEXPR ) - -constexpr std::size_t cx_plus() -{ - return 0; -} - -template<class T1, class... T> constexpr std::size_t cx_plus(T1 t1, T... t) -{ - return static_cast<std::size_t>(t1) + cx_plus(t...); -} - -template<class T1, class T2, class T3, class T4, class T5, class T6, class T7, class T8, class T9, class T10, class... T> -constexpr std::size_t cx_plus(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6, T7 t7, T8 t8, T9 t9, T10 t10, T... t) -{ - return static_cast<std::size_t>(t1 + t2 + t3 + t4 + t5 + t6 + t7 + t8 + t9 + t10) + cx_plus(t...); -} - -template<template<class...> class L, class... T, class V> struct mp_count_impl<L<T...>, V> -{ - using type = mp_size_t<cx_plus(std::is_same<T, V>::value...)>; -}; - -#else - -template<template<class...> class L, class... T, class V> struct mp_count_impl<L<T...>, V> -{ - using type = mp_size_t<mp_plus<std::is_same<T, V>...>::value>; -}; - -#endif - -} // namespace detail - -template<class L, class V> using mp_count = typename detail::mp_count_impl<L, V>::type; - -// mp_count_if<L, P> -namespace detail -{ - -template<class L, template<class...> class P> struct mp_count_if_impl; - -#if defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) && !BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - -template<template<class...> class L, class... T, template<class...> class P> struct mp_count_if_impl<L<T...>, P> -{ - using type = mp_size_t<(mp_to_bool<P<T>>::value + ... + 0)>; -}; - -#elif !defined( BOOST_MP11_NO_CONSTEXPR ) - -template<template<class...> class L, class... T, template<class...> class P> struct mp_count_if_impl<L<T...>, P> -{ - using type = mp_size_t<cx_plus(mp_to_bool<P<T>>::value...)>; -}; - -#else - -template<template<class...> class L, class... T, template<class...> class P> struct mp_count_if_impl<L<T...>, P> -{ -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - - template<class T> struct _f { using type = mp_to_bool<P<T>>; }; - using type = mp_size_t<mp_plus<typename _f<T>::type...>::value>; - -#else - - using type = mp_size_t<mp_plus<mp_to_bool<P<T>>...>::value>; - -#endif -}; - -#endif - -} // namespace detail - -template<class L, template<class...> class P> using mp_count_if = typename detail::mp_count_if_impl<L, P>::type; -template<class L, class Q> using mp_count_if_q = mp_count_if<L, Q::template fn>; - -} // namespace mp11 -} // namespace boost - -#endif // #ifndef BOOST_MP11_DETAIL_MP_COUNT_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/detail/mp_with_index.hpp b/ThirdParty/boost/mp11/detail/mp_with_index.hpp deleted file mode 100644 index 3eec9b691c61941a5321868dddd84c63475265cf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/detail/mp_with_index.hpp +++ /dev/null @@ -1,398 +0,0 @@ -#ifndef BOOST_MP11_DETAIL_MP_WITH_INDEX_HPP_INCLUDED -#define BOOST_MP11_DETAIL_MP_WITH_INDEX_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 - -#include <boost/mp11/integral.hpp> -#include <boost/mp11/detail/config.hpp> -#include <type_traits> -#include <utility> -#include <cassert> - -#if defined( BOOST_MP11_HAS_CXX14_CONSTEXPR ) -# define BOOST_MP11_CONSTEXPR14 constexpr -#else -# define BOOST_MP11_CONSTEXPR14 -#endif - -#if defined( __GNUC__ ) || defined( __clang__ ) -# define BOOST_MP11_UNREACHABLE_DEFAULT default: __builtin_unreachable(); -#elif defined( _MSC_VER ) -# define BOOST_MP11_UNREACHABLE_DEFAULT default: __assume(false); -#else -# define BOOST_MP11_UNREACHABLE_DEFAULT -#endif - -namespace boost -{ -namespace mp11 -{ - -namespace detail -{ - -template<std::size_t N> struct mp_with_index_impl_ -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - case 12: return std::forward<F>(f)( mp_size_t<K+12>() ); - case 13: return std::forward<F>(f)( mp_size_t<K+13>() ); - case 14: return std::forward<F>(f)( mp_size_t<K+14>() ); - case 15: return std::forward<F>(f)( mp_size_t<K+15>() ); - } - - return mp_with_index_impl_<N-16>::template call<K+16>( i-16, std::forward<F>(f) ); - } -}; - -template<> struct mp_with_index_impl_<0> -{ -}; - -template<> struct mp_with_index_impl_<1> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t /*i*/, F && f ) - { - return std::forward<F>(f)( mp_size_t<K+0>() ); - } -}; - -template<> struct mp_with_index_impl_<2> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - } - } -}; - -template<> struct mp_with_index_impl_<3> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - } - } -}; - -template<> struct mp_with_index_impl_<4> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - } - } -}; - -template<> struct mp_with_index_impl_<5> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - } - } -}; - -template<> struct mp_with_index_impl_<6> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - } - } -}; - -template<> struct mp_with_index_impl_<7> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - } - } -}; - -template<> struct mp_with_index_impl_<8> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - } - } -}; - -template<> struct mp_with_index_impl_<9> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - } - } -}; - -template<> struct mp_with_index_impl_<10> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - } - } -}; - -template<> struct mp_with_index_impl_<11> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - } - } -}; - -template<> struct mp_with_index_impl_<12> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - } - } -}; - -template<> struct mp_with_index_impl_<13> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - case 12: return std::forward<F>(f)( mp_size_t<K+12>() ); - } - } -}; - -template<> struct mp_with_index_impl_<14> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - case 12: return std::forward<F>(f)( mp_size_t<K+12>() ); - case 13: return std::forward<F>(f)( mp_size_t<K+13>() ); - } - } -}; - -template<> struct mp_with_index_impl_<15> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - case 12: return std::forward<F>(f)( mp_size_t<K+12>() ); - case 13: return std::forward<F>(f)( mp_size_t<K+13>() ); - case 14: return std::forward<F>(f)( mp_size_t<K+14>() ); - } - } -}; - -template<> struct mp_with_index_impl_<16> -{ - template<std::size_t K, class F> static BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) call( std::size_t i, F && f ) - { - switch( i ) - { - BOOST_MP11_UNREACHABLE_DEFAULT - case 0: return std::forward<F>(f)( mp_size_t<K+0>() ); - case 1: return std::forward<F>(f)( mp_size_t<K+1>() ); - case 2: return std::forward<F>(f)( mp_size_t<K+2>() ); - case 3: return std::forward<F>(f)( mp_size_t<K+3>() ); - case 4: return std::forward<F>(f)( mp_size_t<K+4>() ); - case 5: return std::forward<F>(f)( mp_size_t<K+5>() ); - case 6: return std::forward<F>(f)( mp_size_t<K+6>() ); - case 7: return std::forward<F>(f)( mp_size_t<K+7>() ); - case 8: return std::forward<F>(f)( mp_size_t<K+8>() ); - case 9: return std::forward<F>(f)( mp_size_t<K+9>() ); - case 10: return std::forward<F>(f)( mp_size_t<K+10>() ); - case 11: return std::forward<F>(f)( mp_size_t<K+11>() ); - case 12: return std::forward<F>(f)( mp_size_t<K+12>() ); - case 13: return std::forward<F>(f)( mp_size_t<K+13>() ); - case 14: return std::forward<F>(f)( mp_size_t<K+14>() ); - case 15: return std::forward<F>(f)( mp_size_t<K+15>() ); - } - } -}; - -} // namespace detail - -template<std::size_t N, class F> inline BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) mp_with_index( std::size_t i, F && f ) -{ - assert( i < N ); - return detail::mp_with_index_impl_<N>::template call<0>( i, std::forward<F>(f) ); -} - -template<class N, class F> inline BOOST_MP11_CONSTEXPR14 decltype(std::declval<F>()(std::declval<mp_size_t<0>>())) mp_with_index( std::size_t i, F && f ) -{ - return mp_with_index<std::size_t{N::value}>( i, std::forward<F>(f) ); -} - -#undef BOOST_MP11_CONSTEXPR14 -#undef BOOST_MP11_UNREACHABLE_DEFAULT - -} // namespace mp11 -} // namespace boost - -#endif // #ifndef BOOST_MP11_DETAIL_MP_WITH_INDEX_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/detail/mpl_common.hpp b/ThirdParty/boost/mp11/detail/mpl_common.hpp deleted file mode 100644 index 208885cbd06eea46a9783aa960a1075cdd5bf458..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/detail/mpl_common.hpp +++ /dev/null @@ -1,160 +0,0 @@ -#ifndef BOOST_MP11_DETAIL_MPL_COMMON_HPP_INCLUDED -#define BOOST_MP11_DETAIL_MPL_COMMON_HPP_INCLUDED - -// Copyright 2017, 2019 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/mp11/list.hpp> -#include <boost/mp11/algorithm.hpp> - -namespace boost -{ -namespace mpl -{ - -struct forward_iterator_tag; - -namespace aux -{ - -struct mp11_tag {}; - -template<class L> struct mp11_iterator -{ - using category = forward_iterator_tag; - - using type = mp11::mp_first<L>; - using next = mp11_iterator<mp11::mp_rest<L>>; -}; - -} // namespace aux - -// at - -template< typename Tag > struct at_impl; - -template<> struct at_impl<aux::mp11_tag> -{ - template<class L, class I> struct apply - { - using type = mp11::mp_at<L, I>; - }; -}; - -// back - -template< typename Tag > struct back_impl; - -template<> struct back_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using N = mp11::mp_size<L>; - using type = mp11::mp_at_c<L, N::value - 1>; - }; -}; - -// begin - -template< typename Tag > struct begin_impl; - -template<> struct begin_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = aux::mp11_iterator<L>; - }; -}; - -// clear - -template< typename Tag > struct clear_impl; - -template<> struct clear_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = mp11::mp_clear<L>; - }; -}; - -// end - -template< typename Tag > struct end_impl; - -template<> struct end_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = aux::mp11_iterator<mp11::mp_clear<L>>; - }; -}; - -// front - -template< typename Tag > struct front_impl; - -template<> struct front_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = mp11::mp_front<L>; - }; -}; - -// pop_front - -template< typename Tag > struct pop_front_impl; - -template<> struct pop_front_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = mp11::mp_pop_front<L>; - }; -}; - -// push_back - -template< typename Tag > struct push_back_impl; - -template<> struct push_back_impl<aux::mp11_tag> -{ - template<class L, class T> struct apply - { - using type = mp11::mp_push_back<L, T>; - }; -}; - -// push_front - -template< typename Tag > struct push_front_impl; - -template<> struct push_front_impl<aux::mp11_tag> -{ - template<class L, class T> struct apply - { - using type = mp11::mp_push_front<L, T>; - }; -}; - -// size - -template< typename Tag > struct size_impl; - -template<> struct size_impl<aux::mp11_tag> -{ - template<class L> struct apply - { - using type = mp11::mp_size<L>; - }; -}; - -} // namespace mpl -} // namespace boost - -#endif // #ifndef BOOST_MP11_DETAIL_MPL_COMMON_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/function.hpp b/ThirdParty/boost/mp11/function.hpp deleted file mode 100644 index 1aeccac4ef51b858148af6ad948ec94a228cf4ed..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/function.hpp +++ /dev/null @@ -1,226 +0,0 @@ -#ifndef BOOST_MP11_FUNCTION_HPP_INCLUDED -#define BOOST_MP11_FUNCTION_HPP_INCLUDED - -// Copyright 2015-2019 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/mp11/integral.hpp> -#include <boost/mp11/utility.hpp> -#include <boost/mp11/detail/mp_list.hpp> -#include <boost/mp11/detail/mp_count.hpp> -#include <boost/mp11/detail/mp_plus.hpp> -#include <boost/mp11/detail/mp_min_element.hpp> -#include <boost/mp11/detail/mp_void.hpp> -#include <boost/mp11/detail/config.hpp> -#include <type_traits> - -namespace boost -{ -namespace mp11 -{ - -// mp_void<T...> -// in detail/mp_void.hpp - -// mp_and<T...> -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1910 ) - -namespace detail -{ - -template<class... T> struct mp_and_impl; - -} // namespace detail - -template<class... T> using mp_and = mp_to_bool< typename detail::mp_and_impl<T...>::type >; - -namespace detail -{ - -template<> struct mp_and_impl<> -{ - using type = mp_true; -}; - -template<class T> struct mp_and_impl<T> -{ - using type = T; -}; - -template<class T1, class... T> struct mp_and_impl<T1, T...> -{ - using type = mp_eval_if< mp_not<T1>, T1, mp_and, T... >; -}; - -} // namespace detail - -#else - -namespace detail -{ - -template<class L, class E = void> struct mp_and_impl -{ - using type = mp_false; -}; - -template<class... T> struct mp_and_impl< mp_list<T...>, mp_void<mp_if<T, void>...> > -{ - using type = mp_true; -}; - -} // namespace detail - -template<class... T> using mp_and = typename detail::mp_and_impl<mp_list<T...>>::type; - -#endif - -// mp_all<T...> -// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86355 -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) || BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, != 0 ) - -template<class... T> using mp_all = mp_bool< mp_count_if< mp_list<T...>, mp_not >::value == 0 >; - -#elif defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) - -template<class... T> using mp_all = mp_bool<(static_cast<bool>(T::value) && ...)>; - -#else - -template<class... T> using mp_all = mp_and<mp_to_bool<T>...>; - -#endif - -// mp_or<T...> -namespace detail -{ - -template<class... T> struct mp_or_impl; - -} // namespace detail - -template<class... T> using mp_or = mp_to_bool< typename detail::mp_or_impl<T...>::type >; - -namespace detail -{ - -template<> struct mp_or_impl<> -{ - using type = mp_false; -}; - -template<class T> struct mp_or_impl<T> -{ - using type = T; -}; - -template<class T1, class... T> struct mp_or_impl<T1, T...> -{ - using type = mp_eval_if< T1, T1, mp_or, T... >; -}; - -} // namespace detail - -// mp_any<T...> -// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86356 -#if defined( BOOST_MP11_HAS_FOLD_EXPRESSIONS ) && !BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, != 0 ) && !BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1920 ) - -template<class... T> using mp_any = mp_bool<(static_cast<bool>(T::value) || ...)>; - -#else - -template<class... T> using mp_any = mp_bool< mp_count_if< mp_list<T...>, mp_to_bool >::value != 0 >; - -#endif - -// mp_same<T...> -namespace detail -{ - -template<class... T> struct mp_same_impl; - -template<> struct mp_same_impl<> -{ - using type = mp_true; -}; - -template<class T1, class... T> struct mp_same_impl<T1, T...> -{ - using type = mp_all<std::is_same<T1, T>...>; -}; - -} // namespace detail - -template<class... T> using mp_same = typename detail::mp_same_impl<T...>::type; - -// mp_similar<T...> -namespace detail -{ - -template<class... T> struct mp_similar_impl; - -template<> struct mp_similar_impl<> -{ - using type = mp_true; -}; - -template<class T> struct mp_similar_impl<T> -{ - using type = mp_true; -}; - -template<class T> struct mp_similar_impl<T, T> -{ - using type = mp_true; -}; - -template<class T1, class T2> struct mp_similar_impl<T1, T2> -{ - using type = mp_false; -}; - -template<template<class...> class L, class... T1, class... T2> struct mp_similar_impl<L<T1...>, L<T2...>> -{ - using type = mp_true; -}; - -template<template<class...> class L, class... T> struct mp_similar_impl<L<T...>, L<T...>> -{ - using type = mp_true; -}; - -template<class T1, class T2, class T3, class... T> struct mp_similar_impl<T1, T2, T3, T...> -{ - using type = mp_all< typename mp_similar_impl<T1, T2>::type, typename mp_similar_impl<T1, T3>::type, typename mp_similar_impl<T1, T>::type... >; -}; - -} // namespace detail - -template<class... T> using mp_similar = typename detail::mp_similar_impl<T...>::type; - -#if BOOST_MP11_GCC -# pragma GCC diagnostic push -# pragma GCC diagnostic ignored "-Wsign-compare" -#endif - -// mp_less<T1, T2> -template<class T1, class T2> using mp_less = mp_bool<(T1::value < 0 && T2::value >= 0) || ((T1::value < T2::value) && !(T1::value >= 0 && T2::value < 0))>; - -#if BOOST_MP11_GCC -# pragma GCC diagnostic pop -#endif - -// mp_min<T...> -template<class T1, class... T> using mp_min = mp_min_element<mp_list<T1, T...>, mp_less>; - -// mp_max<T...> -template<class T1, class... T> using mp_max = mp_max_element<mp_list<T1, T...>, mp_less>; - -} // namespace mp11 -} // namespace boost - -#endif // #ifndef BOOST_MP11_FUNCTION_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/mpl.hpp b/ThirdParty/boost/mp11/mpl.hpp deleted file mode 100644 index 994705ffc4d516110409042deb94e7bc18d08772..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/mpl.hpp +++ /dev/null @@ -1,14 +0,0 @@ -#ifndef BOOST_MP11_MPL_HPP_INCLUDED -#define BOOST_MP11_MPL_HPP_INCLUDED - -// Copyright 2017, 2019 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/mp11/mpl_list.hpp> -#include <boost/mp11/mpl_tuple.hpp> - -#endif // #ifndef BOOST_MP11_MPL_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/mpl_list.hpp b/ThirdParty/boost/mp11/mpl_list.hpp deleted file mode 100644 index 643da43a08a75eb616165152b1f1f425fc0f55b3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/mpl_list.hpp +++ /dev/null @@ -1,28 +0,0 @@ -#ifndef BOOST_MP11_MPL_LIST_HPP_INCLUDED -#define BOOST_MP11_MPL_LIST_HPP_INCLUDED - -// Copyright 2017, 2019 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/mp11/detail/mpl_common.hpp> - -namespace boost -{ -namespace mpl -{ - -template< typename Sequence > struct sequence_tag; - -template<class... T> struct sequence_tag<mp11::mp_list<T...>> -{ - using type = aux::mp11_tag; -}; - -} // namespace mpl -} // namespace boost - -#endif // #ifndef BOOST_MP11_MPL_LIST_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/mpl_tuple.hpp b/ThirdParty/boost/mp11/mpl_tuple.hpp deleted file mode 100644 index b6900b1cd4213c991023c27d3a1897182ec4a871..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/mpl_tuple.hpp +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef BOOST_MP11_MPL_TUPLE_HPP_INCLUDED -#define BOOST_MP11_MPL_TUPLE_HPP_INCLUDED - -// Copyright 2017, 2019 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/mp11/detail/mpl_common.hpp> -#include <tuple> - -namespace boost -{ -namespace mpl -{ - -template< typename Sequence > struct sequence_tag; - -template<class... T> struct sequence_tag<std::tuple<T...>> -{ - using type = aux::mp11_tag; -}; - -} // namespace mpl -} // namespace boost - -#endif // #ifndef BOOST_MP11_MPL_TUPLE_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/utility.hpp b/ThirdParty/boost/mp11/utility.hpp deleted file mode 100644 index a8a32fb09f458592012ee9eb048f08c2aa524116..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/utility.hpp +++ /dev/null @@ -1,275 +0,0 @@ -#ifndef BOOST_MP11_UTILITY_HPP_INCLUDED -#define BOOST_MP11_UTILITY_HPP_INCLUDED - -// Copyright 2015-2020 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/mp11/integral.hpp> -#include <boost/mp11/detail/mp_list.hpp> -#include <boost/mp11/detail/mp_fold.hpp> -#include <boost/mp11/detail/config.hpp> - -namespace boost -{ -namespace mp11 -{ - -// mp_identity -template<class T> struct mp_identity -{ - using type = T; -}; - -// mp_identity_t -template<class T> using mp_identity_t = typename mp_identity<T>::type; - -// mp_inherit -template<class... T> struct mp_inherit: T... {}; - -// mp_if, mp_if_c -namespace detail -{ - -template<bool C, class T, class... E> struct mp_if_c_impl -{ -}; - -template<class T, class... E> struct mp_if_c_impl<true, T, E...> -{ - using type = T; -}; - -template<class T, class E> struct mp_if_c_impl<false, T, E> -{ - using type = E; -}; - -} // namespace detail - -template<bool C, class T, class... E> using mp_if_c = typename detail::mp_if_c_impl<C, T, E...>::type; -template<class C, class T, class... E> using mp_if = typename detail::mp_if_c_impl<static_cast<bool>(C::value), T, E...>::type; - -// mp_valid - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_INTEL, != 0 ) // tested at 1800 - -// contributed by Roland Schulz in https://github.com/boostorg/mp11/issues/17 - -namespace detail -{ - -template<class...> using void_t = void; - -template<class, template<class...> class F, class... T> -struct mp_valid_impl: mp_false {}; - -template<template<class...> class F, class... T> -struct mp_valid_impl<void_t<F<T...>>, F, T...>: mp_true {}; - -} // namespace detail - -template<template<class...> class F, class... T> using mp_valid = typename detail::mp_valid_impl<void, F, T...>; - -#else - -// implementation by Bruno Dutra (by the name is_evaluable) -namespace detail -{ - -template<template<class...> class F, class... T> struct mp_valid_impl -{ - template<template<class...> class G, class = G<T...>> static mp_true check(int); - template<template<class...> class> static mp_false check(...); - - using type = decltype(check<F>(0)); -}; - -} // namespace detail - -template<template<class...> class F, class... T> using mp_valid = typename detail::mp_valid_impl<F, T...>::type; - -#endif - -template<class Q, class... T> using mp_valid_q = mp_valid<Q::template fn, T...>; - -// mp_defer -namespace detail -{ - -template<template<class...> class F, class... T> struct mp_defer_impl -{ - using type = F<T...>; -}; - -struct mp_no_type -{ -}; - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<template<class...> class F, class... T> struct mp_defer_cuda_workaround -{ - using type = mp_if<mp_valid<F, T...>, detail::mp_defer_impl<F, T...>, detail::mp_no_type>; -}; - -#endif - -} // namespace detail - -#if BOOST_MP11_WORKAROUND( BOOST_MP11_CUDA, >= 9000000 && BOOST_MP11_CUDA < 10000000 ) - -template<template<class...> class F, class... T> using mp_defer = typename detail::mp_defer_cuda_workaround< F, T...>::type; - -#else - -template<template<class...> class F, class... T> using mp_defer = mp_if<mp_valid<F, T...>, detail::mp_defer_impl<F, T...>, detail::mp_no_type>; - -#endif - -// mp_eval_if, mp_eval_if_c -namespace detail -{ - -template<bool C, class T, template<class...> class F, class... U> struct mp_eval_if_c_impl; - -template<class T, template<class...> class F, class... U> struct mp_eval_if_c_impl<true, T, F, U...> -{ - using type = T; -}; - -template<class T, template<class...> class F, class... U> struct mp_eval_if_c_impl<false, T, F, U...>: mp_defer<F, U...> -{ -}; - -} // namespace detail - -template<bool C, class T, template<class...> class F, class... U> using mp_eval_if_c = typename detail::mp_eval_if_c_impl<C, T, F, U...>::type; -template<class C, class T, template<class...> class F, class... U> using mp_eval_if = typename detail::mp_eval_if_c_impl<static_cast<bool>(C::value), T, F, U...>::type; -template<class C, class T, class Q, class... U> using mp_eval_if_q = typename detail::mp_eval_if_c_impl<static_cast<bool>(C::value), T, Q::template fn, U...>::type; - -// mp_eval_if_not -template<class C, class T, template<class...> class F, class... U> using mp_eval_if_not = mp_eval_if<mp_not<C>, T, F, U...>; -template<class C, class T, class Q, class... U> using mp_eval_if_not_q = mp_eval_if<mp_not<C>, T, Q::template fn, U...>; - -// mp_eval_or -template<class T, template<class...> class F, class... U> using mp_eval_or = mp_eval_if_not<mp_valid<F, U...>, T, F, U...>; -template<class T, class Q, class... U> using mp_eval_or_q = mp_eval_or<T, Q::template fn, U...>; - -// mp_cond - -// so elegant; so doesn't work -// template<class C, class T, class... E> using mp_cond = mp_eval_if<C, T, mp_cond, E...>; - -namespace detail -{ - -template<class C, class T, class... E> struct mp_cond_impl; - -} // namespace detail - -template<class C, class T, class... E> using mp_cond = typename detail::mp_cond_impl<C, T, E...>::type; - -namespace detail -{ - -template<class C, class T, class... E> using mp_cond_ = mp_eval_if<C, T, mp_cond, E...>; - -template<class C, class T, class... E> struct mp_cond_impl: mp_defer<mp_cond_, C, T, E...> -{ -}; - -} // namespace detail - -// mp_quote -template<template<class...> class F> struct mp_quote -{ - // the indirection through mp_defer works around the language inability - // to expand T... into a fixed parameter list of an alias template - - template<class... T> using fn = typename mp_defer<F, T...>::type; -}; - -// mp_quote_trait -template<template<class...> class F> struct mp_quote_trait -{ - template<class... T> using fn = typename F<T...>::type; -}; - -// mp_invoke_q -#if BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1900 ) - -namespace detail -{ - -template<class Q, class... T> struct mp_invoke_q_impl: mp_defer<Q::template fn, T...> {}; - -} // namespace detail - -template<class Q, class... T> using mp_invoke_q = typename detail::mp_invoke_q_impl<Q, T...>::type; - -#elif BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, < 50000 ) - -template<class Q, class... T> using mp_invoke_q = typename mp_defer<Q::template fn, T...>::type; - -#else - -template<class Q, class... T> using mp_invoke_q = typename Q::template fn<T...>; - -#endif - -// old name for mp_invoke_q retained for compatibility, but deprecated -#if !defined(__clang__) - -template<class Q, class... T> using mp_invoke BOOST_MP11_DEPRECATED("please use mp_invoke_q") = mp_invoke_q<Q, T...>; - -#else - -// Clang doesn't warn on deprecated alias templates - -template<class Q, class... T> struct BOOST_MP11_DEPRECATED("please use mp_invoke_q") mp_invoke_ -{ - using type = mp_invoke_q<Q, T...>; -}; - -template<class Q, class... T> using mp_invoke = typename mp_invoke_<Q, T...>::type; - -#endif - -// mp_not_fn<P> -template<template<class...> class P> struct mp_not_fn -{ - template<class... T> using fn = mp_not< mp_invoke_q<mp_quote<P>, T...> >; -}; - -template<class Q> using mp_not_fn_q = mp_not_fn<Q::template fn>; - -// mp_compose -namespace detail -{ - -template<class T, class Q> using mp_reverse_invoke_q = mp_invoke_q<Q, T>; - -} // namespace detail - -#if !BOOST_MP11_WORKAROUND( BOOST_MP11_MSVC, < 1900 ) - -template<template<class...> class... F> struct mp_compose -{ - template<class T> using fn = mp_fold<mp_list<mp_quote<F>...>, T, detail::mp_reverse_invoke_q>; -}; - -#endif - -template<class... Q> struct mp_compose_q -{ - template<class T> using fn = mp_fold<mp_list<Q...>, T, detail::mp_reverse_invoke_q>; -}; - -} // namespace mp11 -} // namespace boost - -#endif // #ifndef BOOST_MP11_UTILITY_HPP_INCLUDED diff --git a/ThirdParty/boost/mp11/version.hpp b/ThirdParty/boost/mp11/version.hpp deleted file mode 100644 index 3eba11031026729f4e2b2f33ae7ae146a1fab48c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mp11/version.hpp +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef BOOST_MP11_VERSION_HPP_INCLUDED -#define BOOST_MP11_VERSION_HPP_INCLUDED - -// Copyright 2019 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 - -// Same format as BOOST_VERSION: -// major * 100000 + minor * 100 + patch - -#define BOOST_MP11_VERSION 107300 - -#endif // #ifndef BOOST_MP11_VERSION_HPP_INCLUDED diff --git a/ThirdParty/boost/mpl/if.hpp b/ThirdParty/boost/mpl/if.hpp deleted file mode 100644 index 3b0ae19228e92ee73bd367880a58fd68582da69c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/mpl/if.hpp +++ /dev/null @@ -1,135 +0,0 @@ - -#ifndef BOOST_MPL_IF_HPP_INCLUDED -#define BOOST_MPL_IF_HPP_INCLUDED - -// Copyright Aleksey Gurtovoy 2000-2004 -// -// 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) -// -// See http://www.boost.org/libs/mpl for documentation. - -// $Id$ -// $Date$ -// $Revision$ - -#include <boost/mpl/aux_/value_wknd.hpp> -#include <boost/mpl/aux_/static_cast.hpp> -#include <boost/mpl/aux_/na_spec.hpp> -#include <boost/mpl/aux_/lambda_support.hpp> -#include <boost/mpl/aux_/config/integral.hpp> -#include <boost/mpl/aux_/config/ctps.hpp> -#include <boost/mpl/aux_/config/workaround.hpp> - -namespace boost { namespace mpl { - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - -template< - bool C - , typename T1 - , typename T2 - > -struct if_c -{ - typedef T1 type; -}; - -template< - typename T1 - , typename T2 - > -struct if_c<false,T1,T2> -{ - typedef T2 type; -}; - -// agurt, 05/sep/04: nondescriptive parameter names for the sake of DigitalMars -// (and possibly MWCW < 8.0); see https://lists.boost.org/Archives/boost/2004/09/71383.php -template< - typename BOOST_MPL_AUX_NA_PARAM(T1) - , typename BOOST_MPL_AUX_NA_PARAM(T2) - , typename BOOST_MPL_AUX_NA_PARAM(T3) - > -struct if_ -{ - private: - // agurt, 02/jan/03: two-step 'type' definition for the sake of aCC - typedef if_c< -#if defined(BOOST_MPL_CFG_BCC_INTEGRAL_CONSTANTS) - BOOST_MPL_AUX_VALUE_WKND(T1)::value -#else - BOOST_MPL_AUX_STATIC_CAST(bool, BOOST_MPL_AUX_VALUE_WKND(T1)::value) -#endif - , T2 - , T3 - > almost_type_; - - public: - typedef typename almost_type_::type type; - - BOOST_MPL_AUX_LAMBDA_SUPPORT(3,if_,(T1,T2,T3)) -}; - -#else - -// no partial class template specialization - -namespace aux { - -template< bool C > -struct if_impl -{ - template< typename T1, typename T2 > struct result_ - { - typedef T1 type; - }; -}; - -template<> -struct if_impl<false> -{ - template< typename T1, typename T2 > struct result_ - { - typedef T2 type; - }; -}; - -} // namespace aux - -template< - bool C_ - , typename T1 - , typename T2 - > -struct if_c -{ - typedef typename aux::if_impl< C_ > - ::template result_<T1,T2>::type type; -}; - -// (almost) copy & paste in order to save one more -// recursively nested template instantiation to user -template< - typename BOOST_MPL_AUX_NA_PARAM(C_) - , typename BOOST_MPL_AUX_NA_PARAM(T1) - , typename BOOST_MPL_AUX_NA_PARAM(T2) - > -struct if_ -{ - enum { msvc_wknd_ = BOOST_MPL_AUX_MSVC_VALUE_WKND(C_)::value }; - - typedef typename aux::if_impl< BOOST_MPL_AUX_STATIC_CAST(bool, msvc_wknd_) > - ::template result_<T1,T2>::type type; - - BOOST_MPL_AUX_LAMBDA_SUPPORT(3,if_,(C_,T1,T2)) -}; - -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -BOOST_MPL_AUX_NA_SPEC(3, if_) - -}} - -#endif // BOOST_MPL_IF_HPP_INCLUDED diff --git a/ThirdParty/boost/none.hpp b/ThirdParty/boost/none.hpp deleted file mode 100644 index b5df2143b10900276f170d4753d21d57da138bd6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/none.hpp +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (C) 2003, Fernando Luis Cacciola Carballal. -// Copyright (C) 2014, 2015 Andrzej Krzemienski. -// -// 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) -// -// See http://www.boost.org/libs/optional for documentation. -// -// You are welcome to contact the author at: -// fernando_cacciola@hotmail.com -// -#ifndef BOOST_NONE_17SEP2003_HPP -#define BOOST_NONE_17SEP2003_HPP - -#include "boost/config.hpp" -#include "boost/none_t.hpp" - -// NOTE: Borland users have to include this header outside any precompiled headers -// (bcc<=5.64 cannot include instance data in a precompiled header) -// -- * To be verified, now that there's no unnamed namespace - -namespace boost { - -#ifdef BOOST_OPTIONAL_USE_OLD_DEFINITION_OF_NONE - -BOOST_INLINE_VARIABLE none_t const none = (static_cast<none_t>(0)) ; - -#elif defined BOOST_OPTIONAL_USE_SINGLETON_DEFINITION_OF_NONE - -namespace detail { namespace optional_detail { - - // the trick here is to make boost::none defined once as a global but in a header file - template <typename T> - struct none_instance - { - static const T instance; - }; - - template <typename T> - const T none_instance<T>::instance = T(); // global, but because 'tis a template, no cpp file required - -} } // namespace detail::optional_detail - - -namespace { - // TU-local - const none_t& none = detail::optional_detail::none_instance<none_t>::instance; -} - -#else - -BOOST_INLINE_VARIABLE const none_t none ((none_t::init_tag())); - -#endif // older definitions - -} // namespace boost - -#endif // header guard - diff --git a/ThirdParty/boost/numeric/conversion/converter_policies.hpp b/ThirdParty/boost/numeric/conversion/converter_policies.hpp deleted file mode 100644 index 1619d64df63ae7b3024ddcf086308da8d5f88ac0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/numeric/conversion/converter_policies.hpp +++ /dev/null @@ -1,195 +0,0 @@ -// (c) Copyright Fernando Luis Cacciola Carballal 2000-2004 -// Use, modification, and distribution is subject to 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) - -// See library home page at http://www.boost.org/libs/numeric/conversion -// -// Contact the author at: fernando_cacciola@hotmail.com -// -#ifndef BOOST_NUMERIC_CONVERSION_CONVERTER_POLICIES_FLC_12NOV2002_HPP -#define BOOST_NUMERIC_CONVERSION_CONVERTER_POLICIES_FLC_12NOV2002_HPP - -#include <typeinfo> // for std::bad_cast - -#include <boost/config.hpp> -#include <boost/config/no_tr1/cmath.hpp> // for std::floor and std::ceil -#include <boost/throw_exception.hpp> - -#include <functional> - -#include "boost/type_traits/is_arithmetic.hpp" - -#include "boost/mpl/if.hpp" -#include "boost/mpl/integral_c.hpp" - -namespace boost { namespace numeric -{ - -template<class S> -struct Trunc -{ - typedef S source_type ; - - typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; - - static source_type nearbyint ( argument_type s ) - { -#if !defined(BOOST_NO_STDC_NAMESPACE) - using std::floor ; - using std::ceil ; -#endif - - return s < static_cast<S>(0) ? ceil(s) : floor(s) ; - } - - typedef mpl::integral_c< std::float_round_style, std::round_toward_zero> round_style ; -} ; - - - -template<class S> -struct Floor -{ - typedef S source_type ; - - typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; - - static source_type nearbyint ( argument_type s ) - { -#if !defined(BOOST_NO_STDC_NAMESPACE) - using std::floor ; -#endif - - return floor(s) ; - } - - typedef mpl::integral_c< std::float_round_style, std::round_toward_neg_infinity> round_style ; -} ; - -template<class S> -struct Ceil -{ - typedef S source_type ; - - typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; - - static source_type nearbyint ( argument_type s ) - { -#if !defined(BOOST_NO_STDC_NAMESPACE) - using std::ceil ; -#endif - - return ceil(s) ; - } - - typedef mpl::integral_c< std::float_round_style, std::round_toward_infinity> round_style ; -} ; - -template<class S> -struct RoundEven -{ - typedef S source_type ; - - typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; - - static source_type nearbyint ( argument_type s ) - { - // Algorithm contributed by Guillaume Melquiond - -#if !defined(BOOST_NO_STDC_NAMESPACE) - using std::floor ; - using std::ceil ; -#endif - - // only works inside the range not at the boundaries - S prev = floor(s); - S next = ceil(s); - - S rt = (s - prev) - (next - s); // remainder type - - S const zero(0.0); - S const two(2.0); - - if ( rt < zero ) - return prev; - else if ( rt > zero ) - return next; - else - { - bool is_prev_even = two * floor(prev / two) == prev ; - return ( is_prev_even ? prev : next ) ; - } - } - - typedef mpl::integral_c< std::float_round_style, std::round_to_nearest> round_style ; -} ; - - -enum range_check_result -{ - cInRange = 0 , - cNegOverflow = 1 , - cPosOverflow = 2 -} ; - -class bad_numeric_cast : public std::bad_cast -{ - public: - - virtual const char * what() const BOOST_NOEXCEPT_OR_NOTHROW - { return "bad numeric conversion: overflow"; } -}; - -class negative_overflow : public bad_numeric_cast -{ - public: - - virtual const char * what() const BOOST_NOEXCEPT_OR_NOTHROW - { return "bad numeric conversion: negative overflow"; } -}; -class positive_overflow : public bad_numeric_cast -{ - public: - - virtual const char * what() const BOOST_NOEXCEPT_OR_NOTHROW - { return "bad numeric conversion: positive overflow"; } -}; - -struct def_overflow_handler -{ - void operator() ( range_check_result r ) // throw(negative_overflow,positive_overflow) - { -#ifndef BOOST_NO_EXCEPTIONS - if ( r == cNegOverflow ) - throw negative_overflow() ; - else if ( r == cPosOverflow ) - throw positive_overflow() ; -#else - if ( r == cNegOverflow ) - ::boost::throw_exception(negative_overflow()) ; - else if ( r == cPosOverflow ) - ::boost::throw_exception(positive_overflow()) ; -#endif - } -} ; - -struct silent_overflow_handler -{ - void operator() ( range_check_result ) {} // throw() -} ; - -template<class Traits> -struct raw_converter -{ - typedef typename Traits::result_type result_type ; - typedef typename Traits::argument_type argument_type ; - - static result_type low_level_convert ( argument_type s ) { return static_cast<result_type>(s) ; } -} ; - -struct UseInternalRangeChecker {} ; - -} } // namespace boost::numeric - -#endif diff --git a/ThirdParty/boost/optional/bad_optional_access.hpp b/ThirdParty/boost/optional/bad_optional_access.hpp deleted file mode 100644 index add7867545f0b1f8e74ddf0ddeefe9bab190c2cf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/optional/bad_optional_access.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright (C) 2014, Andrzej Krzemienski. -// -// Use, modification, and distribution is subject to 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) -// -// See http://www.boost.org/libs/optional for documentation. -// -// You are welcome to contact the author at: -// akrzemi1@gmail.com -// -#ifndef BOOST_BAD_OPTIONAL_ACCESS_22MAY2014_HPP -#define BOOST_BAD_OPTIONAL_ACCESS_22MAY2014_HPP - -#include <stdexcept> -#if __cplusplus < 201103L -#include <string> // to make converting-ctor std::string(char const*) visible -#endif - -namespace boost { - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Wweak-vtables" -#endif - -class bad_optional_access : public std::logic_error -{ -public: - bad_optional_access() - : std::logic_error("Attempted to access the value of an uninitialized optional object.") - {} -}; - -#if defined(__clang__) -# pragma clang diagnostic pop -#endif - -} // namespace boost - -#endif diff --git a/ThirdParty/boost/optional/detail/optional_trivially_copyable_base.hpp b/ThirdParty/boost/optional/detail/optional_trivially_copyable_base.hpp deleted file mode 100644 index 2cabf9a7c6c16b6c9e9e79a23fcdeb2943689943..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/optional/detail/optional_trivially_copyable_base.hpp +++ /dev/null @@ -1,499 +0,0 @@ -// trivilally-copyable version of the storage - -template<class T> -class tc_optional_base : public optional_tag -{ - private : - - typedef tc_optional_base<T> this_type ; - - protected : - - typedef T value_type ; - - protected: - typedef T & reference_type ; - typedef T const& reference_const_type ; -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - typedef T && rval_reference_type ; - typedef T && reference_type_of_temporary_wrapper ; -#endif - typedef T * pointer_type ; - typedef T const* pointer_const_type ; - typedef T const& argument_type ; - - tc_optional_base() - : - m_initialized(false) {} - - tc_optional_base ( none_t ) - : - m_initialized(false) {} - - tc_optional_base ( init_value_tag, argument_type val ) - : - m_initialized(true), m_storage(val) {} - - tc_optional_base ( bool cond, argument_type val ) - : - m_initialized(cond), m_storage(val) {} - - // tc_optional_base ( tc_optional_base const& ) = default; - - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - - template<class Expr, class PtrExpr> - explicit tc_optional_base ( Expr&& expr, PtrExpr const* tag ) - : - m_initialized(false) - { - construct(boost::forward<Expr>(expr),tag); - } - -#else - // This is used for both converting and in-place constructions. - // Derived classes use the 'tag' to select the appropriate - // implementation (the correct 'construct()' overload) - template<class Expr> - explicit tc_optional_base ( Expr const& expr, Expr const* tag ) - : - m_initialized(false) - { - construct(expr,tag); - } - -#endif - - // tc_optional_base& operator= ( tc_optional_base const& ) = default; - // ~tc_optional_base() = default; - - // Assigns from another optional<T> (deep-copies the rhs value) - void assign ( tc_optional_base const& rhs ) - { - *this = rhs; - } - - // Assigns from another _convertible_ optional<U> (deep-copies the rhs value) - template<class U> - void assign ( optional<U> const& rhs ) - { - if ( rhs.is_initialized() ) -#ifndef BOOST_OPTIONAL_CONFIG_RESTORE_ASSIGNMENT_OF_NONCONVERTIBLE_TYPES - m_storage = rhs.get(); -#else - m_storage = static_cast<value_type>(rhs.get()); -#endif - - m_initialized = rhs.is_initialized(); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // move-assigns from another _convertible_ optional<U> (deep-moves from the rhs value) - template<class U> - void assign ( optional<U>&& rhs ) - { - typedef BOOST_DEDUCED_TYPENAME optional<U>::rval_reference_type ref_type; - if ( rhs.is_initialized() ) - m_storage = static_cast<ref_type>(rhs.get()); - m_initialized = rhs.is_initialized(); - } -#endif - - void assign ( argument_type val ) - { - construct(val); - } - - void assign ( none_t ) { destroy(); } - -#ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - template<class Expr, class ExprPtr> - void assign_expr ( Expr&& expr, ExprPtr const* tag ) - { - construct(boost::forward<Expr>(expr),tag); - } -#else - template<class Expr> - void assign_expr ( Expr const& expr, Expr const* tag ) - { - construct(expr,tag); - } -#endif - -#endif - - public : - - // Destroys the current value, if any, leaving this UNINITIALIZED - // No-throw (assuming T::~T() doesn't) - void reset() BOOST_NOEXCEPT { destroy(); } - - // **DEPPRECATED** Replaces the current value -if any- with 'val' - void reset ( argument_type val ) BOOST_NOEXCEPT { assign(val); } - - // Returns a pointer to the value if this is initialized, otherwise, - // returns NULL. - // No-throw - pointer_const_type get_ptr() const { return m_initialized ? get_ptr_impl() : 0 ; } - pointer_type get_ptr() { return m_initialized ? get_ptr_impl() : 0 ; } - - bool is_initialized() const { return m_initialized ; } - - protected : - - void construct ( argument_type val ) - { - m_storage = val ; - m_initialized = true ; - } - - -#if (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) && (!defined BOOST_NO_CXX11_VARIADIC_TEMPLATES) - // Constructs in-place - // upon exception *this is always uninitialized - template<class... Args> - void construct ( in_place_init_t, Args&&... args ) - { - m_storage = value_type( boost::forward<Args>(args)... ) ; - m_initialized = true ; - } - - template<class... Args> - void emplace_assign ( Args&&... args ) - { - construct(in_place_init, boost::forward<Args>(args)...); - } - - template<class... Args> - explicit tc_optional_base ( in_place_init_t, Args&&... args ) - : - m_initialized(false) - { - construct(in_place_init, boost::forward<Args>(args)...); - } - - template<class... Args> - explicit tc_optional_base ( in_place_init_if_t, bool cond, Args&&... args ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init, boost::forward<Args>(args)...); - } -#elif (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - template<class Arg> - void construct ( in_place_init_t, Arg&& arg ) - { - m_storage = value_type( boost::forward<Arg>(arg) ); - m_initialized = true ; - } - - void construct ( in_place_init_t ) - { - m_storage = value_type(); - m_initialized = true ; - } - - template<class Arg> - void emplace_assign ( Arg&& arg ) - { - construct(in_place_init, boost::forward<Arg>(arg)) ; - } - - void emplace_assign () - { - construct(in_place_init) ; - } - - template<class Arg> - explicit tc_optional_base ( in_place_init_t, Arg&& arg ) - : - m_initialized(false) - { - construct(in_place_init, boost::forward<Arg>(arg)); - } - - explicit tc_optional_base ( in_place_init_t ) - : - m_initialized(false), m_storage() {} - - template<class Arg> - explicit tc_optional_base ( in_place_init_if_t, bool cond, Arg&& arg ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init, boost::forward<Arg>(arg)); - } - - explicit tc_optional_base ( in_place_init_if_t, bool cond ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init); - } - -#else - - template<class Arg> - void construct ( in_place_init_t, const Arg& arg ) - { - m_storage = value_type( arg ); - m_initialized = true ; - } - - template<class Arg> - void construct ( in_place_init_t, Arg& arg ) - { - m_storage = value_type( arg ); - m_initialized = true ; - } - - void construct ( in_place_init_t ) - { - m_storage = value_type(); - m_initialized = true ; - } - - template<class Arg> - void emplace_assign ( const Arg& arg ) - { - construct(in_place_init, arg); - } - - template<class Arg> - void emplace_assign ( Arg& arg ) - { - construct(in_place_init, arg); - } - - void emplace_assign () - { - construct(in_place_init); - } - - template<class Arg> - explicit tc_optional_base ( in_place_init_t, const Arg& arg ) - : m_initialized(false) - { - construct(in_place_init, arg); - } - - template<class Arg> - explicit tc_optional_base ( in_place_init_t, Arg& arg ) - : m_initialized(false) - { - construct(in_place_init, arg); - } - - explicit tc_optional_base ( in_place_init_t ) - : m_initialized(false) - { - construct(in_place_init); - } - - template<class Arg> - explicit tc_optional_base ( in_place_init_if_t, bool cond, const Arg& arg ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init, arg); - } - - template<class Arg> - explicit tc_optional_base ( in_place_init_if_t, bool cond, Arg& arg ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init, arg); - } - - explicit tc_optional_base ( in_place_init_if_t, bool cond ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init); - } -#endif - -#ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Constructs in-place using the given factory - template<class Expr> - void construct ( Expr&& factory, in_place_factory_base const* ) - { - boost_optional_detail::construct<value_type>(factory, boost::addressof(m_storage)); - m_initialized = true ; - } - - // Constructs in-place using the given typed factory - template<class Expr> - void construct ( Expr&& factory, typed_in_place_factory_base const* ) - { - factory.apply(boost::addressof(m_storage)) ; - m_initialized = true ; - } - - template<class Expr> - void assign_expr_to_initialized ( Expr&& factory, in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - - // Constructs in-place using the given typed factory - template<class Expr> - void assign_expr_to_initialized ( Expr&& factory, typed_in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - -#else - // Constructs in-place using the given factory - template<class Expr> - void construct ( Expr const& factory, in_place_factory_base const* ) - { - boost_optional_detail::construct<value_type>(factory, boost::addressof(m_storage)); - m_initialized = true ; - } - - // Constructs in-place using the given typed factory - template<class Expr> - void construct ( Expr const& factory, typed_in_place_factory_base const* ) - { - factory.apply(boost::addressof(m_storage)) ; - m_initialized = true ; - } - - template<class Expr> - void assign_expr_to_initialized ( Expr const& factory, in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - - // Constructs in-place using the given typed factory - template<class Expr> - void assign_expr_to_initialized ( Expr const& factory, typed_in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } -#endif - -#endif - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Constructs using any expression implicitly convertible to the single argument - // of a one-argument T constructor. - // Converting constructions of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting constructor of T from U. - template<class Expr> - void construct ( Expr&& expr, void const* ) - { - m_storage = value_type(boost::forward<Expr>(expr)) ; - m_initialized = true ; - } - - // Assigns using a form any expression implicitly convertible to the single argument - // of a T's assignment operator. - // Converting assignments of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting assignment of T from U. - template<class Expr> - void assign_expr_to_initialized ( Expr&& expr, void const* ) - { - assign_value( boost::forward<Expr>(expr) ); - } -#else - // Constructs using any expression implicitly convertible to the single argument - // of a one-argument T constructor. - // Converting constructions of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting constructor of T from U. - template<class Expr> - void construct ( Expr const& expr, void const* ) - { - m_storage = value_type(expr) ; - m_initialized = true ; - } - - // Assigns using a form any expression implicitly convertible to the single argument - // of a T's assignment operator. - // Converting assignments of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting assignment of T from U. - template<class Expr> - void assign_expr_to_initialized ( Expr const& expr, void const* ) - { - assign_value(expr); - } - -#endif - -#ifdef BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION - // BCB5.64 (and probably lower versions) workaround. - // The in-place factories are supported by means of catch-all constructors - // and assignment operators (the functions are parameterized in terms of - // an arbitrary 'Expr' type) - // This compiler incorrectly resolves the overload set and sinks optional<T> and optional<U> - // to the 'Expr'-taking functions even though explicit overloads are present for them. - // Thus, the following overload is needed to properly handle the case when the 'lhs' - // is another optional. - // - // For VC<=70 compilers this workaround dosen't work becasue the comnpiler issues and error - // instead of choosing the wrong overload - // -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Notice that 'Expr' will be optional<T> or optional<U> (but not tc_optional_base<..>) - template<class Expr> - void construct ( Expr&& expr, optional_tag const* ) - { - if ( expr.is_initialized() ) - { - // An exception can be thrown here. - // It it happens, THIS will be left uninitialized. - m_storage = value_type(boost::move(expr.get())) ; - m_initialized = true ; - } - } -#else - // Notice that 'Expr' will be optional<T> or optional<U> (but not tc_optional_base<..>) - template<class Expr> - void construct ( Expr const& expr, optional_tag const* ) - { - if ( expr.is_initialized() ) - { - // An exception can be thrown here. - // It it happens, THIS will be left uninitialized. - m_storage = value_type(expr.get()) ; - m_initialized = true ; - } - } -#endif -#endif // defined BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION - - void assign_value ( argument_type val ) { m_storage = val; } -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - void assign_value ( rval_reference_type val ) { m_storage = static_cast<rval_reference_type>(val); } -#endif - - void destroy() - { - m_initialized = false; - } - - reference_const_type get_impl() const { return m_storage ; } - reference_type get_impl() { return m_storage ; } - - pointer_const_type get_ptr_impl() const { return boost::addressof(m_storage); } - pointer_type get_ptr_impl() { return boost::addressof(m_storage); } - - private : - - bool m_initialized ; - T m_storage ; -} ; diff --git a/ThirdParty/boost/optional/optional.hpp b/ThirdParty/boost/optional/optional.hpp deleted file mode 100644 index aadc975a7ae098bf0f7c4d30ef8b144ec085a34f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/optional/optional.hpp +++ /dev/null @@ -1,1605 +0,0 @@ -// Copyright (C) 2003, 2008 Fernando Luis Cacciola Carballal. -// Copyright (C) 2014 - 2018 Andrzej Krzemienski. -// -// Use, modification, and distribution is subject to 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) -// -// See http://www.boost.org/libs/optional for documentation. -// -// You are welcome to contact the author at: -// fernando_cacciola@hotmail.com -// -// Revisions: -// 27 Apr 2008 (improved swap) Fernando Cacciola, Niels Dekker, Thorsten Ottosen -// 05 May 2014 (Added move semantics) Andrzej Krzemienski -// -#ifndef BOOST_OPTIONAL_OPTIONAL_FLC_19NOV2002_HPP -#define BOOST_OPTIONAL_OPTIONAL_FLC_19NOV2002_HPP - -#include <new> -#include <iosfwd> - -#ifdef BOOST_OPTIONAL_DETAIL_USE_STD_TYPE_TRAITS -# include <type_traits> -#endif - -#include <boost/assert.hpp> -#include <boost/core/addressof.hpp> -#include <boost/core/enable_if.hpp> -#include <boost/core/explicit_operator_bool.hpp> -#include <boost/core/swap.hpp> -#include <boost/optional/bad_optional_access.hpp> -#include <boost/static_assert.hpp> -#include <boost/throw_exception.hpp> -#include <boost/type.hpp> -#include <boost/type_traits/alignment_of.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/has_nothrow_constructor.hpp> -#include <boost/type_traits/type_with_alignment.hpp> -#include <boost/type_traits/remove_const.hpp> -#include <boost/type_traits/remove_reference.hpp> -#include <boost/type_traits/decay.hpp> -#include <boost/type_traits/is_base_of.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/is_constructible.hpp> -#include <boost/type_traits/is_lvalue_reference.hpp> -#include <boost/type_traits/is_nothrow_move_assignable.hpp> -#include <boost/type_traits/is_nothrow_move_constructible.hpp> -#include <boost/type_traits/is_rvalue_reference.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/is_volatile.hpp> -#include <boost/type_traits/is_scalar.hpp> -#include <boost/move/utility.hpp> -#include <boost/none.hpp> -#include <boost/utility/compare_pointees.hpp> -#include <boost/utility/result_of.hpp> - -#include <boost/optional/optional_fwd.hpp> -#include <boost/optional/detail/optional_config.hpp> -#include <boost/optional/detail/optional_factory_support.hpp> -#include <boost/optional/detail/optional_aligned_storage.hpp> - -namespace boost { namespace optional_detail { - -template <typename T> -struct optional_value_type -{ -}; - -template <typename T> -struct optional_value_type< ::boost::optional<T> > -{ - typedef T type; -}; - -}} // namespace boost::optional_detail - -#ifdef BOOST_OPTIONAL_CONFIG_USE_OLD_IMPLEMENTATION_OF_OPTIONAL -#include <boost/optional/detail/old_optional_implementation.hpp> -#else -namespace boost { - -namespace optional_ns { - -// a tag for in-place initialization of contained value -struct in_place_init_t -{ - struct init_tag{}; - explicit in_place_init_t(init_tag){} -}; -const in_place_init_t in_place_init ((in_place_init_t::init_tag())); - -// a tag for conditional in-place initialization of contained value -struct in_place_init_if_t -{ - struct init_tag{}; - explicit in_place_init_if_t(init_tag){} -}; -const in_place_init_if_t in_place_init_if ((in_place_init_if_t::init_tag())); - -} // namespace optional_ns - -using optional_ns::in_place_init_t; -using optional_ns::in_place_init; -using optional_ns::in_place_init_if_t; -using optional_ns::in_place_init_if; - -namespace optional_detail { - -struct init_value_tag {}; - -struct optional_tag {}; - - -template<class T> -class optional_base : public optional_tag -{ - private : - - typedef aligned_storage<T> storage_type ; - typedef optional_base<T> this_type ; - - protected : - - typedef T value_type ; - - protected: - typedef T & reference_type ; - typedef T const& reference_const_type ; -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - typedef T && rval_reference_type ; - typedef T && reference_type_of_temporary_wrapper ; -#endif - typedef T * pointer_type ; - typedef T const* pointer_const_type ; - typedef T const& argument_type ; - - // Creates an optional<T> uninitialized. - // No-throw - optional_base() - : - m_initialized(false) {} - - // Creates an optional<T> uninitialized. - // No-throw - optional_base ( none_t ) - : - m_initialized(false) {} - - // Creates an optional<T> initialized with 'val'. - // Can throw if T::T(T const&) does - optional_base ( init_value_tag, argument_type val ) - : - m_initialized(false) - { - construct(val); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // move-construct an optional<T> initialized from an rvalue-ref to 'val'. - // Can throw if T::T(T&&) does - optional_base ( init_value_tag, rval_reference_type val ) - : - m_initialized(false) - { - construct( boost::move(val) ); - } -#endif - - // Creates an optional<T> initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional<T>. - // Can throw if T::T(T const&) does - optional_base ( bool cond, argument_type val ) - : - m_initialized(false) - { - if ( cond ) - construct(val); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Creates an optional<T> initialized with 'move(val)' IFF cond is true, otherwise creates an uninitialized optional<T>. - // Can throw if T::T(T &&) does - optional_base ( bool cond, rval_reference_type val ) - : - m_initialized(false) - { - if ( cond ) - construct(boost::move(val)); - } -#endif - - // Creates a deep copy of another optional<T> - // Can throw if T::T(T const&) does - optional_base ( optional_base const& rhs ) - : - m_initialized(false) - { - if ( rhs.is_initialized() ) - construct(rhs.get_impl()); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Creates a deep move of another optional<T> - // Can throw if T::T(T&&) does - optional_base ( optional_base&& rhs ) - BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible<T>::value) - : - m_initialized(false) - { - if ( rhs.is_initialized() ) - construct( boost::move(rhs.get_impl()) ); - } -#endif - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - - template<class Expr, class PtrExpr> - explicit optional_base ( Expr&& expr, PtrExpr const* tag ) - : - m_initialized(false) - { - construct(boost::forward<Expr>(expr),tag); - } - -#else - // This is used for both converting and in-place constructions. - // Derived classes use the 'tag' to select the appropriate - // implementation (the correct 'construct()' overload) - template<class Expr> - explicit optional_base ( Expr const& expr, Expr const* tag ) - : - m_initialized(false) - { - construct(expr,tag); - } - -#endif - - optional_base& operator= ( optional_base const& rhs ) - { - this->assign(rhs); - return *this; - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - optional_base& operator= ( optional_base && rhs ) - BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible<T>::value && ::boost::is_nothrow_move_assignable<T>::value) - { - this->assign(static_cast<optional_base&&>(rhs)); - return *this; - } -#endif - - // No-throw (assuming T::~T() doesn't) - ~optional_base() { destroy() ; } - - // Assigns from another optional<T> (deep-copies the rhs value) - void assign ( optional_base const& rhs ) - { - if (is_initialized()) - { - if ( rhs.is_initialized() ) - assign_value(rhs.get_impl()); - else destroy(); - } - else - { - if ( rhs.is_initialized() ) - construct(rhs.get_impl()); - } - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Assigns from another optional<T> (deep-moves the rhs value) - void assign ( optional_base&& rhs ) - { - if (is_initialized()) - { - if ( rhs.is_initialized() ) - assign_value( boost::move(rhs.get_impl()) ); - else destroy(); - } - else - { - if ( rhs.is_initialized() ) - construct(boost::move(rhs.get_impl())); - } - } -#endif - - // Assigns from another _convertible_ optional<U> (deep-copies the rhs value) - template<class U> - void assign ( optional<U> const& rhs ) - { - if (is_initialized()) - { - if ( rhs.is_initialized() ) -#ifndef BOOST_OPTIONAL_CONFIG_RESTORE_ASSIGNMENT_OF_NONCONVERTIBLE_TYPES - assign_value( rhs.get() ); -#else - assign_value( static_cast<value_type>(rhs.get()) ); -#endif - - else destroy(); - } - else - { - if ( rhs.is_initialized() ) -#ifndef BOOST_OPTIONAL_CONFIG_RESTORE_ASSIGNMENT_OF_NONCONVERTIBLE_TYPES - construct(rhs.get()); -#else - construct(static_cast<value_type>(rhs.get())); -#endif - } - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // move-assigns from another _convertible_ optional<U> (deep-moves from the rhs value) - template<class U> - void assign ( optional<U>&& rhs ) - { - typedef BOOST_DEDUCED_TYPENAME optional<U>::rval_reference_type ref_type; - if (is_initialized()) - { - if ( rhs.is_initialized() ) - assign_value( static_cast<ref_type>(rhs.get()) ); - else destroy(); - } - else - { - if ( rhs.is_initialized() ) - construct(static_cast<ref_type>(rhs.get())); - } - } -#endif - - // Assigns from a T (deep-copies the rhs value) - void assign ( argument_type val ) - { - if (is_initialized()) - assign_value(val); - else construct(val); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Assigns from a T (deep-moves the rhs value) - void assign ( rval_reference_type val ) - { - if (is_initialized()) - assign_value( boost::move(val) ); - else construct( boost::move(val) ); - } -#endif - - // Assigns from "none", destroying the current value, if any, leaving this UNINITIALIZED - // No-throw (assuming T::~T() doesn't) - void assign ( none_t ) BOOST_NOEXCEPT { destroy(); } - -#ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - template<class Expr, class ExprPtr> - void assign_expr ( Expr&& expr, ExprPtr const* tag ) - { - if (is_initialized()) - assign_expr_to_initialized(boost::forward<Expr>(expr),tag); - else construct(boost::forward<Expr>(expr),tag); - } -#else - template<class Expr> - void assign_expr ( Expr const& expr, Expr const* tag ) - { - if (is_initialized()) - assign_expr_to_initialized(expr,tag); - else construct(expr,tag); - } -#endif - -#endif - - public : - - // Destroys the current value, if any, leaving this UNINITIALIZED - // No-throw (assuming T::~T() doesn't) - void reset() BOOST_NOEXCEPT { destroy(); } - - // **DEPPRECATED** Replaces the current value -if any- with 'val' - void reset ( argument_type val ) { assign(val); } - - // Returns a pointer to the value if this is initialized, otherwise, - // returns NULL. - // No-throw - pointer_const_type get_ptr() const { return m_initialized ? get_ptr_impl() : 0 ; } - pointer_type get_ptr() { return m_initialized ? get_ptr_impl() : 0 ; } - - bool is_initialized() const BOOST_NOEXCEPT { return m_initialized ; } - - protected : - - void construct ( argument_type val ) - { - ::new (m_storage.address()) value_type(val) ; - m_initialized = true ; - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - void construct ( rval_reference_type val ) - { - ::new (m_storage.address()) value_type( boost::move(val) ) ; - m_initialized = true ; - } -#endif - - -#if (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) && (!defined BOOST_NO_CXX11_VARIADIC_TEMPLATES) - // Constructs in-place - // upon exception *this is always uninitialized - template<class... Args> - void construct ( in_place_init_t, Args&&... args ) - { - ::new (m_storage.address()) value_type( boost::forward<Args>(args)... ) ; - m_initialized = true ; - } - - template<class... Args> - void emplace_assign ( Args&&... args ) - { - destroy(); - construct(in_place_init, boost::forward<Args>(args)...); - } - - template<class... Args> - explicit optional_base ( in_place_init_t, Args&&... args ) - : - m_initialized(false) - { - construct(in_place_init, boost::forward<Args>(args)...); - } - - template<class... Args> - explicit optional_base ( in_place_init_if_t, bool cond, Args&&... args ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init, boost::forward<Args>(args)...); - } -#elif (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - template<class Arg> - void construct ( in_place_init_t, Arg&& arg ) - { - ::new (m_storage.address()) value_type( boost::forward<Arg>(arg) ); - m_initialized = true ; - } - - void construct ( in_place_init_t ) - { - ::new (m_storage.address()) value_type(); - m_initialized = true ; - } - - template<class Arg> - void emplace_assign ( Arg&& arg ) - { - destroy(); - construct(in_place_init, boost::forward<Arg>(arg)) ; - } - - void emplace_assign () - { - destroy(); - construct(in_place_init) ; - } - - template<class Arg> - explicit optional_base ( in_place_init_t, Arg&& arg ) - : - m_initialized(false) - { - construct(in_place_init, boost::forward<Arg>(arg)); - } - - explicit optional_base ( in_place_init_t ) - : - m_initialized(false) - { - construct(in_place_init); - } - - template<class Arg> - explicit optional_base ( in_place_init_if_t, bool cond, Arg&& arg ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init, boost::forward<Arg>(arg)); - } - - explicit optional_base ( in_place_init_if_t, bool cond ) - : - m_initialized(false) - { - if ( cond ) - construct(in_place_init); - } - -#else - - template<class Arg> - void construct ( in_place_init_t, const Arg& arg ) - { - ::new (m_storage.address()) value_type( arg ); - m_initialized = true ; - } - - template<class Arg> - void construct ( in_place_init_t, Arg& arg ) - { - ::new (m_storage.address()) value_type( arg ); - m_initialized = true ; - } - - void construct ( in_place_init_t ) - { - ::new (m_storage.address()) value_type(); - m_initialized = true ; - } - - template<class Arg> - void emplace_assign ( const Arg& arg ) - { - destroy(); - construct(in_place_init, arg); - } - - template<class Arg> - void emplace_assign ( Arg& arg ) - { - destroy(); - construct(in_place_init, arg); - } - - void emplace_assign () - { - destroy(); - construct(in_place_init); - } - - template<class Arg> - explicit optional_base ( in_place_init_t, const Arg& arg ) - : m_initialized(false) - { - construct(in_place_init, arg); - } - - template<class Arg> - explicit optional_base ( in_place_init_t, Arg& arg ) - : m_initialized(false) - { - construct(in_place_init, arg); - } - - explicit optional_base ( in_place_init_t ) - : m_initialized(false) - { - construct(in_place_init); - } - - template<class Arg> - explicit optional_base ( in_place_init_if_t, bool cond, const Arg& arg ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init, arg); - } - - template<class Arg> - explicit optional_base ( in_place_init_if_t, bool cond, Arg& arg ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init, arg); - } - - explicit optional_base ( in_place_init_if_t, bool cond ) - : m_initialized(false) - { - if ( cond ) - construct(in_place_init); - } -#endif - -#ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Constructs in-place using the given factory - template<class Expr> - void construct ( Expr&& factory, in_place_factory_base const* ) - { - boost_optional_detail::construct<value_type>(factory, m_storage.address()); - m_initialized = true ; - } - - // Constructs in-place using the given typed factory - template<class Expr> - void construct ( Expr&& factory, typed_in_place_factory_base const* ) - { - factory.apply(m_storage.address()) ; - m_initialized = true ; - } - - template<class Expr> - void assign_expr_to_initialized ( Expr&& factory, in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - - // Constructs in-place using the given typed factory - template<class Expr> - void assign_expr_to_initialized ( Expr&& factory, typed_in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - -#else - // Constructs in-place using the given factory - template<class Expr> - void construct ( Expr const& factory, in_place_factory_base const* ) - { - boost_optional_detail::construct<value_type>(factory, m_storage.address()); - m_initialized = true ; - } - - // Constructs in-place using the given typed factory - template<class Expr> - void construct ( Expr const& factory, typed_in_place_factory_base const* ) - { - factory.apply(m_storage.address()) ; - m_initialized = true ; - } - - template<class Expr> - void assign_expr_to_initialized ( Expr const& factory, in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } - - // Constructs in-place using the given typed factory - template<class Expr> - void assign_expr_to_initialized ( Expr const& factory, typed_in_place_factory_base const* tag ) - { - destroy(); - construct(factory,tag); - } -#endif - -#endif - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Constructs using any expression implicitly convertible to the single argument - // of a one-argument T constructor. - // Converting constructions of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting constructor of T from U. - template<class Expr> - void construct ( Expr&& expr, void const* ) - { - new (m_storage.address()) value_type(boost::forward<Expr>(expr)) ; - m_initialized = true ; - } - - // Assigns using a form any expression implicitly convertible to the single argument - // of a T's assignment operator. - // Converting assignments of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting assignment of T from U. - template<class Expr> - void assign_expr_to_initialized ( Expr&& expr, void const* ) - { - assign_value( boost::forward<Expr>(expr) ); - } -#else - // Constructs using any expression implicitly convertible to the single argument - // of a one-argument T constructor. - // Converting constructions of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting constructor of T from U. - template<class Expr> - void construct ( Expr const& expr, void const* ) - { - new (m_storage.address()) value_type(expr) ; - m_initialized = true ; - } - - // Assigns using a form any expression implicitly convertible to the single argument - // of a T's assignment operator. - // Converting assignments of optional<T> from optional<U> uses this function with - // 'Expr' being of type 'U' and relying on a converting assignment of T from U. - template<class Expr> - void assign_expr_to_initialized ( Expr const& expr, void const* ) - { - assign_value(expr); - } - -#endif - -#ifdef BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION - // BCB5.64 (and probably lower versions) workaround. - // The in-place factories are supported by means of catch-all constructors - // and assignment operators (the functions are parameterized in terms of - // an arbitrary 'Expr' type) - // This compiler incorrectly resolves the overload set and sinks optional<T> and optional<U> - // to the 'Expr'-taking functions even though explicit overloads are present for them. - // Thus, the following overload is needed to properly handle the case when the 'lhs' - // is another optional. - // - // For VC<=70 compilers this workaround dosen't work becasue the comnpiler issues and error - // instead of choosing the wrong overload - // -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Notice that 'Expr' will be optional<T> or optional<U> (but not optional_base<..>) - template<class Expr> - void construct ( Expr&& expr, optional_tag const* ) - { - if ( expr.is_initialized() ) - { - // An exception can be thrown here. - // It it happens, THIS will be left uninitialized. - new (m_storage.address()) value_type(boost::move(expr.get())) ; - m_initialized = true ; - } - } -#else - // Notice that 'Expr' will be optional<T> or optional<U> (but not optional_base<..>) - template<class Expr> - void construct ( Expr const& expr, optional_tag const* ) - { - if ( expr.is_initialized() ) - { - // An exception can be thrown here. - // It it happens, THIS will be left uninitialized. - new (m_storage.address()) value_type(expr.get()) ; - m_initialized = true ; - } - } -#endif -#endif // defined BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION - - void assign_value ( argument_type val ) { get_impl() = val; } -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - void assign_value ( rval_reference_type val ) { get_impl() = static_cast<rval_reference_type>(val); } -#endif - - void destroy() - { - if ( m_initialized ) - destroy_impl() ; - } - - reference_const_type get_impl() const { return m_storage.ref() ; } - reference_type get_impl() { return m_storage.ref() ; } - - pointer_const_type get_ptr_impl() const { return m_storage.ptr_ref(); } - pointer_type get_ptr_impl() { return m_storage.ptr_ref(); } - - private : - -#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1900)) - void destroy_impl ( ) { m_storage.ptr_ref()->~T() ; m_initialized = false ; } -#else - void destroy_impl ( ) { m_storage.ref().T::~T() ; m_initialized = false ; } -#endif - - bool m_initialized ; - storage_type m_storage ; -} ; - -#include <boost/optional/detail/optional_trivially_copyable_base.hpp> - -// definition of metafunction is_optional_val_init_candidate -template <typename U> -struct is_optional_related - : boost::conditional< boost::is_base_of<optional_detail::optional_tag, BOOST_DEDUCED_TYPENAME boost::decay<U>::type>::value - || boost::is_same<BOOST_DEDUCED_TYPENAME boost::decay<U>::type, none_t>::value - || boost::is_same<BOOST_DEDUCED_TYPENAME boost::decay<U>::type, in_place_init_t>::value - || boost::is_same<BOOST_DEDUCED_TYPENAME boost::decay<U>::type, in_place_init_if_t>::value, - boost::true_type, boost::false_type>::type -{}; - -#if !defined(BOOST_OPTIONAL_DETAIL_NO_IS_CONSTRUCTIBLE_TRAIT) - -template <typename T, typename U> -struct is_convertible_to_T_or_factory - : boost::conditional< boost::is_base_of<boost::in_place_factory_base, BOOST_DEDUCED_TYPENAME boost::decay<U>::type>::value - || boost::is_base_of<boost::typed_in_place_factory_base, BOOST_DEDUCED_TYPENAME boost::decay<U>::type>::value - || (boost::is_constructible<T, U&&>::value && !boost::is_same<T, BOOST_DEDUCED_TYPENAME boost::decay<U>::type>::value) - , boost::true_type, boost::false_type>::type -{}; - -template <typename T, typename U> -struct is_optional_constructible : boost::is_constructible<T, U> -{}; - -#else - -template <typename, typename> -struct is_convertible_to_T_or_factory : boost::true_type -{}; - -template <typename T, typename U> -struct is_optional_constructible : boost::true_type -{}; - -#endif // is_convertible condition - -template <typename T, typename U, bool = is_optional_related<U>::value> -struct is_optional_val_init_candidate - : boost::false_type -{}; - -template <typename T, typename U> -struct is_optional_val_init_candidate<T, U, false> - : boost::conditional< is_convertible_to_T_or_factory<T, U>::value - , boost::true_type, boost::false_type>::type -{}; - -} // namespace optional_detail - -namespace optional_config { - -template <typename T> -struct optional_uses_direct_storage_for - : boost::conditional<(boost::is_scalar<T>::value && !boost::is_const<T>::value && !boost::is_volatile<T>::value) - , boost::true_type, boost::false_type>::type -{}; - -} // namespace optional_config - - -#ifndef BOOST_OPTIONAL_DETAIL_NO_DIRECT_STORAGE_SPEC -# define BOOST_OPTIONAL_BASE_TYPE(T) boost::conditional< optional_config::optional_uses_direct_storage_for<T>::value, \ - optional_detail::tc_optional_base<T>, \ - optional_detail::optional_base<T> \ - >::type -#else -# define BOOST_OPTIONAL_BASE_TYPE(T) optional_detail::optional_base<T> -#endif - -template<class T> -class optional - : public BOOST_OPTIONAL_BASE_TYPE(T) -{ - typedef typename BOOST_OPTIONAL_BASE_TYPE(T) base ; - - public : - - typedef optional<T> this_type ; - - typedef BOOST_DEDUCED_TYPENAME base::value_type value_type ; - typedef BOOST_DEDUCED_TYPENAME base::reference_type reference_type ; - typedef BOOST_DEDUCED_TYPENAME base::reference_const_type reference_const_type ; -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - typedef BOOST_DEDUCED_TYPENAME base::rval_reference_type rval_reference_type ; - typedef BOOST_DEDUCED_TYPENAME base::reference_type_of_temporary_wrapper reference_type_of_temporary_wrapper ; -#endif - typedef BOOST_DEDUCED_TYPENAME base::pointer_type pointer_type ; - typedef BOOST_DEDUCED_TYPENAME base::pointer_const_type pointer_const_type ; - typedef BOOST_DEDUCED_TYPENAME base::argument_type argument_type ; - - // Creates an optional<T> uninitialized. - // No-throw - optional() BOOST_NOEXCEPT : base() {} - - // Creates an optional<T> uninitialized. - // No-throw - optional( none_t none_ ) BOOST_NOEXCEPT : base(none_) {} - - // Creates an optional<T> initialized with 'val'. - // Can throw if T::T(T const&) does - optional ( argument_type val ) : base(optional_detail::init_value_tag(), val) {} - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Creates an optional<T> initialized with 'move(val)'. - // Can throw if T::T(T &&) does - optional ( rval_reference_type val ) : base(optional_detail::init_value_tag(), boost::forward<T>(val)) - {} -#endif - - // Creates an optional<T> initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional. - // Can throw if T::T(T const&) does - optional ( bool cond, argument_type val ) : base(cond,val) {} - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - /// Creates an optional<T> initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional. - // Can throw if T::T(T &&) does - optional ( bool cond, rval_reference_type val ) : base( cond, boost::forward<T>(val) ) - {} -#endif - - // NOTE: MSVC needs templated versions first - - // Creates a deep copy of another convertible optional<U> - // Requires a valid conversion from U to T. - // Can throw if T::T(U const&) does - template<class U> - explicit optional ( optional<U> const& rhs -#ifndef BOOST_OPTIONAL_DETAIL_NO_SFINAE_FRIENDLY_CONSTRUCTORS - ,BOOST_DEDUCED_TYPENAME boost::enable_if< optional_detail::is_optional_constructible<T, U const&>, bool>::type = true -#endif - ) - : - base() - { - if ( rhs.is_initialized() ) - this->construct(rhs.get()); - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Creates a deep move of another convertible optional<U> - // Requires a valid conversion from U to T. - // Can throw if T::T(U&&) does - template<class U> - explicit optional ( optional<U> && rhs -#ifndef BOOST_OPTIONAL_DETAIL_NO_SFINAE_FRIENDLY_CONSTRUCTORS - ,BOOST_DEDUCED_TYPENAME boost::enable_if< optional_detail::is_optional_constructible<T, U>, bool>::type = true -#endif - ) - : - base() - { - if ( rhs.is_initialized() ) - this->construct( boost::move(rhs.get()) ); - } -#endif - -#ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - // Creates an optional<T> with an expression which can be either - // (a) An instance of InPlaceFactory (i.e. in_place(a,b,...,n); - // (b) An instance of TypedInPlaceFactory ( i.e. in_place<T>(a,b,...,n); - // (c) Any expression implicitly convertible to the single type - // of a one-argument T's constructor. - // (d*) Weak compilers (BCB) might also resolved Expr as optional<T> and optional<U> - // even though explicit overloads are present for these. - // Depending on the above some T ctor is called. - // Can throw if the resolved T ctor throws. -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - - - template<class Expr> - explicit optional ( Expr&& expr, - BOOST_DEDUCED_TYPENAME boost::enable_if< optional_detail::is_optional_val_init_candidate<T, Expr>, bool>::type = true - ) - : base(boost::forward<Expr>(expr),boost::addressof(expr)) - {} - -#else - template<class Expr> - explicit optional ( Expr const& expr ) : base(expr,boost::addressof(expr)) {} -#endif // !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES -#endif // !defined BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT - - // Creates a deep copy of another optional<T> - // Can throw if T::T(T const&) does -#ifndef BOOST_OPTIONAL_DETAIL_NO_DEFAULTED_MOVE_FUNCTIONS - optional ( optional const& ) = default; -#else - optional ( optional const& rhs ) : base( static_cast<base const&>(rhs) ) {} -#endif - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Creates a deep move of another optional<T> - // Can throw if T::T(T&&) does - -#ifndef BOOST_OPTIONAL_DETAIL_NO_DEFAULTED_MOVE_FUNCTIONS - optional ( optional && ) = default; -#else - optional ( optional && rhs ) - BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible<T>::value) - : base( boost::move(rhs) ) - {} -#endif - -#endif - -#if BOOST_WORKAROUND(_MSC_VER, <= 1600) - // On old MSVC compilers the implicitly declared dtor is not called - ~optional() {} -#endif - - -#if !defined(BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT) && !defined(BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION) - // Assigns from an expression. See corresponding constructor. - // Basic Guarantee: If the resolved T ctor throws, this is left UNINITIALIZED -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - - template<class Expr> - BOOST_DEDUCED_TYPENAME boost::enable_if<optional_detail::is_optional_val_init_candidate<T, Expr>, optional&>::type - operator= ( Expr&& expr ) - { - this->assign_expr(boost::forward<Expr>(expr),boost::addressof(expr)); - return *this ; - } - -#else - template<class Expr> - optional& operator= ( Expr const& expr ) - { - this->assign_expr(expr,boost::addressof(expr)); - return *this ; - } -#endif // !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES -#endif // !defined(BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT) && !defined(BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION) - - // Copy-assigns from another convertible optional<U> (converts && deep-copies the rhs value) - // Requires a valid conversion from U to T. - // Basic Guarantee: If T::T( U const& ) throws, this is left UNINITIALIZED - template<class U> - optional& operator= ( optional<U> const& rhs ) - { - this->assign(rhs); - return *this ; - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Move-assigns from another convertible optional<U> (converts && deep-moves the rhs value) - // Requires a valid conversion from U to T. - // Basic Guarantee: If T::T( U && ) throws, this is left UNINITIALIZED - template<class U> - optional& operator= ( optional<U> && rhs ) - { - this->assign(boost::move(rhs)); - return *this ; - } -#endif - - // Assigns from another optional<T> (deep-copies the rhs value) - // Basic Guarantee: If T::T( T const& ) throws, this is left UNINITIALIZED - // (NOTE: On BCB, this operator is not actually called and left is left UNMODIFIED in case of a throw) -#ifndef BOOST_OPTIONAL_DETAIL_NO_DEFAULTED_MOVE_FUNCTIONS - optional& operator= ( optional const& rhs ) = default; -#else - optional& operator= ( optional const& rhs ) - { - this->assign( static_cast<base const&>(rhs) ) ; - return *this ; - } -#endif - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Assigns from another optional<T> (deep-moves the rhs value) -#ifndef BOOST_OPTIONAL_DETAIL_NO_DEFAULTED_MOVE_FUNCTIONS - optional& operator= ( optional && ) = default; -#else - optional& operator= ( optional && rhs ) - BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible<T>::value && ::boost::is_nothrow_move_assignable<T>::value) - { - this->assign( static_cast<base &&>(rhs) ) ; - return *this ; - } -#endif - -#endif // BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - -#ifndef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX - - // Assigns from a T (deep-moves/copies the rhs value) - template <typename T_> - BOOST_DEDUCED_TYPENAME boost::enable_if<boost::is_same<T, BOOST_DEDUCED_TYPENAME boost::decay<T_>::type>, optional&>::type - operator= ( T_&& val ) - { - this->assign( boost::forward<T_>(val) ) ; - return *this ; - } - -#else - - // Assigns from a T (deep-copies the rhs value) - // Basic Guarantee: If T::( T const& ) throws, this is left UNINITIALIZED - optional& operator= ( argument_type val ) - { - this->assign( val ) ; - return *this ; - } - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - // Assigns from a T (deep-moves the rhs value) - optional& operator= ( rval_reference_type val ) - { - this->assign( boost::move(val) ) ; - return *this ; - } -#endif - -#endif // BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX - - // Assigns from a "none" - // Which destroys the current value, if any, leaving this UNINITIALIZED - // No-throw (assuming T::~T() doesn't) - optional& operator= ( none_t none_ ) BOOST_NOEXCEPT - { - this->assign( none_ ) ; - return *this ; - } - -#if (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) && (!defined BOOST_NO_CXX11_VARIADIC_TEMPLATES) - // Constructs in-place - // upon exception *this is always uninitialized - template<class... Args> - void emplace ( Args&&... args ) - { - this->emplace_assign( boost::forward<Args>(args)... ); - } - - template<class... Args> - explicit optional ( in_place_init_t, Args&&... args ) - : base( in_place_init, boost::forward<Args>(args)... ) - {} - - template<class... Args> - explicit optional ( in_place_init_if_t, bool cond, Args&&... args ) - : base( in_place_init_if, cond, boost::forward<Args>(args)... ) - {} - -#elif (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - template<class Arg> - void emplace ( Arg&& arg ) - { - this->emplace_assign( boost::forward<Arg>(arg) ); - } - - void emplace () - { - this->emplace_assign(); - } - - template<class Args> - explicit optional ( in_place_init_t, Args&& args ) - : base( in_place_init, boost::forward<Args>(args) ) - {} - - explicit optional ( in_place_init_t ) - : base( in_place_init ) - {} - - template<class Args> - explicit optional ( in_place_init_if_t, bool cond, Args&& args ) - : base( in_place_init_if, cond, boost::forward<Args>(args) ) - {} - - explicit optional ( in_place_init_if_t, bool cond ) - : base( in_place_init_if, cond ) - {} -#else - template<class Arg> - void emplace ( const Arg& arg ) - { - this->emplace_assign( arg ); - } - - template<class Arg> - void emplace ( Arg& arg ) - { - this->emplace_assign( arg ); - } - - void emplace () - { - this->emplace_assign(); - } - - template<class Arg> - explicit optional ( in_place_init_t, const Arg& arg ) - : base( in_place_init, arg ) - {} - - template<class Arg> - explicit optional ( in_place_init_t, Arg& arg ) - : base( in_place_init, arg ) - {} - - explicit optional ( in_place_init_t ) - : base( in_place_init ) - {} - - template<class Arg> - explicit optional ( in_place_init_if_t, bool cond, const Arg& arg ) - : base( in_place_init_if, cond, arg ) - {} - - template<class Arg> - explicit optional ( in_place_init_if_t, bool cond, Arg& arg ) - : base( in_place_init_if, cond, arg ) - {} - - explicit optional ( in_place_init_if_t, bool cond ) - : base( in_place_init_if, cond ) - {} -#endif - - void swap( optional & arg ) - BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible<T>::value && ::boost::is_nothrow_move_assignable<T>::value) - { - // allow for Koenig lookup - boost::swap(*this, arg); - } - - - // Returns a reference to the value if this is initialized, otherwise, - // the behaviour is UNDEFINED - // No-throw - reference_const_type get() const { BOOST_ASSERT(this->is_initialized()) ; return this->get_impl(); } - reference_type get() { BOOST_ASSERT(this->is_initialized()) ; return this->get_impl(); } - - // Returns a copy of the value if this is initialized, 'v' otherwise - reference_const_type get_value_or ( reference_const_type v ) const { return this->is_initialized() ? get() : v ; } - reference_type get_value_or ( reference_type v ) { return this->is_initialized() ? get() : v ; } - - // Returns a pointer to the value if this is initialized, otherwise, - // the behaviour is UNDEFINED - // No-throw - pointer_const_type operator->() const { BOOST_ASSERT(this->is_initialized()) ; return this->get_ptr_impl() ; } - pointer_type operator->() { BOOST_ASSERT(this->is_initialized()) ; return this->get_ptr_impl() ; } - - // Returns a reference to the value if this is initialized, otherwise, - // the behaviour is UNDEFINED - // No-throw -#if (!defined BOOST_NO_CXX11_REF_QUALIFIERS) && (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - reference_const_type operator *() const& { return this->get() ; } - reference_type operator *() & { return this->get() ; } - reference_type_of_temporary_wrapper operator *() && { return boost::move(this->get()) ; } -#else - reference_const_type operator *() const { return this->get() ; } - reference_type operator *() { return this->get() ; } -#endif // !defined BOOST_NO_CXX11_REF_QUALIFIERS - -#if (!defined BOOST_NO_CXX11_REF_QUALIFIERS) && (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - reference_const_type value() const& - { - if (this->is_initialized()) - return this->get() ; - else - throw_exception(bad_optional_access()); - } - - reference_type value() & - { - if (this->is_initialized()) - return this->get() ; - else - throw_exception(bad_optional_access()); - } - - reference_type_of_temporary_wrapper value() && - { - if (this->is_initialized()) - return boost::move(this->get()) ; - else - throw_exception(bad_optional_access()); - } - -#else - reference_const_type value() const - { - if (this->is_initialized()) - return this->get() ; - else - throw_exception(bad_optional_access()); - } - - reference_type value() - { - if (this->is_initialized()) - return this->get() ; - else - throw_exception(bad_optional_access()); - } -#endif - - -#ifndef BOOST_NO_CXX11_REF_QUALIFIERS - template <class U> - value_type value_or ( U&& v ) const& - { - if (this->is_initialized()) - return get(); - else - return boost::forward<U>(v); - } - - template <class U> - value_type value_or ( U&& v ) && - { - if (this->is_initialized()) - return boost::move(get()); - else - return boost::forward<U>(v); - } -#elif !defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - template <class U> - value_type value_or ( U&& v ) const - { - if (this->is_initialized()) - return get(); - else - return boost::forward<U>(v); - } -#else - template <class U> - value_type value_or ( U const& v ) const - { - if (this->is_initialized()) - return get(); - else - return v; - } - - template <class U> - value_type value_or ( U& v ) const - { - if (this->is_initialized()) - return get(); - else - return v; - } -#endif - - -#if (!defined BOOST_NO_CXX11_REF_QUALIFIERS) && (!defined BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES) - template <typename F> - value_type value_or_eval ( F f ) const& - { - if (this->is_initialized()) - return get(); - else - return f(); - } - - template <typename F> - value_type value_or_eval ( F f ) && - { - if (this->is_initialized()) - return boost::move(get()); - else - return f(); - } - - template <typename F> - optional<typename boost::result_of<F(reference_type)>::type> map(F f) & - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename boost::result_of<F(reference_const_type)>::type> map(F f) const& - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename boost::result_of<F(reference_type_of_temporary_wrapper)>::type> map(F f) && - { - if (this->has_value()) - return f(boost::move(this->get())); - else - return none; - } - - template <typename F> - optional<typename optional_detail::optional_value_type<typename boost::result_of<F(reference_type)>::type>::type> flat_map(F f) & - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename optional_detail::optional_value_type<typename boost::result_of<F(reference_const_type)>::type>::type> flat_map(F f) const& - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename optional_detail::optional_value_type<typename boost::result_of<F(reference_type_of_temporary_wrapper)>::type>::type> flat_map(F f) && - { - if (this->has_value()) - return f(boost::move(get())); - else - return none; - } - -#else - template <typename F> - value_type value_or_eval ( F f ) const - { - if (this->is_initialized()) - return get(); - else - return f(); - } - - template <typename F> - optional<typename boost::result_of<F(reference_type)>::type> map(F f) - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename boost::result_of<F(reference_const_type)>::type> map(F f) const - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename optional_detail::optional_value_type<typename boost::result_of<F(reference_type)>::type>::type> flat_map(F f) - { - if (this->has_value()) - return f(get()); - else - return none; - } - - template <typename F> - optional<typename optional_detail::optional_value_type<typename boost::result_of<F(reference_const_type)>::type>::type> flat_map(F f) const - { - if (this->has_value()) - return f(get()); - else - return none; - } - -#endif - - bool has_value() const BOOST_NOEXCEPT { return this->is_initialized() ; } - - bool operator!() const BOOST_NOEXCEPT { return !this->is_initialized() ; } - - BOOST_EXPLICIT_OPERATOR_BOOL_NOEXCEPT() -} ; - -} // namespace boost - -#endif // BOOST_OPTIONAL_CONFIG_USE_OLD_IMPLEMENTATION_OF_OPTIONAL - -namespace boost { - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES -template<class T> -class optional<T&&> -{ - BOOST_STATIC_ASSERT_MSG(sizeof(T) == 0, "Optional rvalue references are illegal."); -} ; -#endif - -} // namespace boost - -#ifndef BOOST_OPTIONAL_CONFIG_DONT_SPECIALIZE_OPTIONAL_REFS -# include <boost/optional/detail/optional_reference_spec.hpp> -#endif - -namespace boost { - -#ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - -template<class T> -inline -optional<BOOST_DEDUCED_TYPENAME boost::decay<T>::type> make_optional ( T && v ) -{ - return optional<BOOST_DEDUCED_TYPENAME boost::decay<T>::type>(boost::forward<T>(v)); -} - -// Returns optional<T>(cond,v) -template<class T> -inline -optional<BOOST_DEDUCED_TYPENAME boost::decay<T>::type> make_optional ( bool cond, T && v ) -{ - return optional<BOOST_DEDUCED_TYPENAME boost::decay<T>::type>(cond,boost::forward<T>(v)); -} - -#else - -// Returns optional<T>(v) -template<class T> -inline -optional<T> make_optional ( T const& v ) -{ - return optional<T>(v); -} - -// Returns optional<T>(cond,v) -template<class T> -inline -optional<T> make_optional ( bool cond, T const& v ) -{ - return optional<T>(cond,v); -} - -#endif // BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - -// Returns a reference to the value if this is initialized, otherwise, the behaviour is UNDEFINED. -// No-throw -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::reference_const_type -get ( optional<T> const& opt ) -{ - return opt.get() ; -} - -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::reference_type -get ( optional<T>& opt ) -{ - return opt.get() ; -} - -// Returns a pointer to the value if this is initialized, otherwise, returns NULL. -// No-throw -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::pointer_const_type -get ( optional<T> const* opt ) -{ - return opt->get_ptr() ; -} - -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::pointer_type -get ( optional<T>* opt ) -{ - return opt->get_ptr() ; -} - -// Returns a reference to the value if this is initialized, otherwise, the behaviour is UNDEFINED. -// No-throw -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::reference_const_type -get_optional_value_or ( optional<T> const& opt, BOOST_DEDUCED_TYPENAME optional<T>::reference_const_type v ) -{ - return opt.get_value_or(v) ; -} - -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::reference_type -get_optional_value_or ( optional<T>& opt, BOOST_DEDUCED_TYPENAME optional<T>::reference_type v ) -{ - return opt.get_value_or(v) ; -} - -// Returns a pointer to the value if this is initialized, otherwise, returns NULL. -// No-throw -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::pointer_const_type -get_pointer ( optional<T> const& opt ) -{ - return opt.get_ptr() ; -} - -template<class T> -inline -BOOST_DEDUCED_TYPENAME optional<T>::pointer_type -get_pointer ( optional<T>& opt ) -{ - return opt.get_ptr() ; -} - -} // namespace boost - -namespace boost { - -// The following declaration prevents a bug where operator safe-bool is used upon streaming optional object if you forget the IO header. -template<class CharType, class CharTrait> -std::basic_ostream<CharType, CharTrait>& -operator<<(std::basic_ostream<CharType, CharTrait>& os, optional_detail::optional_tag const&) -{ - BOOST_STATIC_ASSERT_MSG(sizeof(CharType) == 0, "If you want to output boost::optional, include header <boost/optional/optional_io.hpp>"); - return os; -} - -} // namespace boost - -#include <boost/optional/detail/optional_relops.hpp> -#include <boost/optional/detail/optional_swap.hpp> - -#endif // header guard diff --git a/ThirdParty/boost/pointer_to_other.hpp b/ThirdParty/boost/pointer_to_other.hpp deleted file mode 100644 index d7d455dc6e3e1ef60bce487a3f9b1a164fa3890f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/pointer_to_other.hpp +++ /dev/null @@ -1,55 +0,0 @@ -#ifndef BOOST_POINTER_TO_OTHER_HPP_INCLUDED -#define BOOST_POINTER_TO_OTHER_HPP_INCLUDED - -// -// pointer_to_other.hpp -// -// (C) Copyright Ion Gaztanaga 2005. -// Copyright (c) 2005 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) -// -// See http://www.boost.org/libs/smart_ptr/ for documentation. -// - -namespace boost -{ - -// Defines the same pointer type (raw or smart) to another pointee type - -template<class T, class U> -struct pointer_to_other; - -template<class T, class U, - template<class> class Sp> -struct pointer_to_other< Sp<T>, U > -{ - typedef Sp<U> type; -}; - -template<class T, class T2, class U, - template<class, class> class Sp> -struct pointer_to_other< Sp<T, T2>, U > -{ - typedef Sp<U, T2> type; -}; - -template<class T, class T2, class T3, class U, - template<class, class, class> class Sp> -struct pointer_to_other< Sp<T, T2, T3>, U > -{ - typedef Sp<U, T2, T3> type; -}; - -template<class T, class U> -struct pointer_to_other< T*, U > -{ - typedef U* type; -}; - -} // namespace boost - -#endif // #ifndef BOOST_POINTER_TO_OTHER_HPP_INCLUDED diff --git a/ThirdParty/boost/polymorphic_cast.hpp b/ThirdParty/boost/polymorphic_cast.hpp deleted file mode 100644 index 3592506003250f5f6cf16b39ac19cd98f2956e42..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/polymorphic_cast.hpp +++ /dev/null @@ -1,126 +0,0 @@ -// boost polymorphic_cast.hpp header file ----------------------------------------------// - -// (C) Copyright Kevlin Henney and Dave Abrahams 1999. -// (C) Copyright Boris Rasin 2014. -// 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) - -// See http://www.boost.org/libs/conversion for Documentation. - -// Revision History -// 10 Nov 14 polymorphic_pointer_downcast moved to a separate header, -// minor improvements to stisfy latest Boost coding style -// 08 Nov 14 Add polymorphic_pointer_downcast (Boris Rasin) -// 09 Jun 14 "cast.hpp" was renamed to "polymorphic_cast.hpp" and -// inclusion of numeric_cast was removed (Antony Polukhin) -// 23 Jun 05 numeric_cast removed and redirected to the new verion (Fernando Cacciola) -// 02 Apr 01 Removed BOOST_NO_LIMITS workarounds and included -// <boost/limits.hpp> instead (the workaround did not -// actually compile when BOOST_NO_LIMITS was defined in -// any case, so we loose nothing). (John Maddock) -// 21 Jan 01 Undid a bug I introduced yesterday. numeric_cast<> never -// worked with stock GCC; trying to get it to do that broke -// vc-stlport. -// 20 Jan 01 Moved BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS to config.hpp. -// Removed unused BOOST_EXPLICIT_TARGET macro. Moved -// boost::detail::type to boost/type.hpp. Made it compile with -// stock gcc again (Dave Abrahams) -// 29 Nov 00 Remove nested namespace cast, cleanup spacing before Formal -// Review (Beman Dawes) -// 19 Oct 00 Fix numeric_cast for floating-point types (Dave Abrahams) -// 15 Jul 00 Suppress numeric_cast warnings for GCC, Borland and MSVC -// (Dave Abrahams) -// 30 Jun 00 More MSVC6 wordarounds. See comments below. (Dave Abrahams) -// 28 Jun 00 Removed implicit_cast<>. See comment below. (Beman Dawes) -// 27 Jun 00 More MSVC6 workarounds -// 15 Jun 00 Add workarounds for MSVC6 -// 2 Feb 00 Remove bad_numeric_cast ";" syntax error (Doncho Angelov) -// 26 Jan 00 Add missing throw() to bad_numeric_cast::what(0 (Adam Levar) -// 29 Dec 99 Change using declarations so usages in other namespaces work -// correctly (Dave Abrahams) -// 23 Sep 99 Change polymorphic_downcast assert to also detect M.I. errors -// as suggested Darin Adler and improved by Valentin Bonnard. -// 2 Sep 99 Remove controversial asserts, simplify, rename. -// 30 Aug 99 Move to cast.hpp, replace value_cast with numeric_cast, -// place in nested namespace. -// 3 Aug 99 Initial version - -#ifndef BOOST_POLYMORPHIC_CAST_HPP -#define BOOST_POLYMORPHIC_CAST_HPP - -# include <boost/config.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -# include <boost/assert.hpp> -# include <boost/core/addressof.hpp> -# include <boost/core/enable_if.hpp> -# include <boost/throw_exception.hpp> -# include <boost/type_traits/is_reference.hpp> -# include <boost/type_traits/remove_reference.hpp> - -# include <typeinfo> - -namespace boost -{ -// See the documentation for descriptions of how to choose between -// static_cast<>, dynamic_cast<>, polymorphic_cast<> and polymorphic_downcast<> - -// polymorphic_cast --------------------------------------------------------// - - // Runtime checked polymorphic downcasts and crosscasts. - // Suggested in The C++ Programming Language, 3rd Ed, Bjarne Stroustrup, - // section 15.8 exercise 1, page 425. - - template <class Target, class Source> - inline Target polymorphic_cast(Source* x) - { - Target tmp = dynamic_cast<Target>(x); - if ( tmp == 0 ) boost::throw_exception( std::bad_cast() ); - return tmp; - } - -// polymorphic_downcast ----------------------------------------------------// - - // BOOST_ASSERT() checked raw pointer polymorphic downcast. Crosscasts prohibited. - - // WARNING: Because this cast uses BOOST_ASSERT(), it violates - // the One Definition Rule if used in multiple translation units - // where BOOST_DISABLE_ASSERTS, BOOST_ENABLE_ASSERT_HANDLER - // NDEBUG are defined inconsistently. - - // Contributed by Dave Abrahams - - template <class Target, class Source> - inline Target polymorphic_downcast(Source* x) - { - BOOST_ASSERT( dynamic_cast<Target>(x) == x ); // detect logic error - return static_cast<Target>(x); - } - - // BOOST_ASSERT() checked reference polymorphic downcast. Crosscasts prohibited. - - // WARNING: Because this cast uses BOOST_ASSERT(), it violates - // the One Definition Rule if used in multiple translation units - // where BOOST_DISABLE_ASSERTS, BOOST_ENABLE_ASSERT_HANDLER - // NDEBUG are defined inconsistently. - - // Contributed by Julien Delacroix - - template <class Target, class Source> - inline typename boost::enable_if_c< - boost::is_reference<Target>::value, Target - >::type polymorphic_downcast(Source& x) - { - typedef typename boost::remove_reference<Target>::type* target_pointer_type; - return *boost::polymorphic_downcast<target_pointer_type>( - boost::addressof(x) - ); - } - -} // namespace boost - -#endif // BOOST_POLYMORPHIC_CAST_HPP diff --git a/ThirdParty/boost/predef/architecture.h b/ThirdParty/boost/predef/architecture.h deleted file mode 100644 index 732d6f0e5d95e57cc0c7efc6e90144b05cdb6ffe..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture.h +++ /dev/null @@ -1,34 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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) -*/ - -#if !defined(BOOST_PREDEF_ARCHITECTURE_H) || defined(BOOST_PREDEF_INTERNAL_GENERATE_TESTS) -#ifndef BOOST_PREDEF_ARCHITECTURE_H -#define BOOST_PREDEF_ARCHITECTURE_H -#endif - -#include <boost/predef/architecture/alpha.h> -#include <boost/predef/architecture/arm.h> -#include <boost/predef/architecture/blackfin.h> -#include <boost/predef/architecture/convex.h> -#include <boost/predef/architecture/ia64.h> -#include <boost/predef/architecture/m68k.h> -#include <boost/predef/architecture/mips.h> -#include <boost/predef/architecture/parisc.h> -#include <boost/predef/architecture/ppc.h> -#include <boost/predef/architecture/ptx.h> -#include <boost/predef/architecture/pyramid.h> -#include <boost/predef/architecture/riscv.h> -#include <boost/predef/architecture/rs6k.h> -#include <boost/predef/architecture/sparc.h> -#include <boost/predef/architecture/superh.h> -#include <boost/predef/architecture/sys370.h> -#include <boost/predef/architecture/sys390.h> -#include <boost/predef/architecture/x86.h> -#include <boost/predef/architecture/z.h> -/*#include <boost/predef/architecture/.h>*/ - -#endif diff --git a/ThirdParty/boost/predef/architecture/alpha.h b/ThirdParty/boost/predef/architecture/alpha.h deleted file mode 100644 index a24b10fac3cac720bddc141e7cf192b0456c28bc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/alpha.h +++ /dev/null @@ -1,60 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_ALPHA_H -#define BOOST_PREDEF_ARCHITECTURE_ALPHA_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_ALPHA` - -http://en.wikipedia.org/wiki/DEC_Alpha[DEC Alpha] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} -| `+__alpha__+` | {predef_detection} -| `+__alpha+` | {predef_detection} -| `+_M_ALPHA+` | {predef_detection} - -| `+__alpha_ev4__+` | 4.0.0 -| `+__alpha_ev5__+` | 5.0.0 -| `+__alpha_ev6__+` | 6.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_ALPHA BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__alpha__) || defined(__alpha) || \ - defined(_M_ALPHA) -# undef BOOST_ARCH_ALPHA -# if !defined(BOOST_ARCH_ALPHA) && defined(__alpha_ev4__) -# define BOOST_ARCH_ALPHA BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_ALPHA) && defined(__alpha_ev5__) -# define BOOST_ARCH_ALPHA BOOST_VERSION_NUMBER(5,0,0) -# endif -# if !defined(BOOST_ARCH_ALPHA) && defined(__alpha_ev6__) -# define BOOST_ARCH_ALPHA BOOST_VERSION_NUMBER(6,0,0) -# endif -# if !defined(BOOST_ARCH_ALPHA) -# define BOOST_ARCH_ALPHA BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_ALPHA -# define BOOST_ARCH_ALPHA_AVAILABLE -#endif - -#define BOOST_ARCH_ALPHA_NAME "DEC Alpha" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_ALPHA,BOOST_ARCH_ALPHA_NAME) diff --git a/ThirdParty/boost/predef/architecture/arm.h b/ThirdParty/boost/predef/architecture/arm.h deleted file mode 100644 index b7a8a835dbc3cc920d11f77fa35f3c3c0da98670..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/arm.h +++ /dev/null @@ -1,134 +0,0 @@ -/* -Copyright Rene Rivera 2008-2019 -Copyright Franz Detro 2014 -Copyright (c) Microsoft Corporation 2014 -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_PREDEF_ARCHITECTURE_ARM_H -#define BOOST_PREDEF_ARCHITECTURE_ARM_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_ARM` - -http://en.wikipedia.org/wiki/ARM_architecture[ARM] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ARM_ARCH+` | {predef_detection} -| `+__TARGET_ARCH_ARM+` | {predef_detection} -| `+__TARGET_ARCH_THUMB+` | {predef_detection} -| `+_M_ARM+` | {predef_detection} -| `+__arm__+` | {predef_detection} -| `+__arm64+` | {predef_detection} -| `+__thumb__+` | {predef_detection} -| `+_M_ARM64+` | {predef_detection} -| `+__aarch64__+` | {predef_detection} -| `+__AARCH64EL__+` | {predef_detection} -| `+__ARM_ARCH_7__+` | {predef_detection} -| `+__ARM_ARCH_7A__+` | {predef_detection} -| `+__ARM_ARCH_7R__+` | {predef_detection} -| `+__ARM_ARCH_7M__+` | {predef_detection} -| `+__ARM_ARCH_6K__+` | {predef_detection} -| `+__ARM_ARCH_6Z__+` | {predef_detection} -| `+__ARM_ARCH_6KZ__+` | {predef_detection} -| `+__ARM_ARCH_6T2__+` | {predef_detection} -| `+__ARM_ARCH_5TE__+` | {predef_detection} -| `+__ARM_ARCH_5TEJ__+` | {predef_detection} -| `+__ARM_ARCH_4T__+` | {predef_detection} -| `+__ARM_ARCH_4__+` | {predef_detection} - -| `+__ARM_ARCH+` | V.0.0 -| `+__TARGET_ARCH_ARM+` | V.0.0 -| `+__TARGET_ARCH_THUMB+` | V.0.0 -| `+_M_ARM+` | V.0.0 -| `+__arm64+` | 8.0.0 -| `+_M_ARM64+` | 8.0.0 -| `+__aarch64__+` | 8.0.0 -| `+__AARCH64EL__+` | 8.0.0 -| `+__ARM_ARCH_7__+` | 7.0.0 -| `+__ARM_ARCH_7A__+` | 7.0.0 -| `+__ARM_ARCH_7R__+` | 7.0.0 -| `+__ARM_ARCH_7M__+` | 7.0.0 -| `+__ARM_ARCH_6K__+` | 6.0.0 -| `+__ARM_ARCH_6Z__+` | 6.0.0 -| `+__ARM_ARCH_6KZ__+` | 6.0.0 -| `+__ARM_ARCH_6T2__+` | 6.0.0 -| `+__ARM_ARCH_5TE__+` | 5.0.0 -| `+__ARM_ARCH_5TEJ__+` | 5.0.0 -| `+__ARM_ARCH_4T__+` | 4.0.0 -| `+__ARM_ARCH_4__+` | 4.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_ARM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if \ - defined(__ARM_ARCH) || defined(__TARGET_ARCH_ARM) || \ - defined(__TARGET_ARCH_THUMB) || defined(_M_ARM) || \ - defined(__arm__) || defined(__arm64) || defined(__thumb__) || \ - defined(_M_ARM64) || defined(__aarch64__) || defined(__AARCH64EL__) || \ - defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || \ - defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) || \ - defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6Z__) || \ - defined(__ARM_ARCH_6KZ__) || defined(__ARM_ARCH_6T2__) || \ - defined(__ARM_ARCH_5TE__) || defined(__ARM_ARCH_5TEJ__) || \ - defined(__ARM_ARCH_4T__) || defined(__ARM_ARCH_4__) -# undef BOOST_ARCH_ARM -# if !defined(BOOST_ARCH_ARM) && defined(__ARM_ARCH) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(__ARM_ARCH,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && defined(__TARGET_ARCH_ARM) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(__TARGET_ARCH_ARM,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && defined(__TARGET_ARCH_THUMB) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(__TARGET_ARCH_THUMB,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && defined(_M_ARM) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(_M_ARM,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && ( \ - defined(__arm64) || defined(_M_ARM64) || defined(__aarch64__) || \ - defined(__AARCH64EL__) ) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(8,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && ( \ - defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || \ - defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) ) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(7,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && ( \ - defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6Z__) || \ - defined(__ARM_ARCH_6KZ__) || defined(__ARM_ARCH_6T2__) ) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(6,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && ( \ - defined(__ARM_ARCH_5TE__) || defined(__ARM_ARCH_5TEJ__) ) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(5,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) && ( \ - defined(__ARM_ARCH_4T__) || defined(__ARM_ARCH_4__) ) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_ARM) -# define BOOST_ARCH_ARM BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_ARM -# define BOOST_ARCH_ARM_AVAILABLE -#endif - -#define BOOST_ARCH_ARM_NAME "ARM" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_ARM,BOOST_ARCH_ARM_NAME) diff --git a/ThirdParty/boost/predef/architecture/blackfin.h b/ThirdParty/boost/predef/architecture/blackfin.h deleted file mode 100644 index ce1a65557e8147bcb620f7ed03600ca4025c38df..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/blackfin.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Rene Rivera 2013-2015 -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_PREDEF_ARCHITECTURE_BLACKFIN_H -#define BOOST_PREDEF_ARCHITECTURE_BLACKFIN_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_BLACKFIN` - -Blackfin Processors from Analog Devices. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__bfin__+` | {predef_detection} -| `+__BFIN__+` | {predef_detection} -| `bfin` | {predef_detection} -| `BFIN` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_BLACKFIN BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__bfin__) || defined(__BFIN__) || \ - defined(bfin) || defined(BFIN) -# undef BOOST_ARCH_BLACKFIN -# define BOOST_ARCH_BLACKFIN BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_BLACKFIN -# define BOOST_ARCH_BLACKFIN_AVAILABLE -#endif - -#define BOOST_ARCH_BLACKFIN_NAME "Blackfin" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_BLACKFIN,BOOST_ARCH_BLACKFIN_NAME) diff --git a/ThirdParty/boost/predef/architecture/convex.h b/ThirdParty/boost/predef/architecture/convex.h deleted file mode 100644 index 5ce59c7539608e081c84819331e7b6716ef2768d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/convex.h +++ /dev/null @@ -1,66 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_ARCHITECTURE_CONVEX_H -#define BOOST_PREDEF_ARCHITECTURE_CONVEX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_CONVEX` - -http://en.wikipedia.org/wiki/Convex_Computer[Convex Computer] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__convex__+` | {predef_detection} - -| `+__convex_c1__+` | 1.0.0 -| `+__convex_c2__+` | 2.0.0 -| `+__convex_c32__+` | 3.2.0 -| `+__convex_c34__+` | 3.4.0 -| `+__convex_c38__+` | 3.8.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__convex__) -# undef BOOST_ARCH_CONVEX -# if !defined(BOOST_ARCH_CONVEX) && defined(__convex_c1__) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_ARCH_CONVEX) && defined(__convex_c2__) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_ARCH_CONVEX) && defined(__convex_c32__) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER(3,2,0) -# endif -# if !defined(BOOST_ARCH_CONVEX) && defined(__convex_c34__) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER(3,4,0) -# endif -# if !defined(BOOST_ARCH_CONVEX) && defined(__convex_c38__) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER(3,8,0) -# endif -# if !defined(BOOST_ARCH_CONVEX) -# define BOOST_ARCH_CONVEX BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_CONVEX -# define BOOST_ARCH_CONVEX_AVAILABLE -#endif - -#define BOOST_ARCH_CONVEX_NAME "Convex Computer" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_CONVEX,BOOST_ARCH_CONVEX_NAME) diff --git a/ThirdParty/boost/predef/architecture/ia64.h b/ThirdParty/boost/predef/architecture/ia64.h deleted file mode 100644 index 12a08d14ed364fac442ccd4b068eeb4bb94de5de..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/ia64.h +++ /dev/null @@ -1,50 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_IA64_H -#define BOOST_PREDEF_ARCHITECTURE_IA64_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_IA64` - -http://en.wikipedia.org/wiki/Ia64[Intel Itanium 64] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ia64__+` | {predef_detection} -| `+_IA64+` | {predef_detection} -| `+__IA64__+` | {predef_detection} -| `+__ia64+` | {predef_detection} -| `+_M_IA64+` | {predef_detection} -| `+__itanium__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_IA64 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__ia64__) || defined(_IA64) || \ - defined(__IA64__) || defined(__ia64) || \ - defined(_M_IA64) || defined(__itanium__) -# undef BOOST_ARCH_IA64 -# define BOOST_ARCH_IA64 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_IA64 -# define BOOST_ARCH_IA64_AVAILABLE -#endif - -#define BOOST_ARCH_IA64_NAME "Intel Itanium 64" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_IA64,BOOST_ARCH_IA64_NAME) diff --git a/ThirdParty/boost/predef/architecture/m68k.h b/ThirdParty/boost/predef/architecture/m68k.h deleted file mode 100644 index 2d877452193d1b0f690efe8c86b4fe4faeb1fc95..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/m68k.h +++ /dev/null @@ -1,83 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_M68K_H -#define BOOST_PREDEF_ARCHITECTURE_M68K_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_M68K` - -http://en.wikipedia.org/wiki/M68k[Motorola 68k] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__m68k__+` | {predef_detection} -| `M68000` | {predef_detection} - -| `+__mc68060__+` | 6.0.0 -| `mc68060` | 6.0.0 -| `+__mc68060+` | 6.0.0 -| `+__mc68040__+` | 4.0.0 -| `mc68040` | 4.0.0 -| `+__mc68040+` | 4.0.0 -| `+__mc68030__+` | 3.0.0 -| `mc68030` | 3.0.0 -| `+__mc68030+` | 3.0.0 -| `+__mc68020__+` | 2.0.0 -| `mc68020` | 2.0.0 -| `+__mc68020+` | 2.0.0 -| `+__mc68010__+` | 1.0.0 -| `mc68010` | 1.0.0 -| `+__mc68010+` | 1.0.0 -| `+__mc68000__+` | 0.0.1 -| `mc68000` | 0.0.1 -| `+__mc68000+` | 0.0.1 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_M68K BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__m68k__) || defined(M68000) -# undef BOOST_ARCH_M68K -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68060__) || defined(mc68060) || defined(__mc68060)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER(6,0,0) -# endif -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68040__) || defined(mc68040) || defined(__mc68040)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68030__) || defined(mc68030) || defined(__mc68030)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68020__) || defined(mc68020) || defined(__mc68020)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68010__) || defined(mc68010) || defined(__mc68010)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_ARCH_M68K) && (defined(__mc68000__) || defined(mc68000) || defined(__mc68000)) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if !defined(BOOST_ARCH_M68K) -# define BOOST_ARCH_M68K BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_M68K -# define BOOST_ARCH_M68K_AVAILABLE -#endif - -#define BOOST_ARCH_M68K_NAME "Motorola 68k" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_M68K,BOOST_ARCH_M68K_NAME) diff --git a/ThirdParty/boost/predef/architecture/mips.h b/ThirdParty/boost/predef/architecture/mips.h deleted file mode 100644 index 490c5e59030777bf09c836fd8c5ef756ca780eaf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/mips.h +++ /dev/null @@ -1,74 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_MIPS_H -#define BOOST_PREDEF_ARCHITECTURE_MIPS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_MIPS` - -http://en.wikipedia.org/wiki/MIPS_architecture[MIPS] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__mips__+` | {predef_detection} -| `+__mips+` | {predef_detection} -| `+__MIPS__+` | {predef_detection} - -| `+__mips+` | V.0.0 -| `+_MIPS_ISA_MIPS1+` | 1.0.0 -| `+_R3000+` | 1.0.0 -| `+_MIPS_ISA_MIPS2+` | 2.0.0 -| `+__MIPS_ISA2__+` | 2.0.0 -| `+_R4000+` | 2.0.0 -| `+_MIPS_ISA_MIPS3+` | 3.0.0 -| `+__MIPS_ISA3__+` | 3.0.0 -| `+_MIPS_ISA_MIPS4+` | 4.0.0 -| `+__MIPS_ISA4__+` | 4.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__mips__) || defined(__mips) || \ - defined(__MIPS__) -# undef BOOST_ARCH_MIPS -# if !defined(BOOST_ARCH_MIPS) && (defined(__mips)) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER(__mips,0,0) -# endif -# if !defined(BOOST_ARCH_MIPS) && (defined(_MIPS_ISA_MIPS1) || defined(_R3000)) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_ARCH_MIPS) && (defined(_MIPS_ISA_MIPS2) || defined(__MIPS_ISA2__) || defined(_R4000)) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_ARCH_MIPS) && (defined(_MIPS_ISA_MIPS3) || defined(__MIPS_ISA3__)) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_ARCH_MIPS) && (defined(_MIPS_ISA_MIPS4) || defined(__MIPS_ISA4__)) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_MIPS) -# define BOOST_ARCH_MIPS BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_MIPS -# define BOOST_ARCH_MIPS_AVAILABLE -#endif - -#define BOOST_ARCH_MIPS_NAME "MIPS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_MIPS,BOOST_ARCH_MIPS_NAME) diff --git a/ThirdParty/boost/predef/architecture/parisc.h b/ThirdParty/boost/predef/architecture/parisc.h deleted file mode 100644 index 0825445a34b2154fc552fb90af2d6ad34e156e75..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/parisc.h +++ /dev/null @@ -1,65 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_PARISC_H -#define BOOST_PREDEF_ARCHITECTURE_PARISC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_PARISC` - -http://en.wikipedia.org/wiki/PA-RISC_family[HP/PA RISC] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__hppa__+` | {predef_detection} -| `+__hppa+` | {predef_detection} -| `+__HPPA__+` | {predef_detection} - -| `+_PA_RISC1_0+` | 1.0.0 -| `+_PA_RISC1_1+` | 1.1.0 -| `+__HPPA11__+` | 1.1.0 -| `+__PA7100__+` | 1.1.0 -| `+_PA_RISC2_0+` | 2.0.0 -| `+__RISC2_0__+` | 2.0.0 -| `+__HPPA20__+` | 2.0.0 -| `+__PA8000__+` | 2.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_PARISC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__hppa__) || defined(__hppa) || defined(__HPPA__) -# undef BOOST_ARCH_PARISC -# if !defined(BOOST_ARCH_PARISC) && (defined(_PA_RISC1_0)) -# define BOOST_ARCH_PARISC BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_ARCH_PARISC) && (defined(_PA_RISC1_1) || defined(__HPPA11__) || defined(__PA7100__)) -# define BOOST_ARCH_PARISC BOOST_VERSION_NUMBER(1,1,0) -# endif -# if !defined(BOOST_ARCH_PARISC) && (defined(_PA_RISC2_0) || defined(__RISC2_0__) || defined(__HPPA20__) || defined(__PA8000__)) -# define BOOST_ARCH_PARISC BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_ARCH_PARISC) -# define BOOST_ARCH_PARISC BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_PARISC -# define BOOST_ARCH_PARISC_AVAILABLE -#endif - -#define BOOST_ARCH_PARISC_NAME "HP/PA RISC" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_PARISC,BOOST_ARCH_PARISC_NAME) diff --git a/ThirdParty/boost/predef/architecture/ppc.h b/ThirdParty/boost/predef/architecture/ppc.h deleted file mode 100644 index 019e11be81f023d9878962690f666cf84356ec9b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/ppc.h +++ /dev/null @@ -1,73 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_PPC_H -#define BOOST_PREDEF_ARCHITECTURE_PPC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_PPC` - -http://en.wikipedia.org/wiki/PowerPC[PowerPC] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__powerpc+` | {predef_detection} -| `+__powerpc__+` | {predef_detection} -| `+__POWERPC__+` | {predef_detection} -| `+__ppc__+` | {predef_detection} -| `+_M_PPC+` | {predef_detection} -| `+_ARCH_PPC+` | {predef_detection} -| `+__PPCGECKO__+` | {predef_detection} -| `+__PPCBROADWAY__+` | {predef_detection} -| `+_XENON+` | {predef_detection} - -| `+__ppc601__+` | 6.1.0 -| `+_ARCH_601+` | 6.1.0 -| `+__ppc603__+` | 6.3.0 -| `+_ARCH_603+` | 6.3.0 -| `+__ppc604__+` | 6.4.0 -| `+__ppc604__+` | 6.4.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_PPC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__powerpc) || defined(__powerpc__) || \ - defined(__POWERPC__) || defined(__ppc__) || \ - defined(_M_PPC) || defined(_ARCH_PPC) || \ - defined(__PPCGECKO__) || defined(__PPCBROADWAY__) || \ - defined(_XENON) -# undef BOOST_ARCH_PPC -# if !defined (BOOST_ARCH_PPC) && (defined(__ppc601__) || defined(_ARCH_601)) -# define BOOST_ARCH_PPC BOOST_VERSION_NUMBER(6,1,0) -# endif -# if !defined (BOOST_ARCH_PPC) && (defined(__ppc603__) || defined(_ARCH_603)) -# define BOOST_ARCH_PPC BOOST_VERSION_NUMBER(6,3,0) -# endif -# if !defined (BOOST_ARCH_PPC) && (defined(__ppc604__) || defined(__ppc604__)) -# define BOOST_ARCH_PPC BOOST_VERSION_NUMBER(6,4,0) -# endif -# if !defined (BOOST_ARCH_PPC) -# define BOOST_ARCH_PPC BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_PPC -# define BOOST_ARCH_PPC_AVAILABLE -#endif - -#define BOOST_ARCH_PPC_NAME "PowerPC" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_PPC,BOOST_ARCH_PPC_NAME) diff --git a/ThirdParty/boost/predef/architecture/ptx.h b/ThirdParty/boost/predef/architecture/ptx.h deleted file mode 100644 index a3310943ee4ba95b4bae0aab11820deebd196367..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/ptx.h +++ /dev/null @@ -1,45 +0,0 @@ -/* -Copyright Benjamin Worpitz 2018 -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_PREDEF_ARCHITECTURE_PTX_H -#define BOOST_PREDEF_ARCHITECTURE_PTX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_PTX` - -https://en.wikipedia.org/wiki/Parallel_Thread_Execution[PTX] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__CUDA_ARCH__+` | {predef_detection} - -| `+__CUDA_ARCH__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_PTX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__CUDA_ARCH__) -# undef BOOST_ARCH_PTX -# define BOOST_ARCH_PTX BOOST_PREDEF_MAKE_10_VR0(__CUDA_ARCH__) -#endif - -#if BOOST_ARCH_PTX -# define BOOST_ARCH_PTX_AVAILABLE -#endif - -#define BOOST_ARCH_PTX_NAME "PTX" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_PTX,BOOST_ARCH_PTX_NAME) diff --git a/ThirdParty/boost/predef/architecture/pyramid.h b/ThirdParty/boost/predef/architecture/pyramid.h deleted file mode 100644 index afcd1a96e50c632e10ce9fc49ff7afbf2ff5d2e3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/pyramid.h +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_ARCHITECTURE_PYRAMID_H -#define BOOST_PREDEF_ARCHITECTURE_PYRAMID_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_PYRAMID` - -Pyramid 9810 architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `pyr` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_PYRAMID BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(pyr) -# undef BOOST_ARCH_PYRAMID -# define BOOST_ARCH_PYRAMID BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_PYRAMID -# define BOOST_ARCH_PYRAMID_AVAILABLE -#endif - -#define BOOST_ARCH_PYRAMID_NAME "Pyramid 9810" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_PYRAMID,BOOST_ARCH_PYRAMID_NAME) diff --git a/ThirdParty/boost/predef/architecture/riscv.h b/ThirdParty/boost/predef/architecture/riscv.h deleted file mode 100644 index 7c3a7ba0587aa04917be44280cb3b7cb8ff1d52d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/riscv.h +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright Andreas Schwab 2019 -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_PREDEF_ARCHITECTURE_RISCV_H -#define BOOST_PREDEF_ARCHITECTURE_RISCV_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_RISCV` - -http://en.wikipedia.org/wiki/RISC-V[RISC-V] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__riscv+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_RISCV BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__riscv) -# undef BOOST_ARCH_RISCV -# define BOOST_ARCH_RISCV BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_RISCV -# define BOOST_ARCH_RISCV_AVAILABLE -#endif - -#define BOOST_ARCH_RISCV_NAME "RISC-V" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_RISCV,BOOST_ARCH_RISCV_NAME) diff --git a/ThirdParty/boost/predef/architecture/rs6k.h b/ThirdParty/boost/predef/architecture/rs6k.h deleted file mode 100644 index e33c7935e9c6f5344297ad5f8eb8dd506c962aed..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/rs6k.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_RS6K_H -#define BOOST_PREDEF_ARCHITECTURE_RS6K_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_RS6000` - -http://en.wikipedia.org/wiki/RS/6000[RS/6000] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__THW_RS6000+` | {predef_detection} -| `+_IBMR2+` | {predef_detection} -| `+_POWER+` | {predef_detection} -| `+_ARCH_PWR+` | {predef_detection} -| `+_ARCH_PWR2+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_RS6000 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__THW_RS6000) || defined(_IBMR2) || \ - defined(_POWER) || defined(_ARCH_PWR) || \ - defined(_ARCH_PWR2) -# undef BOOST_ARCH_RS6000 -# define BOOST_ARCH_RS6000 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_RS6000 -# define BOOST_ARCH_RS6000_AVAILABLE -#endif - -#define BOOST_ARCH_RS6000_NAME "RS/6000" - -#define BOOST_ARCH_PWR BOOST_ARCH_RS6000 - -#if BOOST_ARCH_PWR -# define BOOST_ARCH_PWR_AVAILABLE -#endif - -#define BOOST_ARCH_PWR_NAME BOOST_ARCH_RS6000_NAME - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_RS6000,BOOST_ARCH_RS6000_NAME) diff --git a/ThirdParty/boost/predef/architecture/sparc.h b/ThirdParty/boost/predef/architecture/sparc.h deleted file mode 100644 index 31551e393e2272ba8d2719bc191f8084bcaf6fa2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/sparc.h +++ /dev/null @@ -1,55 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_SPARC_H -#define BOOST_PREDEF_ARCHITECTURE_SPARC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_SPARC` - -http://en.wikipedia.org/wiki/SPARC[SPARC] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__sparc__+` | {predef_detection} -| `+__sparc+` | {predef_detection} - -| `+__sparcv9+` | 9.0.0 -| `+__sparcv8+` | 8.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_SPARC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__sparc__) || defined(__sparc) -# undef BOOST_ARCH_SPARC -# if !defined(BOOST_ARCH_SPARC) && defined(__sparcv9) -# define BOOST_ARCH_SPARC BOOST_VERSION_NUMBER(9,0,0) -# endif -# if !defined(BOOST_ARCH_SPARC) && defined(__sparcv8) -# define BOOST_ARCH_SPARC BOOST_VERSION_NUMBER(8,0,0) -# endif -# if !defined(BOOST_ARCH_SPARC) -# define BOOST_ARCH_SPARC BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_SPARC -# define BOOST_ARCH_SPARC_AVAILABLE -#endif - -#define BOOST_ARCH_SPARC_NAME "SPARC" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_SPARC,BOOST_ARCH_SPARC_NAME) diff --git a/ThirdParty/boost/predef/architecture/superh.h b/ThirdParty/boost/predef/architecture/superh.h deleted file mode 100644 index 5034d90b37b34f465ab07531e2556481611b87d4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/superh.h +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_SUPERH_H -#define BOOST_PREDEF_ARCHITECTURE_SUPERH_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_SH` - -http://en.wikipedia.org/wiki/SuperH[SuperH] architecture: -If available versions [1-5] are specifically detected. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__sh__+` | {predef_detection} - -| `+__SH5__+` | 5.0.0 -| `+__SH4__+` | 4.0.0 -| `+__sh3__+` | 3.0.0 -| `+__SH3__+` | 3.0.0 -| `+__sh2__+` | 2.0.0 -| `+__sh1__+` | 1.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_SH BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__sh__) -# undef BOOST_ARCH_SH -# if !defined(BOOST_ARCH_SH) && (defined(__SH5__)) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER(5,0,0) -# endif -# if !defined(BOOST_ARCH_SH) && (defined(__SH4__)) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_SH) && (defined(__sh3__) || defined(__SH3__)) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_ARCH_SH) && (defined(__sh2__)) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_ARCH_SH) && (defined(__sh1__)) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_ARCH_SH) -# define BOOST_ARCH_SH BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_SH -# define BOOST_ARCH_SH_AVAILABLE -#endif - -#define BOOST_ARCH_SH_NAME "SuperH" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_SH,BOOST_ARCH_SH_NAME) diff --git a/ThirdParty/boost/predef/architecture/sys370.h b/ThirdParty/boost/predef/architecture/sys370.h deleted file mode 100644 index 265d0f05557b365e1c4838839d0a92e1b58e6cbd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/sys370.h +++ /dev/null @@ -1,44 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_SYS370_H -#define BOOST_PREDEF_ARCHITECTURE_SYS370_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_SYS370` - -http://en.wikipedia.org/wiki/System/370[System/370] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__370__+` | {predef_detection} -| `+__THW_370__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_SYS370 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__370__) || defined(__THW_370__) -# undef BOOST_ARCH_SYS370 -# define BOOST_ARCH_SYS370 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_SYS370 -# define BOOST_ARCH_SYS370_AVAILABLE -#endif - -#define BOOST_ARCH_SYS370_NAME "System/370" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_SYS370,BOOST_ARCH_SYS370_NAME) diff --git a/ThirdParty/boost/predef/architecture/sys390.h b/ThirdParty/boost/predef/architecture/sys390.h deleted file mode 100644 index 155c9beac6854a5fae0b659dfc6475691cd42b23..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/sys390.h +++ /dev/null @@ -1,44 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_SYS390_H -#define BOOST_PREDEF_ARCHITECTURE_SYS390_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_SYS390` - -http://en.wikipedia.org/wiki/System/390[System/390] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__s390__+` | {predef_detection} -| `+__s390x__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_SYS390 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__s390__) || defined(__s390x__) -# undef BOOST_ARCH_SYS390 -# define BOOST_ARCH_SYS390 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_SYS390 -# define BOOST_ARCH_SYS390_AVAILABLE -#endif - -#define BOOST_ARCH_SYS390_NAME "System/390" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_SYS390,BOOST_ARCH_SYS390_NAME) diff --git a/ThirdParty/boost/predef/architecture/x86.h b/ThirdParty/boost/predef/architecture/x86.h deleted file mode 100644 index 9827ef3ab5d871c96c9b9de59397ce2fb8cbd398..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/x86.h +++ /dev/null @@ -1,38 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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/predef/architecture/x86/32.h> -#include <boost/predef/architecture/x86/64.h> - -#ifndef BOOST_PREDEF_ARCHITECTURE_X86_H -#define BOOST_PREDEF_ARCHITECTURE_X86_H - -/* tag::reference[] -= `BOOST_ARCH_X86` - -http://en.wikipedia.org/wiki/X86[Intel x86] architecture. This is -a category to indicate that either `BOOST_ARCH_X86_32` or -`BOOST_ARCH_X86_64` is detected. -*/ // end::reference[] - -#define BOOST_ARCH_X86 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_ARCH_X86_32 || BOOST_ARCH_X86_64 -# undef BOOST_ARCH_X86 -# define BOOST_ARCH_X86 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_X86 -# define BOOST_ARCH_X86_AVAILABLE -#endif - -#define BOOST_ARCH_X86_NAME "Intel x86" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_X86,BOOST_ARCH_X86_NAME) diff --git a/ThirdParty/boost/predef/architecture/x86/32.h b/ThirdParty/boost/predef/architecture/x86/32.h deleted file mode 100644 index cd2e7504f63575ecc0e951b32ccd15b1b86a3732..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/x86/32.h +++ /dev/null @@ -1,88 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_X86_32_H -#define BOOST_PREDEF_ARCHITECTURE_X86_32_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_X86_32` - -http://en.wikipedia.org/wiki/X86[Intel x86] architecture: -If available versions [3-6] are specifically detected. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `i386` | {predef_detection} -| `+__i386__+` | {predef_detection} -| `+__i486__+` | {predef_detection} -| `+__i586__+` | {predef_detection} -| `+__i686__+` | {predef_detection} -| `+__i386+` | {predef_detection} -| `+_M_IX86+` | {predef_detection} -| `+_X86_+` | {predef_detection} -| `+__THW_INTEL__+` | {predef_detection} -| `+__I86__+` | {predef_detection} -| `+__INTEL__+` | {predef_detection} - -| `+__I86__+` | V.0.0 -| `+_M_IX86+` | V.0.0 -| `+__i686__+` | 6.0.0 -| `+__i586__+` | 5.0.0 -| `+__i486__+` | 4.0.0 -| `+__i386__+` | 3.0.0 -|=== -*/ // end::reference[] - -#define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(i386) || defined(__i386__) || \ - defined(__i486__) || defined(__i586__) || \ - defined(__i686__) || defined(__i386) || \ - defined(_M_IX86) || defined(_X86_) || \ - defined(__THW_INTEL__) || defined(__I86__) || \ - defined(__INTEL__) -# undef BOOST_ARCH_X86_32 -# if !defined(BOOST_ARCH_X86_32) && defined(__I86__) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER(__I86__,0,0) -# endif -# if !defined(BOOST_ARCH_X86_32) && defined(_M_IX86) -# define BOOST_ARCH_X86_32 BOOST_PREDEF_MAKE_10_VV00(_M_IX86) -# endif -# if !defined(BOOST_ARCH_X86_32) && defined(__i686__) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER(6,0,0) -# endif -# if !defined(BOOST_ARCH_X86_32) && defined(__i586__) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER(5,0,0) -# endif -# if !defined(BOOST_ARCH_X86_32) && defined(__i486__) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_ARCH_X86_32) && defined(__i386__) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_ARCH_X86_32) -# define BOOST_ARCH_X86_32 BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_ARCH_X86_32 -# define BOOST_ARCH_X86_32_AVAILABLE -#endif - -#define BOOST_ARCH_X86_32_NAME "Intel x86-32" - -#include <boost/predef/architecture/x86.h> - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_X86_32,BOOST_ARCH_X86_32_NAME) diff --git a/ThirdParty/boost/predef/architecture/x86/64.h b/ThirdParty/boost/predef/architecture/x86/64.h deleted file mode 100644 index ebd80fb5e8fc4e0ae9cc9104abf973ecfdd3e404..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/x86/64.h +++ /dev/null @@ -1,51 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_X86_64_H -#define BOOST_PREDEF_ARCHITECTURE_X86_64_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_X86_64` - -http://en.wikipedia.org/wiki/Ia64[Intel IA-64] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__x86_64+` | {predef_detection} -| `+__x86_64__+` | {predef_detection} -| `+__amd64__+` | {predef_detection} -| `+__amd64+` | {predef_detection} -| `+_M_X64+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_X86_64 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__x86_64) || defined(__x86_64__) || \ - defined(__amd64__) || defined(__amd64) || \ - defined(_M_X64) -# undef BOOST_ARCH_X86_64 -# define BOOST_ARCH_X86_64 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_X86_64 -# define BOOST_ARCH_X86_64_AVAILABLE -#endif - -#define BOOST_ARCH_X86_64_NAME "Intel x86-64" - -#include <boost/predef/architecture/x86.h> - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_X86_64,BOOST_ARCH_X86_64_NAME) diff --git a/ThirdParty/boost/predef/architecture/z.h b/ThirdParty/boost/predef/architecture/z.h deleted file mode 100644 index d2d8e95f44105687235771b1c0c12a75ae53cfd1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/architecture/z.h +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_ARCHITECTURE_Z_H -#define BOOST_PREDEF_ARCHITECTURE_Z_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_ARCH_Z` - -http://en.wikipedia.org/wiki/Z/Architecture[z/Architecture] architecture. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SYSC_ZARCH__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_ARCH_Z BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__SYSC_ZARCH__) -# undef BOOST_ARCH_Z -# define BOOST_ARCH_Z BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_ARCH_Z -# define BOOST_ARCH_Z_AVAILABLE -#endif - -#define BOOST_ARCH_Z_NAME "z/Architecture" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ARCH_Z,BOOST_ARCH_Z_NAME) diff --git a/ThirdParty/boost/predef/compiler/borland.h b/ThirdParty/boost/predef/compiler/borland.h deleted file mode 100644 index 64daf909bad65bd7989a38ccd1c1fe17da9b0920..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/borland.h +++ /dev/null @@ -1,64 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_BORLAND_H -#define BOOST_PREDEF_COMPILER_BORLAND_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_BORLAND` - -http://en.wikipedia.org/wiki/C_plus_plus_builder[Borland {CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__BORLANDC__+` | {predef_detection} -| `+__CODEGEARC__+` | {predef_detection} - -| `+__BORLANDC__+` | V.R.P -| `+__CODEGEARC__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_BORLAND BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__BORLANDC__) || defined(__CODEGEARC__) -# if !defined(BOOST_COMP_BORLAND_DETECTION) && (defined(__CODEGEARC__)) -# define BOOST_COMP_BORLAND_DETECTION BOOST_PREDEF_MAKE_0X_VVRP(__CODEGEARC__) -# endif -# if !defined(BOOST_COMP_BORLAND_DETECTION) -# define BOOST_COMP_BORLAND_DETECTION BOOST_PREDEF_MAKE_0X_VVRP(__BORLANDC__) -# endif -#endif - -#ifdef BOOST_COMP_BORLAND_DETECTION -# define BOOST_COMP_BORLAND_AVAILABLE -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_BORLAND_EMULATED BOOST_COMP_BORLAND_DETECTION -# else -# undef BOOST_COMP_BORLAND -# define BOOST_COMP_BORLAND BOOST_COMP_BORLAND_DETECTION -# endif -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_BORLAND_NAME "Borland C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_BORLAND,BOOST_COMP_BORLAND_NAME) - -#ifdef BOOST_COMP_BORLAND_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_BORLAND_EMULATED,BOOST_COMP_BORLAND_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/clang.h b/ThirdParty/boost/predef/compiler/clang.h deleted file mode 100644 index 5e62da256b7b37e3775fa22ec3e31274f6d0f6ae..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/clang.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_CLANG_H -#define BOOST_PREDEF_COMPILER_CLANG_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_CLANG` - -http://en.wikipedia.org/wiki/Clang[Clang] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__clang__+` | {predef_detection} - -| `+__clang_major__+`, `+__clang_minor__+`, `+__clang_patchlevel__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_CLANG BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__clang__) -# define BOOST_COMP_CLANG_DETECTION BOOST_VERSION_NUMBER(__clang_major__,__clang_minor__,__clang_patchlevel__) -#endif - -#ifdef BOOST_COMP_CLANG_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_CLANG_EMULATED BOOST_COMP_CLANG_DETECTION -# else -# undef BOOST_COMP_CLANG -# define BOOST_COMP_CLANG BOOST_COMP_CLANG_DETECTION -# endif -# define BOOST_COMP_CLANG_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_CLANG_NAME "Clang" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_CLANG,BOOST_COMP_CLANG_NAME) - -#ifdef BOOST_COMP_CLANG_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_CLANG_EMULATED,BOOST_COMP_CLANG_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/comeau.h b/ThirdParty/boost/predef/compiler/comeau.h deleted file mode 100644 index 749694d0721c0ff57bd56227a775d8d617c15463..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/comeau.h +++ /dev/null @@ -1,62 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_COMEAU_H -#define BOOST_PREDEF_COMPILER_COMEAU_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -#define BOOST_COMP_COMO BOOST_VERSION_NUMBER_NOT_AVAILABLE - -/* tag::reference[] -= `BOOST_COMP_COMO` - -http://en.wikipedia.org/wiki/Comeau_C/C%2B%2B[Comeau {CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__COMO__+` | {predef_detection} - -| `+__COMO_VERSION__+` | V.R.P -|=== -*/ // end::reference[] - -#if defined(__COMO__) -# if !defined(BOOST_COMP_COMO_DETECTION) && defined(__COMO_VERSION__) -# define BOOST_COMP_COMO_DETECTION BOOST_PREDEF_MAKE_0X_VRP(__COMO_VERSION__) -# endif -# if !defined(BOOST_COMP_COMO_DETECTION) -# define BOOST_COMP_COMO_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_COMO_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_COMO_EMULATED BOOST_COMP_COMO_DETECTION -# else -# undef BOOST_COMP_COMO -# define BOOST_COMP_COMO BOOST_COMP_COMO_DETECTION -# endif -# define BOOST_COMP_COMO_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_COMO_NAME "Comeau C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_COMO,BOOST_COMP_COMO_NAME) - -#ifdef BOOST_COMP_COMO_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_COMO_EMULATED,BOOST_COMP_COMO_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/compaq.h b/ThirdParty/boost/predef/compiler/compaq.h deleted file mode 100644 index a2a403ff288ed6c5926440db372eef61eb82c5f0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/compaq.h +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_COMPAQ_H -#define BOOST_PREDEF_COMPILER_COMPAQ_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_DEC` - -http://www.openvms.compaq.com/openvms/brochures/deccplus/[Compaq C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__DECCXX+` | {predef_detection} -| `+__DECC+` | {predef_detection} - -| `+__DECCXX_VER+` | V.R.P -| `+__DECC_VER+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_DEC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__DECC) || defined(__DECCXX) -# if !defined(BOOST_COMP_DEC_DETECTION) && defined(__DECCXX_VER) -# define BOOST_COMP_DEC_DETECTION BOOST_PREDEF_MAKE_10_VVRR0PP00(__DECCXX_VER) -# endif -# if !defined(BOOST_COMP_DEC_DETECTION) && defined(__DECC_VER) -# define BOOST_COMP_DEC_DETECTION BOOST_PREDEF_MAKE_10_VVRR0PP00(__DECC_VER) -# endif -# if !defined(BOOST_COMP_DEC_DETECTION) -# define BOOST_COMP_DEC_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_DEC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_DEC_EMULATED BOOST_COMP_DEC_DETECTION -# else -# undef BOOST_COMP_DEC -# define BOOST_COMP_DEC BOOST_COMP_DEC_DETECTION -# endif -# define BOOST_COMP_DEC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_DEC_NAME "Compaq C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DEC,BOOST_COMP_DEC_NAME) - -#ifdef BOOST_COMP_DEC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DEC_EMULATED,BOOST_COMP_DEC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/diab.h b/ThirdParty/boost/predef/compiler/diab.h deleted file mode 100644 index 9be1d1aee0fa5a4d6549d8b9b3f7981ab93fe366..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/diab.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_DIAB_H -#define BOOST_PREDEF_COMPILER_DIAB_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_DIAB` - -http://www.windriver.com/products/development_suite/wind_river_compiler/[Diab C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__DCC__+` | {predef_detection} - -| `+__VERSION_NUMBER__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_DIAB BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__DCC__) -# define BOOST_COMP_DIAB_DETECTION BOOST_PREDEF_MAKE_10_VRPP(__VERSION_NUMBER__) -#endif - -#ifdef BOOST_COMP_DIAB_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_DIAB_EMULATED BOOST_COMP_DIAB_DETECTION -# else -# undef BOOST_COMP_DIAB -# define BOOST_COMP_DIAB BOOST_COMP_DIAB_DETECTION -# endif -# define BOOST_COMP_DIAB_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_DIAB_NAME "Diab C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DIAB,BOOST_COMP_DIAB_NAME) - -#ifdef BOOST_COMP_DIAB_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DIAB_EMULATED,BOOST_COMP_DIAB_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/digitalmars.h b/ThirdParty/boost/predef/compiler/digitalmars.h deleted file mode 100644 index 3b2d53f7190048f68a3130637e82395941e922ad..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/digitalmars.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_DIGITALMARS_H -#define BOOST_PREDEF_COMPILER_DIGITALMARS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_DMC` - -http://en.wikipedia.org/wiki/Digital_Mars[Digital Mars] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__DMC__+` | {predef_detection} - -| `+__DMC__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_DMC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__DMC__) -# define BOOST_COMP_DMC_DETECTION BOOST_PREDEF_MAKE_0X_VRP(__DMC__) -#endif - -#ifdef BOOST_COMP_DMC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_DMC_EMULATED BOOST_COMP_DMC_DETECTION -# else -# undef BOOST_COMP_DMC -# define BOOST_COMP_DMC BOOST_COMP_DMC_DETECTION -# endif -# define BOOST_COMP_DMC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_DMC_NAME "Digital Mars" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DMC,BOOST_COMP_DMC_NAME) - -#ifdef BOOST_COMP_DMC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_DMC_EMULATED,BOOST_COMP_DMC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/dignus.h b/ThirdParty/boost/predef/compiler/dignus.h deleted file mode 100644 index 8177cc76ee8685c1ebc99cf3b2192fac72783bdb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/dignus.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_DIGNUS_H -#define BOOST_PREDEF_COMPILER_DIGNUS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_SYSC` - -http://www.dignus.com/dcxx/[Dignus Systems/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SYSC__+` | {predef_detection} - -| `+__SYSC_VER__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_SYSC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__SYSC__) -# define BOOST_COMP_SYSC_DETECTION BOOST_PREDEF_MAKE_10_VRRPP(__SYSC_VER__) -#endif - -#ifdef BOOST_COMP_SYSC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_SYSC_EMULATED BOOST_COMP_SYSC_DETECTION -# else -# undef BOOST_COMP_SYSC -# define BOOST_COMP_SYSC BOOST_COMP_SYSC_DETECTION -# endif -# define BOOST_COMP_SYSC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_SYSC_NAME "Dignus Systems/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SYSC,BOOST_COMP_SYSC_NAME) - -#ifdef BOOST_COMP_SYSC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SYSC_EMULATED,BOOST_COMP_SYSC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/edg.h b/ThirdParty/boost/predef/compiler/edg.h deleted file mode 100644 index 6e0f97a2bb9f9106aff30b2e8764ba5e5f4b17d1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/edg.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_EDG_H -#define BOOST_PREDEF_COMPILER_EDG_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_EDG` - -http://en.wikipedia.org/wiki/Edison_Design_Group[EDG {CPP} Frontend] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__EDG__+` | {predef_detection} - -| `+__EDG_VERSION__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_COMP_EDG BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__EDG__) -# define BOOST_COMP_EDG_DETECTION BOOST_PREDEF_MAKE_10_VRR(__EDG_VERSION__) -#endif - -#ifdef BOOST_COMP_EDG_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_EDG_EMULATED BOOST_COMP_EDG_DETECTION -# else -# undef BOOST_COMP_EDG -# define BOOST_COMP_EDG BOOST_COMP_EDG_DETECTION -# endif -# define BOOST_COMP_EDG_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_EDG_NAME "EDG C++ Frontend" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_EDG,BOOST_COMP_EDG_NAME) - -#ifdef BOOST_COMP_EDG_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_EDG_EMULATED,BOOST_COMP_EDG_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/ekopath.h b/ThirdParty/boost/predef/compiler/ekopath.h deleted file mode 100644 index f91c9dceffe2d996d29170a876291aa7d144dd7e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/ekopath.h +++ /dev/null @@ -1,58 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_EKOPATH_H -#define BOOST_PREDEF_COMPILER_EKOPATH_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_PATH` - -http://en.wikipedia.org/wiki/PathScale[EKOpath] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__PATHCC__+` | {predef_detection} - -| `+__PATHCC__+`, `+__PATHCC_MINOR__+`, `+__PATHCC_PATCHLEVEL__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_PATH BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__PATHCC__) -# define BOOST_COMP_PATH_DETECTION \ - BOOST_VERSION_NUMBER(__PATHCC__,__PATHCC_MINOR__,__PATHCC_PATCHLEVEL__) -#endif - -#ifdef BOOST_COMP_PATH_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_PATH_EMULATED BOOST_COMP_PATH_DETECTION -# else -# undef BOOST_COMP_PATH -# define BOOST_COMP_PATH BOOST_COMP_PATH_DETECTION -# endif -# define BOOST_COMP_PATH_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_PATH_NAME "EKOpath" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PATH,BOOST_COMP_PATH_NAME) - -#ifdef BOOST_COMP_PATH_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PATH_EMULATED,BOOST_COMP_PATH_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/gcc.h b/ThirdParty/boost/predef/compiler/gcc.h deleted file mode 100644 index 88698d21e900ef1d923f8815cba4d919f981cbab..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/gcc.h +++ /dev/null @@ -1,69 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_GCC_H -#define BOOST_PREDEF_COMPILER_GCC_H - -/* Other compilers that emulate this one need to be detected first. */ - -#include <boost/predef/compiler/clang.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_GNUC` - -http://en.wikipedia.org/wiki/GNU_Compiler_Collection[Gnu GCC C/{CPP}] compiler. -Version number available as major, minor, and patch (if available). - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__GNUC__+` | {predef_detection} - -| `+__GNUC__+`, `+__GNUC_MINOR__+`, `+__GNUC_PATCHLEVEL__+` | V.R.P -| `+__GNUC__+`, `+__GNUC_MINOR__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_COMP_GNUC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__GNUC__) -# if !defined(BOOST_COMP_GNUC_DETECTION) && defined(__GNUC_PATCHLEVEL__) -# define BOOST_COMP_GNUC_DETECTION \ - BOOST_VERSION_NUMBER(__GNUC__,__GNUC_MINOR__,__GNUC_PATCHLEVEL__) -# endif -# if !defined(BOOST_COMP_GNUC_DETECTION) -# define BOOST_COMP_GNUC_DETECTION \ - BOOST_VERSION_NUMBER(__GNUC__,__GNUC_MINOR__,0) -# endif -#endif - -#ifdef BOOST_COMP_GNUC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_GNUC_EMULATED BOOST_COMP_GNUC_DETECTION -# else -# undef BOOST_COMP_GNUC -# define BOOST_COMP_GNUC BOOST_COMP_GNUC_DETECTION -# endif -# define BOOST_COMP_GNUC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_GNUC_NAME "Gnu GCC C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GNUC,BOOST_COMP_GNUC_NAME) - -#ifdef BOOST_COMP_GNUC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GNUC_EMULATED,BOOST_COMP_GNUC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/gcc_xml.h b/ThirdParty/boost/predef/compiler/gcc_xml.h deleted file mode 100644 index a9253370120660e49b9c38fbe1debda3bae51ed6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/gcc_xml.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_GCC_XML_H -#define BOOST_PREDEF_COMPILER_GCC_XML_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_GCCXML` - -http://www.gccxml.org/[GCC XML] compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__GCCXML__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_COMP_GCCXML BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__GCCXML__) -# define BOOST_COMP_GCCXML_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#ifdef BOOST_COMP_GCCXML_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_GCCXML_EMULATED BOOST_COMP_GCCXML_DETECTION -# else -# undef BOOST_COMP_GCCXML -# define BOOST_COMP_GCCXML BOOST_COMP_GCCXML_DETECTION -# endif -# define BOOST_COMP_GCCXML_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_GCCXML_NAME "GCC XML" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GCCXML,BOOST_COMP_GCCXML_NAME) - -#ifdef BOOST_COMP_GCCXML_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GCCXML_EMULATED,BOOST_COMP_GCCXML_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/greenhills.h b/ThirdParty/boost/predef/compiler/greenhills.h deleted file mode 100644 index 9bf5bf17baea85b116a6a8707bb90be95537c17f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/greenhills.h +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_GREENHILLS_H -#define BOOST_PREDEF_COMPILER_GREENHILLS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_GHS` - -http://en.wikipedia.org/wiki/Green_Hills_Software[Green Hills C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ghs+` | {predef_detection} -| `+__ghs__+` | {predef_detection} - -| `+__GHS_VERSION_NUMBER__+` | V.R.P -| `+__ghs+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_GHS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__ghs) || defined(__ghs__) -# if !defined(BOOST_COMP_GHS_DETECTION) && defined(__GHS_VERSION_NUMBER__) -# define BOOST_COMP_GHS_DETECTION BOOST_PREDEF_MAKE_10_VRP(__GHS_VERSION_NUMBER__) -# endif -# if !defined(BOOST_COMP_GHS_DETECTION) && defined(__ghs) -# define BOOST_COMP_GHS_DETECTION BOOST_PREDEF_MAKE_10_VRP(__ghs) -# endif -# if !defined(BOOST_COMP_GHS_DETECTION) -# define BOOST_COMP_GHS_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_GHS_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_GHS_EMULATED BOOST_COMP_GHS_DETECTION -# else -# undef BOOST_COMP_GHS -# define BOOST_COMP_GHS BOOST_COMP_GHS_DETECTION -# endif -# define BOOST_COMP_GHS_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_GHS_NAME "Green Hills C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GHS,BOOST_COMP_GHS_NAME) - -#ifdef BOOST_COMP_GHS_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_GHS_EMULATED,BOOST_COMP_GHS_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/hp_acc.h b/ThirdParty/boost/predef/compiler/hp_acc.h deleted file mode 100644 index 7a825cd51f07065d4b4abe905f5746ce2160c603..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/hp_acc.h +++ /dev/null @@ -1,62 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_HP_ACC_H -#define BOOST_PREDEF_COMPILER_HP_ACC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_HPACC` - -HP a{CPP} compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__HP_aCC+` | {predef_detection} - -| `+__HP_aCC+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_HPACC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__HP_aCC) -# if !defined(BOOST_COMP_HPACC_DETECTION) && (__HP_aCC > 1) -# define BOOST_COMP_HPACC_DETECTION BOOST_PREDEF_MAKE_10_VVRRPP(__HP_aCC) -# endif -# if !defined(BOOST_COMP_HPACC_DETECTION) -# define BOOST_COMP_HPACC_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_HPACC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_HPACC_EMULATED BOOST_COMP_HPACC_DETECTION -# else -# undef BOOST_COMP_HPACC -# define BOOST_COMP_HPACC BOOST_COMP_HPACC_DETECTION -# endif -# define BOOST_COMP_HPACC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_HPACC_NAME "HP aC++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_HPACC,BOOST_COMP_HPACC_NAME) - -#ifdef BOOST_COMP_HPACC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_HPACC_EMULATED,BOOST_COMP_HPACC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/iar.h b/ThirdParty/boost/predef/compiler/iar.h deleted file mode 100644 index 1140b0b4dda82a976123b36f69907e1293441280..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/iar.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_IAR_H -#define BOOST_PREDEF_COMPILER_IAR_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_IAR` - -IAR C/{CPP} compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__IAR_SYSTEMS_ICC__+` | {predef_detection} - -| `+__VER__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_IAR BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__IAR_SYSTEMS_ICC__) -# define BOOST_COMP_IAR_DETECTION BOOST_PREDEF_MAKE_10_VVRR(__VER__) -#endif - -#ifdef BOOST_COMP_IAR_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_IAR_EMULATED BOOST_COMP_IAR_DETECTION -# else -# undef BOOST_COMP_IAR -# define BOOST_COMP_IAR BOOST_COMP_IAR_DETECTION -# endif -# define BOOST_COMP_IAR_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_IAR_NAME "IAR C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_IAR,BOOST_COMP_IAR_NAME) - -#ifdef BOOST_COMP_IAR_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_IAR_EMULATED,BOOST_COMP_IAR_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/ibm.h b/ThirdParty/boost/predef/compiler/ibm.h deleted file mode 100644 index 6820677f90656e28987f7ac51a28970f035d7d77..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/ibm.h +++ /dev/null @@ -1,73 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_IBM_H -#define BOOST_PREDEF_COMPILER_IBM_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_IBM` - -http://en.wikipedia.org/wiki/VisualAge[IBM XL C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__IBMCPP__+` | {predef_detection} -| `+__xlC__+` | {predef_detection} -| `+__xlc__+` | {predef_detection} - -| `+__COMPILER_VER__+` | V.R.P -| `+__xlC__+` | V.R.P -| `+__xlc__+` | V.R.P -| `+__IBMCPP__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_IBM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__IBMCPP__) || defined(__xlC__) || defined(__xlc__) -# if !defined(BOOST_COMP_IBM_DETECTION) && defined(__COMPILER_VER__) -# define BOOST_COMP_IBM_DETECTION BOOST_PREDEF_MAKE_0X_VRRPPPP(__COMPILER_VER__) -# endif -# if !defined(BOOST_COMP_IBM_DETECTION) && defined(__xlC__) -# define BOOST_COMP_IBM_DETECTION BOOST_PREDEF_MAKE_0X_VVRR(__xlC__) -# endif -# if !defined(BOOST_COMP_IBM_DETECTION) && defined(__xlc__) -# define BOOST_COMP_IBM_DETECTION BOOST_PREDEF_MAKE_0X_VVRR(__xlc__) -# endif -# if !defined(BOOST_COMP_IBM_DETECTION) -# define BOOST_COMP_IBM_DETECTION BOOST_PREDEF_MAKE_10_VRP(__IBMCPP__) -# endif -#endif - -#ifdef BOOST_COMP_IBM_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_IBM_EMULATED BOOST_COMP_IBM_DETECTION -# else -# undef BOOST_COMP_IBM -# define BOOST_COMP_IBM BOOST_COMP_IBM_DETECTION -# endif -# define BOOST_COMP_IBM_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_IBM_NAME "IBM XL C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_IBM,BOOST_COMP_IBM_NAME) - -#ifdef BOOST_COMP_IBM_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_IBM_EMULATED,BOOST_COMP_IBM_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/intel.h b/ThirdParty/boost/predef/compiler/intel.h deleted file mode 100644 index 62d510ab62100c26ac99bdc68752af6238d04dff..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/intel.h +++ /dev/null @@ -1,80 +0,0 @@ -/* -Copyright Rene Rivera 2008-2017 -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_PREDEF_COMPILER_INTEL_H -#define BOOST_PREDEF_COMPILER_INTEL_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_INTEL` - -http://en.wikipedia.org/wiki/Intel_C%2B%2B[Intel C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__INTEL_COMPILER+` | {predef_detection} -| `+__ICL+` | {predef_detection} -| `+__ICC+` | {predef_detection} -| `+__ECC+` | {predef_detection} - -| `+__INTEL_COMPILER+` | V.R -| `+__INTEL_COMPILER+` and `+__INTEL_COMPILER_UPDATE+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_INTEL BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || \ - defined(__ECC) -/* tag::reference[] -NOTE: Because of an Intel mistake in the release version numbering when -`__INTEL_COMPILER` is `9999` it is detected as version 12.1.0. -*/ // end::reference[] -# if !defined(BOOST_COMP_INTEL_DETECTION) && defined(__INTEL_COMPILER) && (__INTEL_COMPILER == 9999) -# define BOOST_COMP_INTEL_DETECTION BOOST_VERSION_NUMBER(12,1,0) -# endif -# if !defined(BOOST_COMP_INTEL_DETECTION) && defined(__INTEL_COMPILER) && defined(__INTEL_COMPILER_UPDATE) -# define BOOST_COMP_INTEL_DETECTION BOOST_VERSION_NUMBER( \ - BOOST_VERSION_NUMBER_MAJOR(BOOST_PREDEF_MAKE_10_VVRR(__INTEL_COMPILER)), \ - BOOST_VERSION_NUMBER_MINOR(BOOST_PREDEF_MAKE_10_VVRR(__INTEL_COMPILER)), \ - __INTEL_COMPILER_UPDATE) -# endif -# if !defined(BOOST_COMP_INTEL_DETECTION) && defined(__INTEL_COMPILER) -# define BOOST_COMP_INTEL_DETECTION BOOST_PREDEF_MAKE_10_VVRR(__INTEL_COMPILER) -# endif -# if !defined(BOOST_COMP_INTEL_DETECTION) -# define BOOST_COMP_INTEL_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_INTEL_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_INTEL_EMULATED BOOST_COMP_INTEL_DETECTION -# else -# undef BOOST_COMP_INTEL -# define BOOST_COMP_INTEL BOOST_COMP_INTEL_DETECTION -# endif -# define BOOST_COMP_INTEL_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_INTEL_NAME "Intel C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_INTEL,BOOST_COMP_INTEL_NAME) - -#ifdef BOOST_COMP_INTEL_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_INTEL_EMULATED,BOOST_COMP_INTEL_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/kai.h b/ThirdParty/boost/predef/compiler/kai.h deleted file mode 100644 index 1980cc8406b5d5f18c0b947f1879e390d1154370..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/kai.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_KAI_H -#define BOOST_PREDEF_COMPILER_KAI_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_KCC` - -Kai {CPP} compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__KCC+` | {predef_detection} - -| `+__KCC_VERSION+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_KCC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__KCC) -# define BOOST_COMP_KCC_DETECTION BOOST_PREDEF_MAKE_0X_VRPP(__KCC_VERSION) -#endif - -#ifdef BOOST_COMP_KCC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_KCC_EMULATED BOOST_COMP_KCC_DETECTION -# else -# undef BOOST_COMP_KCC -# define BOOST_COMP_KCC BOOST_COMP_KCC_DETECTION -# endif -# define BOOST_COMP_KCC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_KCC_NAME "Kai C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_KCC,BOOST_COMP_KCC_NAME) - -#ifdef BOOST_COMP_KCC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_KCC_EMULATED,BOOST_COMP_KCC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/llvm.h b/ThirdParty/boost/predef/compiler/llvm.h deleted file mode 100644 index 09f2b8044b2aa44227d5b872fa3c956bde7ac36d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/llvm.h +++ /dev/null @@ -1,58 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_LLVM_H -#define BOOST_PREDEF_COMPILER_LLVM_H - -/* Other compilers that emulate this one need to be detected first. */ - -#include <boost/predef/compiler/clang.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_LLVM` - -http://en.wikipedia.org/wiki/LLVM[LLVM] compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__llvm__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_COMP_LLVM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__llvm__) -# define BOOST_COMP_LLVM_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#ifdef BOOST_COMP_LLVM_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_LLVM_EMULATED BOOST_COMP_LLVM_DETECTION -# else -# undef BOOST_COMP_LLVM -# define BOOST_COMP_LLVM BOOST_COMP_LLVM_DETECTION -# endif -# define BOOST_COMP_LLVM_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_LLVM_NAME "LLVM" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_LLVM,BOOST_COMP_LLVM_NAME) - -#ifdef BOOST_COMP_LLVM_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_LLVM_EMULATED,BOOST_COMP_LLVM_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/metaware.h b/ThirdParty/boost/predef/compiler/metaware.h deleted file mode 100644 index e210943d770e6d58b9d6598bb7fb9f06a5eb3c27..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/metaware.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_METAWARE_H -#define BOOST_PREDEF_COMPILER_METAWARE_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_HIGHC` - -MetaWare High C/{CPP} compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__HIGHC__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_COMP_HIGHC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__HIGHC__) -# define BOOST_COMP_HIGHC_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#ifdef BOOST_COMP_HIGHC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_HIGHC_EMULATED BOOST_COMP_HIGHC_DETECTION -# else -# undef BOOST_COMP_HIGHC -# define BOOST_COMP_HIGHC BOOST_COMP_HIGHC_DETECTION -# endif -# define BOOST_COMP_HIGHC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_HIGHC_NAME "MetaWare High C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_HIGHC,BOOST_COMP_HIGHC_NAME) - -#ifdef BOOST_COMP_HIGHC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_HIGHC_EMULATED,BOOST_COMP_HIGHC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/metrowerks.h b/ThirdParty/boost/predef/compiler/metrowerks.h deleted file mode 100644 index 98cb751d2978092fdc6a686364bdbb7c0da0e818..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/metrowerks.h +++ /dev/null @@ -1,78 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_METROWERKS_H -#define BOOST_PREDEF_COMPILER_METROWERKS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_MWERKS` - -http://en.wikipedia.org/wiki/CodeWarrior[Metrowerks CodeWarrior] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MWERKS__+` | {predef_detection} -| `+__CWCC__+` | {predef_detection} - -| `+__CWCC__+` | V.R.P -| `+__MWERKS__+` | V.R.P >= 4.2.0 -| `+__MWERKS__+` | 9.R.0 -| `+__MWERKS__+` | 8.R.0 -|=== -*/ // end::reference[] - -#define BOOST_COMP_MWERKS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MWERKS__) || defined(__CWCC__) -# if !defined(BOOST_COMP_MWERKS_DETECTION) && defined(__CWCC__) -# define BOOST_COMP_MWERKS_DETECTION BOOST_PREDEF_MAKE_0X_VRPP(__CWCC__) -# endif -# if !defined(BOOST_COMP_MWERKS_DETECTION) && (__MWERKS__ >= 0x4200) -# define BOOST_COMP_MWERKS_DETECTION BOOST_PREDEF_MAKE_0X_VRPP(__MWERKS__) -# endif -# if !defined(BOOST_COMP_MWERKS_DETECTION) && (__MWERKS__ >= 0x3204) // note the "skip": 04->9.3 -# define BOOST_COMP_MWERKS_DETECTION BOOST_VERSION_NUMBER(9,(__MWERKS__)%100-1,0) -# endif -# if !defined(BOOST_COMP_MWERKS_DETECTION) && (__MWERKS__ >= 0x3200) -# define BOOST_COMP_MWERKS_DETECTION BOOST_VERSION_NUMBER(9,(__MWERKS__)%100,0) -# endif -# if !defined(BOOST_COMP_MWERKS_DETECTION) && (__MWERKS__ >= 0x3000) -# define BOOST_COMP_MWERKS_DETECTION BOOST_VERSION_NUMBER(8,(__MWERKS__)%100,0) -# endif -# if !defined(BOOST_COMP_MWERKS_DETECTION) -# define BOOST_COMP_MWERKS_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_MWERKS_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_MWERKS_EMULATED BOOST_COMP_MWERKS_DETECTION -# else -# undef BOOST_COMP_MWERKS -# define BOOST_COMP_MWERKS BOOST_COMP_MWERKS_DETECTION -# endif -# define BOOST_COMP_MWERKS_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_MWERKS_NAME "Metrowerks CodeWarrior" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MWERKS,BOOST_COMP_MWERKS_NAME) - -#ifdef BOOST_COMP_MWERKS_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MWERKS_EMULATED,BOOST_COMP_MWERKS_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/microtec.h b/ThirdParty/boost/predef/compiler/microtec.h deleted file mode 100644 index 93c7e91086bfbc759912c033dc96d6a35abdb3c8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/microtec.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_MICROTEC_H -#define BOOST_PREDEF_COMPILER_MICROTEC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_MRI` - -http://www.mentor.com/microtec/[Microtec C/{CPP}] compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_MRI+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_COMP_MRI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(_MRI) -# define BOOST_COMP_MRI_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#ifdef BOOST_COMP_MRI_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_MRI_EMULATED BOOST_COMP_MRI_DETECTION -# else -# undef BOOST_COMP_MRI -# define BOOST_COMP_MRI BOOST_COMP_MRI_DETECTION -# endif -# define BOOST_COMP_MRI_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_MRI_NAME "Microtec C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MRI,BOOST_COMP_MRI_NAME) - -#ifdef BOOST_COMP_MRI_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MRI_EMULATED,BOOST_COMP_MRI_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/mpw.h b/ThirdParty/boost/predef/compiler/mpw.h deleted file mode 100644 index 963f756718060a3f02358ca2b8c6abdb8f8b63cc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/mpw.h +++ /dev/null @@ -1,64 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_MPW_H -#define BOOST_PREDEF_COMPILER_MPW_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_MPW` - -http://en.wikipedia.org/wiki/Macintosh_Programmer%27s_Workshop[MPW {CPP}] compiler. -Version number available as major, and minor. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MRC__+` | {predef_detection} -| `MPW_C` | {predef_detection} -| `MPW_CPLUS` | {predef_detection} - -| `+__MRC__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_COMP_MPW BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MRC__) || defined(MPW_C) || defined(MPW_CPLUS) -# if !defined(BOOST_COMP_MPW_DETECTION) && defined(__MRC__) -# define BOOST_COMP_MPW_DETECTION BOOST_PREDEF_MAKE_0X_VVRR(__MRC__) -# endif -# if !defined(BOOST_COMP_MPW_DETECTION) -# define BOOST_COMP_MPW_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_MPW_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_MPW_EMULATED BOOST_COMP_MPW_DETECTION -# else -# undef BOOST_COMP_MPW -# define BOOST_COMP_MPW BOOST_COMP_MPW_DETECTION -# endif -# define BOOST_COMP_MPW_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_MPW_NAME "MPW C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MPW,BOOST_COMP_MPW_NAME) - -#ifdef BOOST_COMP_MPW_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MPW_EMULATED,BOOST_COMP_MPW_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/nvcc.h b/ThirdParty/boost/predef/compiler/nvcc.h deleted file mode 100644 index 3690c53557225d89cd78c2c3b93b5a56a33832ed..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/nvcc.h +++ /dev/null @@ -1,74 +0,0 @@ -/* -Copyright Benjamin Worpitz 2018 -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_PREDEF_COMPILER_NVCC_H -#define BOOST_PREDEF_COMPILER_NVCC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_NVCC` - -https://en.wikipedia.org/wiki/NVIDIA_CUDA_Compiler[NVCC] compiler. -Version number available as major, minor, and patch beginning with version 7.5. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__NVCC__+` | {predef_detection} - -| `+__CUDACC_VER_MAJOR__+`, `+__CUDACC_VER_MINOR__+`, `+__CUDACC_VER_BUILD__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_NVCC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__NVCC__) -# if !defined(__CUDACC_VER_MAJOR__) || !defined(__CUDACC_VER_MINOR__) || !defined(__CUDACC_VER_BUILD__) -# define BOOST_COMP_NVCC_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# else -# define BOOST_COMP_NVCC_DETECTION BOOST_VERSION_NUMBER(__CUDACC_VER_MAJOR__, __CUDACC_VER_MINOR__, __CUDACC_VER_BUILD__) -# endif -#endif - -#ifdef BOOST_COMP_NVCC_DETECTION -/* -Always define BOOST_COMP_NVCC instead of BOOST_COMP_NVCC_EMULATED -The nvcc compilation process is somewhat special as can be read here: -https://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/index.html#cuda-compilation-trajectory -The nvcc compiler precompiles the input two times. Once for the device code -being compiled by the cicc device compiler and once for the host code -compiled by the real host compiler. NVCC uses gcc/clang/msvc/... -depending on the host compiler being set on the command line. - -Predef (as a preprocessor only lib) detects the one doing the preprocessing -as compiler and expects it to be the one doing the real compilation. -This is not true for NVCC which is only doing the preprocessing and which -is using another compiler for parts of its work. So for NVCC it should be -allowed to set BOOST_COMP_NVCC additionally to the already detected host -compiler because both is true: It is gcc/clang/... compiling the code, but it -is also NVCC doing the preprocessing and adding some other quirks you may -want to detect. - -This behavior is similar to what boost config is doing in `select_compiler_config.hpp`. -There the NVCC detection is not handled as a real compiler (part of the -#if-#elif) but as additional option before the real compiler. -*/ -# undef BOOST_COMP_NVCC -# define BOOST_COMP_NVCC BOOST_COMP_NVCC_DETECTION -# define BOOST_COMP_NVCC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_NVCC_NAME "NVCC" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_NVCC,BOOST_COMP_NVCC_NAME) diff --git a/ThirdParty/boost/predef/compiler/palm.h b/ThirdParty/boost/predef/compiler/palm.h deleted file mode 100644 index 7f1821519ad27a22de01f03493a566a0cca39dbe..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/palm.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_PALM_H -#define BOOST_PREDEF_COMPILER_PALM_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_PALM` - -Palm C/{CPP} compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_PACC_VER+` | {predef_detection} - -| `+_PACC_VER+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_PALM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(_PACC_VER) -# define BOOST_COMP_PALM_DETECTION BOOST_PREDEF_MAKE_0X_VRRPP000(_PACC_VER) -#endif - -#ifdef BOOST_COMP_PALM_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_PALM_EMULATED BOOST_COMP_PALM_DETECTION -# else -# undef BOOST_COMP_PALM -# define BOOST_COMP_PALM BOOST_COMP_PALM_DETECTION -# endif -# define BOOST_COMP_PALM_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_PALM_NAME "Palm C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PALM,BOOST_COMP_PALM_NAME) - -#ifdef BOOST_COMP_PALM_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PALM_EMULATED,BOOST_COMP_PALM_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/pgi.h b/ThirdParty/boost/predef/compiler/pgi.h deleted file mode 100644 index 649e87add32623d67ddaf22a1e92257b143ca3d6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/pgi.h +++ /dev/null @@ -1,61 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_PGI_H -#define BOOST_PREDEF_COMPILER_PGI_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_PGI` - -http://en.wikipedia.org/wiki/The_Portland_Group[Portland Group C/{CPP}] compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__PGI+` | {predef_detection} - -| `+__PGIC__+`, `+__PGIC_MINOR__+`, `+__PGIC_PATCHLEVEL__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_PGI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__PGI) -# if !defined(BOOST_COMP_PGI_DETECTION) && (defined(__PGIC__) && defined(__PGIC_MINOR__) && defined(__PGIC_PATCHLEVEL__)) -# define BOOST_COMP_PGI_DETECTION BOOST_VERSION_NUMBER(__PGIC__,__PGIC_MINOR__,__PGIC_PATCHLEVEL__) -# endif -# if !defined(BOOST_COMP_PGI_DETECTION) -# define BOOST_COMP_PGI_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_PGI_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_PGI_EMULATED BOOST_COMP_PGI_DETECTION -# else -# undef BOOST_COMP_PGI -# define BOOST_COMP_PGI BOOST_COMP_PGI_DETECTION -# endif -# define BOOST_COMP_PGI_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_PGI_NAME "Portland Group C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PGI,BOOST_COMP_PGI_NAME) - -#ifdef BOOST_COMP_PGI_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_PGI_EMULATED,BOOST_COMP_PGI_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/sgi_mipspro.h b/ThirdParty/boost/predef/compiler/sgi_mipspro.h deleted file mode 100644 index 7bfdc9c68bff746d32c98f0f2c3600f62bfcc873..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/sgi_mipspro.h +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_SGI_MIPSPRO_H -#define BOOST_PREDEF_COMPILER_SGI_MIPSPRO_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_SGI` - -http://en.wikipedia.org/wiki/MIPSpro[SGI MIPSpro] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__sgi+` | {predef_detection} -| `sgi` | {predef_detection} - -| `+_SGI_COMPILER_VERSION+` | V.R.P -| `+_COMPILER_VERSION+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_SGI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__sgi) || defined(sgi) -# if !defined(BOOST_COMP_SGI_DETECTION) && defined(_SGI_COMPILER_VERSION) -# define BOOST_COMP_SGI_DETECTION BOOST_PREDEF_MAKE_10_VRP(_SGI_COMPILER_VERSION) -# endif -# if !defined(BOOST_COMP_SGI_DETECTION) && defined(_COMPILER_VERSION) -# define BOOST_COMP_SGI_DETECTION BOOST_PREDEF_MAKE_10_VRP(_COMPILER_VERSION) -# endif -# if !defined(BOOST_COMP_SGI_DETECTION) -# define BOOST_COMP_SGI_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_SGI_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_SGI_EMULATED BOOST_COMP_SGI_DETECTION -# else -# undef BOOST_COMP_SGI -# define BOOST_COMP_SGI BOOST_COMP_SGI_DETECTION -# endif -# define BOOST_COMP_SGI_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_SGI_NAME "SGI MIPSpro" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SGI,BOOST_COMP_SGI_NAME) - -#ifdef BOOST_COMP_SGI_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SGI_EMULATED,BOOST_COMP_SGI_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/sunpro.h b/ThirdParty/boost/predef/compiler/sunpro.h deleted file mode 100644 index b44d0bb338c8e68e9c19e59ca2ad045041e334f8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/sunpro.h +++ /dev/null @@ -1,77 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_SUNPRO_H -#define BOOST_PREDEF_COMPILER_SUNPRO_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_SUNPRO` - -http://en.wikipedia.org/wiki/Oracle_Solaris_Studio[Oracle Solaris Studio] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SUNPRO_CC+` | {predef_detection} -| `+__SUNPRO_C+` | {predef_detection} - -| `+__SUNPRO_CC+` | V.R.P -| `+__SUNPRO_C+` | V.R.P -| `+__SUNPRO_CC+` | VV.RR.P -| `+__SUNPRO_C+` | VV.RR.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_SUNPRO BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__SUNPRO_CC) || defined(__SUNPRO_C) -# if !defined(BOOST_COMP_SUNPRO_DETECTION) && defined(__SUNPRO_CC) -# if (__SUNPRO_CC < 0x5100) -# define BOOST_COMP_SUNPRO_DETECTION BOOST_PREDEF_MAKE_0X_VRP(__SUNPRO_CC) -# else -# define BOOST_COMP_SUNPRO_DETECTION BOOST_PREDEF_MAKE_0X_VVRRP(__SUNPRO_CC) -# endif -# endif -# if !defined(BOOST_COMP_SUNPRO_DETECTION) && defined(__SUNPRO_C) -# if (__SUNPRO_C < 0x5100) -# define BOOST_COMP_SUNPRO_DETECTION BOOST_PREDEF_MAKE_0X_VRP(__SUNPRO_C) -# else -# define BOOST_COMP_SUNPRO_DETECTION BOOST_PREDEF_MAKE_0X_VVRRP(__SUNPRO_C) -# endif -# endif -# if !defined(BOOST_COMP_SUNPRO_DETECTION) -# define BOOST_COMP_SUNPRO_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_COMP_SUNPRO_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_SUNPRO_EMULATED BOOST_COMP_SUNPRO_DETECTION -# else -# undef BOOST_COMP_SUNPRO -# define BOOST_COMP_SUNPRO BOOST_COMP_SUNPRO_DETECTION -# endif -# define BOOST_COMP_SUNPRO_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_SUNPRO_NAME "Oracle Solaris Studio" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SUNPRO,BOOST_COMP_SUNPRO_NAME) - -#ifdef BOOST_COMP_SUNPRO_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_SUNPRO_EMULATED,BOOST_COMP_SUNPRO_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/tendra.h b/ThirdParty/boost/predef/compiler/tendra.h deleted file mode 100644 index bb896c0782eba8e5cea6d4a243eff9cf861ee53b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/tendra.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_TENDRA_H -#define BOOST_PREDEF_COMPILER_TENDRA_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_TENDRA` - -http://en.wikipedia.org/wiki/TenDRA_Compiler[TenDRA C/{CPP}] compiler. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__TenDRA__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_COMP_TENDRA BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__TenDRA__) -# define BOOST_COMP_TENDRA_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#ifdef BOOST_COMP_TENDRA_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_TENDRA_EMULATED BOOST_COMP_TENDRA_DETECTION -# else -# undef BOOST_COMP_TENDRA -# define BOOST_COMP_TENDRA BOOST_COMP_TENDRA_DETECTION -# endif -# define BOOST_COMP_TENDRA_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_TENDRA_NAME "TenDRA C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_TENDRA,BOOST_COMP_TENDRA_NAME) - -#ifdef BOOST_COMP_TENDRA_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_TENDRA_EMULATED,BOOST_COMP_TENDRA_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/visualc.h b/ThirdParty/boost/predef/compiler/visualc.h deleted file mode 100644 index 5b0f2b8366bf8a04b53ccefea89c968cc95d8770..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/visualc.h +++ /dev/null @@ -1,106 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_VISUALC_H -#define BOOST_PREDEF_COMPILER_VISUALC_H - -/* Other compilers that emulate this one need to be detected first. */ - -#include <boost/predef/compiler/clang.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_MSVC` - -http://en.wikipedia.org/wiki/Visual_studio[Microsoft Visual C/{CPP}] compiler. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_MSC_VER+` | {predef_detection} - -| `+_MSC_FULL_VER+` | V.R.P -| `+_MSC_VER+` | V.R.0 -|=== - -NOTE: Release of Visual Studio after 2015 will no longer be identified -by Boost Predef as the marketing version number. Instead we use the -compiler version number directly, i.e. the _MSC_VER number. -*/ // end::reference[] - -#define BOOST_COMP_MSVC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(_MSC_VER) -# if !defined (_MSC_FULL_VER) -# define BOOST_COMP_MSVC_BUILD 0 -# else - /* how many digits does the build number have? */ -# if _MSC_FULL_VER / 10000 == _MSC_VER - /* four digits */ -# define BOOST_COMP_MSVC_BUILD (_MSC_FULL_VER % 10000) -# elif _MSC_FULL_VER / 100000 == _MSC_VER - /* five digits */ -# define BOOST_COMP_MSVC_BUILD (_MSC_FULL_VER % 100000) -# else -# error "Cannot determine build number from _MSC_FULL_VER" -# endif -# endif - /* - VS2014 was skipped in the release sequence for MS. Which - means that the compiler and VS product versions are no longer - in sync. Hence we need to use different formulas for - mapping from MSC version to VS product version. - - VS2017 is a total nightmare when it comes to version numbers. - Hence to avoid arguments relating to that both present and - future.. Any version after VS2015 will use solely the compiler - version, i.e. cl.exe, as the version number here. - */ -# if (_MSC_VER > 1900) -# define BOOST_COMP_MSVC_DETECTION BOOST_VERSION_NUMBER(\ - _MSC_VER/100,\ - _MSC_VER%100,\ - BOOST_COMP_MSVC_BUILD) -# elif (_MSC_VER >= 1900) -# define BOOST_COMP_MSVC_DETECTION BOOST_VERSION_NUMBER(\ - _MSC_VER/100-5,\ - _MSC_VER%100,\ - BOOST_COMP_MSVC_BUILD) -# else -# define BOOST_COMP_MSVC_DETECTION BOOST_VERSION_NUMBER(\ - _MSC_VER/100-6,\ - _MSC_VER%100,\ - BOOST_COMP_MSVC_BUILD) -# endif -#endif - -#ifdef BOOST_COMP_MSVC_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_MSVC_EMULATED BOOST_COMP_MSVC_DETECTION -# else -# undef BOOST_COMP_MSVC -# define BOOST_COMP_MSVC BOOST_COMP_MSVC_DETECTION -# endif -# define BOOST_COMP_MSVC_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_MSVC_NAME "Microsoft Visual C/C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MSVC,BOOST_COMP_MSVC_NAME) - -#ifdef BOOST_COMP_MSVC_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_MSVC_EMULATED,BOOST_COMP_MSVC_NAME) -#endif diff --git a/ThirdParty/boost/predef/compiler/watcom.h b/ThirdParty/boost/predef/compiler/watcom.h deleted file mode 100644 index 1f8c069dc16dcf0b784643cdd7f8de883d039454..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/compiler/watcom.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_COMPILER_WATCOM_H -#define BOOST_PREDEF_COMPILER_WATCOM_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_COMP_WATCOM` - -http://en.wikipedia.org/wiki/Watcom[Watcom {CPP}] compiler. -Version number available as major, and minor. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__WATCOMC__+` | {predef_detection} - -| `+__WATCOMC__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_COMP_WATCOM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__WATCOMC__) -# define BOOST_COMP_WATCOM_DETECTION BOOST_PREDEF_MAKE_10_VVRR(__WATCOMC__) -#endif - -#ifdef BOOST_COMP_WATCOM_DETECTION -# if defined(BOOST_PREDEF_DETAIL_COMP_DETECTED) -# define BOOST_COMP_WATCOM_EMULATED BOOST_COMP_WATCOM_DETECTION -# else -# undef BOOST_COMP_WATCOM -# define BOOST_COMP_WATCOM BOOST_COMP_WATCOM_DETECTION -# endif -# define BOOST_COMP_WATCOM_AVAILABLE -# include <boost/predef/detail/comp_detected.h> -#endif - -#define BOOST_COMP_WATCOM_NAME "Watcom C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_WATCOM,BOOST_COMP_WATCOM_NAME) - -#ifdef BOOST_COMP_WATCOM_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_COMP_WATCOM_EMULATED,BOOST_COMP_WATCOM_NAME) -#endif diff --git a/ThirdParty/boost/predef/hardware/simd.h b/ThirdParty/boost/predef/hardware/simd.h deleted file mode 100644 index b671fa3be9129b87979176aeab51a4b89e2c1725..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd.h +++ /dev/null @@ -1,168 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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/predef/hardware/simd/x86.h> -#include <boost/predef/hardware/simd/x86_amd.h> -#include <boost/predef/hardware/simd/arm.h> -#include <boost/predef/hardware/simd/ppc.h> - -#ifndef BOOST_PREDEF_HARDWARE_SIMD_H -#define BOOST_PREDEF_HARDWARE_SIMD_H - -#include <boost/predef/version_number.h> - -/* tag::reference[] -= Using the `BOOST_HW_SIMD_*` predefs - -SIMD predefs depend on compiler options. For example, you will have to add the -option `-msse3` to clang or gcc to enable SSE3. SIMD predefs are also inclusive. -This means that if SSE3 is enabled, then every other extensions with a lower -version number will implicitly be enabled and detected. However, some extensions -are CPU specific, they may not be detected nor enabled when an upper version is -enabled. - -NOTE: SSE(1) and SSE2 are automatically enabled by default when using x86-64 -architecture. - -To check if any SIMD extension has been enabled, you can use: - -[source] ----- -#include <boost/predef/hardware/simd.h> -#include <iostream> - -int main() -{ -#if defined(BOOST_HW_SIMD_AVAILABLE) - std::cout << "SIMD detected!" << std::endl; -#endif - return 0; -} ----- - -When writing SIMD specific code, you may want to check if a particular extension -has been detected. To do so you have to use the right architecture predef and -compare it. Those predef are of the form `BOOST_HW_SIMD_"ARCH"` (where `"ARCH"` -is either `ARM`, `PPC`, or `X86`). For example, if you compile code for x86 -architecture, you will have to use `BOOST_HW_SIMD_X86`. Its value will be the -version number of the most recent SIMD extension detected for the architecture. - -To check if an extension has been enabled: - -[source] ----- -#include <boost/predef/hardware/simd.h> -#include <iostream> - -int main() -{ -#if BOOST_HW_SIMD_X86 >= BOOST_HW_SIMD_X86_SSE3_VERSION - std::cout << "This is SSE3!" << std::endl; -#endif - return 0; -} ----- - -NOTE: The *_VERSION* defines that map version number to actual real -identifiers. This way it is easier to write comparisons without messing up with -version numbers. - -To *"strictly"* check the most recent detected extension: - -[source] ----- -#include <boost/predef/hardware/simd.h> -#include <iostream> - -int main() -{ -#if BOOST_HW_SIMD_X86 == BOOST_HW_SIMD_X86_SSE3_VERSION - std::cout << "This is SSE3 and this is the most recent enabled extension!" - << std::endl; -#endif - return 0; -} ----- - -Because of the version systems of predefs and of the inclusive property of SIMD -extensions macros, you can easily check for ranges of supported extensions: - -[source] ----- -#include <boost/predef/hardware/simd.h> -#include <iostream> - -int main() -{ -#if BOOST_HW_SIMD_X86 >= BOOST_HW_SIMD_X86_SSE2_VERSION &&\ - BOOST_HW_SIMD_X86 <= BOOST_HW_SIMD_X86_SSSE3_VERSION - std::cout << "This is SSE2, SSE3 and SSSE3!" << std::endl; -#endif - return 0; -} ----- - -NOTE: Unlike gcc and clang, Visual Studio does not allow you to specify precisely -the SSE variants you want to use, the only detections that will take place are -SSE, SSE2, AVX and AVX2. For more informations, - see [@https://msdn.microsoft.com/en-us/library/b0084kay.aspx here]. - - -*/ // end::reference[] - -// We check if SIMD extension of multiples architectures have been detected, -// if yes, then this is an error! -// -// NOTE: _X86_AMD implies _X86, so there is no need to check for it here! -// -#if defined(BOOST_HW_SIMD_ARM_AVAILABLE) && defined(BOOST_HW_SIMD_PPC_AVAILABLE) ||\ - defined(BOOST_HW_SIMD_ARM_AVAILABLE) && defined(BOOST_HW_SIMD_X86_AVAILABLE) ||\ - defined(BOOST_HW_SIMD_PPC_AVAILABLE) && defined(BOOST_HW_SIMD_X86_AVAILABLE) -# error "Multiple SIMD architectures detected, this cannot happen!" -#endif - -#if defined(BOOST_HW_SIMD_X86_AVAILABLE) && defined(BOOST_HW_SIMD_X86_AMD_AVAILABLE) - // If both standard _X86 and _X86_AMD are available, - // then take the biggest version of the two! -# if BOOST_HW_SIMD_X86 >= BOOST_HW_SIMD_X86_AMD -# define BOOST_HW_SIMD BOOST_HW_SIMD_X86 -# else -# define BOOST_HW_SIMD BOOST_HW_SIMD_X86_AMD -# endif -#endif - -#if !defined(BOOST_HW_SIMD) - // At this point, only one of these two is defined -# if defined(BOOST_HW_SIMD_X86_AVAILABLE) -# define BOOST_HW_SIMD BOOST_HW_SIMD_X86 -# endif -# if defined(BOOST_HW_SIMD_X86_AMD_AVAILABLE) -# define BOOST_HW_SIMD BOOST_HW_SIMD_X86_AMD -# endif -#endif - -#if defined(BOOST_HW_SIMD_ARM_AVAILABLE) -# define BOOST_HW_SIMD BOOST_HW_SIMD_ARM -#endif - -#if defined(BOOST_HW_SIMD_PPC_AVAILABLE) -# define BOOST_HW_SIMD BOOST_HW_SIMD_PPC -#endif - -#if defined(BOOST_HW_SIMD) -# define BOOST_HW_SIMD_AVAILABLE -#else -# define BOOST_HW_SIMD BOOST_VERSION_NUMBER_NOT_AVAILABLE -#endif - -#define BOOST_HW_SIMD_NAME "Hardware SIMD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD, BOOST_HW_SIMD_NAME) diff --git a/ThirdParty/boost/predef/hardware/simd/arm.h b/ThirdParty/boost/predef/hardware/simd/arm.h deleted file mode 100644 index 24e4c1b0910b02114a850fcf5fcd2112fd4d83b4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/arm.h +++ /dev/null @@ -1,61 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_ARM_H -#define BOOST_PREDEF_HARDWARE_SIMD_ARM_H - -#include <boost/predef/version_number.h> -#include <boost/predef/hardware/simd/arm/versions.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_ARM` - -The SIMD extension for ARM (*if detected*). -Version number depends on the most recent detected extension. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ARM_NEON__+` | {predef_detection} -| `+__aarch64__+` | {predef_detection} -| `+_M_ARM+` | {predef_detection} -| `+_M_ARM64+` | {predef_detection} -|=== - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ARM_NEON__+` | BOOST_HW_SIMD_ARM_NEON_VERSION -| `+__aarch64__+` | BOOST_HW_SIMD_ARM_NEON_VERSION -| `+_M_ARM+` | BOOST_HW_SIMD_ARM_NEON_VERSION -| `+_M_ARM64+` | BOOST_HW_SIMD_ARM_NEON_VERSION -|=== - -*/ // end::reference[] - -#define BOOST_HW_SIMD_ARM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#undef BOOST_HW_SIMD_ARM -#if !defined(BOOST_HW_SIMD_ARM) && (defined(__ARM_NEON__) || defined(__aarch64__) || defined (_M_ARM) || defined (_M_ARM64)) -# define BOOST_HW_SIMD_ARM BOOST_HW_SIMD_ARM_NEON_VERSION -#endif - -#if !defined(BOOST_HW_SIMD_ARM) -# define BOOST_HW_SIMD_ARM BOOST_VERSION_NUMBER_NOT_AVAILABLE -#else -# define BOOST_HW_SIMD_ARM_AVAILABLE -#endif - -#define BOOST_HW_SIMD_ARM_NAME "ARM SIMD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD_ARM, BOOST_HW_SIMD_ARM_NAME) diff --git a/ThirdParty/boost/predef/hardware/simd/arm/versions.h b/ThirdParty/boost/predef/hardware/simd/arm/versions.h deleted file mode 100644 index 92071a6b36e075589f99ecd3596d28216e2c0ef6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/arm/versions.h +++ /dev/null @@ -1,38 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_ARM_VERSIONS_H -#define BOOST_PREDEF_HARDWARE_SIMD_ARM_VERSIONS_H - -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_ARM_*_VERSION` - -Those defines represent ARM SIMD extensions versions. - -NOTE: You *MUST* compare them with the predef `BOOST_HW_SIMD_ARM`. -*/ // end::reference[] - -// --------------------------------- - -/* tag::reference[] -= `BOOST_HW_SIMD_ARM_NEON_VERSION` - -The https://en.wikipedia.org/wiki/ARM_architecture#Advanced_SIMD_.28NEON.29[NEON] -ARM extension version number. - -Version number is: *1.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_ARM_NEON_VERSION BOOST_VERSION_NUMBER(1, 0, 0) - -/* tag::reference[] - -*/ // end::reference[] - -#endif diff --git a/ThirdParty/boost/predef/hardware/simd/ppc.h b/ThirdParty/boost/predef/hardware/simd/ppc.h deleted file mode 100644 index bf30cc1e81b84e1ab360279da616428ea5bb8427..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/ppc.h +++ /dev/null @@ -1,71 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_PPC_H -#define BOOST_PREDEF_HARDWARE_SIMD_PPC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/hardware/simd/ppc/versions.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_PPC` - -The SIMD extension for PowerPC (*if detected*). -Version number depends on the most recent detected extension. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__VECTOR4DOUBLE__+` | {predef_detection} - -| `+__ALTIVEC__+` | {predef_detection} -| `+__VEC__+` | {predef_detection} - -| `+__VSX__+` | {predef_detection} -|=== - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__VECTOR4DOUBLE__+` | BOOST_HW_SIMD_PPC_QPX_VERSION - -| `+__ALTIVEC__+` | BOOST_HW_SIMD_PPC_VMX_VERSION -| `+__VEC__+` | BOOST_HW_SIMD_PPC_VMX_VERSION - -| `+__VSX__+` | BOOST_HW_SIMD_PPC_VSX_VERSION -|=== - -*/ // end::reference[] - -#define BOOST_HW_SIMD_PPC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#undef BOOST_HW_SIMD_PPC -#if !defined(BOOST_HW_SIMD_PPC) && defined(__VECTOR4DOUBLE__) -# define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_QPX_VERSION -#endif -#if !defined(BOOST_HW_SIMD_PPC) && defined(__VSX__) -# define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_VSX_VERSION -#endif -#if !defined(BOOST_HW_SIMD_PPC) && (defined(__ALTIVEC__) || defined(__VEC__)) -# define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_VMX_VERSION -#endif - -#if !defined(BOOST_HW_SIMD_PPC) -# define BOOST_HW_SIMD_PPC BOOST_VERSION_NUMBER_NOT_AVAILABLE -#else -# define BOOST_HW_SIMD_PPC_AVAILABLE -#endif - -#define BOOST_HW_SIMD_PPC_NAME "PPC SIMD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD_PPC, BOOST_HW_SIMD_PPC_NAME) diff --git a/ThirdParty/boost/predef/hardware/simd/ppc/versions.h b/ThirdParty/boost/predef/hardware/simd/ppc/versions.h deleted file mode 100644 index 3cf8319c2460181deedfc5ba3dfd34e74200355c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/ppc/versions.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_PPC_VERSIONS_H -#define BOOST_PREDEF_HARDWARE_SIMD_PPC_VERSIONS_H - -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_PPC_*_VERSION` - -Those defines represent Power PC SIMD extensions versions. - -NOTE: You *MUST* compare them with the predef `BOOST_HW_SIMD_PPC`. -*/ // end::reference[] - -// --------------------------------- - -/* tag::reference[] -= `BOOST_HW_SIMD_PPC_VMX_VERSION` - -The https://en.wikipedia.org/wiki/AltiVec#VMX128[VMX] powerpc extension -version number. - -Version number is: *1.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_PPC_VMX_VERSION BOOST_VERSION_NUMBER(1, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_PPC_VSX_VERSION` - -The https://en.wikipedia.org/wiki/AltiVec#VSX[VSX] powerpc extension version -number. - -Version number is: *1.1.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_PPC_VSX_VERSION BOOST_VERSION_NUMBER(1, 1, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_PPC_QPX_VERSION` - -The QPX powerpc extension version number. - -Version number is: *2.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_PPC_QPX_VERSION BOOST_VERSION_NUMBER(2, 0, 0) - -/* tag::reference[] - -*/ // end::reference[] - -#endif diff --git a/ThirdParty/boost/predef/hardware/simd/x86.h b/ThirdParty/boost/predef/hardware/simd/x86.h deleted file mode 100644 index 6c9a0fb8ab2608ee0ab0cbca6a2e527c7fe6f266..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/x86.h +++ /dev/null @@ -1,125 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_X86_H -#define BOOST_PREDEF_HARDWARE_SIMD_X86_H - -#include <boost/predef/version_number.h> -#include <boost/predef/hardware/simd/x86/versions.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_X86` - -The SIMD extension for x86 (*if detected*). -Version number depends on the most recent detected extension. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SSE__+` | {predef_detection} -| `+_M_X64+` | {predef_detection} -| `_M_IX86_FP >= 1` | {predef_detection} - -| `+__SSE2__+` | {predef_detection} -| `+_M_X64+` | {predef_detection} -| `_M_IX86_FP >= 2` | {predef_detection} - -| `+__SSE3__+` | {predef_detection} - -| `+__SSSE3__+` | {predef_detection} - -| `+__SSE4_1__+` | {predef_detection} - -| `+__SSE4_2__+` | {predef_detection} - -| `+__AVX__+` | {predef_detection} - -| `+__FMA__+` | {predef_detection} - -| `+__AVX2__+` | {predef_detection} -|=== - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SSE__+` | BOOST_HW_SIMD_X86_SSE_VERSION -| `+_M_X64+` | BOOST_HW_SIMD_X86_SSE_VERSION -| `_M_IX86_FP >= 1` | BOOST_HW_SIMD_X86_SSE_VERSION - -| `+__SSE2__+` | BOOST_HW_SIMD_X86_SSE2_VERSION -| `+_M_X64+` | BOOST_HW_SIMD_X86_SSE2_VERSION -| `_M_IX86_FP >= 2` | BOOST_HW_SIMD_X86_SSE2_VERSION - -| `+__SSE3__+` | BOOST_HW_SIMD_X86_SSE3_VERSION - -| `+__SSSE3__+` | BOOST_HW_SIMD_X86_SSSE3_VERSION - -| `+__SSE4_1__+` | BOOST_HW_SIMD_X86_SSE4_1_VERSION - -| `+__SSE4_2__+` | BOOST_HW_SIMD_X86_SSE4_2_VERSION - -| `+__AVX__+` | BOOST_HW_SIMD_X86_AVX_VERSION - -| `+__FMA__+` | BOOST_HW_SIMD_X86_FMA3_VERSION - -| `+__AVX2__+` | BOOST_HW_SIMD_X86_AVX2_VERSION -|=== - -*/ // end::reference[] - -#define BOOST_HW_SIMD_X86 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#undef BOOST_HW_SIMD_X86 -#if !defined(BOOST_HW_SIMD_X86) && defined(__MIC__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_MIC_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__AVX2__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_AVX2_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__AVX__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_AVX_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__FMA__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_FMA_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__SSE4_2__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSE4_2_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__SSE4_1__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSE4_1_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__SSSE3__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSSE3_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__SSE3__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSE3_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && (defined(__SSE2__) || defined(_M_X64) || (defined(_M_IX86_FP) && _M_IX86_FP >= 2)) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSE2_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && (defined(__SSE__) || defined(_M_X64) || (defined(_M_IX86_FP) && _M_IX86_FP >= 1)) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_SSE_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86) && defined(__MMX__) -# define BOOST_HW_SIMD_X86 BOOST_HW_SIMD_X86_MMX_VERSION -#endif - -#if !defined(BOOST_HW_SIMD_X86) -# define BOOST_HW_SIMD_X86 BOOST_VERSION_NUMBER_NOT_AVAILABLE -#else -# define BOOST_HW_SIMD_X86_AVAILABLE -#endif - -#define BOOST_HW_SIMD_X86_NAME "x86 SIMD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD_X86, BOOST_HW_SIMD_X86_NAME) diff --git a/ThirdParty/boost/predef/hardware/simd/x86/versions.h b/ThirdParty/boost/predef/hardware/simd/x86/versions.h deleted file mode 100644 index ef5b002d4141e0ec58b52be030b98ed5671ce6c0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/x86/versions.h +++ /dev/null @@ -1,135 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_X86_VERSIONS_H -#define BOOST_PREDEF_HARDWARE_SIMD_X86_VERSIONS_H - -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_*_VERSION` - -Those defines represent x86 SIMD extensions versions. - -NOTE: You *MUST* compare them with the predef `BOOST_HW_SIMD_X86`. -*/ // end::reference[] - -// --------------------------------- - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_MMX_VERSION` - -The https://en.wikipedia.org/wiki/MMX_(instruction_set)[MMX] x86 extension -version number. - -Version number is: *0.99.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_MMX_VERSION BOOST_VERSION_NUMBER(0, 99, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSE_VERSION` - -The https://en.wikipedia.org/wiki/Streaming_SIMD_Extensions[SSE] x86 extension -version number. - -Version number is: *1.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSE_VERSION BOOST_VERSION_NUMBER(1, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSE2_VERSION` - -The https://en.wikipedia.org/wiki/SSE2[SSE2] x86 extension version number. - -Version number is: *2.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSE2_VERSION BOOST_VERSION_NUMBER(2, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSE3_VERSION` - -The https://en.wikipedia.org/wiki/SSE3[SSE3] x86 extension version number. - -Version number is: *3.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSE3_VERSION BOOST_VERSION_NUMBER(3, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSSE3_VERSION` - -The https://en.wikipedia.org/wiki/SSSE3[SSSE3] x86 extension version number. - -Version number is: *3.1.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSSE3_VERSION BOOST_VERSION_NUMBER(3, 1, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSE4_1_VERSION` - -The https://en.wikipedia.org/wiki/SSE4#SSE4.1[SSE4_1] x86 extension version -number. - -Version number is: *4.1.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSE4_1_VERSION BOOST_VERSION_NUMBER(4, 1, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_SSE4_2_VERSION` - -The https://en.wikipedia.org/wiki/SSE4##SSE4.2[SSE4_2] x86 extension version -number. - -Version number is: *4.2.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_SSE4_2_VERSION BOOST_VERSION_NUMBER(4, 2, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AVX_VERSION` - -The https://en.wikipedia.org/wiki/Advanced_Vector_Extensions[AVX] x86 -extension version number. - -Version number is: *5.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_AVX_VERSION BOOST_VERSION_NUMBER(5, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_FMA3_VERSION` - -The https://en.wikipedia.org/wiki/FMA_instruction_set[FMA3] x86 extension -version number. - -Version number is: *5.2.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_FMA3_VERSION BOOST_VERSION_NUMBER(5, 2, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AVX2_VERSION` - -The https://en.wikipedia.org/wiki/Advanced_Vector_Extensions#Advanced_Vector_Extensions_2[AVX2] -x86 extension version number. - -Version number is: *5.3.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_AVX2_VERSION BOOST_VERSION_NUMBER(5, 3, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_MIC_VERSION` - -The https://en.wikipedia.org/wiki/Xeon_Phi[MIC] (Xeon Phi) x86 extension -version number. - -Version number is: *9.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_MIC_VERSION BOOST_VERSION_NUMBER(9, 0, 0) - -/* tag::reference[] - -*/ // end::reference[] - -#endif diff --git a/ThirdParty/boost/predef/hardware/simd/x86_amd.h b/ThirdParty/boost/predef/hardware/simd/x86_amd.h deleted file mode 100644 index ed96af35730f39a7f8d5a8bf3d75eb0c968567ff..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/x86_amd.h +++ /dev/null @@ -1,89 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_X86_AMD_H -#define BOOST_PREDEF_HARDWARE_SIMD_X86_AMD_H - -#include <boost/predef/version_number.h> -#include <boost/predef/hardware/simd/x86_amd/versions.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AMD` - -The SIMD extension for x86 (AMD) (*if detected*). -Version number depends on the most recent detected extension. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SSE4A__+` | {predef_detection} - -| `+__FMA4__+` | {predef_detection} - -| `+__XOP__+` | {predef_detection} - -| `BOOST_HW_SIMD_X86` | {predef_detection} -|=== - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SSE4A__+` | BOOST_HW_SIMD_X86_SSE4A_VERSION - -| `+__FMA4__+` | BOOST_HW_SIMD_X86_FMA4_VERSION - -| `+__XOP__+` | BOOST_HW_SIMD_X86_XOP_VERSION - -| `BOOST_HW_SIMD_X86` | BOOST_HW_SIMD_X86 -|=== - -NOTE: This predef includes every other x86 SIMD extensions and also has other -more specific extensions (FMA4, XOP, SSE4a). You should use this predef -instead of `BOOST_HW_SIMD_X86` to test if those specific extensions have -been detected. - -*/ // end::reference[] - -#define BOOST_HW_SIMD_X86_AMD BOOST_VERSION_NUMBER_NOT_AVAILABLE - -// AMD CPUs also use x86 architecture. We first try to detect if any AMD -// specific extension are detected, if yes, then try to detect more recent x86 -// common extensions. - -#undef BOOST_HW_SIMD_X86_AMD -#if !defined(BOOST_HW_SIMD_X86_AMD) && defined(__XOP__) -# define BOOST_HW_SIMD_X86_AMD BOOST_HW_SIMD_X86_AMD_XOP_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86_AMD) && defined(__FMA4__) -# define BOOST_HW_SIMD_X86_AMD BOOST_HW_SIMD_X86_AMD_FMA4_VERSION -#endif -#if !defined(BOOST_HW_SIMD_X86_AMD) && defined(__SSE4A__) -# define BOOST_HW_SIMD_X86_AMD BOOST_HW_SIMD_X86_AMD_SSE4A_VERSION -#endif - -#if !defined(BOOST_HW_SIMD_X86_AMD) -# define BOOST_HW_SIMD_X86_AMD BOOST_VERSION_NUMBER_NOT_AVAILABLE -#else - // At this point, we know that we have an AMD CPU, we do need to check for - // other x86 extensions to determine the final version number. -# include <boost/predef/hardware/simd/x86.h> -# if BOOST_HW_SIMD_X86 > BOOST_HW_SIMD_X86_AMD -# undef BOOST_HW_SIMD_X86_AMD -# define BOOST_HW_SIMD_X86_AMD BOOST_HW_SIMD_X86 -# endif -# define BOOST_HW_SIMD_X86_AMD_AVAILABLE -#endif - -#define BOOST_HW_SIMD_X86_AMD_NAME "x86 (AMD) SIMD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD_X86_AMD, BOOST_HW_SIMD_X86_AMD_NAME) diff --git a/ThirdParty/boost/predef/hardware/simd/x86_amd/versions.h b/ThirdParty/boost/predef/hardware/simd/x86_amd/versions.h deleted file mode 100644 index aa54a5cb17e6f90abb5e905a8ac067822d45d447..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/hardware/simd/x86_amd/versions.h +++ /dev/null @@ -1,56 +0,0 @@ -/* -Copyright Charly Chevalier 2015 -Copyright Joel Falcou 2015 -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_PREDEF_HARDWARE_SIMD_X86_AMD_VERSIONS_H -#define BOOST_PREDEF_HARDWARE_SIMD_X86_AMD_VERSIONS_H - -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AMD_*_VERSION` - -Those defines represent x86 (AMD specific) SIMD extensions versions. - -NOTE: You *MUST* compare them with the predef `BOOST_HW_SIMD_X86_AMD`. -*/ // end::reference[] - - -// --------------------------------- - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AMD_SSE4A_VERSION` - -https://en.wikipedia.org/wiki/SSE4##SSE4A[SSE4A] x86 extension (AMD specific). - -Version number is: *4.0.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_AMD_SSE4A_VERSION BOOST_VERSION_NUMBER(4, 0, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AMD_FMA4_VERSION` - -https://en.wikipedia.org/wiki/FMA_instruction_set#FMA4_instruction_set[FMA4] x86 extension (AMD specific). - -Version number is: *5.1.0*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_AMD_FMA4_VERSION BOOST_VERSION_NUMBER(5, 1, 0) - -/* tag::reference[] -= `BOOST_HW_SIMD_X86_AMD_XOP_VERSION` - -https://en.wikipedia.org/wiki/XOP_instruction_set[XOP] x86 extension (AMD specific). - -Version number is: *5.1.1*. -*/ // end::reference[] -#define BOOST_HW_SIMD_X86_AMD_XOP_VERSION BOOST_VERSION_NUMBER(5, 1, 1) - -/* tag::reference[] - -*/ // end::reference[] - -#endif diff --git a/ThirdParty/boost/predef/language/cuda.h b/ThirdParty/boost/predef/language/cuda.h deleted file mode 100644 index 1159af4986dd34017d489a7ec87f474eb20a536d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/language/cuda.h +++ /dev/null @@ -1,53 +0,0 @@ -/* -Copyright Benjamin Worpitz 2018 -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_PREDEF_LANGUAGE_CUDA_H -#define BOOST_PREDEF_LANGUAGE_CUDA_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LANG_CUDA` - -https://en.wikipedia.org/wiki/CUDA[CUDA C/{CPP}] language. -If available, the version is detected as VV.RR.P. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__CUDACC__+` | {predef_detection} -| `+__CUDA__+` | {predef_detection} - -| `CUDA_VERSION` | VV.RR.P -|=== -*/ // end::reference[] - -#define BOOST_LANG_CUDA BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__CUDACC__) || defined(__CUDA__) -# undef BOOST_LANG_CUDA -# include <cuda.h> -# if defined(CUDA_VERSION) -# define BOOST_LANG_CUDA BOOST_PREDEF_MAKE_10_VVRRP(CUDA_VERSION) -# else -# define BOOST_LANG_CUDA BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LANG_CUDA -# define BOOST_LANG_CUDA_AVAILABLE -#endif - -#define BOOST_LANG_CUDA_NAME "CUDA C/C++" - - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_CUDA,BOOST_LANG_CUDA_NAME) diff --git a/ThirdParty/boost/predef/language/objc.h b/ThirdParty/boost/predef/language/objc.h deleted file mode 100644 index c521371daa91d8b60cec49de3535619c02cabea3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/language/objc.h +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_LANGUAGE_OBJC_H -#define BOOST_PREDEF_LANGUAGE_OBJC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LANG_OBJC` - -http://en.wikipedia.org/wiki/Objective-C[Objective-C] language. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__OBJC__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_LANG_OBJC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__OBJC__) -# undef BOOST_LANG_OBJC -# define BOOST_LANG_OBJC BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_LANG_OBJC -# define BOOST_LANG_OBJC_AVAILABLE -#endif - -#define BOOST_LANG_OBJC_NAME "Objective-C" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_OBJC,BOOST_LANG_OBJC_NAME) diff --git a/ThirdParty/boost/predef/language/stdc.h b/ThirdParty/boost/predef/language/stdc.h deleted file mode 100644 index 94e30fe6c62d119dc05b6187c0a0ff7487c9d028..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/language/stdc.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_LANGUAGE_STDC_H -#define BOOST_PREDEF_LANGUAGE_STDC_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LANG_STDC` - -http://en.wikipedia.org/wiki/C_(programming_language)[Standard C] language. -If available, the year of the standard is detected as YYYY.MM.1 from the Epoc date. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__STDC__+` | {predef_detection} - -| `+__STDC_VERSION__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LANG_STDC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__STDC__) -# undef BOOST_LANG_STDC -# if defined(__STDC_VERSION__) -# if (__STDC_VERSION__ > 100) -# define BOOST_LANG_STDC BOOST_PREDEF_MAKE_YYYYMM(__STDC_VERSION__) -# else -# define BOOST_LANG_STDC BOOST_VERSION_NUMBER_AVAILABLE -# endif -# else -# define BOOST_LANG_STDC BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LANG_STDC -# define BOOST_LANG_STDC_AVAILABLE -#endif - -#define BOOST_LANG_STDC_NAME "Standard C" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDC,BOOST_LANG_STDC_NAME) diff --git a/ThirdParty/boost/predef/language/stdcpp.h b/ThirdParty/boost/predef/language/stdcpp.h deleted file mode 100644 index fc83431ced5c74e1ee34b0b7c360a678d51346a8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/language/stdcpp.h +++ /dev/null @@ -1,128 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_LANGUAGE_STDCPP_H -#define BOOST_PREDEF_LANGUAGE_STDCPP_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LANG_STDCPP` - -http://en.wikipedia.org/wiki/C%2B%2B[Standard {CPP}] language. -If available, the year of the standard is detected as YYYY.MM.1 from the Epoc date. -Because of the way the {CPP} standardization process works the -defined version year will not be the commonly known year of the standard. -Specifically the defined versions are: - -.Detected Version Number vs. {CPP} Standard Year -[options="header"] -|=== -| Detected Version Number | Standard Year | {CPP} Standard -| 27.11.1 | 1998 | ISO/IEC 14882:1998 -| 41.3.1 | 2011 | ISO/IEC 14882:2011 -| 44.2.1 | 2014 | ISO/IEC 14882:2014 -| 47.3.1 | 2017 | ISO/IEC 14882:2017 -|=== - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__cplusplus+` | {predef_detection} - -| `+__cplusplus+` | YYYY.MM.1 -|=== -*/ // end::reference[] - -#define BOOST_LANG_STDCPP BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__cplusplus) -# undef BOOST_LANG_STDCPP -# if (__cplusplus > 100) -# define BOOST_LANG_STDCPP BOOST_PREDEF_MAKE_YYYYMM(__cplusplus) -# else -# define BOOST_LANG_STDCPP BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LANG_STDCPP -# define BOOST_LANG_STDCPP_AVAILABLE -#endif - -#define BOOST_LANG_STDCPP_NAME "Standard C++" - -/* tag::reference[] -= `BOOST_LANG_STDCPPCLI` - -http://en.wikipedia.org/wiki/C%2B%2B/CLI[Standard {CPP}/CLI] language. -If available, the year of the standard is detected as YYYY.MM.1 from the Epoc date. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__cplusplus_cli+` | {predef_detection} - -| `+__cplusplus_cli+` | YYYY.MM.1 -|=== -*/ // end::reference[] - -#define BOOST_LANG_STDCPPCLI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__cplusplus_cli) -# undef BOOST_LANG_STDCPPCLI -# if (__cplusplus_cli > 100) -# define BOOST_LANG_STDCPPCLI BOOST_PREDEF_MAKE_YYYYMM(__cplusplus_cli) -# else -# define BOOST_LANG_STDCPPCLI BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LANG_STDCPPCLI -# define BOOST_LANG_STDCPPCLI_AVAILABLE -#endif - -#define BOOST_LANG_STDCPPCLI_NAME "Standard C++/CLI" - -/* tag::reference[] -= `BOOST_LANG_STDECPP` - -http://en.wikipedia.org/wiki/Embedded_C%2B%2B[Standard Embedded {CPP}] language. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__embedded_cplusplus+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_LANG_STDECPP BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__embedded_cplusplus) -# undef BOOST_LANG_STDECPP -# define BOOST_LANG_STDECPP BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_LANG_STDECPP -# define BOOST_LANG_STDECPP_AVAILABLE -#endif - -#define BOOST_LANG_STDECPP_NAME "Standard Embedded C++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDCPP,BOOST_LANG_STDCPP_NAME) - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDCPPCLI,BOOST_LANG_STDCPPCLI_NAME) - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_STDECPP,BOOST_LANG_STDECPP_NAME) diff --git a/ThirdParty/boost/predef/library/c/cloudabi.h b/ThirdParty/boost/predef/library/c/cloudabi.h deleted file mode 100644 index 80ce81caefd58a4f7aa29450be5c578a51addae4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/c/cloudabi.h +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright (C) 2017 James E. King III - * - * 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_PREDEF_LIBRARY_C_CLOUDABI_H -#define BOOST_PREDEF_LIBRARY_C_CLOUDABI_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -#include <boost/predef/library/c/_prefix.h> - -#if defined(__CloudABI__) -#include <stddef.h> -#endif - -/* tag::reference[] -= `BOOST_LIB_C_CLOUDABI` - -https://github.com/NuxiNL/cloudlibc[cloudlibc] - CloudABI's standard C library. -Version number available as major, and minor. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__cloudlibc__+` | {predef_detection} - -| `+__cloudlibc_major__+`, `+__cloudlibc_minor__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_LIB_C_CLOUDABI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__cloudlibc__) -# undef BOOST_LIB_C_CLOUDABI -# define BOOST_LIB_C_CLOUDABI \ - BOOST_VERSION_NUMBER(__cloudlibc_major__,__cloudlibc_minor__,0) -#endif - -#if BOOST_LIB_C_CLOUDABI -# define BOOST_LIB_C_CLOUDABI_AVAILABLE -#endif - -#define BOOST_LIB_C_CLOUDABI_NAME "cloudlibc" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_C_CLOUDABI,BOOST_LIB_C_CLOUDABI_NAME) diff --git a/ThirdParty/boost/predef/library/c/gnu.h b/ThirdParty/boost/predef/library/c/gnu.h deleted file mode 100644 index dd7a2052bedd8ab67f46d84d3e4253167a6eb59a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/c/gnu.h +++ /dev/null @@ -1,62 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_C_GNU_H -#define BOOST_PREDEF_LIBRARY_C_GNU_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -#include <boost/predef/library/c/_prefix.h> - -#if defined(__STDC__) -#include <stddef.h> -#elif defined(__cplusplus) -#include <cstddef> -#endif - -/* tag::reference[] -= `BOOST_LIB_C_GNU` - -http://en.wikipedia.org/wiki/Glibc[GNU glibc] Standard C library. -Version number available as major, and minor. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__GLIBC__+` | {predef_detection} -| `+__GNU_LIBRARY__+` | {predef_detection} - -| `+__GLIBC__+`, `+__GLIBC_MINOR__+` | V.R.0 -| `+__GNU_LIBRARY__+`, `+__GNU_LIBRARY_MINOR__+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_LIB_C_GNU BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__GLIBC__) || defined(__GNU_LIBRARY__) -# undef BOOST_LIB_C_GNU -# if defined(__GLIBC__) -# define BOOST_LIB_C_GNU \ - BOOST_VERSION_NUMBER(__GLIBC__,__GLIBC_MINOR__,0) -# else -# define BOOST_LIB_C_GNU \ - BOOST_VERSION_NUMBER(__GNU_LIBRARY__,__GNU_LIBRARY_MINOR__,0) -# endif -#endif - -#if BOOST_LIB_C_GNU -# define BOOST_LIB_C_GNU_AVAILABLE -#endif - -#define BOOST_LIB_C_GNU_NAME "GNU" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_C_GNU,BOOST_LIB_C_GNU_NAME) diff --git a/ThirdParty/boost/predef/library/c/uc.h b/ThirdParty/boost/predef/library/c/uc.h deleted file mode 100644 index 6eb22f0c0731142292afb340fad630f04e3eb0b9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/c/uc.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_C_UC_H -#define BOOST_PREDEF_LIBRARY_C_UC_H - -#include <boost/predef/library/c/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_C_UC` - -http://en.wikipedia.org/wiki/Uclibc[uClibc] Standard C library. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__UCLIBC__+` | {predef_detection} - -| `+__UCLIBC_MAJOR__+`, `+__UCLIBC_MINOR__+`, `+__UCLIBC_SUBLEVEL__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_C_UC BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__UCLIBC__) -# undef BOOST_LIB_C_UC -# define BOOST_LIB_C_UC BOOST_VERSION_NUMBER(\ - __UCLIBC_MAJOR__,__UCLIBC_MINOR__,__UCLIBC_SUBLEVEL__) -#endif - -#if BOOST_LIB_C_UC -# define BOOST_LIB_C_UC_AVAILABLE -#endif - -#define BOOST_LIB_C_UC_NAME "uClibc" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_C_UC,BOOST_LIB_C_UC_NAME) diff --git a/ThirdParty/boost/predef/library/c/vms.h b/ThirdParty/boost/predef/library/c/vms.h deleted file mode 100644 index ca9050f8c86ba0bcddd4fa0e6984f30184a7a6ba..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/c/vms.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_C_VMS_H -#define BOOST_PREDEF_LIBRARY_C_VMS_H - -#include <boost/predef/library/c/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_C_VMS` - -VMS libc Standard C library. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__CRTL_VER+` | {predef_detection} - -| `+__CRTL_VER+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_C_VMS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__CRTL_VER) -# undef BOOST_LIB_C_VMS -# define BOOST_LIB_C_VMS BOOST_PREDEF_MAKE_10_VVRR0PP00(__CRTL_VER) -#endif - -#if BOOST_LIB_C_VMS -# define BOOST_LIB_C_VMS_AVAILABLE -#endif - -#define BOOST_LIB_C_VMS_NAME "VMS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_C_VMS,BOOST_LIB_C_VMS_NAME) diff --git a/ThirdParty/boost/predef/library/c/zos.h b/ThirdParty/boost/predef/library/c/zos.h deleted file mode 100644 index 8390762103b2e6ea3540c13aeac711d9549646f5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/c/zos.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_C_ZOS_H -#define BOOST_PREDEF_LIBRARY_C_ZOS_H - -#include <boost/predef/library/c/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_C_ZOS` - -z/OS libc Standard C library. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__LIBREL__+` | {predef_detection} - -| `+__LIBREL__+` | V.R.P -| `+__TARGET_LIB__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_C_ZOS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__LIBREL__) -# undef BOOST_LIB_C_ZOS -# if !defined(BOOST_LIB_C_ZOS) && defined(__LIBREL__) -# define BOOST_LIB_C_ZOS BOOST_PREDEF_MAKE_0X_VRRPPPP(__LIBREL__) -# endif -# if !defined(BOOST_LIB_C_ZOS) && defined(__TARGET_LIB__) -# define BOOST_LIB_C_ZOS BOOST_PREDEF_MAKE_0X_VRRPPPP(__TARGET_LIB__) -# endif -# if !defined(BOOST_LIB_C_ZOS) -# define BOOST_LIB_C_ZOS BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LIB_C_ZOS -# define BOOST_LIB_C_ZOS_AVAILABLE -#endif - -#define BOOST_LIB_C_ZOS_NAME "z/OS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_C_ZOS,BOOST_LIB_C_ZOS_NAME) diff --git a/ThirdParty/boost/predef/library/std/cxx.h b/ThirdParty/boost/predef/library/std/cxx.h deleted file mode 100644 index 61a09a8c3322e5703e7eec904b0de6631d65806a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/cxx.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_LIBRARY_STD_CXX_H -#define BOOST_PREDEF_LIBRARY_STD_CXX_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_CXX` - -http://libcxx.llvm.org/[libc++] {CPP} Standard Library. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_LIBCPP_VERSION+` | {predef_detection} - -| `+_LIBCPP_VERSION+` | V.0.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_CXX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(_LIBCPP_VERSION) -# undef BOOST_LIB_STD_CXX -# define BOOST_LIB_STD_CXX BOOST_PREDEF_MAKE_10_VPPP(_LIBCPP_VERSION) -#endif - -#if BOOST_LIB_STD_CXX -# define BOOST_LIB_STD_CXX_AVAILABLE -#endif - -#define BOOST_LIB_STD_CXX_NAME "libc++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_CXX,BOOST_LIB_STD_CXX_NAME) diff --git a/ThirdParty/boost/predef/library/std/dinkumware.h b/ThirdParty/boost/predef/library/std/dinkumware.h deleted file mode 100644 index 5a4bc57a5bfe386e68eae367b22e15aae5fdfcd9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/dinkumware.h +++ /dev/null @@ -1,53 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_DINKUMWARE_H -#define BOOST_PREDEF_LIBRARY_STD_DINKUMWARE_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_DINKUMWARE` - -http://en.wikipedia.org/wiki/Dinkumware[Dinkumware] Standard {CPP} Library. -If available version number as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_YVALS+`, `+__IBMCPP__+` | {predef_detection} -| `+_CPPLIB_VER+` | {predef_detection} - -| `+_CPPLIB_VER+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_DINKUMWARE BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER) -# undef BOOST_LIB_STD_DINKUMWARE -# if defined(_CPPLIB_VER) -# define BOOST_LIB_STD_DINKUMWARE BOOST_PREDEF_MAKE_10_VVRR(_CPPLIB_VER) -# else -# define BOOST_LIB_STD_DINKUMWARE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LIB_STD_DINKUMWARE -# define BOOST_LIB_STD_DINKUMWARE_AVAILABLE -#endif - -#define BOOST_LIB_STD_DINKUMWARE_NAME "Dinkumware" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_DINKUMWARE,BOOST_LIB_STD_DINKUMWARE_NAME) diff --git a/ThirdParty/boost/predef/library/std/libcomo.h b/ThirdParty/boost/predef/library/std/libcomo.h deleted file mode 100644 index a2116c85eb4816c815f34f72a4ac07128be7fac2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/libcomo.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_LIBCOMO_H -#define BOOST_PREDEF_LIBRARY_STD_LIBCOMO_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_COMO` - -http://www.comeaucomputing.com/libcomo/[Comeau Computing] Standard {CPP} Library. -Version number available as major. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__LIBCOMO__+` | {predef_detection} - -| `+__LIBCOMO_VERSION__+` | V.0.0 -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_COMO BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__LIBCOMO__) -# undef BOOST_LIB_STD_COMO -# define BOOST_LIB_STD_COMO BOOST_VERSION_NUMBER(__LIBCOMO_VERSION__,0,0) -#endif - -#if BOOST_LIB_STD_COMO -# define BOOST_LIB_STD_COMO_AVAILABLE -#endif - -#define BOOST_LIB_STD_COMO_NAME "Comeau Computing" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_COMO,BOOST_LIB_STD_COMO_NAME) diff --git a/ThirdParty/boost/predef/library/std/modena.h b/ThirdParty/boost/predef/library/std/modena.h deleted file mode 100644 index 4ce1cfcd7ae9bccf2f8c7a8b45a95ad5754a24dc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/modena.h +++ /dev/null @@ -1,46 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_MODENA_H -#define BOOST_PREDEF_LIBRARY_STD_MODENA_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_MSIPL` - -http://modena.us/[Modena Software Lib++] Standard {CPP} Library. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `MSIPL_COMPILE_H` | {predef_detection} -| `+__MSIPL_COMPILE_H+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_MSIPL BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(MSIPL_COMPILE_H) || defined(__MSIPL_COMPILE_H) -# undef BOOST_LIB_STD_MSIPL -# define BOOST_LIB_STD_MSIPL BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_LIB_STD_MSIPL -# define BOOST_LIB_STD_MSIPL_AVAILABLE -#endif - -#define BOOST_LIB_STD_MSIPL_NAME "Modena Software Lib++" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_MSIPL,BOOST_LIB_STD_MSIPL_NAME) diff --git a/ThirdParty/boost/predef/library/std/msl.h b/ThirdParty/boost/predef/library/std/msl.h deleted file mode 100644 index 932da795b5bca1379e8f625b7038ee1240f06db6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/msl.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_MSL_H -#define BOOST_PREDEF_LIBRARY_STD_MSL_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_MSL` - -http://www.freescale.com/[Metrowerks] Standard {CPP} Library. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MSL_CPP__+` | {predef_detection} -| `+__MSL__+` | {predef_detection} - -| `+__MSL_CPP__+` | V.R.P -| `+__MSL__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_MSL BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MSL_CPP__) || defined(__MSL__) -# undef BOOST_LIB_STD_MSL -# if defined(__MSL_CPP__) -# define BOOST_LIB_STD_MSL BOOST_PREDEF_MAKE_0X_VRPP(__MSL_CPP__) -# else -# define BOOST_LIB_STD_MSL BOOST_PREDEF_MAKE_0X_VRPP(__MSL__) -# endif -#endif - -#if BOOST_LIB_STD_MSL -# define BOOST_LIB_STD_MSL_AVAILABLE -#endif - -#define BOOST_LIB_STD_MSL_NAME "Metrowerks" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_MSL,BOOST_LIB_STD_MSL_NAME) diff --git a/ThirdParty/boost/predef/library/std/roguewave.h b/ThirdParty/boost/predef/library/std/roguewave.h deleted file mode 100644 index c64cb061d89fa93455deec43f0acdaed8aa82fed..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/roguewave.h +++ /dev/null @@ -1,57 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_ROGUEWAVE_H -#define BOOST_PREDEF_LIBRARY_STD_ROGUEWAVE_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_RW` - -http://stdcxx.apache.org/[Roguewave] Standard {CPP} library. -If available version number as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__STD_RWCOMPILER_H__+` | {predef_detection} -| `+_RWSTD_VER+` | {predef_detection} - -| `+_RWSTD_VER+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_RW BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) -# undef BOOST_LIB_STD_RW -# if defined(_RWSTD_VER) -# if _RWSTD_VER < 0x010000 -# define BOOST_LIB_STD_RW BOOST_PREDEF_MAKE_0X_VVRRP(_RWSTD_VER) -# else -# define BOOST_LIB_STD_RW BOOST_PREDEF_MAKE_0X_VVRRPP(_RWSTD_VER) -# endif -# else -# define BOOST_LIB_STD_RW BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LIB_STD_RW -# define BOOST_LIB_STD_RW_AVAILABLE -#endif - -#define BOOST_LIB_STD_RW_NAME "Roguewave" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_RW,BOOST_LIB_STD_RW_NAME) diff --git a/ThirdParty/boost/predef/library/std/sgi.h b/ThirdParty/boost/predef/library/std/sgi.h deleted file mode 100644 index 3d11dd43c7534a173707d58340316e8b75381c69..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/sgi.h +++ /dev/null @@ -1,52 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_SGI_H -#define BOOST_PREDEF_LIBRARY_STD_SGI_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_SGI` - -http://www.sgi.com/tech/stl/[SGI] Standard {CPP} library. -If available version number as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__STL_CONFIG_H+` | {predef_detection} - -| `+__SGI_STL+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_SGI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__STL_CONFIG_H) -# undef BOOST_LIB_STD_SGI -# if defined(__SGI_STL) -# define BOOST_LIB_STD_SGI BOOST_PREDEF_MAKE_0X_VRP(__SGI_STL) -# else -# define BOOST_LIB_STD_SGI BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_LIB_STD_SGI -# define BOOST_LIB_STD_SGI_AVAILABLE -#endif - -#define BOOST_LIB_STD_SGI_NAME "SGI" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_SGI,BOOST_LIB_STD_SGI_NAME) diff --git a/ThirdParty/boost/predef/library/std/stdcpp3.h b/ThirdParty/boost/predef/library/std/stdcpp3.h deleted file mode 100644 index bc9717a2c8dfe0536fc60e48be74a6152cfd3509..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/stdcpp3.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_STDCPP3_H -#define BOOST_PREDEF_LIBRARY_STD_STDCPP3_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_GNU` - -http://gcc.gnu.org/libstdc++/[GNU libstdc++] Standard {CPP} library. -Version number available as year (from 1970), month, and day. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__GLIBCXX__+` | {predef_detection} -| `+__GLIBCPP__+` | {predef_detection} - -| `+__GLIBCXX__+` | V.R.P -| `+__GLIBCPP__+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_GNU BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__GLIBCPP__) || defined(__GLIBCXX__) -# undef BOOST_LIB_STD_GNU -# if defined(__GLIBCXX__) -# define BOOST_LIB_STD_GNU BOOST_PREDEF_MAKE_YYYYMMDD(__GLIBCXX__) -# else -# define BOOST_LIB_STD_GNU BOOST_PREDEF_MAKE_YYYYMMDD(__GLIBCPP__) -# endif -#endif - -#if BOOST_LIB_STD_GNU -# define BOOST_LIB_STD_GNU_AVAILABLE -#endif - -#define BOOST_LIB_STD_GNU_NAME "GNU" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_GNU,BOOST_LIB_STD_GNU_NAME) diff --git a/ThirdParty/boost/predef/library/std/stlport.h b/ThirdParty/boost/predef/library/std/stlport.h deleted file mode 100644 index 9d7f14f8afa5ef21c008cbd069ae0bb7b7ac11d7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/stlport.h +++ /dev/null @@ -1,60 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_STLPORT_H -#define BOOST_PREDEF_LIBRARY_STD_STLPORT_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_STLPORT` - -http://sourceforge.net/projects/stlport/[STLport Standard {CPP}] library. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__SGI_STL_PORT+` | {predef_detection} -| `+_STLPORT_VERSION+` | {predef_detection} - -| `+_STLPORT_MAJOR+`, `+_STLPORT_MINOR+`, `+_STLPORT_PATCHLEVEL+` | V.R.P -| `+_STLPORT_VERSION+` | V.R.P -| `+__SGI_STL_PORT+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_STLPORT BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -# undef BOOST_LIB_STD_STLPORT -# if !defined(BOOST_LIB_STD_STLPORT) && defined(_STLPORT_MAJOR) -# define BOOST_LIB_STD_STLPORT \ - BOOST_VERSION_NUMBER(_STLPORT_MAJOR,_STLPORT_MINOR,_STLPORT_PATCHLEVEL) -# endif -# if !defined(BOOST_LIB_STD_STLPORT) && defined(_STLPORT_VERSION) -# define BOOST_LIB_STD_STLPORT BOOST_PREDEF_MAKE_0X_VRP(_STLPORT_VERSION) -# endif -# if !defined(BOOST_LIB_STD_STLPORT) -# define BOOST_LIB_STD_STLPORT BOOST_PREDEF_MAKE_0X_VRP(__SGI_STL_PORT) -# endif -#endif - -#if BOOST_LIB_STD_STLPORT -# define BOOST_LIB_STD_STLPORT_AVAILABLE -#endif - -#define BOOST_LIB_STD_STLPORT_NAME "STLport" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_STLPORT,BOOST_LIB_STD_STLPORT_NAME) diff --git a/ThirdParty/boost/predef/library/std/vacpp.h b/ThirdParty/boost/predef/library/std/vacpp.h deleted file mode 100644 index 6165feffeb2e46cf74e43e3d7ca83b2ac1b029ce..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/library/std/vacpp.h +++ /dev/null @@ -1,45 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_LIBRARY_STD_VACPP_H -#define BOOST_PREDEF_LIBRARY_STD_VACPP_H - -#include <boost/predef/library/std/_prefix.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_LIB_STD_IBM` - -http://www.ibm.com/software/awdtools/xlcpp/[IBM VACPP Standard {CPP}] library. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__IBMCPP__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_LIB_STD_IBM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__IBMCPP__) -# undef BOOST_LIB_STD_IBM -# define BOOST_LIB_STD_IBM BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_LIB_STD_IBM -# define BOOST_LIB_STD_IBM_AVAILABLE -#endif - -#define BOOST_LIB_STD_IBM_NAME "IBM VACPP" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_IBM,BOOST_LIB_STD_IBM_NAME) diff --git a/ThirdParty/boost/predef/make.h b/ThirdParty/boost/predef/make.h deleted file mode 100644 index 810ba456e39fbbac6d40e5b8ec969f2d09d7d0a1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/make.h +++ /dev/null @@ -1,159 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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/predef/detail/test.h> - -#ifndef BOOST_PREDEF_MAKE_H -#define BOOST_PREDEF_MAKE_H - -/* -Shorthands for the common version number formats used by vendors... -*/ - -/* tag::reference[] -= `BOOST_PREDEF_MAKE_..` macros - -These set of macros decompose common vendor version number -macros which are composed version, revision, and patch digits. -The naming convention indicates: - -* The base of the specified version number. "`BOOST_PREDEF_MAKE_0X`" for - hexadecimal digits, and "`BOOST_PREDEF_MAKE_10`" for decimal digits. -* The format of the vendor version number. Where "`V`" indicates the version digits, - "`R`" indicates the revision digits, "`P`" indicates the patch digits, and "`0`" - indicates an ignored digit. - -Macros are: - -*/ // end::reference[] -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VRP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VRP(V) BOOST_VERSION_NUMBER((V&0xF00)>>8,(V&0xF0)>>4,(V&0xF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VVRP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VVRP(V) BOOST_VERSION_NUMBER((V&0xFF00)>>8,(V&0xF0)>>4,(V&0xF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VRPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VRPP(V) BOOST_VERSION_NUMBER((V&0xF000)>>12,(V&0xF00)>>8,(V&0xFF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VVRR(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VVRR(V) BOOST_VERSION_NUMBER((V&0xFF00)>>8,(V&0xFF),0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VRRPPPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VRRPPPP(V) BOOST_VERSION_NUMBER((V&0xF000000)>>24,(V&0xFF0000)>>16,(V&0xFFFF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VVRRP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VVRRP(V) BOOST_VERSION_NUMBER((V&0xFF000)>>12,(V&0xFF0)>>4,(V&0xF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VRRPP000(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VRRPP000(V) BOOST_VERSION_NUMBER((V&0xF0000000)>>28,(V&0xFF00000)>>20,(V&0xFF000)>>12) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_0X_VVRRPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_0X_VVRRPP(V) BOOST_VERSION_NUMBER((V&0xFF0000)>>16,(V&0xFF00)>>8,(V&0xFF)) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VPPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VPPP(V) BOOST_VERSION_NUMBER(((V)/1000)%10,0,(V)%1000) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VR0(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VR0(V) BOOST_VERSION_NUMBER(((V)/100)%10,((V)/10)%10,0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRP(V) BOOST_VERSION_NUMBER(((V)/100)%10,((V)/10)%10,(V)%10) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRP000(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRP000(V) BOOST_VERSION_NUMBER(((V)/100000)%10,((V)/10000)%10,((V)/1000)%10) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRPPPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRPPPP(V) BOOST_VERSION_NUMBER(((V)/100000)%10,((V)/10000)%10,(V)%10000) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRPP(V) BOOST_VERSION_NUMBER(((V)/1000)%10,((V)/100)%10,(V)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRR(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRR(V) BOOST_VERSION_NUMBER(((V)/100)%10,(V)%100,0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRRPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRRPP(V) BOOST_VERSION_NUMBER(((V)/10000)%10,((V)/100)%100,(V)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VRR000(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VRR000(V) BOOST_VERSION_NUMBER(((V)/100000)%10,((V)/1000)%100,0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VV00(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VV00(V) BOOST_VERSION_NUMBER(((V)/100)%100,0,0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRR(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRR(V) BOOST_VERSION_NUMBER(((V)/100)%100,(V)%100,0) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRRP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRRP(V) BOOST_VERSION_NUMBER(((V)/1000)%100,((V)/10)%100,(V)%10) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRRPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRRPP(V) BOOST_VERSION_NUMBER(((V)/10000)%100,((V)/100)%100,(V)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRRPPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRRPPP(V) BOOST_VERSION_NUMBER(((V)/100000)%100,((V)/1000)%100,(V)%1000) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRR0PP00(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRR0PP00(V) BOOST_VERSION_NUMBER(((V)/10000000)%100,((V)/100000)%100,((V)/100)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRR0PPPP(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRR0PPPP(V) BOOST_VERSION_NUMBER(((V)/10000000)%100,((V)/100000)%100,(V)%10000) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_10_VVRR00PP00(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_10_VVRR00PP00(V) BOOST_VERSION_NUMBER(((V)/100000000)%100,((V)/1000000)%100,((V)/100)%100) - -/* tag::reference[] - -= `BOOST_PREDEF_MAKE_*..` date macros - -Date decomposition macros return a date in the relative to the 1970 -Epoch date. If the month is not available, January 1st is used as the month and day. -If the day is not available, but the month is, the 1st of the month is used as the day. - -*/ // end::reference[] -/* tag::reference[] -* `BOOST_PREDEF_MAKE_DATE(Y,M,D)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_DATE(Y,M,D) BOOST_VERSION_NUMBER((Y)%10000-1970,(M)%100,(D)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_YYYYMMDD(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_YYYYMMDD(V) BOOST_PREDEF_MAKE_DATE(((V)/10000)%10000,((V)/100)%100,(V)%100) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_YYYY(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_YYYY(V) BOOST_PREDEF_MAKE_DATE(V,1,1) -/* tag::reference[] -* `BOOST_PREDEF_MAKE_YYYYMM(V)` -*/ // end::reference[] -#define BOOST_PREDEF_MAKE_YYYYMM(V) BOOST_PREDEF_MAKE_DATE((V)/100,(V)%100,1) - -#endif diff --git a/ThirdParty/boost/predef/os.h b/ThirdParty/boost/predef/os.h deleted file mode 100644 index da28e1c47e5310f42df6a19c5b42099c8407ee39..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os.h +++ /dev/null @@ -1,32 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -Copyright Franz Detro 2014 -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) -*/ - -#if !defined(BOOST_PREDEF_OS_H) || defined(BOOST_PREDEF_INTERNAL_GENERATE_TESTS) -#ifndef BOOST_PREDEF_OS_H -#define BOOST_PREDEF_OS_H -#endif - -#include <boost/predef/os/aix.h> -#include <boost/predef/os/amigaos.h> -#include <boost/predef/os/beos.h> -#include <boost/predef/os/bsd.h> -#include <boost/predef/os/cygwin.h> -#include <boost/predef/os/haiku.h> -#include <boost/predef/os/hpux.h> -#include <boost/predef/os/irix.h> -#include <boost/predef/os/ios.h> -#include <boost/predef/os/linux.h> -#include <boost/predef/os/macos.h> -#include <boost/predef/os/os400.h> -#include <boost/predef/os/qnxnto.h> -#include <boost/predef/os/solaris.h> -#include <boost/predef/os/unix.h> -#include <boost/predef/os/vms.h> -#include <boost/predef/os/windows.h> - -#endif diff --git a/ThirdParty/boost/predef/os/aix.h b/ThirdParty/boost/predef/os/aix.h deleted file mode 100644 index 9bfe740c40f4033f7d15ca5dc09ee4ab3d3899d5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/aix.h +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_AIX_H -#define BOOST_PREDEF_OS_AIX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_AIX` - -http://en.wikipedia.org/wiki/AIX_operating_system[IBM AIX] operating system. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_AIX+` | {predef_detection} -| `+__TOS_AIX__+` | {predef_detection} - -| `+_AIX43+` | 4.3.0 -| `+_AIX41+` | 4.1.0 -| `+_AIX32+` | 3.2.0 -| `+_AIX3+` | 3.0.0 -|=== -*/ // end::reference[] - -#define BOOST_OS_AIX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(_AIX) || defined(__TOS_AIX__) \ - ) -# undef BOOST_OS_AIX -# if !defined(BOOST_OS_AIX) && defined(_AIX43) -# define BOOST_OS_AIX BOOST_VERSION_NUMBER(4,3,0) -# endif -# if !defined(BOOST_OS_AIX) && defined(_AIX41) -# define BOOST_OS_AIX BOOST_VERSION_NUMBER(4,1,0) -# endif -# if !defined(BOOST_OS_AIX) && defined(_AIX32) -# define BOOST_OS_AIX BOOST_VERSION_NUMBER(3,2,0) -# endif -# if !defined(BOOST_OS_AIX) && defined(_AIX3) -# define BOOST_OS_AIX BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_OS_AIX) -# define BOOST_OS_AIX BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_AIX -# define BOOST_OS_AIX_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_AIX_NAME "IBM AIX" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_AIX,BOOST_OS_AIX_NAME) diff --git a/ThirdParty/boost/predef/os/amigaos.h b/ThirdParty/boost/predef/os/amigaos.h deleted file mode 100644 index c6a1f71ac0684822278a2803329e74536f3dbac6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/amigaos.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_AMIGAOS_H -#define BOOST_PREDEF_OS_AMIGAOS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_AMIGAOS` - -http://en.wikipedia.org/wiki/AmigaOS[AmigaOS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `AMIGA` | {predef_detection} -| `+__amigaos__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_AMIGAOS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(AMIGA) || defined(__amigaos__) \ - ) -# undef BOOST_OS_AMIGAOS -# define BOOST_OS_AMIGAOS BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_AMIGAOS -# define BOOST_OS_AMIGAOS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_AMIGAOS_NAME "AmigaOS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_AMIGAOS,BOOST_OS_AMIGAOS_NAME) diff --git a/ThirdParty/boost/predef/os/beos.h b/ThirdParty/boost/predef/os/beos.h deleted file mode 100644 index 8f764875e4f66f076372265c855dca5614b0c79b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/beos.h +++ /dev/null @@ -1,46 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_BEOS_H -#define BOOST_PREDEF_OS_BEOS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_BEOS` - -http://en.wikipedia.org/wiki/BeOS[BeOS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__BEOS__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_BEOS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__BEOS__) \ - ) -# undef BOOST_OS_BEOS -# define BOOST_OS_BEOS BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_BEOS -# define BOOST_OS_BEOS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BEOS_NAME "BeOS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BEOS,BOOST_OS_BEOS_NAME) diff --git a/ThirdParty/boost/predef/os/bsd.h b/ThirdParty/boost/predef/os/bsd.h deleted file mode 100644 index 528a5972bfbefdcd4f3cebd26eb4446e3a96941b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd.h +++ /dev/null @@ -1,102 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_BSD_H -#define BOOST_PREDEF_OS_BSD_H - -/* Special case: OSX will define BSD predefs if the sys/param.h - * header is included. We can guard against that, but only if we - * detect OSX first. Hence we will force include OSX detection - * before doing any BSD detection. - */ -#include <boost/predef/os/macos.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_BSD` - -http://en.wikipedia.org/wiki/Berkeley_Software_Distribution[BSD] operating system. - -BSD has various branch operating systems possible and each detected -individually. This detects the following variations and sets a specific -version number macro to match: - -* `BOOST_OS_BSD_DRAGONFLY` http://en.wikipedia.org/wiki/DragonFly_BSD[DragonFly BSD] -* `BOOST_OS_BSD_FREE` http://en.wikipedia.org/wiki/Freebsd[FreeBSD] -* `BOOST_OS_BSD_BSDI` http://en.wikipedia.org/wiki/BSD/OS[BSDi BSD/OS] -* `BOOST_OS_BSD_NET` http://en.wikipedia.org/wiki/Netbsd[NetBSD] -* `BOOST_OS_BSD_OPEN` http://en.wikipedia.org/wiki/Openbsd[OpenBSD] - -NOTE: The general `BOOST_OS_BSD` is set in all cases to indicate some form -of BSD. If the above variants is detected the corresponding macro is also set. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `BSD` | {predef_detection} -| `+_SYSTYPE_BSD+` | {predef_detection} - -| `BSD4_2` | 4.2.0 -| `BSD4_3` | 4.3.0 -| `BSD4_4` | 4.4.0 -| `BSD` | V.R.0 -|=== -*/ // end::reference[] - -#include <boost/predef/os/bsd/bsdi.h> -#include <boost/predef/os/bsd/dragonfly.h> -#include <boost/predef/os/bsd/free.h> -#include <boost/predef/os/bsd/open.h> -#include <boost/predef/os/bsd/net.h> - -#ifndef BOOST_OS_BSD -#define BOOST_OS_BSD BOOST_VERSION_NUMBER_NOT_AVAILABLE -#endif - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(BSD) || \ - defined(_SYSTYPE_BSD) \ - ) -# undef BOOST_OS_BSD -# include <sys/param.h> -# if !defined(BOOST_OS_BSD) && defined(BSD4_4) -# define BOOST_OS_BSD BOOST_VERSION_NUMBER(4,4,0) -# endif -# if !defined(BOOST_OS_BSD) && defined(BSD4_3) -# define BOOST_OS_BSD BOOST_VERSION_NUMBER(4,3,0) -# endif -# if !defined(BOOST_OS_BSD) && defined(BSD4_2) -# define BOOST_OS_BSD BOOST_VERSION_NUMBER(4,2,0) -# endif -# if !defined(BOOST_OS_BSD) && defined(BSD) -# define BOOST_OS_BSD BOOST_PREDEF_MAKE_10_VVRR(BSD) -# endif -# if !defined(BOOST_OS_BSD) -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_BSD -# define BOOST_OS_BSD_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_NAME "BSD" - -#endif - -#include <boost/predef/os/bsd/bsdi.h> -#include <boost/predef/os/bsd/dragonfly.h> -#include <boost/predef/os/bsd/free.h> -#include <boost/predef/os/bsd/open.h> -#include <boost/predef/os/bsd/net.h> - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD,BOOST_OS_BSD_NAME) diff --git a/ThirdParty/boost/predef/os/bsd/bsdi.h b/ThirdParty/boost/predef/os/bsd/bsdi.h deleted file mode 100644 index 0c90f6d41dfdabb5f819eaea822e9908028f8dd1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd/bsdi.h +++ /dev/null @@ -1,49 +0,0 @@ -/* -Copyright Rene Rivera 2012-2015 -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_PREDEF_OS_BSD_BSDI_H -#define BOOST_PREDEF_OS_BSD_BSDI_H - -#include <boost/predef/os/bsd.h> - -/* tag::reference[] -= `BOOST_OS_BSD_BSDI` - -http://en.wikipedia.org/wiki/BSD/OS[BSDi BSD/OS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__bsdi__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_BSD_BSDI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__bsdi__) \ - ) -# ifndef BOOST_OS_BSD_AVAILABLE -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# define BOOST_OS_BSD_AVAILABLE -# endif -# undef BOOST_OS_BSD_BSDI -# define BOOST_OS_BSD_BSDI BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_BSD_BSDI -# define BOOST_OS_BSD_BSDI_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_BSDI_NAME "BSDi BSD/OS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD_BSDI,BOOST_OS_BSD_BSDI_NAME) diff --git a/ThirdParty/boost/predef/os/bsd/dragonfly.h b/ThirdParty/boost/predef/os/bsd/dragonfly.h deleted file mode 100644 index 253f0e24e4c3d5b8ade7bc9cb323edd4cf2d2ad1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd/dragonfly.h +++ /dev/null @@ -1,51 +0,0 @@ -/* -Copyright Rene Rivera 2012-2015 -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_PREDEF_OS_BSD_DRAGONFLY_H -#define BOOST_PREDEF_OS_BSD_DRAGONFLY_H - -#include <boost/predef/os/bsd.h> - -/* tag::reference[] -= `BOOST_OS_BSD_DRAGONFLY` - -http://en.wikipedia.org/wiki/DragonFly_BSD[DragonFly BSD] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__DragonFly__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_BSD_DRAGONFLY BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__DragonFly__) \ - ) -# ifndef BOOST_OS_BSD_AVAILABLE -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# define BOOST_OS_BSD_AVAILABLE -# endif -# undef BOOST_OS_BSD_DRAGONFLY -# if defined(__DragonFly__) -# define BOOST_OS_DRAGONFLY_BSD BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_BSD_DRAGONFLY -# define BOOST_OS_BSD_DRAGONFLY_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_DRAGONFLY_NAME "DragonFly BSD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD_DRAGONFLY,BOOST_OS_BSD_DRAGONFLY_NAME) diff --git a/ThirdParty/boost/predef/os/bsd/free.h b/ThirdParty/boost/predef/os/bsd/free.h deleted file mode 100644 index 0cf82ae9d6d9e894a0c918a4008897f43ea0a309..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd/free.h +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright Rene Rivera 2012-2015 -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_PREDEF_OS_BSD_FREE_H -#define BOOST_PREDEF_OS_BSD_FREE_H - -#include <boost/predef/os/bsd.h> - -/* tag::reference[] -= `BOOST_OS_BSD_FREE` - -http://en.wikipedia.org/wiki/Freebsd[FreeBSD] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__FreeBSD__+` | {predef_detection} - -| `+__FreeBSD_version+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_OS_BSD_FREE BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__FreeBSD__) \ - ) -# ifndef BOOST_OS_BSD_AVAILABLE -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# define BOOST_OS_BSD_AVAILABLE -# endif -# undef BOOST_OS_BSD_FREE -# include <sys/param.h> -# if defined(__FreeBSD_version) -# if __FreeBSD_version == 491000 -# define BOOST_OS_BSD_FREE \ - BOOST_VERSION_NUMBER(4, 10, 0) -# elif __FreeBSD_version == 492000 -# define BOOST_OS_BSD_FREE \ - BOOST_VERSION_NUMBER(4, 11, 0) -# elif __FreeBSD_version < 500000 -# define BOOST_OS_BSD_FREE \ - BOOST_PREDEF_MAKE_10_VRPPPP(__FreeBSD_version) -# else -# define BOOST_OS_BSD_FREE \ - BOOST_PREDEF_MAKE_10_VVRRPPP(__FreeBSD_version) -# endif -# else -# define BOOST_OS_BSD_FREE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_BSD_FREE -# define BOOST_OS_BSD_FREE_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_FREE_NAME "Free BSD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD_FREE,BOOST_OS_BSD_FREE_NAME) diff --git a/ThirdParty/boost/predef/os/bsd/net.h b/ThirdParty/boost/predef/os/bsd/net.h deleted file mode 100644 index c4e3c92ba6e1f5e12924f7cef485f7142c5b95f8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd/net.h +++ /dev/null @@ -1,85 +0,0 @@ -/* -Copyright Rene Rivera 2012-2015 -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_PREDEF_OS_BSD_NET_H -#define BOOST_PREDEF_OS_BSD_NET_H - -#include <boost/predef/os/bsd.h> - -/* tag::reference[] -= `BOOST_OS_BSD_NET` - -http://en.wikipedia.org/wiki/Netbsd[NetBSD] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__NETBSD__+` | {predef_detection} -| `+__NetBSD__+` | {predef_detection} - -| `+__NETBSD_version+` | V.R.P -| `NetBSD0_8` | 0.8.0 -| `NetBSD0_9` | 0.9.0 -| `NetBSD1_0` | 1.0.0 -| `+__NetBSD_Version+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__NETBSD__) || defined(__NetBSD__) \ - ) -# ifndef BOOST_OS_BSD_AVAILABLE -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# define BOOST_OS_BSD_AVAILABLE -# endif -# undef BOOST_OS_BSD_NET -# if defined(__NETBSD__) -# if defined(__NETBSD_version) -# if __NETBSD_version < 500000 -# define BOOST_OS_BSD_NET \ - BOOST_PREDEF_MAKE_10_VRP000(__NETBSD_version) -# else -# define BOOST_OS_BSD_NET \ - BOOST_PREDEF_MAKE_10_VRR000(__NETBSD_version) -# endif -# else -# define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER_AVAILABLE -# endif -# elif defined(__NetBSD__) -# if !defined(BOOST_OS_BSD_NET) && defined(NetBSD0_8) -# define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER(0,8,0) -# endif -# if !defined(BOOST_OS_BSD_NET) && defined(NetBSD0_9) -# define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER(0,9,0) -# endif -# if !defined(BOOST_OS_BSD_NET) && defined(NetBSD1_0) -# define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER(1,0,0) -# endif -# if !defined(BOOST_OS_BSD_NET) && defined(__NetBSD_Version) -# define BOOST_OS_BSD_NET \ - BOOST_PREDEF_MAKE_10_VVRR00PP00(__NetBSD_Version) -# endif -# if !defined(BOOST_OS_BSD_NET) -# define BOOST_OS_BSD_NET BOOST_VERSION_NUMBER_AVAILABLE -# endif -# endif -#endif - -#if BOOST_OS_BSD_NET -# define BOOST_OS_BSD_NET_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_NET_NAME "NetBSD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD_NET,BOOST_OS_BSD_NET_NAME) diff --git a/ThirdParty/boost/predef/os/bsd/open.h b/ThirdParty/boost/predef/os/bsd/open.h deleted file mode 100644 index 3a9081c8534d17ff9b380fd34d134388b0264a89..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/bsd/open.h +++ /dev/null @@ -1,252 +0,0 @@ -/* -Copyright Rene Rivera 2012-2015 -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_PREDEF_OS_BSD_OPEN_H -#define BOOST_PREDEF_OS_BSD_OPEN_H - -#include <boost/predef/os/bsd.h> - -/* tag::reference[] -= `BOOST_OS_BSD_OPEN` - -http://en.wikipedia.org/wiki/Openbsd[OpenBSD] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__OpenBSD__+` | {predef_detection} - -| `OpenBSD2_0` | 2.0.0 -| `OpenBSD2_1` | 2.1.0 -| `OpenBSD2_2` | 2.2.0 -| `OpenBSD2_3` | 2.3.0 -| `OpenBSD2_4` | 2.4.0 -| `OpenBSD2_5` | 2.5.0 -| `OpenBSD2_6` | 2.6.0 -| `OpenBSD2_7` | 2.7.0 -| `OpenBSD2_8` | 2.8.0 -| `OpenBSD2_9` | 2.9.0 -| `OpenBSD3_0` | 3.0.0 -| `OpenBSD3_1` | 3.1.0 -| `OpenBSD3_2` | 3.2.0 -| `OpenBSD3_3` | 3.3.0 -| `OpenBSD3_4` | 3.4.0 -| `OpenBSD3_5` | 3.5.0 -| `OpenBSD3_6` | 3.6.0 -| `OpenBSD3_7` | 3.7.0 -| `OpenBSD3_8` | 3.8.0 -| `OpenBSD3_9` | 3.9.0 -| `OpenBSD4_0` | 4.0.0 -| `OpenBSD4_1` | 4.1.0 -| `OpenBSD4_2` | 4.2.0 -| `OpenBSD4_3` | 4.3.0 -| `OpenBSD4_4` | 4.4.0 -| `OpenBSD4_5` | 4.5.0 -| `OpenBSD4_6` | 4.6.0 -| `OpenBSD4_7` | 4.7.0 -| `OpenBSD4_8` | 4.8.0 -| `OpenBSD4_9` | 4.9.0 -| `OpenBSD5_0` | 5.0.0 -| `OpenBSD5_1` | 5.1.0 -| `OpenBSD5_2` | 5.2.0 -| `OpenBSD5_3` | 5.3.0 -| `OpenBSD5_4` | 5.4.0 -| `OpenBSD5_5` | 5.5.0 -| `OpenBSD5_6` | 5.6.0 -| `OpenBSD5_7` | 5.7.0 -| `OpenBSD5_8` | 5.8.0 -| `OpenBSD5_9` | 5.9.0 -| `OpenBSD6_0` | 6.0.0 -| `OpenBSD6_1` | 6.1.0 -| `OpenBSD6_2` | 6.2.0 -| `OpenBSD6_3` | 6.3.0 -| `OpenBSD6_4` | 6.4.0 -| `OpenBSD6_5` | 6.5.0 -| `OpenBSD6_6` | 6.6.0 -| `OpenBSD6_7` | 6.7.0 -| `OpenBSD6_8` | 6.8.0 -| `OpenBSD6_9` | 6.9.0 -|=== -*/ // end::reference[] - -#define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__OpenBSD__) \ - ) -# ifndef BOOST_OS_BSD_AVAILABLE -# define BOOST_OS_BSD BOOST_VERSION_NUMBER_AVAILABLE -# define BOOST_OS_BSD_AVAILABLE -# endif -# undef BOOST_OS_BSD_OPEN -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_0) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,0,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_1) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,1,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_2) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,2,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_3) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,3,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_4) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,4,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_5) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,5,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_6) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,6,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_7) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,7,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_8) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,8,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD2_9) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(2,9,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_0) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,0,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_1) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,1,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_2) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,2,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_3) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,3,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_4) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,4,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_5) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,5,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_6) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,6,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_7) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,7,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_8) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,8,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD3_9) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(3,9,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_0) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_1) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,1,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_2) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,2,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_3) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,3,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_4) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,4,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_5) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,5,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_6) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,6,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_7) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,7,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_8) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,8,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD4_9) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(4,9,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_0) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,0,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_1) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,1,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_2) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,2,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_3) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,3,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_4) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,4,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_5) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,5,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_6) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,6,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_7) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,7,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_8) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,8,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD5_9) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(5,9,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_0) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,0,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_1) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,1,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_2) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,2,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_3) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,3,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_4) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,4,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_5) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,5,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_6) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,6,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_7) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,7,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_8) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,8,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) && defined(OpenBSD6_9) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER(6,9,0) -# endif -# if !defined(BOOST_OS_BSD_OPEN) -# define BOOST_OS_BSD_OPEN BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_BSD_OPEN -# define BOOST_OS_BSD_OPEN_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_BSD_OPEN_NAME "OpenBSD" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_BSD_OPEN,BOOST_OS_BSD_OPEN_NAME) diff --git a/ThirdParty/boost/predef/os/cygwin.h b/ThirdParty/boost/predef/os/cygwin.h deleted file mode 100644 index 3ca73d26d5f8db1d39f2ec8230bd462e94ae086b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/cygwin.h +++ /dev/null @@ -1,51 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_CYGWIN_H -#define BOOST_PREDEF_OS_CYGWIN_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_CYGWIN` - -http://en.wikipedia.org/wiki/Cygwin[Cygwin] evironment. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__CYGWIN__+` | {predef_detection} - -| `CYGWIN_VERSION_API_MAJOR`, `CYGWIN_VERSION_API_MINOR` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_OS_CYGWIN BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__CYGWIN__) \ - ) -# include <cygwin/version.h> -# undef BOOST_OS_CYGWIN -# define BOOST_OS_CYGWIN \ - BOOST_VERSION_NUMBER(CYGWIN_VERSION_API_MAJOR,\ - CYGWIN_VERSION_API_MINOR, 0) -#endif - -#if BOOST_OS_CYGWIN -# define BOOST_OS_CYGWIN_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_CYGWIN_NAME "Cygwin" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_CYGWIN,BOOST_OS_CYGWIN_NAME) diff --git a/ThirdParty/boost/predef/os/haiku.h b/ThirdParty/boost/predef/os/haiku.h deleted file mode 100644 index 4ae31583de2ebf38cbffd06043782249d96e516d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/haiku.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Jessica Hamilton 2014 -Copyright Rene Rivera 2014-2015 -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_PREDEF_OS_HAIKU_H -#define BOOST_PREDEF_OS_HAIKU_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_HAIKU` - -http://en.wikipedia.org/wiki/Haiku_(operating_system)[Haiku] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__HAIKU__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_HAIKU BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__HAIKU__) \ - ) -# undef BOOST_OS_HAIKU -# define BOOST_OS_HAIKU BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_HAIKU -# define BOOST_OS_HAIKU_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_HAIKU_NAME "Haiku" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_HAIKU,BOOST_OS_HAIKU_NAME) diff --git a/ThirdParty/boost/predef/os/hpux.h b/ThirdParty/boost/predef/os/hpux.h deleted file mode 100644 index 7901914824ed20121ebfab027b13c7cc894266af..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/hpux.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_HPUX_H -#define BOOST_PREDEF_OS_HPUX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_HPUX` - -http://en.wikipedia.org/wiki/HP-UX[HP-UX] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `hpux` | {predef_detection} -| `+_hpux+` | {predef_detection} -| `+__hpux+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_HPUX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(hpux) || defined(_hpux) || defined(__hpux) \ - ) -# undef BOOST_OS_HPUX -# define BOOST_OS_HPUX BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_HPUX -# define BOOST_OS_HPUX_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_HPUX_NAME "HP-UX" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_HPUX,BOOST_OS_HPUX_NAME) diff --git a/ThirdParty/boost/predef/os/ios.h b/ThirdParty/boost/predef/os/ios.h deleted file mode 100644 index 138963afaa2046d584497575cb724c5138255f0e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/ios.h +++ /dev/null @@ -1,52 +0,0 @@ -/* -Copyright Franz Detro 2014 -Copyright Rene Rivera 2015 -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_PREDEF_OS_IOS_H -#define BOOST_PREDEF_OS_IOS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_IOS` - -http://en.wikipedia.org/wiki/iOS[iOS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__APPLE__+` | {predef_detection} -| `+__MACH__+` | {predef_detection} -| `+__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__+` | {predef_detection} - -| `+__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__+` | +__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__+*1000 -|=== -*/ // end::reference[] - -#define BOOST_OS_IOS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__APPLE__) && defined(__MACH__) && \ - defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) \ - ) -# undef BOOST_OS_IOS -# define BOOST_OS_IOS (__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__*1000) -#endif - -#if BOOST_OS_IOS -# define BOOST_OS_IOS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_IOS_NAME "iOS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_IOS,BOOST_OS_IOS_NAME) diff --git a/ThirdParty/boost/predef/os/irix.h b/ThirdParty/boost/predef/os/irix.h deleted file mode 100644 index 7c0bab04eaf64a9fe33b326ca4fec049c53be8c3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/irix.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_IRIX_H -#define BOOST_PREDEF_OS_IRIX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_IRIX` - -http://en.wikipedia.org/wiki/Irix[IRIX] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `sgi` | {predef_detection} -| `+__sgi+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_IRIX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(sgi) || defined(__sgi) \ - ) -# undef BOOST_OS_IRIX -# define BOOST_OS_IRIX BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_IRIX -# define BOOST_OS_IRIX_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_IRIX_NAME "IRIX" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_IRIX,BOOST_OS_IRIX_NAME) diff --git a/ThirdParty/boost/predef/os/linux.h b/ThirdParty/boost/predef/os/linux.h deleted file mode 100644 index bab64fc4a8b74cef7d8f6aca9283df223925fee4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/linux.h +++ /dev/null @@ -1,50 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_LINUX_H -#define BOOST_PREDEF_OS_LINUX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_LINUX` - -http://en.wikipedia.org/wiki/Linux[Linux] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `linux` | {predef_detection} -| `+__linux+` | {predef_detection} -| `+__linux__+` | {predef_detection} -| `+__gnu_linux__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_LINUX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(linux) || defined(__linux) || \ - defined(__linux__) || defined(__gnu_linux__) \ - ) -# undef BOOST_OS_LINUX -# define BOOST_OS_LINUX BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_LINUX -# define BOOST_OS_LINUX_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_LINUX_NAME "Linux" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_LINUX,BOOST_OS_LINUX_NAME) diff --git a/ThirdParty/boost/predef/os/macos.h b/ThirdParty/boost/predef/os/macos.h deleted file mode 100644 index 1a443184622a2bf1327b46193e8d96ef4e50e2bb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/macos.h +++ /dev/null @@ -1,66 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -Copyright Franz Detro 2014 -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_PREDEF_OS_MACOS_H -#define BOOST_PREDEF_OS_MACOS_H - -/* Special case: iOS will define the same predefs as MacOS, and additionally - '__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__'. We can guard against that, - but only if we detect iOS first. Hence we will force include iOS detection - * before doing any MacOS detection. - */ -#include <boost/predef/os/ios.h> - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_MACOS` - -http://en.wikipedia.org/wiki/Mac_OS[Mac OS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `macintosh` | {predef_detection} -| `Macintosh` | {predef_detection} -| `+__APPLE__+` | {predef_detection} -| `+__MACH__+` | {predef_detection} - -| `+__APPLE__+`, `+__MACH__+` | 10.0.0 -| `_otherwise_` | 9.0.0 -|=== -*/ // end::reference[] - -#define BOOST_OS_MACOS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(macintosh) || defined(Macintosh) || \ - (defined(__APPLE__) && defined(__MACH__)) \ - ) -# undef BOOST_OS_MACOS -# if !defined(BOOST_OS_MACOS) && defined(__APPLE__) && defined(__MACH__) -# define BOOST_OS_MACOS BOOST_VERSION_NUMBER(10,0,0) -# endif -# if !defined(BOOST_OS_MACOS) -# define BOOST_OS_MACOS BOOST_VERSION_NUMBER(9,0,0) -# endif -#endif - -#if BOOST_OS_MACOS -# define BOOST_OS_MACOS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_MACOS_NAME "Mac OS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_MACOS,BOOST_OS_MACOS_NAME) diff --git a/ThirdParty/boost/predef/os/os400.h b/ThirdParty/boost/predef/os/os400.h deleted file mode 100644 index 209638d114e57ff50366223ce66c12fcc7e9714a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/os400.h +++ /dev/null @@ -1,46 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_OS_OS400_H -#define BOOST_PREDEF_OS_OS400_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_OS400` - -http://en.wikipedia.org/wiki/IBM_i[IBM OS/400] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__OS400__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_OS400 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__OS400__) \ - ) -# undef BOOST_OS_OS400 -# define BOOST_OS_OS400 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_OS400 -# define BOOST_OS_OS400_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_OS400_NAME "IBM OS/400" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_OS400,BOOST_OS_OS400_NAME) diff --git a/ThirdParty/boost/predef/os/qnxnto.h b/ThirdParty/boost/predef/os/qnxnto.h deleted file mode 100644 index 7507cd08f5052317568b8a86addd54e802632430..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/qnxnto.h +++ /dev/null @@ -1,60 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_QNXNTO_H -#define BOOST_PREDEF_OS_QNXNTO_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_QNX` - -http://en.wikipedia.org/wiki/QNX[QNX] operating system. -Version number available as major, and minor if possible. And -version 4 is specifically detected. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__QNX__+` | {predef_detection} -| `+__QNXNTO__+` | {predef_detection} - -| `+_NTO_VERSION+` | V.R.0 -| `+__QNX__+` | 4.0.0 -|=== -*/ // end::reference[] - -#define BOOST_OS_QNX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(__QNX__) || defined(__QNXNTO__) \ - ) -# undef BOOST_OS_QNX -# if !defined(BOOST_OS_QNX) && defined(_NTO_VERSION) -# define BOOST_OS_QNX BOOST_PREDEF_MAKE_10_VVRR(_NTO_VERSION) -# endif -# if !defined(BOOST_OS_QNX) && defined(__QNX__) -# define BOOST_OS_QNX BOOST_VERSION_NUMBER(4,0,0) -# endif -# if !defined(BOOST_OS_QNX) -# define BOOST_OS_QNX BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_QNX -# define BOOST_OS_QNX_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_QNX_NAME "QNX" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_QNX,BOOST_OS_QNX_NAME) diff --git a/ThirdParty/boost/predef/os/solaris.h b/ThirdParty/boost/predef/os/solaris.h deleted file mode 100644 index 529af2b3b41ec50e4fecc9cf03167d85e8b679f6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/solaris.h +++ /dev/null @@ -1,47 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_SOLARIS_H -#define BOOST_PREDEF_OS_SOLARIS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_SOLARIS` - -http://en.wikipedia.org/wiki/Solaris_Operating_Environment[Solaris] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `sun` | {predef_detection} -| `+__sun+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_SOLARIS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(sun) || defined(__sun) \ - ) -# undef BOOST_OS_SOLARIS -# define BOOST_OS_SOLARIS BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_SOLARIS -# define BOOST_OS_SOLARIS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_SOLARIS_NAME "Solaris" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_SOLARIS,BOOST_OS_SOLARIS_NAME) diff --git a/ThirdParty/boost/predef/os/unix.h b/ThirdParty/boost/predef/os/unix.h deleted file mode 100644 index b86051dd5f7586b76ea469869fb25740a2c9febe..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/unix.h +++ /dev/null @@ -1,78 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_UNIX_H -#define BOOST_PREDEF_OS_UNIX_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_UNIX` - -http://en.wikipedia.org/wiki/Unix[Unix Environment] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `unix` | {predef_detection} -| `+__unix+` | {predef_detection} -| `+_XOPEN_SOURCE+` | {predef_detection} -| `+_POSIX_SOURCE+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_UNIX BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(unix) || defined(__unix) || \ - defined(_XOPEN_SOURCE) || defined(_POSIX_SOURCE) -# undef BOOST_OS_UNIX -# define BOOST_OS_UNIX BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_UNIX -# define BOOST_OS_UNIX_AVAILABLE -#endif - -#define BOOST_OS_UNIX_NAME "Unix Environment" - -/* tag::reference[] -= `BOOST_OS_SVR4` - -http://en.wikipedia.org/wiki/UNIX_System_V[SVR4 Environment] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__sysv__+` | {predef_detection} -| `+__SVR4+` | {predef_detection} -| `+__svr4__+` | {predef_detection} -| `+_SYSTYPE_SVR4+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_SVR4 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__sysv__) || defined(__SVR4) || \ - defined(__svr4__) || defined(_SYSTYPE_SVR4) -# undef BOOST_OS_SVR4 -# define BOOST_OS_SVR4 BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_SVR4 -# define BOOST_OS_SVR4_AVAILABLE -#endif - -#define BOOST_OS_SVR4_NAME "SVR4 Environment" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_UNIX,BOOST_OS_UNIX_NAME) -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_SVR4,BOOST_OS_SVR4_NAME) diff --git a/ThirdParty/boost/predef/os/vms.h b/ThirdParty/boost/predef/os/vms.h deleted file mode 100644 index 7db611816940bcdf834b9e8af1c0275e042ff14a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/vms.h +++ /dev/null @@ -1,53 +0,0 @@ -/* -Copyright Rene Rivera 2011-2015 -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_PREDEF_OS_VMS_H -#define BOOST_PREDEF_OS_VMS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_VMS` - -http://en.wikipedia.org/wiki/Vms[VMS] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `VMS` | {predef_detection} -| `+__VMS+` | {predef_detection} - -| `+__VMS_VER+` | V.R.P -|=== -*/ // end::reference[] - -#define BOOST_OS_VMS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(VMS) || defined(__VMS) \ - ) -# undef BOOST_OS_VMS -# if defined(__VMS_VER) -# define BOOST_OS_VMS BOOST_PREDEF_MAKE_10_VVRR00PP00(__VMS_VER) -# else -# define BOOST_OS_VMS BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_OS_VMS -# define BOOST_OS_VMS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_VMS_NAME "VMS" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_VMS,BOOST_OS_VMS_NAME) diff --git a/ThirdParty/boost/predef/os/windows.h b/ThirdParty/boost/predef/os/windows.h deleted file mode 100644 index d8d2d2b2d3668f5258f6d1f62706e007193454ce..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/os/windows.h +++ /dev/null @@ -1,52 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_OS_WINDOWS_H -#define BOOST_PREDEF_OS_WINDOWS_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_OS_WINDOWS` - -http://en.wikipedia.org/wiki/Category:Microsoft_Windows[Microsoft Windows] operating system. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+_WIN32+` | {predef_detection} -| `+_WIN64+` | {predef_detection} -| `+__WIN32__+` | {predef_detection} -| `+__TOS_WIN__+` | {predef_detection} -| `+__WINDOWS__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_OS_WINDOWS BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \ - defined(_WIN32) || defined(_WIN64) || \ - defined(__WIN32__) || defined(__TOS_WIN__) || \ - defined(__WINDOWS__) \ - ) -# undef BOOST_OS_WINDOWS -# define BOOST_OS_WINDOWS BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_OS_WINDOWS -# define BOOST_OS_WINDOWS_AVAILABLE -# include <boost/predef/detail/os_detected.h> -#endif - -#define BOOST_OS_WINDOWS_NAME "Microsoft Windows" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_OS_WINDOWS,BOOST_OS_WINDOWS_NAME) diff --git a/ThirdParty/boost/predef/other/endian.h b/ThirdParty/boost/predef/other/endian.h deleted file mode 100644 index 0281e4a3f99570d05bf5f690a7cc4af632e030b4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/other/endian.h +++ /dev/null @@ -1,204 +0,0 @@ -/* -Copyright Rene Rivera 2013-2015 -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_PREDEF_ENDIAN_H -#define BOOST_PREDEF_ENDIAN_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> -#include <boost/predef/library/c/gnu.h> -#include <boost/predef/os/macos.h> -#include <boost/predef/os/bsd.h> -#include <boost/predef/platform/android.h> - -/* tag::reference[] -= `BOOST_ENDIAN_*` - -Detection of endian memory ordering. There are four defined macros -in this header that define the various generally possible endian -memory orderings: - -* `BOOST_ENDIAN_BIG_BYTE`, byte-swapped big-endian. -* `BOOST_ENDIAN_BIG_WORD`, word-swapped big-endian. -* `BOOST_ENDIAN_LITTLE_BYTE`, byte-swapped little-endian. -* `BOOST_ENDIAN_LITTLE_WORD`, word-swapped little-endian. - -The detection is conservative in that it only identifies endianness -that it knows for certain. In particular bi-endianness is not -indicated as is it not practically possible to determine the -endianness from anything but an operating system provided -header. And the currently known headers do not define that -programatic bi-endianness is available. - -This implementation is a compilation of various publicly available -information and acquired knowledge: - -. The indispensable documentation of "Pre-defined Compiler Macros" - http://sourceforge.net/p/predef/wiki/Endianness[Endianness]. -. The various endian specifications available in the - http://wikipedia.org/[Wikipedia] computer architecture pages. -. Generally available searches for headers that define endianness. -*/ // end::reference[] - -#define BOOST_ENDIAN_BIG_BYTE BOOST_VERSION_NUMBER_NOT_AVAILABLE -#define BOOST_ENDIAN_BIG_WORD BOOST_VERSION_NUMBER_NOT_AVAILABLE -#define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_NOT_AVAILABLE -#define BOOST_ENDIAN_LITTLE_WORD BOOST_VERSION_NUMBER_NOT_AVAILABLE - -/* GNU libc provides a header defining __BYTE_ORDER, or _BYTE_ORDER. - * And some OSs provide some for of endian header also. - */ -#if !BOOST_ENDIAN_BIG_BYTE && !BOOST_ENDIAN_BIG_WORD && \ - !BOOST_ENDIAN_LITTLE_BYTE && !BOOST_ENDIAN_LITTLE_WORD -# if BOOST_LIB_C_GNU || BOOST_PLAT_ANDROID -# include <endian.h> -# else -# if BOOST_OS_MACOS -# include <machine/endian.h> -# else -# if BOOST_OS_BSD -# if BOOST_OS_BSD_OPEN -# include <machine/endian.h> -# else -# include <sys/endian.h> -# endif -# endif -# endif -# endif -# if defined(__BYTE_ORDER) -# if defined(__BIG_ENDIAN) && (__BYTE_ORDER == __BIG_ENDIAN) -# undef BOOST_ENDIAN_BIG_BYTE -# define BOOST_ENDIAN_BIG_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if defined(__LITTLE_ENDIAN) && (__BYTE_ORDER == __LITTLE_ENDIAN) -# undef BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if defined(__PDP_ENDIAN) && (__BYTE_ORDER == __PDP_ENDIAN) -# undef BOOST_ENDIAN_LITTLE_WORD -# define BOOST_ENDIAN_LITTLE_WORD BOOST_VERSION_NUMBER_AVAILABLE -# endif -# endif -# if !defined(__BYTE_ORDER) && defined(_BYTE_ORDER) -# if defined(_BIG_ENDIAN) && (_BYTE_ORDER == _BIG_ENDIAN) -# undef BOOST_ENDIAN_BIG_BYTE -# define BOOST_ENDIAN_BIG_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if defined(_LITTLE_ENDIAN) && (_BYTE_ORDER == _LITTLE_ENDIAN) -# undef BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if defined(_PDP_ENDIAN) && (_BYTE_ORDER == _PDP_ENDIAN) -# undef BOOST_ENDIAN_LITTLE_WORD -# define BOOST_ENDIAN_LITTLE_WORD BOOST_VERSION_NUMBER_AVAILABLE -# endif -# endif -#endif - -/* Built-in byte-swpped big-endian macros. - */ -#if !BOOST_ENDIAN_BIG_BYTE && !BOOST_ENDIAN_BIG_WORD && \ - !BOOST_ENDIAN_LITTLE_BYTE && !BOOST_ENDIAN_LITTLE_WORD -# if (defined(__BIG_ENDIAN__) && !defined(__LITTLE_ENDIAN__)) || \ - (defined(_BIG_ENDIAN) && !defined(_LITTLE_ENDIAN)) || \ - defined(__ARMEB__) || \ - defined(__THUMBEB__) || \ - defined(__AARCH64EB__) || \ - defined(_MIPSEB) || \ - defined(__MIPSEB) || \ - defined(__MIPSEB__) -# undef BOOST_ENDIAN_BIG_BYTE -# define BOOST_ENDIAN_BIG_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -/* Built-in byte-swpped little-endian macros. - */ -#if !BOOST_ENDIAN_BIG_BYTE && !BOOST_ENDIAN_BIG_WORD && \ - !BOOST_ENDIAN_LITTLE_BYTE && !BOOST_ENDIAN_LITTLE_WORD -# if (defined(__LITTLE_ENDIAN__) && !defined(__BIG_ENDIAN__)) || \ - (defined(_LITTLE_ENDIAN) && !defined(_BIG_ENDIAN)) || \ - defined(__ARMEL__) || \ - defined(__THUMBEL__) || \ - defined(__AARCH64EL__) || \ - defined(_MIPSEL) || \ - defined(__MIPSEL) || \ - defined(__MIPSEL__) || \ - defined(__riscv) -# undef BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -/* Some architectures are strictly one endianess (as opposed - * the current common bi-endianess). - */ -#if !BOOST_ENDIAN_BIG_BYTE && !BOOST_ENDIAN_BIG_WORD && \ - !BOOST_ENDIAN_LITTLE_BYTE && !BOOST_ENDIAN_LITTLE_WORD -# include <boost/predef/architecture.h> -# if BOOST_ARCH_M68K || \ - BOOST_ARCH_PARISC || \ - BOOST_ARCH_SPARC || \ - BOOST_ARCH_SYS370 || \ - BOOST_ARCH_SYS390 || \ - BOOST_ARCH_Z -# undef BOOST_ENDIAN_BIG_BYTE -# define BOOST_ENDIAN_BIG_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# if BOOST_ARCH_IA64 || \ - BOOST_ARCH_X86 || \ - BOOST_ARCH_BLACKFIN -# undef BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -/* Windows on ARM, if not otherwise detected/specified, is always - * byte-swaped little-endian. - */ -#if !BOOST_ENDIAN_BIG_BYTE && !BOOST_ENDIAN_BIG_WORD && \ - !BOOST_ENDIAN_LITTLE_BYTE && !BOOST_ENDIAN_LITTLE_WORD -# if BOOST_ARCH_ARM -# include <boost/predef/os/windows.h> -# if BOOST_OS_WINDOWS -# undef BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE BOOST_VERSION_NUMBER_AVAILABLE -# endif -# endif -#endif - -#if BOOST_ENDIAN_BIG_BYTE -# define BOOST_ENDIAN_BIG_BYTE_AVAILABLE -#endif -#if BOOST_ENDIAN_BIG_WORD -# define BOOST_ENDIAN_BIG_WORD_BYTE_AVAILABLE -#endif -#if BOOST_ENDIAN_LITTLE_BYTE -# define BOOST_ENDIAN_LITTLE_BYTE_AVAILABLE -#endif -#if BOOST_ENDIAN_LITTLE_WORD -# define BOOST_ENDIAN_LITTLE_WORD_BYTE_AVAILABLE -#endif - -#define BOOST_ENDIAN_BIG_BYTE_NAME "Byte-Swapped Big-Endian" -#define BOOST_ENDIAN_BIG_WORD_NAME "Word-Swapped Big-Endian" -#define BOOST_ENDIAN_LITTLE_BYTE_NAME "Byte-Swapped Little-Endian" -#define BOOST_ENDIAN_LITTLE_WORD_NAME "Word-Swapped Little-Endian" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ENDIAN_BIG_BYTE,BOOST_ENDIAN_BIG_BYTE_NAME) - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ENDIAN_BIG_WORD,BOOST_ENDIAN_BIG_WORD_NAME) - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ENDIAN_LITTLE_BYTE,BOOST_ENDIAN_LITTLE_BYTE_NAME) - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_ENDIAN_LITTLE_WORD,BOOST_ENDIAN_LITTLE_WORD_NAME) diff --git a/ThirdParty/boost/predef/platform/android.h b/ThirdParty/boost/predef/platform/android.h deleted file mode 100644 index 5acfcd386ea3b87afc0acc98370de3e7389934be..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/android.h +++ /dev/null @@ -1,44 +0,0 @@ -/* -Copyright Rene Rivera 2015-2019 -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_PREDEF_PLAT_ANDROID_H -#define BOOST_PREDEF_PLAT_ANDROID_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_PLAT_ANDROID` - -http://en.wikipedia.org/wiki/Android_%28operating_system%29[Android] platform. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__ANDROID__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_ANDROID BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__ANDROID__) -# undef BOOST_PLAT_ANDROID -# define BOOST_PLAT_ANDROID BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_ANDROID -# define BOOST_PLAT_ANDROID_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_ANDROID_NAME "Android" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_ANDROID,BOOST_PLAT_ANDROID_NAME) diff --git a/ThirdParty/boost/predef/platform/cloudabi.h b/ThirdParty/boost/predef/platform/cloudabi.h deleted file mode 100644 index a951c0ef23449e15b5c3e44e07f8581ca65aa451..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/cloudabi.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - Copyright 2017 James E. King, III - 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_PREDEF_PLAT_CLOUDABI_H -#define BOOST_PREDEF_PLAT_CLOUDABI_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_PLAT_CLOUDABI` - -https://github.com/NuxiNL/cloudabi[CloudABI] platform. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__CloudABI__+` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_CLOUDABI BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__CloudABI__) -# undef BOOST_PLAT_CLOUDABI -# define BOOST_PLAT_CLOUDABI BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_CLOUDABI -# define BOOST_PLAT_CLOUDABI_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_CLOUDABI_NAME "CloudABI" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_CLOUDABI,BOOST_PLAT_CLOUDABI_NAME) diff --git a/ThirdParty/boost/predef/platform/ios.h b/ThirdParty/boost/predef/platform/ios.h deleted file mode 100644 index 7d7c815f8edf2ddb9c9490245ff3e76305a92693..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/ios.h +++ /dev/null @@ -1,63 +0,0 @@ -/* -Copyright Ruslan Baratov 2017 -Copyright Rene Rivera 2017 -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_PREDEF_PLAT_IOS_H -#define BOOST_PREDEF_PLAT_IOS_H - -#include <boost/predef/os/ios.h> // BOOST_OS_IOS -#include <boost/predef/version_number.h> // BOOST_VERSION_NUMBER_NOT_AVAILABLE - -/* tag::reference[] -= `BOOST_PLAT_IOS_DEVICE` -= `BOOST_PLAT_IOS_SIMULATOR` - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `TARGET_IPHONE_SIMULATOR` | {predef_detection} -| `TARGET_OS_SIMULATOR` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_IOS_DEVICE BOOST_VERSION_NUMBER_NOT_AVAILABLE -#define BOOST_PLAT_IOS_SIMULATOR BOOST_VERSION_NUMBER_NOT_AVAILABLE - -// https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/TargetConditionals.h -#if BOOST_OS_IOS -# include <TargetConditionals.h> -# if defined(TARGET_OS_SIMULATOR) && (TARGET_OS_SIMULATOR == 1) -# undef BOOST_PLAT_IOS_SIMULATOR -# define BOOST_PLAT_IOS_SIMULATOR BOOST_VERSION_NUMBER_AVAILABLE -# elif defined(TARGET_IPHONE_SIMULATOR) && (TARGET_IPHONE_SIMULATOR == 1) -# undef BOOST_PLAT_IOS_SIMULATOR -# define BOOST_PLAT_IOS_SIMULATOR BOOST_VERSION_NUMBER_AVAILABLE -# else -# undef BOOST_PLAT_IOS_DEVICE -# define BOOST_PLAT_IOS_DEVICE BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#if BOOST_PLAT_IOS_SIMULATOR -# define BOOST_PLAT_IOS_SIMULATOR_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#if BOOST_PLAT_IOS_DEVICE -# define BOOST_PLAT_IOS_DEVICE_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_IOS_SIMULATOR_NAME "iOS Simulator" -#define BOOST_PLAT_IOS_DEVICE_NAME "iOS Device" - -#endif // BOOST_PREDEF_PLAT_IOS_H - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_IOS_SIMULATOR,BOOST_PLAT_IOS_SIMULATOR_NAME) -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_IOS_DEVICE,BOOST_PLAT_IOS_DEVICE_NAME) diff --git a/ThirdParty/boost/predef/platform/mingw.h b/ThirdParty/boost/predef/platform/mingw.h deleted file mode 100644 index 0be00c61ea98b0cba65238e67efdf96b4a486944..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/mingw.h +++ /dev/null @@ -1,70 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_PLAT_MINGW_H -#define BOOST_PREDEF_PLAT_MINGW_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_PLAT_MINGW` - -http://en.wikipedia.org/wiki/MinGW[MinGW] platform, either variety. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MINGW32__+` | {predef_detection} -| `+__MINGW64__+` | {predef_detection} - -| `+__MINGW64_VERSION_MAJOR+`, `+__MINGW64_VERSION_MINOR+` | V.R.0 -| `+__MINGW32_VERSION_MAJOR+`, `+__MINGW32_VERSION_MINOR+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_PLAT_MINGW BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MINGW32__) || defined(__MINGW64__) -# include <_mingw.h> -# if !defined(BOOST_PLAT_MINGW_DETECTION) && (defined(__MINGW64_VERSION_MAJOR) && defined(__MINGW64_VERSION_MINOR)) -# define BOOST_PLAT_MINGW_DETECTION \ - BOOST_VERSION_NUMBER(__MINGW64_VERSION_MAJOR,__MINGW64_VERSION_MINOR,0) -# endif -# if !defined(BOOST_PLAT_MINGW_DETECTION) && (defined(__MINGW32_VERSION_MAJOR) && defined(__MINGW32_VERSION_MINOR)) -# define BOOST_PLAT_MINGW_DETECTION \ - BOOST_VERSION_NUMBER(__MINGW32_MAJOR_VERSION,__MINGW32_MINOR_VERSION,0) -# endif -# if !defined(BOOST_PLAT_MINGW_DETECTION) -# define BOOST_PLAT_MINGW_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_PLAT_MINGW_DETECTION -# define BOOST_PLAT_MINGW_AVAILABLE -# if defined(BOOST_PREDEF_DETAIL_PLAT_DETECTED) -# define BOOST_PLAT_MINGW_EMULATED BOOST_PLAT_MINGW_DETECTION -# else -# undef BOOST_PLAT_MINGW -# define BOOST_PLAT_MINGW BOOST_PLAT_MINGW_DETECTION -# endif -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_MINGW_NAME "MinGW (any variety)" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW,BOOST_PLAT_MINGW_NAME) - -#ifdef BOOST_PLAT_MINGW_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW_EMULATED,BOOST_PLAT_MINGW_NAME) -#endif diff --git a/ThirdParty/boost/predef/platform/mingw32.h b/ThirdParty/boost/predef/platform/mingw32.h deleted file mode 100644 index 73e99e685ddb8335c814cf98b0ded5f3e7b9651b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/mingw32.h +++ /dev/null @@ -1,64 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_PLAT_MINGW32_H -#define BOOST_PREDEF_PLAT_MINGW32_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_PLAT_MINGW32` - -http://www.mingw.org/[MinGW] platform. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MINGW32__+` | {predef_detection} - -| `+__MINGW32_VERSION_MAJOR+`, `+__MINGW32_VERSION_MINOR+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_PLAT_MINGW32 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MINGW32__) -# include <_mingw.h> -# if !defined(BOOST_PLAT_MINGW32_DETECTION) && (defined(__MINGW32_VERSION_MAJOR) && defined(__MINGW32_VERSION_MINOR)) -# define BOOST_PLAT_MINGW32_DETECTION \ - BOOST_VERSION_NUMBER(__MINGW32_VERSION_MAJOR,__MINGW32_VERSION_MINOR,0) -# endif -# if !defined(BOOST_PLAT_MINGW32_DETECTION) -# define BOOST_PLAT_MINGW32_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_PLAT_MINGW32_DETECTION -# define BOOST_PLAT_MINGW32_AVAILABLE -# if defined(BOOST_PREDEF_DETAIL_PLAT_DETECTED) -# define BOOST_PLAT_MINGW32_EMULATED BOOST_PLAT_MINGW32_DETECTION -# else -# undef BOOST_PLAT_MINGW32 -# define BOOST_PLAT_MINGW32 BOOST_PLAT_MINGW32_DETECTION -# endif -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_MINGW32_NAME "MinGW" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW32,BOOST_PLAT_MINGW32_NAME) - -#ifdef BOOST_PLAT_MINGW32_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW32_EMULATED,BOOST_PLAT_MINGW32_NAME) -#endif diff --git a/ThirdParty/boost/predef/platform/mingw64.h b/ThirdParty/boost/predef/platform/mingw64.h deleted file mode 100644 index a49b195f4e2bc11550ba5c0a74c6e8cb5e60eeee..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/mingw64.h +++ /dev/null @@ -1,64 +0,0 @@ -/* -Copyright Rene Rivera 2008-2015 -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_PREDEF_PLAT_MINGW64_H -#define BOOST_PREDEF_PLAT_MINGW64_H - -#include <boost/predef/version_number.h> -#include <boost/predef/make.h> - -/* tag::reference[] -= `BOOST_PLAT_MINGW64` - -https://mingw-w64.org/[MinGW-w64] platform. -Version number available as major, minor, and patch. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MINGW64__+` | {predef_detection} - -| `+__MINGW64_VERSION_MAJOR+`, `+__MINGW64_VERSION_MINOR+` | V.R.0 -|=== -*/ // end::reference[] - -#define BOOST_PLAT_MINGW64 BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if defined(__MINGW64__) -# include <_mingw.h> -# if !defined(BOOST_PLAT_MINGW64_DETECTION) && (defined(__MINGW64_VERSION_MAJOR) && defined(__MINGW64_VERSION_MINOR)) -# define BOOST_PLAT_MINGW64_DETECTION \ - BOOST_VERSION_NUMBER(__MINGW64_VERSION_MAJOR,__MINGW64_VERSION_MINOR,0) -# endif -# if !defined(BOOST_PLAT_MINGW64_DETECTION) -# define BOOST_PLAT_MINGW64_DETECTION BOOST_VERSION_NUMBER_AVAILABLE -# endif -#endif - -#ifdef BOOST_PLAT_MINGW64_DETECTION -# define BOOST_PLAT_MINGW64_AVAILABLE -# if defined(BOOST_PREDEF_DETAIL_PLAT_DETECTED) -# define BOOST_PLAT_MINGW64_EMULATED BOOST_PLAT_MINGW64_DETECTION -# else -# undef BOOST_PLAT_MINGW64 -# define BOOST_PLAT_MINGW64 BOOST_PLAT_MINGW64_DETECTION -# endif -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_MINGW64_NAME "MinGW-w64" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW64,BOOST_PLAT_MINGW64_NAME) - -#ifdef BOOST_PLAT_MINGW64_EMULATED -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW64_EMULATED,BOOST_PLAT_MINGW64_NAME) -#endif diff --git a/ThirdParty/boost/predef/platform/windows_desktop.h b/ThirdParty/boost/predef/platform/windows_desktop.h deleted file mode 100644 index 917c3395ef1d8d704019654d763b68c865985878..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_desktop.h +++ /dev/null @@ -1,52 +0,0 @@ -/* -Copyright (c) Microsoft Corporation 2014 -Copyright Rene Rivera 2015 -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_PREDEF_PLAT_WINDOWS_DESKTOP_H -#define BOOST_PREDEF_PLAT_WINDOWS_DESKTOP_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_uwp.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_DESKTOP` - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows Desktop development. Also available if the Platform SDK is too -old to support UWP. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP` | {predef_detection} -| `!BOOST_PLAT_WINDOWS_UWP` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_DESKTOP BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - ((defined(WINAPI_FAMILY_DESKTOP_APP) && WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP) || \ - !BOOST_PLAT_WINDOWS_UWP) -# undef BOOST_PLAT_WINDOWS_DESKTOP -# define BOOST_PLAT_WINDOWS_DESKTOP BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_DESKTOP -# define BOOST_PLAT_WINDOWS_DESKTOP_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_DESKTOP_NAME "Windows Desktop" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_DESKTOP,BOOST_PLAT_WINDOWS_DESKTOP_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_phone.h b/ThirdParty/boost/predef/platform/windows_phone.h deleted file mode 100644 index cfb1b65e2e241b7eee29d93a62af88c75cdf71fd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_phone.h +++ /dev/null @@ -1,49 +0,0 @@ -/* -Copyright (c) Microsoft Corporation 2014 -Copyright Rene Rivera 2015 -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_PREDEF_PLAT_WINDOWS_PHONE_H -#define BOOST_PREDEF_PLAT_WINDOWS_PHONE_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_uwp.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_PHONE` - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows Phone development. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_PHONE BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - defined(WINAPI_FAMILY_PHONE_APP) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP -# undef BOOST_PLAT_WINDOWS_PHONE -# define BOOST_PLAT_WINDOWS_PHONE BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_PHONE -# define BOOST_PLAT_WINDOWS_PHONE_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_PHONE_NAME "Windows Phone" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_PHONE,BOOST_PLAT_WINDOWS_PHONE_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_runtime.h b/ThirdParty/boost/predef/platform/windows_runtime.h deleted file mode 100644 index 44542d61aabdf749e4995039a56f0f2b51b2c588..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_runtime.h +++ /dev/null @@ -1,54 +0,0 @@ -/* -Copyright (c) Microsoft Corporation 2014 -Copyright Rene Rivera 2015 -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_PREDEF_PLAT_WINDOWS_RUNTIME_H -#define BOOST_PREDEF_PLAT_WINDOWS_RUNTIME_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_phone.h> -#include <boost/predef/platform/windows_store.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_RUNTIME` - -Deprecated. - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows Phone or Store development. This does not align to the existing development model for -UWP and is deprecated. Use one of the other `BOOST_PLAT_WINDOWS_*`definitions instead. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `BOOST_PLAT_WINDOWS_PHONE` | {predef_detection} -| `BOOST_PLAT_WINDOWS_STORE` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_RUNTIME BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - (BOOST_PLAT_WINDOWS_STORE || BOOST_PLAT_WINDOWS_PHONE) -# undef BOOST_PLAT_WINDOWS_RUNTIME -# define BOOST_PLAT_WINDOWS_RUNTIME BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_RUNTIME -# define BOOST_PLAT_WINDOWS_RUNTIME_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_RUNTIME_NAME "Windows Runtime" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_RUNTIME,BOOST_PLAT_WINDOWS_RUNTIME_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_server.h b/ThirdParty/boost/predef/platform/windows_server.h deleted file mode 100644 index f0e3dc0bbb918fcfe0b5ae537ce77ca92472f1ac..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_server.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright James E. King III, 2017 -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_PREDEF_PLAT_WINDOWS_SERVER_H -#define BOOST_PREDEF_PLAT_WINDOWS_SERVER_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_uwp.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_SERVER` - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows Server development. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `WINAPI_FAMILY == WINAPI_FAMILY_SERVER` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_SERVER BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - defined(WINAPI_FAMILY_SERVER) && WINAPI_FAMILY == WINAPI_FAMILY_SERVER -# undef BOOST_PLAT_WINDOWS_SERVER -# define BOOST_PLAT_WINDOWS_SERVER BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_SERVER -# define BOOST_PLAT_WINDOWS_SERVER_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_SERVER_NAME "Windows Server" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_SERVER,BOOST_PLAT_WINDOWS_SERVER_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_store.h b/ThirdParty/boost/predef/platform/windows_store.h deleted file mode 100644 index ac5ff519951ecc5161021bf5f1e32eababaf697c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_store.h +++ /dev/null @@ -1,51 +0,0 @@ -/* -Copyright (c) Microsoft Corporation 2014 -Copyright Rene Rivera 2015 -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_PREDEF_PLAT_WINDOWS_STORE_H -#define BOOST_PREDEF_PLAT_WINDOWS_STORE_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_uwp.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_STORE` - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows Store development. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `WINAPI_FAMILY == WINAPI_FAMILY_PC_APP` | {predef_detection} -| `WINAPI_FAMILY == WINAPI_FAMILY_APP` (deprecated) | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_STORE BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - ((defined(WINAPI_FAMILY_PC_APP) && WINAPI_FAMILY == WINAPI_FAMILY_PC_APP) || \ - (defined(WINAPI_FAMILY_APP) && WINAPI_FAMILY == WINAPI_FAMILY_APP)) -# undef BOOST_PLAT_WINDOWS_STORE -# define BOOST_PLAT_WINDOWS_STORE BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_STORE -# define BOOST_PLAT_WINDOWS_STORE_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_STORE_NAME "Windows Store" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_STORE,BOOST_PLAT_WINDOWS_STORE_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_system.h b/ThirdParty/boost/predef/platform/windows_system.h deleted file mode 100644 index 71a0c2c62b98d212d6eb155612cefbe8e5387320..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_system.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -Copyright James E. King III, 2017 -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_PREDEF_PLAT_WINDOWS_SYSTEM_H -#define BOOST_PREDEF_PLAT_WINDOWS_SYSTEM_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/platform/windows_uwp.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_SYSTEM` - -https://docs.microsoft.com/en-us/windows/uwp/get-started/universal-application-platform-guide[UWP] -for Windows System development. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `WINAPI_FAMILY == WINAPI_FAMILY_SYSTEM` | {predef_detection} -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_SYSTEM BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS && \ - defined(WINAPI_FAMILY_SYSTEM) && WINAPI_FAMILY == WINAPI_FAMILY_SYSTEM -# undef BOOST_PLAT_WINDOWS_SYSTEM -# define BOOST_PLAT_WINDOWS_SYSTEM BOOST_VERSION_NUMBER_AVAILABLE -#endif - -#if BOOST_PLAT_WINDOWS_SYSTEM -# define BOOST_PLAT_WINDOWS_SYSTEM_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -#endif - -#define BOOST_PLAT_WINDOWS_SYSTEM_NAME "Windows Drivers and Tools" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_SYSTEM,BOOST_PLAT_WINDOWS_SYSTEM_NAME) diff --git a/ThirdParty/boost/predef/platform/windows_uwp.h b/ThirdParty/boost/predef/platform/windows_uwp.h deleted file mode 100644 index 8dc1380bbf8eabd390ffc6034728e0d5ed858080..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/platform/windows_uwp.h +++ /dev/null @@ -1,61 +0,0 @@ -/* -Copyright James E. King III, 2017 -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_PREDEF_PLAT_WINDOWS_UWP_H -#define BOOST_PREDEF_PLAT_WINDOWS_UWP_H - -#include <boost/predef/make.h> -#include <boost/predef/os/windows.h> -#include <boost/predef/version_number.h> - -/* tag::reference[] -= `BOOST_PLAT_WINDOWS_UWP` - -http://docs.microsoft.com/windows/uwp/[Universal Windows Platform] -is available if the current development environment is capable of targeting -UWP development. - -[options="header"] -|=== -| {predef_symbol} | {predef_version} - -| `+__MINGW64_VERSION_MAJOR+` from `+_mingw.h+` | `>= 3` -| `VER_PRODUCTBUILD` from `ntverp.h` | `>= 9200` -|=== -*/ // end::reference[] - -#define BOOST_PLAT_WINDOWS_UWP BOOST_VERSION_NUMBER_NOT_AVAILABLE -#define BOOST_PLAT_WINDOWS_SDK_VERSION BOOST_VERSION_NUMBER_NOT_AVAILABLE - -#if BOOST_OS_WINDOWS -// MinGW (32-bit), WinCE, and wineg++ don't have a ntverp.h header -#if !defined(__MINGW32__) && !defined(_WIN32_WCE) && !defined(__WINE__) -# include <ntverp.h> -# undef BOOST_PLAT_WINDOWS_SDK_VERSION -# define BOOST_PLAT_WINDOWS_SDK_VERSION BOOST_VERSION_NUMBER(0, 0, VER_PRODUCTBUILD) -#endif - -// 9200 is Windows SDK 8.0 from ntverp.h which introduced family support -#if ((BOOST_PLAT_WINDOWS_SDK_VERSION >= BOOST_VERSION_NUMBER(0, 0, 9200)) || \ - (defined(__MINGW64__) && __MINGW64_VERSION_MAJOR >= 3)) -# undef BOOST_PLAT_WINDOWS_UWP -# define BOOST_PLAT_WINDOWS_UWP BOOST_VERSION_NUMBER_AVAILABLE -#endif -#endif - -#if BOOST_PLAT_WINDOWS_UWP -# define BOOST_PLAT_WINDOWS_UWP_AVAILABLE -# include <boost/predef/detail/platform_detected.h> -# include <winapifamily.h> // Windows SDK -#endif - -#define BOOST_PLAT_WINDOWS_UWP_NAME "Universal Windows Platform" - -#endif - -#include <boost/predef/detail/test.h> -BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_WINDOWS_UWP, BOOST_PLAT_WINDOWS_UWP_NAME) diff --git a/ThirdParty/boost/predef/version.h b/ThirdParty/boost/predef/version.h deleted file mode 100644 index 39ef2b49a58a5a4e462c16a1e4b8da209fd4491b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/version.h +++ /dev/null @@ -1,15 +0,0 @@ -/* -Copyright Rene Rivera 2015-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_PREDEF_VERSION_H -#define BOOST_PREDEF_VERSION_H - -#include <boost/predef/version_number.h> - -#define BOOST_PREDEF_VERSION BOOST_VERSION_NUMBER(1,11,0) - -#endif diff --git a/ThirdParty/boost/predef/version_number.h b/ThirdParty/boost/predef/version_number.h deleted file mode 100644 index 903578245b72ce31ce082599aaeb71d78283eb3e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/predef/version_number.h +++ /dev/null @@ -1,74 +0,0 @@ -/* -Copyright Rene Rivera 2005-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_PREDEF_VERSION_NUMBER_H -#define BOOST_PREDEF_VERSION_NUMBER_H - -/* tag::reference[] -= `BOOST_VERSION_NUMBER` - -[source] ----- -BOOST_VERSION_NUMBER(major,minor,patch) ----- - -Defines standard version numbers, with these properties: - -* Decimal base whole numbers in the range [0,1000000000). - The number range is designed to allow for a (2,2,5) triplet. - Which fits within a 32 bit value. -* The `major` number can be in the [0,99] range. -* The `minor` number can be in the [0,99] range. -* The `patch` number can be in the [0,99999] range. -* Values can be specified in any base. As the defined value - is an constant expression. -* Value can be directly used in both preprocessor and compiler - expressions for comparison to other similarly defined values. -* The implementation enforces the individual ranges for the - major, minor, and patch numbers. And values over the ranges - are truncated (modulo). - -*/ // end::reference[] -#define BOOST_VERSION_NUMBER(major,minor,patch) \ - ( (((major)%100)*10000000) + (((minor)%100)*100000) + ((patch)%100000) ) - -#define BOOST_VERSION_NUMBER_MAX \ - BOOST_VERSION_NUMBER(99,99,99999) - -#define BOOST_VERSION_NUMBER_ZERO \ - BOOST_VERSION_NUMBER(0,0,0) - -#define BOOST_VERSION_NUMBER_MIN \ - BOOST_VERSION_NUMBER(0,0,1) - -#define BOOST_VERSION_NUMBER_AVAILABLE \ - BOOST_VERSION_NUMBER_MIN - -#define BOOST_VERSION_NUMBER_NOT_AVAILABLE \ - BOOST_VERSION_NUMBER_ZERO - -/* tag::reference[] -[source] ----- -BOOST_VERSION_NUMBER_MAJOR(N), BOOST_VERSION_NUMBER_MINOR(N), BOOST_VERSION_NUMBER_PATCH(N) ----- - -The macros extract the major, minor, and patch portion from a well formed -version number resulting in a preprocessor expression in the range of -[0,99] or [0,99999] for the major and minor, or patch numbers -respectively. -*/ // end::reference[] -#define BOOST_VERSION_NUMBER_MAJOR(N) \ - ( ((N)/10000000)%100 ) - -#define BOOST_VERSION_NUMBER_MINOR(N) \ - ( ((N)/100000)%100 ) - -#define BOOST_VERSION_NUMBER_PATCH(N) \ - ( (N)%100000 ) - -#endif diff --git a/ThirdParty/boost/preprocessor/config/config.hpp b/ThirdParty/boost/preprocessor/config/config.hpp deleted file mode 100644 index 2c7ece92e34df0a3475912d6b921d56a9f9933b2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/config/config.hpp +++ /dev/null @@ -1,115 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002-2011. * -# * (C) Copyright Edward Diener 2011. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_CONFIG_CONFIG_HPP -# define BOOST_PREPROCESSOR_CONFIG_CONFIG_HPP -# -# /* BOOST_PP_CONFIG_FLAGS */ -# -# define BOOST_PP_CONFIG_STRICT() 0x0001 -# define BOOST_PP_CONFIG_IDEAL() 0x0002 -# -# define BOOST_PP_CONFIG_MSVC() 0x0004 -# define BOOST_PP_CONFIG_MWCC() 0x0008 -# define BOOST_PP_CONFIG_BCC() 0x0010 -# define BOOST_PP_CONFIG_EDG() 0x0020 -# define BOOST_PP_CONFIG_DMC() 0x0040 -# -# ifndef BOOST_PP_CONFIG_FLAGS -# if defined(__GCCXML__) || defined(__WAVE__) || defined(__MWERKS__) && __MWERKS__ >= 0x3200 -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# elif defined(__EDG__) || defined(__EDG_VERSION__) -# if defined(_MSC_VER) && !defined(__clang__) && (defined(__INTELLISENSE__) || __EDG_VERSION__ >= 308) -# if !defined(_MSVC_TRADITIONAL) || _MSVC_TRADITIONAL -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_MSVC()) -# else -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# endif -# else -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_EDG() | BOOST_PP_CONFIG_STRICT()) -# endif -# elif defined(_MSC_VER) && defined(__clang__) -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# elif defined(__MWERKS__) -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_MWCC()) -# elif defined(__DMC__) -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_DMC()) -# elif defined(__BORLANDC__) && __BORLANDC__ >= 0x581 -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# elif defined(__BORLANDC__) || defined(__IBMC__) || defined(__IBMCPP__) || defined(__SUNPRO_CC) -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_BCC()) -# elif defined(_MSC_VER) -# if !defined(_MSVC_TRADITIONAL) || _MSVC_TRADITIONAL -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_MSVC()) -# else -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# endif -# else -# define BOOST_PP_CONFIG_FLAGS() (BOOST_PP_CONFIG_STRICT()) -# endif -# endif -# -# /* BOOST_PP_CONFIG_EXTENDED_LINE_INFO */ -# -# ifndef BOOST_PP_CONFIG_EXTENDED_LINE_INFO -# define BOOST_PP_CONFIG_EXTENDED_LINE_INFO 0 -# endif -# -# /* BOOST_PP_CONFIG_ERRORS */ -# -# ifndef BOOST_PP_CONFIG_ERRORS -# ifdef NDEBUG -# define BOOST_PP_CONFIG_ERRORS 0 -# else -# define BOOST_PP_CONFIG_ERRORS 1 -# endif -# endif -# -# /* BOOST_PP_VARIADICS */ -# -# define BOOST_PP_VARIADICS_MSVC 0 -# if !defined BOOST_PP_VARIADICS -# /* variadic support explicitly disabled for all untested compilers */ - -# if defined __GCCXML__ || (defined __NVCC__ && defined __CUDACC__) || defined __PATHSCALE__ || defined __DMC__ || (defined __CODEGEARC__ && !defined(__clang__)) || (defined __BORLANDC__ && !defined(__clang__)) || defined __MWERKS__ || ( defined __SUNPRO_CC && __SUNPRO_CC < 0x5120 ) || (defined __HP_aCC && !defined __EDG__) || defined __MRC__ || defined __SC__ || (defined(__PGI) && !defined(__EDG__)) -# define BOOST_PP_VARIADICS 0 -# elif defined(_MSC_VER) && defined(__clang__) -# define BOOST_PP_VARIADICS 1 -# /* VC++ (C/C++) and Intel C++ Compiler >= 17.0 with MSVC */ -# elif defined _MSC_VER && _MSC_VER >= 1400 && (!defined __EDG__ || defined(__INTELLISENSE__) || defined(__INTEL_COMPILER) && __INTEL_COMPILER >= 1700) -# define BOOST_PP_VARIADICS 1 -# if !defined(_MSVC_TRADITIONAL) || _MSVC_TRADITIONAL -# undef BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_VARIADICS_MSVC 1 -# endif -# /* Wave (C/C++), GCC (C++) */ -# elif defined __WAVE__ && __WAVE_HAS_VARIADICS__ || defined __GNUC__ && defined __GXX_EXPERIMENTAL_CXX0X__ && __GXX_EXPERIMENTAL_CXX0X__ -# define BOOST_PP_VARIADICS 1 -# /* EDG-based (C/C++), GCC (C), and unknown (C/C++) */ -# elif !defined __cplusplus && __STDC_VERSION__ >= 199901L || __cplusplus >= 201103L -# define BOOST_PP_VARIADICS 1 -# else -# define BOOST_PP_VARIADICS 0 -# endif -# elif !BOOST_PP_VARIADICS + 1 < 2 -# undef BOOST_PP_VARIADICS -# define BOOST_PP_VARIADICS 1 -# if defined _MSC_VER && _MSC_VER >= 1400 && !defined(__clang__) && (defined(__INTELLISENSE__) || (defined(__INTEL_COMPILER) && __INTEL_COMPILER >= 1700) || !(defined __EDG__ || defined __GCCXML__ || (defined __NVCC__ && defined __CUDACC__) || defined __PATHSCALE__ || defined __DMC__ || defined __CODEGEARC__ || defined __BORLANDC__ || defined __MWERKS__ || defined __SUNPRO_CC || defined __HP_aCC || defined __MRC__ || defined __SC__ || defined __IBMCPP__ || defined __PGI)) && (!defined(_MSVC_TRADITIONAL) || _MSVC_TRADITIONAL) -# undef BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_VARIADICS_MSVC 1 -# endif -# else -# undef BOOST_PP_VARIADICS -# define BOOST_PP_VARIADICS 0 -# endif -# -# endif diff --git a/ThirdParty/boost/preprocessor/facilities/detail/is_empty.hpp b/ThirdParty/boost/preprocessor/facilities/detail/is_empty.hpp deleted file mode 100644 index ce167325279589b81553dd331dcd5dffb19a0af1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/facilities/detail/is_empty.hpp +++ /dev/null @@ -1,55 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2014. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -#ifndef BOOST_PREPROCESSOR_DETAIL_IS_EMPTY_HPP -#define BOOST_PREPROCESSOR_DETAIL_IS_EMPTY_HPP - -#include <boost/preprocessor/punctuation/is_begin_parens.hpp> - -#if BOOST_PP_VARIADICS_MSVC - -# pragma warning(once:4002) - -#define BOOST_PP_DETAIL_IS_EMPTY_IIF_0(t, b) b -#define BOOST_PP_DETAIL_IS_EMPTY_IIF_1(t, b) t - -#else - -#define BOOST_PP_DETAIL_IS_EMPTY_IIF_0(t, ...) __VA_ARGS__ -#define BOOST_PP_DETAIL_IS_EMPTY_IIF_1(t, ...) t - -#endif - -#if BOOST_PP_VARIADICS_MSVC && _MSC_VER <= 1400 - -#define BOOST_PP_DETAIL_IS_EMPTY_PROCESS(param) \ - BOOST_PP_IS_BEGIN_PARENS \ - ( \ - BOOST_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C param () \ - ) \ -/**/ - -#else - -#define BOOST_PP_DETAIL_IS_EMPTY_PROCESS(...) \ - BOOST_PP_IS_BEGIN_PARENS \ - ( \ - BOOST_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C __VA_ARGS__ () \ - ) \ -/**/ - -#endif - -#define BOOST_PP_DETAIL_IS_EMPTY_PRIMITIVE_CAT(a, b) a ## b -#define BOOST_PP_DETAIL_IS_EMPTY_IIF(bit) BOOST_PP_DETAIL_IS_EMPTY_PRIMITIVE_CAT(BOOST_PP_DETAIL_IS_EMPTY_IIF_,bit) -#define BOOST_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C(...) () - -#endif /* BOOST_PREPROCESSOR_DETAIL_IS_EMPTY_HPP */ diff --git a/ThirdParty/boost/preprocessor/facilities/is_empty_variadic.hpp b/ThirdParty/boost/preprocessor/facilities/is_empty_variadic.hpp deleted file mode 100644 index 77ebf6d323fe8f43c374e518d01a97aeccd2e5b9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/facilities/is_empty_variadic.hpp +++ /dev/null @@ -1,84 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2014,2019. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_FACILITIES_IS_EMPTY_VARIADIC_HPP -# define BOOST_PREPROCESSOR_FACILITIES_IS_EMPTY_VARIADIC_HPP -# -# include <boost/preprocessor/config/config.hpp> -# -# if BOOST_PP_VARIADICS -# -# include <boost/preprocessor/punctuation/is_begin_parens.hpp> -# include <boost/preprocessor/facilities/detail/is_empty.hpp> -# -#if BOOST_PP_VARIADICS_MSVC && _MSC_VER <= 1400 -# -#define BOOST_PP_IS_EMPTY(param) \ - BOOST_PP_DETAIL_IS_EMPTY_IIF \ - ( \ - BOOST_PP_IS_BEGIN_PARENS \ - ( \ - param \ - ) \ - ) \ - ( \ - BOOST_PP_IS_EMPTY_ZERO, \ - BOOST_PP_DETAIL_IS_EMPTY_PROCESS \ - ) \ - (param) \ -/**/ -#define BOOST_PP_IS_EMPTY_ZERO(param) 0 -# else -# if defined(__cplusplus) && __cplusplus > 201703L -# include <boost/preprocessor/variadic/has_opt.hpp> -#define BOOST_PP_IS_EMPTY(...) \ - BOOST_PP_DETAIL_IS_EMPTY_IIF \ - ( \ - BOOST_PP_VARIADIC_HAS_OPT() \ - ) \ - ( \ - BOOST_PP_IS_EMPTY_OPT, \ - BOOST_PP_IS_EMPTY_NO_OPT \ - ) \ - (__VA_ARGS__) \ -/**/ -#define BOOST_PP_IS_EMPTY_FUNCTION2(...) \ - __VA_OPT__(0,) 1 \ -/**/ -#define BOOST_PP_IS_EMPTY_FUNCTION(...) \ - BOOST_PP_IS_EMPTY_FUNCTION2(__VA_ARGS__) \ -/**/ -#define BOOST_PP_IS_EMPTY_OPT(...) \ - BOOST_PP_VARIADIC_HAS_OPT_ELEM0(BOOST_PP_IS_EMPTY_FUNCTION(__VA_ARGS__),) \ -/**/ -# else -#define BOOST_PP_IS_EMPTY(...) \ - BOOST_PP_IS_EMPTY_NO_OPT(__VA_ARGS__) \ -/**/ -# endif /* defined(__cplusplus) && __cplusplus > 201703L */ -#define BOOST_PP_IS_EMPTY_NO_OPT(...) \ - BOOST_PP_DETAIL_IS_EMPTY_IIF \ - ( \ - BOOST_PP_IS_BEGIN_PARENS \ - ( \ - __VA_ARGS__ \ - ) \ - ) \ - ( \ - BOOST_PP_IS_EMPTY_ZERO, \ - BOOST_PP_DETAIL_IS_EMPTY_PROCESS \ - ) \ - (__VA_ARGS__) \ -/**/ -#define BOOST_PP_IS_EMPTY_ZERO(...) 0 -# endif /* BOOST_PP_VARIADICS_MSVC && _MSC_VER <= 1400 */ -# endif /* BOOST_PP_VARIADICS */ -# endif /* BOOST_PREPROCESSOR_FACILITIES_IS_EMPTY_VARIADIC_HPP */ diff --git a/ThirdParty/boost/preprocessor/repetition/for.hpp b/ThirdParty/boost/preprocessor/repetition/for.hpp deleted file mode 100644 index 3c5048ad01fd816c00a5969cfe40cfff889c48a3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/repetition/for.hpp +++ /dev/null @@ -1,324 +0,0 @@ -# /* Copyright (C) 2001 -# * Housemarque Oy -# * http://www.housemarque.com -# * -# * 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) -# */ -# -# /* Revised by Paul Mensonides (2002) */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_REPETITION_FOR_HPP -# define BOOST_PREPROCESSOR_REPETITION_FOR_HPP -# -# include <boost/preprocessor/cat.hpp> -# include <boost/preprocessor/debug/error.hpp> -# include <boost/preprocessor/facilities/empty.hpp> -# include <boost/preprocessor/logical/bool.hpp> -# include <boost/preprocessor/detail/auto_rec.hpp> -# -# /* BOOST_PP_FOR */ -# -# if 0 -# define BOOST_PP_FOR(state, pred, op, macro) -# endif -# -# define BOOST_PP_FOR BOOST_PP_CAT(BOOST_PP_FOR_, BOOST_PP_AUTO_REC(BOOST_PP_FOR_P, 256)) -# -# define BOOST_PP_FOR_P(n) BOOST_PP_CAT(BOOST_PP_FOR_CHECK_, BOOST_PP_FOR_ ## n(1, BOOST_PP_FOR_SR_P, BOOST_PP_FOR_SR_O, BOOST_PP_FOR_SR_M)) -# -# define BOOST_PP_FOR_SR_P(r, s) s -# define BOOST_PP_FOR_SR_O(r, s) 0 -# define BOOST_PP_FOR_SR_M(r, s) BOOST_PP_NIL -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# include <boost/preprocessor/repetition/detail/edg/for.hpp> -# elif BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC() -# include <boost/preprocessor/repetition/detail/msvc/for.hpp> -# elif BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_DMC() -# include <boost/preprocessor/repetition/detail/dmc/for.hpp> -# else -# include <boost/preprocessor/repetition/detail/for.hpp> -# endif -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_DMC() -# define BOOST_PP_FOR_257_PR(s, p) BOOST_PP_BOOL(p##(257, s)) -# else -# define BOOST_PP_FOR_257_PR(s, p) BOOST_PP_BOOL(p(257, s)) -# endif - -# define BOOST_PP_FOR_257_ERROR() BOOST_PP_ERROR(0x0002) -# define BOOST_PP_FOR_257(s, p, o, m) \ - BOOST_PP_IIF \ - ( \ - BOOST_PP_FOR_257_PR(s,p), \ - BOOST_PP_FOR_257_ERROR, \ - BOOST_PP_EMPTY \ - ) \ - () \ -/**/ -// # define BOOST_PP_FOR_257(s, p, o, m) BOOST_PP_ERROR(0x0002) -# -# define BOOST_PP_FOR_CHECK_BOOST_PP_NIL 1 -# -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_1(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_2(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_3(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_4(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_5(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_6(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_7(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_8(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_9(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_10(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_11(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_12(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_13(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_14(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_15(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_16(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_17(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_18(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_19(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_20(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_21(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_22(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_23(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_24(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_25(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_26(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_27(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_28(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_29(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_30(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_31(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_32(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_33(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_34(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_35(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_36(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_37(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_38(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_39(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_40(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_41(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_42(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_43(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_44(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_45(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_46(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_47(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_48(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_49(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_50(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_51(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_52(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_53(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_54(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_55(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_56(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_57(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_58(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_59(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_60(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_61(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_62(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_63(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_64(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_65(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_66(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_67(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_68(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_69(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_70(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_71(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_72(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_73(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_74(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_75(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_76(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_77(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_78(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_79(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_80(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_81(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_82(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_83(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_84(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_85(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_86(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_87(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_88(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_89(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_90(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_91(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_92(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_93(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_94(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_95(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_96(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_97(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_98(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_99(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_100(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_101(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_102(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_103(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_104(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_105(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_106(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_107(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_108(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_109(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_110(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_111(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_112(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_113(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_114(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_115(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_116(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_117(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_118(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_119(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_120(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_121(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_122(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_123(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_124(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_125(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_126(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_127(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_128(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_129(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_130(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_131(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_132(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_133(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_134(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_135(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_136(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_137(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_138(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_139(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_140(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_141(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_142(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_143(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_144(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_145(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_146(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_147(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_148(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_149(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_150(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_151(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_152(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_153(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_154(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_155(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_156(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_157(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_158(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_159(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_160(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_161(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_162(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_163(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_164(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_165(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_166(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_167(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_168(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_169(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_170(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_171(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_172(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_173(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_174(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_175(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_176(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_177(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_178(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_179(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_180(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_181(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_182(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_183(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_184(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_185(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_186(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_187(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_188(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_189(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_190(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_191(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_192(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_193(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_194(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_195(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_196(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_197(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_198(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_199(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_200(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_201(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_202(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_203(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_204(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_205(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_206(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_207(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_208(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_209(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_210(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_211(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_212(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_213(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_214(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_215(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_216(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_217(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_218(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_219(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_220(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_221(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_222(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_223(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_224(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_225(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_226(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_227(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_228(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_229(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_230(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_231(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_232(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_233(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_234(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_235(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_236(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_237(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_238(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_239(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_240(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_241(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_242(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_243(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_244(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_245(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_246(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_247(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_248(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_249(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_250(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_251(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_252(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_253(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_254(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_255(s, p, o, m) 0 -# define BOOST_PP_FOR_CHECK_BOOST_PP_FOR_256(s, p, o, m) 0 -# -# endif diff --git a/ThirdParty/boost/preprocessor/seq/detail/is_empty.hpp b/ThirdParty/boost/preprocessor/seq/detail/is_empty.hpp deleted file mode 100644 index 14461ba48e19ec0f058f381e880948ae8403fcb3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/seq/detail/is_empty.hpp +++ /dev/null @@ -1,49 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2015. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_SEQ_DETAIL_IS_EMPTY_HPP -# define BOOST_PREPROCESSOR_SEQ_DETAIL_IS_EMPTY_HPP -# -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/arithmetic/dec.hpp> -# include <boost/preprocessor/logical/bool.hpp> -# include <boost/preprocessor/logical/compl.hpp> -# include <boost/preprocessor/seq/size.hpp> -# -/* An empty seq is one that is just BOOST_PP_SEQ_NIL */ -# -# define BOOST_PP_SEQ_DETAIL_IS_EMPTY(seq) \ - BOOST_PP_COMPL \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq) \ - ) \ -/**/ -# -# define BOOST_PP_SEQ_DETAIL_IS_EMPTY_SIZE(size) \ - BOOST_PP_COMPL \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY_SIZE(size) \ - ) \ -/**/ -# -# define BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq) \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY_SIZE(BOOST_PP_SEQ_DETAIL_EMPTY_SIZE(seq)) \ -/**/ -# -# define BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY_SIZE(size) \ - BOOST_PP_BOOL(size) \ -/**/ -# -# define BOOST_PP_SEQ_DETAIL_EMPTY_SIZE(seq) \ - BOOST_PP_DEC(BOOST_PP_SEQ_SIZE(seq (nil))) \ -/**/ -# -# endif diff --git a/ThirdParty/boost/preprocessor/seq/for_each.hpp b/ThirdParty/boost/preprocessor/seq/for_each.hpp deleted file mode 100644 index 00a83d4d790250c7fae48b833bf9d1fe214986bb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/seq/for_each.hpp +++ /dev/null @@ -1,107 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_SEQ_FOR_EACH_HPP -# define BOOST_PREPROCESSOR_SEQ_FOR_EACH_HPP -# -# include <boost/preprocessor/arithmetic/dec.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/control/if.hpp> -# include <boost/preprocessor/control/iif.hpp> -# include <boost/preprocessor/repetition/for.hpp> -# include <boost/preprocessor/seq/seq.hpp> -# include <boost/preprocessor/seq/size.hpp> -# include <boost/preprocessor/seq/detail/is_empty.hpp> -# include <boost/preprocessor/tuple/elem.hpp> -# include <boost/preprocessor/tuple/rem.hpp> -# -# /* BOOST_PP_SEQ_FOR_EACH */ -# -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_SEQ_FOR_EACH(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK(macro, data, seq) -# else -# define BOOST_PP_SEQ_FOR_EACH(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_D(macro, data, seq) -# define BOOST_PP_SEQ_FOR_EACH_D(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK(macro, data, seq) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EXEC(macro, data, seq) BOOST_PP_FOR((macro, data, seq, BOOST_PP_SEQ_SIZE(seq)), BOOST_PP_SEQ_FOR_EACH_P, BOOST_PP_SEQ_FOR_EACH_O, BOOST_PP_SEQ_FOR_EACH_M) -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EMPTY(macro, data, seq) -# -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK(macro, data, seq) \ - BOOST_PP_IIF \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq), \ - BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EXEC, \ - BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EMPTY \ - ) \ - (macro, data, seq) \ -/**/ -# -# define BOOST_PP_SEQ_FOR_EACH_P(r, x) BOOST_PP_TUPLE_ELEM(4, 3, x) -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_STRICT() -# define BOOST_PP_SEQ_FOR_EACH_O(r, x) BOOST_PP_SEQ_FOR_EACH_O_I x -# else -# define BOOST_PP_SEQ_FOR_EACH_O(r, x) BOOST_PP_SEQ_FOR_EACH_O_I(BOOST_PP_TUPLE_ELEM(4, 0, x), BOOST_PP_TUPLE_ELEM(4, 1, x), BOOST_PP_TUPLE_ELEM(4, 2, x), BOOST_PP_TUPLE_ELEM(4, 3, x)) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_O_I(macro, data, seq, sz) \ - BOOST_PP_SEQ_FOR_EACH_O_I_DEC(macro, data, seq, BOOST_PP_DEC(sz)) \ -/**/ -# define BOOST_PP_SEQ_FOR_EACH_O_I_DEC(macro, data, seq, sz) \ - ( \ - macro, \ - data, \ - BOOST_PP_IF \ - ( \ - sz, \ - BOOST_PP_SEQ_FOR_EACH_O_I_TAIL, \ - BOOST_PP_SEQ_FOR_EACH_O_I_NIL \ - ) \ - (seq), \ - sz \ - ) \ -/**/ -# define BOOST_PP_SEQ_FOR_EACH_O_I_TAIL(seq) BOOST_PP_SEQ_TAIL(seq) -# define BOOST_PP_SEQ_FOR_EACH_O_I_NIL(seq) BOOST_PP_NIL -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_STRICT() -# define BOOST_PP_SEQ_FOR_EACH_M(r, x) BOOST_PP_SEQ_FOR_EACH_M_IM(r, BOOST_PP_TUPLE_REM_4 x) -# define BOOST_PP_SEQ_FOR_EACH_M_IM(r, im) BOOST_PP_SEQ_FOR_EACH_M_I(r, im) -# else -# define BOOST_PP_SEQ_FOR_EACH_M(r, x) BOOST_PP_SEQ_FOR_EACH_M_I(r, BOOST_PP_TUPLE_ELEM(4, 0, x), BOOST_PP_TUPLE_ELEM(4, 1, x), BOOST_PP_TUPLE_ELEM(4, 2, x), BOOST_PP_TUPLE_ELEM(4, 3, x)) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_M_I(r, macro, data, seq, sz) macro(r, data, BOOST_PP_SEQ_HEAD(seq)) -# -# /* BOOST_PP_SEQ_FOR_EACH_R */ -# -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_SEQ_FOR_EACH_R(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_R(r, macro, data, seq) -# else -# define BOOST_PP_SEQ_FOR_EACH_R(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_R_I(r, macro, data, seq) -# define BOOST_PP_SEQ_FOR_EACH_R_I(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_R(r, macro, data, seq) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EXEC_R(r, macro, data, seq) BOOST_PP_FOR_ ## r((macro, data, seq, BOOST_PP_SEQ_SIZE(seq)), BOOST_PP_SEQ_FOR_EACH_P, BOOST_PP_SEQ_FOR_EACH_O, BOOST_PP_SEQ_FOR_EACH_M) -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EMPTY_R(r, macro, data, seq) -# -# define BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_R(r, macro, data, seq) \ - BOOST_PP_IIF \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq), \ - BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EXEC_R, \ - BOOST_PP_SEQ_FOR_EACH_DETAIL_CHECK_EMPTY_R \ - ) \ - (r, macro, data, seq) \ -/**/ -# -# endif diff --git a/ThirdParty/boost/preprocessor/seq/for_each_i.hpp b/ThirdParty/boost/preprocessor/seq/for_each_i.hpp deleted file mode 100644 index d29d4c1a2d35b9c77f1bdbffd6e7f70ad785b591..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/seq/for_each_i.hpp +++ /dev/null @@ -1,109 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_SEQ_FOR_EACH_I_HPP -# define BOOST_PREPROCESSOR_SEQ_FOR_EACH_I_HPP -# -# include <boost/preprocessor/arithmetic/dec.hpp> -# include <boost/preprocessor/arithmetic/inc.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/control/if.hpp> -# include <boost/preprocessor/control/iif.hpp> -# include <boost/preprocessor/repetition/for.hpp> -# include <boost/preprocessor/seq/seq.hpp> -# include <boost/preprocessor/seq/size.hpp> -# include <boost/preprocessor/seq/detail/is_empty.hpp> -# include <boost/preprocessor/tuple/elem.hpp> -# include <boost/preprocessor/tuple/rem.hpp> -# -# /* BOOST_PP_SEQ_FOR_EACH_I */ -# -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_SEQ_FOR_EACH_I(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK(macro, data, seq) -# else -# define BOOST_PP_SEQ_FOR_EACH_I(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_I(macro, data, seq) -# define BOOST_PP_SEQ_FOR_EACH_I_I(macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK(macro, data, seq) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK_EXEC(macro, data, seq) BOOST_PP_FOR((macro, data, seq, 0, BOOST_PP_SEQ_SIZE(seq)), BOOST_PP_SEQ_FOR_EACH_I_P, BOOST_PP_SEQ_FOR_EACH_I_O, BOOST_PP_SEQ_FOR_EACH_I_M) -# define BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK_EMPTY(macro, data, seq) -# -# define BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK(macro, data, seq) \ - BOOST_PP_IIF \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq), \ - BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK_EXEC, \ - BOOST_PP_SEQ_FOR_EACH_I_DETAIL_CHECK_EMPTY \ - ) \ - (macro, data, seq) \ -/**/ -# -# define BOOST_PP_SEQ_FOR_EACH_I_P(r, x) BOOST_PP_TUPLE_ELEM(5, 4, x) -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_STRICT() -# define BOOST_PP_SEQ_FOR_EACH_I_O(r, x) BOOST_PP_SEQ_FOR_EACH_I_O_I x -# else -# define BOOST_PP_SEQ_FOR_EACH_I_O(r, x) BOOST_PP_SEQ_FOR_EACH_I_O_I(BOOST_PP_TUPLE_ELEM(5, 0, x), BOOST_PP_TUPLE_ELEM(5, 1, x), BOOST_PP_TUPLE_ELEM(5, 2, x), BOOST_PP_TUPLE_ELEM(5, 3, x), BOOST_PP_TUPLE_ELEM(5, 4, x)) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_I_O_I(macro, data, seq, i, sz) \ - BOOST_PP_SEQ_FOR_EACH_I_O_I_DEC(macro, data, seq, i, BOOST_PP_DEC(sz)) \ -/**/ -# define BOOST_PP_SEQ_FOR_EACH_I_O_I_DEC(macro, data, seq, i, sz) \ - ( \ - macro, \ - data, \ - BOOST_PP_IF \ - ( \ - sz, \ - BOOST_PP_SEQ_FOR_EACH_I_O_I_TAIL, \ - BOOST_PP_SEQ_FOR_EACH_I_O_I_NIL \ - ) \ - (seq), \ - BOOST_PP_INC(i), \ - sz \ - ) \ -/**/ -# define BOOST_PP_SEQ_FOR_EACH_I_O_I_TAIL(seq) BOOST_PP_SEQ_TAIL(seq) -# define BOOST_PP_SEQ_FOR_EACH_I_O_I_NIL(seq) BOOST_PP_NIL -# -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_STRICT() -# define BOOST_PP_SEQ_FOR_EACH_I_M(r, x) BOOST_PP_SEQ_FOR_EACH_I_M_IM(r, BOOST_PP_TUPLE_REM_5 x) -# define BOOST_PP_SEQ_FOR_EACH_I_M_IM(r, im) BOOST_PP_SEQ_FOR_EACH_I_M_I(r, im) -# else -# define BOOST_PP_SEQ_FOR_EACH_I_M(r, x) BOOST_PP_SEQ_FOR_EACH_I_M_I(r, BOOST_PP_TUPLE_ELEM(5, 0, x), BOOST_PP_TUPLE_ELEM(5, 1, x), BOOST_PP_TUPLE_ELEM(5, 2, x), BOOST_PP_TUPLE_ELEM(5, 3, x), BOOST_PP_TUPLE_ELEM(5, 4, x)) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_I_M_I(r, macro, data, seq, i, sz) macro(r, data, i, BOOST_PP_SEQ_HEAD(seq)) -# -# /* BOOST_PP_SEQ_FOR_EACH_I_R */ -# -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_SEQ_FOR_EACH_I_R(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK(r, macro, data, seq) -# else -# define BOOST_PP_SEQ_FOR_EACH_I_R(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_R_I(r, macro, data, seq) -# define BOOST_PP_SEQ_FOR_EACH_I_R_I(r, macro, data, seq) BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK(r, macro, data, seq) -# endif -# -# define BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK_EXEC(r, macro, data, seq) BOOST_PP_FOR_ ## r((macro, data, seq, 0, BOOST_PP_SEQ_SIZE(seq)), BOOST_PP_SEQ_FOR_EACH_I_P, BOOST_PP_SEQ_FOR_EACH_I_O, BOOST_PP_SEQ_FOR_EACH_I_M) -# define BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK_EMPTY(r, macro, data, seq) -# -# define BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK(r, macro, data, seq) \ - BOOST_PP_IIF \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY(seq), \ - BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK_EXEC, \ - BOOST_PP_SEQ_FOR_EACH_I_R_DETAIL_CHECK_EMPTY \ - ) \ - (r, macro, data, seq) \ -/**/ -# -# endif diff --git a/ThirdParty/boost/preprocessor/seq/rest_n.hpp b/ThirdParty/boost/preprocessor/seq/rest_n.hpp deleted file mode 100644 index cac52cff76af445db59d26ed2eaf2e344420bf02..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/seq/rest_n.hpp +++ /dev/null @@ -1,46 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002. -# * 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) -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_SEQ_REST_N_HPP -# define BOOST_PREPROCESSOR_SEQ_REST_N_HPP -# -# include <boost/preprocessor/arithmetic/inc.hpp> -# include <boost/preprocessor/comparison/not_equal.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/control/expr_iif.hpp> -# include <boost/preprocessor/facilities/identity.hpp> -# include <boost/preprocessor/logical/bitand.hpp> -# include <boost/preprocessor/seq/detail/is_empty.hpp> -# include <boost/preprocessor/seq/detail/split.hpp> -# include <boost/preprocessor/tuple/elem.hpp> -# -# /* BOOST_PP_SEQ_REST_N */ -# -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_SEQ_REST_N(n, seq) BOOST_PP_SEQ_REST_N_DETAIL_EXEC(n, seq, BOOST_PP_SEQ_DETAIL_EMPTY_SIZE(seq)) -# else -# define BOOST_PP_SEQ_REST_N(n, seq) BOOST_PP_SEQ_REST_N_I(n, seq) -# define BOOST_PP_SEQ_REST_N_I(n, seq) BOOST_PP_SEQ_REST_N_DETAIL_EXEC(n, seq, BOOST_PP_SEQ_DETAIL_EMPTY_SIZE(seq)) -# endif -# -# define BOOST_PP_SEQ_REST_N_DETAIL_EXEC(n, seq, size) \ - BOOST_PP_EXPR_IIF \ - ( \ - BOOST_PP_BITAND \ - ( \ - BOOST_PP_SEQ_DETAIL_IS_NOT_EMPTY_SIZE(size), \ - BOOST_PP_NOT_EQUAL(n,size) \ - ), \ - BOOST_PP_TUPLE_ELEM(2, 1, BOOST_PP_SEQ_SPLIT(BOOST_PP_INC(n), BOOST_PP_IDENTITY( (nil) seq )))() \ - ) \ -/**/ -# -# endif diff --git a/ThirdParty/boost/preprocessor/tuple/detail/is_single_return.hpp b/ThirdParty/boost/preprocessor/tuple/detail/is_single_return.hpp deleted file mode 100644 index bcdb5449b348385fd2536b139618d5d556f959b8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/tuple/detail/is_single_return.hpp +++ /dev/null @@ -1,28 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2014. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_TUPLE_DETAIL_IS_SINGLE_RETURN_HPP -# define BOOST_PREPROCESSOR_TUPLE_DETAIL_IS_SINGLE_RETURN_HPP -# -# include <boost/preprocessor/config/config.hpp> -# -# /* BOOST_PP_TUPLE_IS_SINGLE_RETURN */ -# -# if BOOST_PP_VARIADICS && BOOST_PP_VARIADICS_MSVC -# include <boost/preprocessor/control/iif.hpp> -# include <boost/preprocessor/facilities/is_1.hpp> -# include <boost/preprocessor/tuple/size.hpp> -# define BOOST_PP_TUPLE_IS_SINGLE_RETURN(sr,nsr,tuple) \ - BOOST_PP_IIF(BOOST_PP_IS_1(BOOST_PP_TUPLE_SIZE(tuple)),sr,nsr) \ - /**/ -# endif /* BOOST_PP_VARIADICS && BOOST_PP_VARIADICS_MSVC */ -# -# endif /* BOOST_PREPROCESSOR_TUPLE_DETAIL_IS_SINGLE_RETURN_HPP */ diff --git a/ThirdParty/boost/preprocessor/tuple/elem.hpp b/ThirdParty/boost/preprocessor/tuple/elem.hpp deleted file mode 100644 index 148e6bdcdb9a80f6a6ab88f39c78938e5e38bda3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/tuple/elem.hpp +++ /dev/null @@ -1,201 +0,0 @@ -# /* Copyright (C) 2001 -# * Housemarque Oy -# * http://www.housemarque.com -# * -# * 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) -# */ -# -# /* Revised by Paul Mensonides (2002-2011) */ -# /* Revised by Edward Diener (2011,2014) */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_TUPLE_ELEM_HPP -# define BOOST_PREPROCESSOR_TUPLE_ELEM_HPP -# -# include <boost/preprocessor/cat.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/facilities/expand.hpp> -# include <boost/preprocessor/facilities/overload.hpp> -# include <boost/preprocessor/tuple/rem.hpp> -# include <boost/preprocessor/variadic/elem.hpp> -# include <boost/preprocessor/tuple/detail/is_single_return.hpp> -# -# if BOOST_PP_VARIADICS -# if BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_TUPLE_ELEM(...) BOOST_PP_TUPLE_ELEM_I(BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_ELEM_O_, __VA_ARGS__), (__VA_ARGS__)) -# define BOOST_PP_TUPLE_ELEM_I(m, args) BOOST_PP_TUPLE_ELEM_II(m, args) -# define BOOST_PP_TUPLE_ELEM_II(m, args) BOOST_PP_CAT(m ## args,) -/* - Use BOOST_PP_REM_CAT if it is a single element tuple ( which might be empty ) - else use BOOST_PP_REM. This fixes a VC++ problem with an empty tuple and BOOST_PP_TUPLE_ELEM - functionality. See tuple_elem_bug_test.cxx. -*/ -# define BOOST_PP_TUPLE_ELEM_O_2(n, tuple) \ - BOOST_PP_VARIADIC_ELEM(n, BOOST_PP_EXPAND(BOOST_PP_TUPLE_IS_SINGLE_RETURN(BOOST_PP_REM_CAT,BOOST_PP_REM,tuple) tuple)) \ - /**/ -# else -# define BOOST_PP_TUPLE_ELEM(...) BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_ELEM_O_, __VA_ARGS__)(__VA_ARGS__) -# define BOOST_PP_TUPLE_ELEM_O_2(n, tuple) BOOST_PP_VARIADIC_ELEM(n, BOOST_PP_REM tuple) -# endif -# define BOOST_PP_TUPLE_ELEM_O_3(size, n, tuple) BOOST_PP_TUPLE_ELEM_O_2(n, tuple) -# else -# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC() -# define BOOST_PP_TUPLE_ELEM(size, n, tuple) BOOST_PP_TUPLE_ELEM_I(BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM_, n), BOOST_PP_CAT(BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM_E_, size), tuple)) -# define BOOST_PP_TUPLE_ELEM_I(m, args) BOOST_PP_TUPLE_ELEM_II(m, args) -# define BOOST_PP_TUPLE_ELEM_II(m, args) BOOST_PP_CAT(m ## args,) -# elif BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC() -# define BOOST_PP_TUPLE_ELEM(size, n, tuple) BOOST_PP_TUPLE_ELEM_I_OO((size, n, tuple)) -# define BOOST_PP_TUPLE_ELEM_I_OO(par) BOOST_PP_TUPLE_ELEM_I ## par -# define BOOST_PP_TUPLE_ELEM_I(size, n, tuple) BOOST_PP_TUPLE_ELEM_II((n, BOOST_PP_TUPLE_ELEM_E_ ## size ## tuple)) -# define BOOST_PP_TUPLE_ELEM_II(par) BOOST_PP_TUPLE_ELEM_III_OO(par) -# define BOOST_PP_TUPLE_ELEM_III_OO(par) BOOST_PP_TUPLE_ELEM_III ## par -# define BOOST_PP_TUPLE_ELEM_III(n, etuple) BOOST_PP_TUPLE_ELEM_ ## n ## etuple -# else -# define BOOST_PP_TUPLE_ELEM(size, n, tuple) BOOST_PP_TUPLE_ELEM_I(BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM_, n) BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM_E_, size) tuple) -# define BOOST_PP_TUPLE_ELEM_I(x) x -# endif -# define BOOST_PP_TUPLE_ELEM_E_1(e0) (e0, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_2(e0, e1) (e0, e1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_3(e0, e1, e2) (e0, e1, e2, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_4(e0, e1, e2, e3) (e0, e1, e2, e3, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_5(e0, e1, e2, e3, e4) (e0, e1, e2, e3, e4, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_6(e0, e1, e2, e3, e4, e5) (e0, e1, e2, e3, e4, e5, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_7(e0, e1, e2, e3, e4, e5, e6) (e0, e1, e2, e3, e4, e5, e6, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_8(e0, e1, e2, e3, e4, e5, e6, e7) (e0, e1, e2, e3, e4, e5, e6, e7, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_9(e0, e1, e2, e3, e4, e5, e6, e7, e8) (e0, e1, e2, e3, e4, e5, e6, e7, e8, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_10(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_11(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_12(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_13(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_14(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_15(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_16(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_17(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_18(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_19(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_20(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_21(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_22(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_23(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_24(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_25(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_26(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_27(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_28(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_29(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_30(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_31(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_32(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_33(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_34(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_35(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_36(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_37(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_38(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_39(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_40(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_41(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_42(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_43(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_44(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_45(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_46(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_47(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_48(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_49(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_50(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_51(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_52(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_53(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_54(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_55(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, ?, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_56(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, ?, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_57(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, ?, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_58(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, ?, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_59(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, ?, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_60(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, ?, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_61(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, ?, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_62(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, ?, ?) -# define BOOST_PP_TUPLE_ELEM_E_63(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62) (e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, ?) -# define BOOST_PP_TUPLE_ELEM_E_64 -# define BOOST_PP_TUPLE_ELEM_0(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e0 -# define BOOST_PP_TUPLE_ELEM_1(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e1 -# define BOOST_PP_TUPLE_ELEM_2(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e2 -# define BOOST_PP_TUPLE_ELEM_3(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e3 -# define BOOST_PP_TUPLE_ELEM_4(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e4 -# define BOOST_PP_TUPLE_ELEM_5(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e5 -# define BOOST_PP_TUPLE_ELEM_6(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e6 -# define BOOST_PP_TUPLE_ELEM_7(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e7 -# define BOOST_PP_TUPLE_ELEM_8(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e8 -# define BOOST_PP_TUPLE_ELEM_9(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e9 -# define BOOST_PP_TUPLE_ELEM_10(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e10 -# define BOOST_PP_TUPLE_ELEM_11(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e11 -# define BOOST_PP_TUPLE_ELEM_12(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e12 -# define BOOST_PP_TUPLE_ELEM_13(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e13 -# define BOOST_PP_TUPLE_ELEM_14(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e14 -# define BOOST_PP_TUPLE_ELEM_15(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e15 -# define BOOST_PP_TUPLE_ELEM_16(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e16 -# define BOOST_PP_TUPLE_ELEM_17(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e17 -# define BOOST_PP_TUPLE_ELEM_18(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e18 -# define BOOST_PP_TUPLE_ELEM_19(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e19 -# define BOOST_PP_TUPLE_ELEM_20(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e20 -# define BOOST_PP_TUPLE_ELEM_21(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e21 -# define BOOST_PP_TUPLE_ELEM_22(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e22 -# define BOOST_PP_TUPLE_ELEM_23(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e23 -# define BOOST_PP_TUPLE_ELEM_24(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e24 -# define BOOST_PP_TUPLE_ELEM_25(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e25 -# define BOOST_PP_TUPLE_ELEM_26(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e26 -# define BOOST_PP_TUPLE_ELEM_27(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e27 -# define BOOST_PP_TUPLE_ELEM_28(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e28 -# define BOOST_PP_TUPLE_ELEM_29(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e29 -# define BOOST_PP_TUPLE_ELEM_30(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e30 -# define BOOST_PP_TUPLE_ELEM_31(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e31 -# define BOOST_PP_TUPLE_ELEM_32(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e32 -# define BOOST_PP_TUPLE_ELEM_33(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e33 -# define BOOST_PP_TUPLE_ELEM_34(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e34 -# define BOOST_PP_TUPLE_ELEM_35(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e35 -# define BOOST_PP_TUPLE_ELEM_36(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e36 -# define BOOST_PP_TUPLE_ELEM_37(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e37 -# define BOOST_PP_TUPLE_ELEM_38(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e38 -# define BOOST_PP_TUPLE_ELEM_39(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e39 -# define BOOST_PP_TUPLE_ELEM_40(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e40 -# define BOOST_PP_TUPLE_ELEM_41(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e41 -# define BOOST_PP_TUPLE_ELEM_42(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e42 -# define BOOST_PP_TUPLE_ELEM_43(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e43 -# define BOOST_PP_TUPLE_ELEM_44(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e44 -# define BOOST_PP_TUPLE_ELEM_45(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e45 -# define BOOST_PP_TUPLE_ELEM_46(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e46 -# define BOOST_PP_TUPLE_ELEM_47(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e47 -# define BOOST_PP_TUPLE_ELEM_48(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e48 -# define BOOST_PP_TUPLE_ELEM_49(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e49 -# define BOOST_PP_TUPLE_ELEM_50(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e50 -# define BOOST_PP_TUPLE_ELEM_51(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e51 -# define BOOST_PP_TUPLE_ELEM_52(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e52 -# define BOOST_PP_TUPLE_ELEM_53(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e53 -# define BOOST_PP_TUPLE_ELEM_54(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e54 -# define BOOST_PP_TUPLE_ELEM_55(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e55 -# define BOOST_PP_TUPLE_ELEM_56(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e56 -# define BOOST_PP_TUPLE_ELEM_57(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e57 -# define BOOST_PP_TUPLE_ELEM_58(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e58 -# define BOOST_PP_TUPLE_ELEM_59(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e59 -# define BOOST_PP_TUPLE_ELEM_60(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e60 -# define BOOST_PP_TUPLE_ELEM_61(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e61 -# define BOOST_PP_TUPLE_ELEM_62(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e62 -# define BOOST_PP_TUPLE_ELEM_63(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e63 -# endif -# -# /* directly used elsewhere in Boost... */ -# -# define BOOST_PP_TUPLE_ELEM_1_0(a) a -# -# define BOOST_PP_TUPLE_ELEM_2_0(a, b) a -# define BOOST_PP_TUPLE_ELEM_2_1(a, b) b -# -# define BOOST_PP_TUPLE_ELEM_3_0(a, b, c) a -# define BOOST_PP_TUPLE_ELEM_3_1(a, b, c) b -# define BOOST_PP_TUPLE_ELEM_3_2(a, b, c) c -# -# endif diff --git a/ThirdParty/boost/preprocessor/tuple/rem.hpp b/ThirdParty/boost/preprocessor/tuple/rem.hpp deleted file mode 100644 index e99008dcdec029ac1ec5a6c20794d43a09e7bb37..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/tuple/rem.hpp +++ /dev/null @@ -1,149 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002-2011. * -# * (C) Copyright Edward Diener 2011,2013. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_TUPLE_REM_HPP -# define BOOST_PREPROCESSOR_TUPLE_REM_HPP -# -# include <boost/preprocessor/cat.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/facilities/expand.hpp> -# include <boost/preprocessor/facilities/overload.hpp> -# include <boost/preprocessor/tuple/detail/is_single_return.hpp> -# -# /* BOOST_PP_REM */ -# -# if BOOST_PP_VARIADICS -# if BOOST_PP_VARIADICS_MSVC - /* To be used internally when __VA_ARGS__ could be empty ( or is a single element ) */ -# define BOOST_PP_REM_CAT(...) BOOST_PP_CAT(__VA_ARGS__,) -# endif -# define BOOST_PP_REM(...) __VA_ARGS__ -# else -# define BOOST_PP_REM(x) x -# endif -# -# /* BOOST_PP_TUPLE_REM */ -# -/* - VC++8.0 cannot handle the variadic version of BOOST_PP_TUPLE_REM(size) -*/ -# if BOOST_PP_VARIADICS && !(BOOST_PP_VARIADICS_MSVC && _MSC_VER <= 1400) -# if BOOST_PP_VARIADICS_MSVC - /* To be used internally when the size could be 0 ( or 1 ) */ -# define BOOST_PP_TUPLE_REM_CAT(size) BOOST_PP_REM_CAT -# endif -# define BOOST_PP_TUPLE_REM(size) BOOST_PP_REM -# else -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC() -# define BOOST_PP_TUPLE_REM(size) BOOST_PP_TUPLE_REM_I(size) -# else -# define BOOST_PP_TUPLE_REM(size) BOOST_PP_TUPLE_REM_OO((size)) -# define BOOST_PP_TUPLE_REM_OO(par) BOOST_PP_TUPLE_REM_I ## par -# endif -# define BOOST_PP_TUPLE_REM_I(size) BOOST_PP_TUPLE_REM_ ## size -# endif -# define BOOST_PP_TUPLE_REM_0() -# define BOOST_PP_TUPLE_REM_1(e0) e0 -# define BOOST_PP_TUPLE_REM_2(e0, e1) e0, e1 -# define BOOST_PP_TUPLE_REM_3(e0, e1, e2) e0, e1, e2 -# define BOOST_PP_TUPLE_REM_4(e0, e1, e2, e3) e0, e1, e2, e3 -# define BOOST_PP_TUPLE_REM_5(e0, e1, e2, e3, e4) e0, e1, e2, e3, e4 -# define BOOST_PP_TUPLE_REM_6(e0, e1, e2, e3, e4, e5) e0, e1, e2, e3, e4, e5 -# define BOOST_PP_TUPLE_REM_7(e0, e1, e2, e3, e4, e5, e6) e0, e1, e2, e3, e4, e5, e6 -# define BOOST_PP_TUPLE_REM_8(e0, e1, e2, e3, e4, e5, e6, e7) e0, e1, e2, e3, e4, e5, e6, e7 -# define BOOST_PP_TUPLE_REM_9(e0, e1, e2, e3, e4, e5, e6, e7, e8) e0, e1, e2, e3, e4, e5, e6, e7, e8 -# define BOOST_PP_TUPLE_REM_10(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9 -# define BOOST_PP_TUPLE_REM_11(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10 -# define BOOST_PP_TUPLE_REM_12(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11 -# define BOOST_PP_TUPLE_REM_13(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12 -# define BOOST_PP_TUPLE_REM_14(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13 -# define BOOST_PP_TUPLE_REM_15(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14 -# define BOOST_PP_TUPLE_REM_16(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15 -# define BOOST_PP_TUPLE_REM_17(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16 -# define BOOST_PP_TUPLE_REM_18(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17 -# define BOOST_PP_TUPLE_REM_19(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18 -# define BOOST_PP_TUPLE_REM_20(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19 -# define BOOST_PP_TUPLE_REM_21(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20 -# define BOOST_PP_TUPLE_REM_22(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21 -# define BOOST_PP_TUPLE_REM_23(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22 -# define BOOST_PP_TUPLE_REM_24(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23 -# define BOOST_PP_TUPLE_REM_25(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24 -# define BOOST_PP_TUPLE_REM_26(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25 -# define BOOST_PP_TUPLE_REM_27(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26 -# define BOOST_PP_TUPLE_REM_28(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27 -# define BOOST_PP_TUPLE_REM_29(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28 -# define BOOST_PP_TUPLE_REM_30(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29 -# define BOOST_PP_TUPLE_REM_31(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30 -# define BOOST_PP_TUPLE_REM_32(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31 -# define BOOST_PP_TUPLE_REM_33(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32 -# define BOOST_PP_TUPLE_REM_34(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33 -# define BOOST_PP_TUPLE_REM_35(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34 -# define BOOST_PP_TUPLE_REM_36(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35 -# define BOOST_PP_TUPLE_REM_37(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36 -# define BOOST_PP_TUPLE_REM_38(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37 -# define BOOST_PP_TUPLE_REM_39(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38 -# define BOOST_PP_TUPLE_REM_40(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39 -# define BOOST_PP_TUPLE_REM_41(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40 -# define BOOST_PP_TUPLE_REM_42(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41 -# define BOOST_PP_TUPLE_REM_43(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42 -# define BOOST_PP_TUPLE_REM_44(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43 -# define BOOST_PP_TUPLE_REM_45(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44 -# define BOOST_PP_TUPLE_REM_46(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45 -# define BOOST_PP_TUPLE_REM_47(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46 -# define BOOST_PP_TUPLE_REM_48(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47 -# define BOOST_PP_TUPLE_REM_49(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48 -# define BOOST_PP_TUPLE_REM_50(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49 -# define BOOST_PP_TUPLE_REM_51(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50 -# define BOOST_PP_TUPLE_REM_52(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51 -# define BOOST_PP_TUPLE_REM_53(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52 -# define BOOST_PP_TUPLE_REM_54(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53 -# define BOOST_PP_TUPLE_REM_55(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54 -# define BOOST_PP_TUPLE_REM_56(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55 -# define BOOST_PP_TUPLE_REM_57(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56 -# define BOOST_PP_TUPLE_REM_58(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57 -# define BOOST_PP_TUPLE_REM_59(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58 -# define BOOST_PP_TUPLE_REM_60(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59 -# define BOOST_PP_TUPLE_REM_61(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60 -# define BOOST_PP_TUPLE_REM_62(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61 -# define BOOST_PP_TUPLE_REM_63(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62 -# define BOOST_PP_TUPLE_REM_64(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63 -# -# /* BOOST_PP_TUPLE_REM_CTOR */ -# -# if BOOST_PP_VARIADICS -# if BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_TUPLE_REM_CTOR(...) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_REM_CTOR_O_, __VA_ARGS__), (__VA_ARGS__)) -# define BOOST_PP_TUPLE_REM_CTOR_I(m, args) BOOST_PP_TUPLE_REM_CTOR_II(m, args) -# define BOOST_PP_TUPLE_REM_CTOR_II(m, args) BOOST_PP_CAT(m ## args,) -# define BOOST_PP_TUPLE_REM_CTOR_O_1(tuple) BOOST_PP_EXPAND(BOOST_PP_TUPLE_IS_SINGLE_RETURN(BOOST_PP_REM_CAT,BOOST_PP_REM,tuple) tuple) -# else -# define BOOST_PP_TUPLE_REM_CTOR(...) BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_REM_CTOR_O_, __VA_ARGS__)(__VA_ARGS__) -# define BOOST_PP_TUPLE_REM_CTOR_O_1(tuple) BOOST_PP_REM tuple -# endif -# define BOOST_PP_TUPLE_REM_CTOR_O_2(size, tuple) BOOST_PP_TUPLE_REM_CTOR_O_1(tuple) -# else -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG() -# define BOOST_PP_TUPLE_REM_CTOR(size, tuple) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_TUPLE_REM(size), tuple) -# else -# define BOOST_PP_TUPLE_REM_CTOR(size, tuple) BOOST_PP_TUPLE_REM_CTOR_D(size, tuple) -# define BOOST_PP_TUPLE_REM_CTOR_D(size, tuple) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_TUPLE_REM(size), tuple) -# endif -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC() -# define BOOST_PP_TUPLE_REM_CTOR_I(ext, tuple) ext tuple -# else -# define BOOST_PP_TUPLE_REM_CTOR_I(ext, tuple) BOOST_PP_TUPLE_REM_CTOR_OO((ext, tuple)) -# define BOOST_PP_TUPLE_REM_CTOR_OO(par) BOOST_PP_TUPLE_REM_CTOR_II ## par -# define BOOST_PP_TUPLE_REM_CTOR_II(ext, tuple) ext ## tuple -# endif -# endif -# -# endif diff --git a/ThirdParty/boost/preprocessor/tuple/to_list.hpp b/ThirdParty/boost/preprocessor/tuple/to_list.hpp deleted file mode 100644 index 25d9b095aeaaffba5a9355e2959683a3bd3f933b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/tuple/to_list.hpp +++ /dev/null @@ -1,118 +0,0 @@ -# /* Copyright (C) 2001 -# * Housemarque Oy -# * http://www.housemarque.com -# * -# * 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) -# */ -# -# /* Revised by Paul Mensonides (2002-2011) */ -# /* Revised by Edward Diener (2011) */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_TUPLE_TO_LIST_HPP -# define BOOST_PREPROCESSOR_TUPLE_TO_LIST_HPP -# -# include <boost/preprocessor/cat.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/facilities/overload.hpp> -# include <boost/preprocessor/tuple/size.hpp> -# include <boost/preprocessor/variadic/size.hpp> -# -# /* BOOST_PP_TUPLE_TO_LIST */ -# -# if BOOST_PP_VARIADICS -# if BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_TUPLE_TO_LIST(...) BOOST_PP_TUPLE_TO_LIST_I(BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_TO_LIST_O_, __VA_ARGS__), (__VA_ARGS__)) -# define BOOST_PP_TUPLE_TO_LIST_I(m, args) BOOST_PP_TUPLE_TO_LIST_II(m, args) -# define BOOST_PP_TUPLE_TO_LIST_II(m, args) BOOST_PP_CAT(m ## args,) -# define BOOST_PP_TUPLE_TO_LIST_O_1(tuple) BOOST_PP_CAT(BOOST_PP_TUPLE_TO_LIST_, BOOST_PP_TUPLE_SIZE(tuple)) tuple -# else -# define BOOST_PP_TUPLE_TO_LIST(...) BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_TO_LIST_O_, __VA_ARGS__)(__VA_ARGS__) -# define BOOST_PP_TUPLE_TO_LIST_O_1(tuple) BOOST_PP_CAT(BOOST_PP_TUPLE_TO_LIST_, BOOST_PP_VARIADIC_SIZE tuple) tuple -# endif -# define BOOST_PP_TUPLE_TO_LIST_O_2(size, tuple) BOOST_PP_TUPLE_TO_LIST_O_1(tuple) -# else -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC() -# define BOOST_PP_TUPLE_TO_LIST(size, tuple) BOOST_PP_TUPLE_TO_LIST_I(size, tuple) -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC() -# define BOOST_PP_TUPLE_TO_LIST_I(s, t) BOOST_PP_TUPLE_TO_LIST_ ## s t -# else -# define BOOST_PP_TUPLE_TO_LIST_I(s, t) BOOST_PP_TUPLE_TO_LIST_II(BOOST_PP_TUPLE_TO_LIST_ ## s t) -# define BOOST_PP_TUPLE_TO_LIST_II(res) res -# endif -# else -# define BOOST_PP_TUPLE_TO_LIST(size, tuple) BOOST_PP_TUPLE_TO_LIST_OO((size, tuple)) -# define BOOST_PP_TUPLE_TO_LIST_OO(par) BOOST_PP_TUPLE_TO_LIST_I ## par -# define BOOST_PP_TUPLE_TO_LIST_I(s, t) BOOST_PP_TUPLE_TO_LIST_ ## s ## t -# endif -# endif -# -# define BOOST_PP_TUPLE_TO_LIST_1(e0) (e0, BOOST_PP_NIL) -# define BOOST_PP_TUPLE_TO_LIST_2(e0, e1) (e0, (e1, BOOST_PP_NIL)) -# define BOOST_PP_TUPLE_TO_LIST_3(e0, e1, e2) (e0, (e1, (e2, BOOST_PP_NIL))) -# define BOOST_PP_TUPLE_TO_LIST_4(e0, e1, e2, e3) (e0, (e1, (e2, (e3, BOOST_PP_NIL)))) -# define BOOST_PP_TUPLE_TO_LIST_5(e0, e1, e2, e3, e4) (e0, (e1, (e2, (e3, (e4, BOOST_PP_NIL))))) -# define BOOST_PP_TUPLE_TO_LIST_6(e0, e1, e2, e3, e4, e5) (e0, (e1, (e2, (e3, (e4, (e5, BOOST_PP_NIL)))))) -# define BOOST_PP_TUPLE_TO_LIST_7(e0, e1, e2, e3, e4, e5, e6) (e0, (e1, (e2, (e3, (e4, (e5, (e6, BOOST_PP_NIL))))))) -# define BOOST_PP_TUPLE_TO_LIST_8(e0, e1, e2, e3, e4, e5, e6, e7) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, BOOST_PP_NIL)))))))) -# define BOOST_PP_TUPLE_TO_LIST_9(e0, e1, e2, e3, e4, e5, e6, e7, e8) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, BOOST_PP_NIL))))))))) -# define BOOST_PP_TUPLE_TO_LIST_10(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, BOOST_PP_NIL)))))))))) -# define BOOST_PP_TUPLE_TO_LIST_11(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, BOOST_PP_NIL))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_12(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, BOOST_PP_NIL)))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_13(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, BOOST_PP_NIL))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_14(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, BOOST_PP_NIL)))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_15(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, BOOST_PP_NIL))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_16(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, BOOST_PP_NIL)))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_17(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, BOOST_PP_NIL))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_18(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, BOOST_PP_NIL)))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_19(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, BOOST_PP_NIL))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_20(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, BOOST_PP_NIL)))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_21(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, BOOST_PP_NIL))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_22(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, BOOST_PP_NIL)))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_23(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, BOOST_PP_NIL))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_24(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, BOOST_PP_NIL)))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_25(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, BOOST_PP_NIL))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_26(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, BOOST_PP_NIL)))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_27(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, BOOST_PP_NIL))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_28(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, BOOST_PP_NIL)))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_29(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, BOOST_PP_NIL))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_30(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, BOOST_PP_NIL)))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_31(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, BOOST_PP_NIL))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_32(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, BOOST_PP_NIL)))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_33(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, BOOST_PP_NIL))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_34(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, BOOST_PP_NIL)))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_35(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, BOOST_PP_NIL))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_36(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_37(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_38(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_39(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_40(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_41(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_42(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_43(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_44(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_45(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_46(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_47(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_48(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_49(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_50(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_51(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_52(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_53(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_54(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_55(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_56(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_57(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_58(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_59(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_60(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, (e59, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_61(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, (e59, (e60, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_62(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, (e59, (e60, (e61, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_63(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, (e59, (e60, (e61, (e62, BOOST_PP_NIL))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# define BOOST_PP_TUPLE_TO_LIST_64(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) (e0, (e1, (e2, (e3, (e4, (e5, (e6, (e7, (e8, (e9, (e10, (e11, (e12, (e13, (e14, (e15, (e16, (e17, (e18, (e19, (e20, (e21, (e22, (e23, (e24, (e25, (e26, (e27, (e28, (e29, (e30, (e31, (e32, (e33, (e34, (e35, (e36, (e37, (e38, (e39, (e40, (e41, (e42, (e43, (e44, (e45, (e46, (e47, (e48, (e49, (e50, (e51, (e52, (e53, (e54, (e55, (e56, (e57, (e58, (e59, (e60, (e61, (e62, (e63, BOOST_PP_NIL)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -# -# endif diff --git a/ThirdParty/boost/preprocessor/tuple/to_seq.hpp b/ThirdParty/boost/preprocessor/tuple/to_seq.hpp deleted file mode 100644 index 028ee42127526697238163b9c76fd653057422c5..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/tuple/to_seq.hpp +++ /dev/null @@ -1,119 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Paul Mensonides 2002-2011. * -# * (C) Copyright Edward Diener 2011. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_TUPLE_TO_SEQ_HPP -# define BOOST_PREPROCESSOR_TUPLE_TO_SEQ_HPP -# -# include <boost/preprocessor/cat.hpp> -# include <boost/preprocessor/config/config.hpp> -# include <boost/preprocessor/facilities/overload.hpp> -# include <boost/preprocessor/tuple/size.hpp> -# include <boost/preprocessor/variadic/size.hpp> -# -# /* BOOST_PP_TUPLE_TO_SEQ */ -# -# if BOOST_PP_VARIADICS -# if BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_TUPLE_TO_SEQ(...) BOOST_PP_TUPLE_TO_SEQ_I(BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_TO_SEQ_O_, __VA_ARGS__), (__VA_ARGS__)) -# define BOOST_PP_TUPLE_TO_SEQ_I(m, args) BOOST_PP_TUPLE_TO_SEQ_II(m, args) -# define BOOST_PP_TUPLE_TO_SEQ_II(m, args) BOOST_PP_CAT(m ## args,) -# define BOOST_PP_TUPLE_TO_SEQ_O_1(tuple) BOOST_PP_CAT(BOOST_PP_TUPLE_TO_SEQ_, BOOST_PP_TUPLE_SIZE(tuple)) tuple -# else -# define BOOST_PP_TUPLE_TO_SEQ(...) BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_TO_SEQ_O_, __VA_ARGS__)(__VA_ARGS__) -# define BOOST_PP_TUPLE_TO_SEQ_O_1(tuple) BOOST_PP_CAT(BOOST_PP_TUPLE_TO_SEQ_, BOOST_PP_VARIADIC_SIZE tuple) tuple -# endif -# define BOOST_PP_TUPLE_TO_SEQ_O_2(size, tuple) BOOST_PP_TUPLE_TO_SEQ_O_1(tuple) -# else -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC() -# define BOOST_PP_TUPLE_TO_SEQ(size, tuple) BOOST_PP_TUPLE_TO_SEQ_I(size, tuple) -# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC() -# define BOOST_PP_TUPLE_TO_SEQ_I(s, t) BOOST_PP_TUPLE_TO_SEQ_ ## s t -# else -# define BOOST_PP_TUPLE_TO_SEQ_I(s, t) BOOST_PP_TUPLE_TO_SEQ_II(BOOST_PP_TUPLE_TO_SEQ_ ## s t) -# define BOOST_PP_TUPLE_TO_SEQ_II(res) res -# endif -# else -# define BOOST_PP_TUPLE_TO_SEQ(size, tuple) BOOST_PP_TUPLE_TO_SEQ_OO((size, tuple)) -# define BOOST_PP_TUPLE_TO_SEQ_OO(par) BOOST_PP_TUPLE_TO_SEQ_I ## par -# define BOOST_PP_TUPLE_TO_SEQ_I(s, t) BOOST_PP_TUPLE_TO_SEQ_ ## s ## t -# endif -# endif -# -/* An empty array can be passed */ -# define BOOST_PP_TUPLE_TO_SEQ_0() () -# -# define BOOST_PP_TUPLE_TO_SEQ_1(e0) (e0) -# define BOOST_PP_TUPLE_TO_SEQ_2(e0, e1) (e0)(e1) -# define BOOST_PP_TUPLE_TO_SEQ_3(e0, e1, e2) (e0)(e1)(e2) -# define BOOST_PP_TUPLE_TO_SEQ_4(e0, e1, e2, e3) (e0)(e1)(e2)(e3) -# define BOOST_PP_TUPLE_TO_SEQ_5(e0, e1, e2, e3, e4) (e0)(e1)(e2)(e3)(e4) -# define BOOST_PP_TUPLE_TO_SEQ_6(e0, e1, e2, e3, e4, e5) (e0)(e1)(e2)(e3)(e4)(e5) -# define BOOST_PP_TUPLE_TO_SEQ_7(e0, e1, e2, e3, e4, e5, e6) (e0)(e1)(e2)(e3)(e4)(e5)(e6) -# define BOOST_PP_TUPLE_TO_SEQ_8(e0, e1, e2, e3, e4, e5, e6, e7) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7) -# define BOOST_PP_TUPLE_TO_SEQ_9(e0, e1, e2, e3, e4, e5, e6, e7, e8) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8) -# define BOOST_PP_TUPLE_TO_SEQ_10(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9) -# define BOOST_PP_TUPLE_TO_SEQ_11(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10) -# define BOOST_PP_TUPLE_TO_SEQ_12(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11) -# define BOOST_PP_TUPLE_TO_SEQ_13(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12) -# define BOOST_PP_TUPLE_TO_SEQ_14(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13) -# define BOOST_PP_TUPLE_TO_SEQ_15(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14) -# define BOOST_PP_TUPLE_TO_SEQ_16(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15) -# define BOOST_PP_TUPLE_TO_SEQ_17(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16) -# define BOOST_PP_TUPLE_TO_SEQ_18(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17) -# define BOOST_PP_TUPLE_TO_SEQ_19(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18) -# define BOOST_PP_TUPLE_TO_SEQ_20(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19) -# define BOOST_PP_TUPLE_TO_SEQ_21(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20) -# define BOOST_PP_TUPLE_TO_SEQ_22(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21) -# define BOOST_PP_TUPLE_TO_SEQ_23(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22) -# define BOOST_PP_TUPLE_TO_SEQ_24(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23) -# define BOOST_PP_TUPLE_TO_SEQ_25(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24) -# define BOOST_PP_TUPLE_TO_SEQ_26(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25) -# define BOOST_PP_TUPLE_TO_SEQ_27(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26) -# define BOOST_PP_TUPLE_TO_SEQ_28(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27) -# define BOOST_PP_TUPLE_TO_SEQ_29(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28) -# define BOOST_PP_TUPLE_TO_SEQ_30(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29) -# define BOOST_PP_TUPLE_TO_SEQ_31(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30) -# define BOOST_PP_TUPLE_TO_SEQ_32(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31) -# define BOOST_PP_TUPLE_TO_SEQ_33(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32) -# define BOOST_PP_TUPLE_TO_SEQ_34(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33) -# define BOOST_PP_TUPLE_TO_SEQ_35(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34) -# define BOOST_PP_TUPLE_TO_SEQ_36(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35) -# define BOOST_PP_TUPLE_TO_SEQ_37(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36) -# define BOOST_PP_TUPLE_TO_SEQ_38(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37) -# define BOOST_PP_TUPLE_TO_SEQ_39(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38) -# define BOOST_PP_TUPLE_TO_SEQ_40(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39) -# define BOOST_PP_TUPLE_TO_SEQ_41(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40) -# define BOOST_PP_TUPLE_TO_SEQ_42(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41) -# define BOOST_PP_TUPLE_TO_SEQ_43(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42) -# define BOOST_PP_TUPLE_TO_SEQ_44(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43) -# define BOOST_PP_TUPLE_TO_SEQ_45(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44) -# define BOOST_PP_TUPLE_TO_SEQ_46(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45) -# define BOOST_PP_TUPLE_TO_SEQ_47(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46) -# define BOOST_PP_TUPLE_TO_SEQ_48(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47) -# define BOOST_PP_TUPLE_TO_SEQ_49(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48) -# define BOOST_PP_TUPLE_TO_SEQ_50(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49) -# define BOOST_PP_TUPLE_TO_SEQ_51(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50) -# define BOOST_PP_TUPLE_TO_SEQ_52(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51) -# define BOOST_PP_TUPLE_TO_SEQ_53(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52) -# define BOOST_PP_TUPLE_TO_SEQ_54(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53) -# define BOOST_PP_TUPLE_TO_SEQ_55(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54) -# define BOOST_PP_TUPLE_TO_SEQ_56(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55) -# define BOOST_PP_TUPLE_TO_SEQ_57(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56) -# define BOOST_PP_TUPLE_TO_SEQ_58(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57) -# define BOOST_PP_TUPLE_TO_SEQ_59(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58) -# define BOOST_PP_TUPLE_TO_SEQ_60(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58)(e59) -# define BOOST_PP_TUPLE_TO_SEQ_61(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58)(e59)(e60) -# define BOOST_PP_TUPLE_TO_SEQ_62(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58)(e59)(e60)(e61) -# define BOOST_PP_TUPLE_TO_SEQ_63(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58)(e59)(e60)(e61)(e62) -# define BOOST_PP_TUPLE_TO_SEQ_64(e0, e1, e2, e3, e4, e5, e6, e7, e8, e9, e10, e11, e12, e13, e14, e15, e16, e17, e18, e19, e20, e21, e22, e23, e24, e25, e26, e27, e28, e29, e30, e31, e32, e33, e34, e35, e36, e37, e38, e39, e40, e41, e42, e43, e44, e45, e46, e47, e48, e49, e50, e51, e52, e53, e54, e55, e56, e57, e58, e59, e60, e61, e62, e63) (e0)(e1)(e2)(e3)(e4)(e5)(e6)(e7)(e8)(e9)(e10)(e11)(e12)(e13)(e14)(e15)(e16)(e17)(e18)(e19)(e20)(e21)(e22)(e23)(e24)(e25)(e26)(e27)(e28)(e29)(e30)(e31)(e32)(e33)(e34)(e35)(e36)(e37)(e38)(e39)(e40)(e41)(e42)(e43)(e44)(e45)(e46)(e47)(e48)(e49)(e50)(e51)(e52)(e53)(e54)(e55)(e56)(e57)(e58)(e59)(e60)(e61)(e62)(e63) -# -# endif diff --git a/ThirdParty/boost/preprocessor/variadic/detail/has_opt.hpp b/ThirdParty/boost/preprocessor/variadic/detail/has_opt.hpp deleted file mode 100644 index 79edf3b2addcc75fa994186dc87f2f57903c73c7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/variadic/detail/has_opt.hpp +++ /dev/null @@ -1,39 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2019. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_VARIADIC_DETAIL_HAS_OPT_HPP -# define BOOST_PREPROCESSOR_VARIADIC_DETAIL_HAS_OPT_HPP -# -# include <boost/preprocessor/config/config.hpp> -# -# if BOOST_PP_VARIADICS && defined(__cplusplus) && __cplusplus > 201703L -# -# if BOOST_PP_VARIADICS_MSVC -# include <boost/preprocessor/cat.hpp> -# endif -# -# define BOOST_PP_VARIADIC_HAS_OPT_FUNCTION(...) \ - __VA_OPT__(,) , 1, 0 \ -/**/ -# -# if BOOST_PP_VARIADICS_MSVC -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM0(e0, ...) BOOST_PP_CAT(BOOST_PP_VARIADIC_HAS_OPT_ELEM_0(e0,__VA_ARGS__),) -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM2(e0, ...) BOOST_PP_CAT(BOOST_PP_VARIADIC_HAS_OPT_ELEM_2(e0,__VA_ARGS__),) -# else -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM0(e0, ...) BOOST_PP_VARIADIC_HAS_OPT_ELEM_0(e0,__VA_ARGS__) -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM2(e0, ...) BOOST_PP_VARIADIC_HAS_OPT_ELEM_2(e0,__VA_ARGS__) -# endif -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM_0(e0, ...) e0 -# define BOOST_PP_VARIADIC_HAS_OPT_ELEM_2(e0, e1, e2, ...) e2 -# -# endif -# -# endif diff --git a/ThirdParty/boost/preprocessor/variadic/has_opt.hpp b/ThirdParty/boost/preprocessor/variadic/has_opt.hpp deleted file mode 100644 index 3ab089019b647f5a5550cbc1267bdbb30e92d28e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/preprocessor/variadic/has_opt.hpp +++ /dev/null @@ -1,28 +0,0 @@ -# /* ************************************************************************** -# * * -# * (C) Copyright Edward Diener 2019. * -# * 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) * -# * * -# ************************************************************************** */ -# -# /* See http://www.boost.org for most recent version. */ -# -# ifndef BOOST_PREPROCESSOR_VARIADIC_HAS_OPT_HPP -# define BOOST_PREPROCESSOR_VARIADIC_HAS_OPT_HPP -# -# include <boost/preprocessor/config/config.hpp> -# -# /* BOOST_PP_VARIADIC_HAS_OPT */ -# -# if BOOST_PP_VARIADICS && defined(__cplusplus) && __cplusplus > 201703L -# include <boost/preprocessor/variadic/detail/has_opt.hpp> -# define BOOST_PP_VARIADIC_HAS_OPT() \ - BOOST_PP_VARIADIC_HAS_OPT_ELEM2(BOOST_PP_VARIADIC_HAS_OPT_FUNCTION(?),) \ -/**/ -# else -# define BOOST_PP_VARIADIC_HAS_OPT() 0 -# endif -# -# endif diff --git a/ThirdParty/boost/rational.hpp b/ThirdParty/boost/rational.hpp deleted file mode 100644 index f33bc3b1f89a70ba66a4a6f698c38c11a6c7bb97..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/rational.hpp +++ /dev/null @@ -1,1046 +0,0 @@ -// Boost rational.hpp header file ------------------------------------------// - -// (C) Copyright Paul Moore 1999. Permission to copy, use, modify, sell and -// distribute this software is granted provided this copyright notice appears -// in all copies. This software is provided "as is" without express or -// implied warranty, and with no claim as to its suitability for any purpose. - -// boostinspect:nolicense (don't complain about the lack of a Boost license) -// (Paul Moore hasn't been in contact for years, so there's no way to change the -// license.) - -// See http://www.boost.org/libs/rational for documentation. - -// Credits: -// Thanks to the boost mailing list in general for useful comments. -// Particular contributions included: -// Andrew D Jewell, for reminding me to take care to avoid overflow -// Ed Brey, for many comments, including picking up on some dreadful typos -// Stephen Silver contributed the test suite and comments on user-defined -// IntType -// Nickolay Mladenov, for the implementation of operator+= - -// Revision History -// 02 Sep 13 Remove unneeded forward declarations; tweak private helper -// function (Daryle Walker) -// 30 Aug 13 Improve exception safety of "assign"; start modernizing I/O code -// (Daryle Walker) -// 27 Aug 13 Add cross-version constructor template, plus some private helper -// functions; add constructor to exception class to take custom -// messages (Daryle Walker) -// 25 Aug 13 Add constexpr qualification wherever possible (Daryle Walker) -// 05 May 12 Reduced use of implicit gcd (Mario Lang) -// 05 Nov 06 Change rational_cast to not depend on division between different -// types (Daryle Walker) -// 04 Nov 06 Off-load GCD and LCM to Boost.Integer; add some invariant checks; -// add std::numeric_limits<> requirement to help GCD (Daryle Walker) -// 31 Oct 06 Recoded both operator< to use round-to-negative-infinity -// divisions; the rational-value version now uses continued fraction -// expansion to avoid overflows, for bug #798357 (Daryle Walker) -// 20 Oct 06 Fix operator bool_type for CW 8.3 (JoaquÃÂn M López Muñoz) -// 18 Oct 06 Use EXPLICIT_TEMPLATE_TYPE helper macros from Boost.Config -// (JoaquÃÂn M López Muñoz) -// 27 Dec 05 Add Boolean conversion operator (Daryle Walker) -// 28 Sep 02 Use _left versions of operators from operators.hpp -// 05 Jul 01 Recode gcd(), avoiding std::swap (Helmut Zeisel) -// 03 Mar 01 Workarounds for Intel C++ 5.0 (David Abrahams) -// 05 Feb 01 Update operator>> to tighten up input syntax -// 05 Feb 01 Final tidy up of gcd code prior to the new release -// 27 Jan 01 Recode abs() without relying on abs(IntType) -// 21 Jan 01 Include Nickolay Mladenov's operator+= algorithm, -// tidy up a number of areas, use newer features of operators.hpp -// (reduces space overhead to zero), add operator!, -// introduce explicit mixed-mode arithmetic operations -// 12 Jan 01 Include fixes to handle a user-defined IntType better -// 19 Nov 00 Throw on divide by zero in operator /= (John (EBo) David) -// 23 Jun 00 Incorporate changes from Mark Rodgers for Borland C++ -// 22 Jun 00 Change _MSC_VER to BOOST_MSVC so other compilers are not -// affected (Beman Dawes) -// 6 Mar 00 Fix operator-= normalization, #include <string> (Jens Maurer) -// 14 Dec 99 Modifications based on comments from the boost list -// 09 Dec 99 Initial Version (Paul Moore) - -#ifndef BOOST_RATIONAL_HPP -#define BOOST_RATIONAL_HPP - -#include <boost/config.hpp> // for BOOST_NO_STDC_NAMESPACE, BOOST_MSVC, etc -#ifndef BOOST_NO_IOSTREAM -#include <iomanip> // for std::setw -#include <ios> // for std::noskipws, streamsize -#include <istream> // for std::istream -#include <ostream> // for std::ostream -#include <sstream> // for std::ostringstream -#endif -#include <cstddef> // for NULL -#include <stdexcept> // for std::domain_error -#include <string> // for std::string implicit constructor -#include <boost/operators.hpp> // for boost::addable etc -#include <cstdlib> // for std::abs -#include <boost/call_traits.hpp> // for boost::call_traits -#include <boost/detail/workaround.hpp> // for BOOST_WORKAROUND -#include <boost/assert.hpp> // for BOOST_ASSERT -#include <boost/integer/common_factor_rt.hpp> // for boost::integer::gcd, lcm -#include <limits> // for std::numeric_limits -#include <boost/static_assert.hpp> // for BOOST_STATIC_ASSERT -#include <boost/throw_exception.hpp> -#include <boost/utility/enable_if.hpp> -#include <boost/type_traits/is_convertible.hpp> -#include <boost/type_traits/is_class.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/is_array.hpp> - -// Control whether depreciated GCD and LCM functions are included (default: yes) -#ifndef BOOST_CONTROL_RATIONAL_HAS_GCD -#define BOOST_CONTROL_RATIONAL_HAS_GCD 1 -#endif - -namespace boost { - -#if BOOST_CONTROL_RATIONAL_HAS_GCD -template <typename IntType> -IntType gcd(IntType n, IntType m) -{ - // Defer to the version in Boost.Integer - return integer::gcd( n, m ); -} - -template <typename IntType> -IntType lcm(IntType n, IntType m) -{ - // Defer to the version in Boost.Integer - return integer::lcm( n, m ); -} -#endif // BOOST_CONTROL_RATIONAL_HAS_GCD - -namespace rational_detail{ - - template <class FromInt, class ToInt, typename Enable = void> - struct is_compatible_integer; - - template <class FromInt, class ToInt> - struct is_compatible_integer<FromInt, ToInt, typename enable_if_c<!is_array<FromInt>::value>::type> - { - BOOST_STATIC_CONSTANT(bool, value = ((std::numeric_limits<FromInt>::is_specialized && std::numeric_limits<FromInt>::is_integer - && (std::numeric_limits<FromInt>::digits <= std::numeric_limits<ToInt>::digits) - && (std::numeric_limits<FromInt>::radix == std::numeric_limits<ToInt>::radix) - && ((std::numeric_limits<FromInt>::is_signed == false) || (std::numeric_limits<ToInt>::is_signed == true)) - && is_convertible<FromInt, ToInt>::value) - || is_same<FromInt, ToInt>::value) - || (is_class<ToInt>::value && is_class<FromInt>::value && is_convertible<FromInt, ToInt>::value)); - }; - - template <class FromInt, class ToInt> - struct is_compatible_integer<FromInt, ToInt, typename enable_if_c<is_array<FromInt>::value>::type> - { - BOOST_STATIC_CONSTANT(bool, value = false); - }; - - template <class FromInt, class ToInt, typename Enable = void> - struct is_backward_compatible_integer; - - template <class FromInt, class ToInt> - struct is_backward_compatible_integer<FromInt, ToInt, typename enable_if_c<!is_array<FromInt>::value>::type> - { - BOOST_STATIC_CONSTANT(bool, value = (std::numeric_limits<FromInt>::is_specialized && std::numeric_limits<FromInt>::is_integer - && !is_compatible_integer<FromInt, ToInt>::value - && (std::numeric_limits<FromInt>::radix == std::numeric_limits<ToInt>::radix) - && is_convertible<FromInt, ToInt>::value)); - }; - - template <class FromInt, class ToInt> - struct is_backward_compatible_integer<FromInt, ToInt, typename enable_if_c<is_array<FromInt>::value>::type> - { - BOOST_STATIC_CONSTANT(bool, value = false); - }; -} - -class bad_rational : public std::domain_error -{ -public: - explicit bad_rational() : std::domain_error("bad rational: zero denominator") {} - explicit bad_rational( char const *what ) : std::domain_error( what ) {} -}; - -template <typename IntType> -class rational -{ - // Class-wide pre-conditions - BOOST_STATIC_ASSERT( ::std::numeric_limits<IntType>::is_specialized ); - - // Helper types - typedef typename boost::call_traits<IntType>::param_type param_type; - - struct helper { IntType parts[2]; }; - typedef IntType (helper::* bool_type)[2]; - -public: - // Component type - typedef IntType int_type; - - BOOST_CONSTEXPR - rational() : num(0), den(1) {} - - template <class T>//, typename enable_if_c<!is_array<T>::value>::type> - BOOST_CONSTEXPR rational(const T& n, typename enable_if_c< - rational_detail::is_compatible_integer<T, IntType>::value - >::type const* = 0) : num(n), den(1) {} - - template <class T, class U> - BOOST_CXX14_CONSTEXPR rational(const T& n, const U& d, typename enable_if_c< - rational_detail::is_compatible_integer<T, IntType>::value && rational_detail::is_compatible_integer<U, IntType>::value - >::type const* = 0) : num(n), den(d) { - normalize(); - } - - template < typename NewType > - BOOST_CONSTEXPR explicit - rational(rational<NewType> const &r, typename enable_if_c<rational_detail::is_compatible_integer<NewType, IntType>::value>::type const* = 0) - : num(r.numerator()), den(is_normalized(int_type(r.numerator()), - int_type(r.denominator())) ? r.denominator() : - (BOOST_THROW_EXCEPTION(bad_rational("bad rational: denormalized conversion")), 0)){} - - template < typename NewType > - BOOST_CONSTEXPR explicit - rational(rational<NewType> const &r, typename disable_if_c<rational_detail::is_compatible_integer<NewType, IntType>::value>::type const* = 0) - : num(r.numerator()), den(is_normalized(int_type(r.numerator()), - int_type(r.denominator())) && is_safe_narrowing_conversion(r.denominator()) && is_safe_narrowing_conversion(r.numerator()) ? r.denominator() : - (BOOST_THROW_EXCEPTION(bad_rational("bad rational: denormalized conversion")), 0)){} - // Default copy constructor and assignment are fine - - // Add assignment from IntType - template <class T> - BOOST_CXX14_CONSTEXPR typename enable_if_c< - rational_detail::is_compatible_integer<T, IntType>::value, rational & - >::type operator=(const T& n) { return assign(static_cast<IntType>(n), static_cast<IntType>(1)); } - - // Assign in place - template <class T, class U> - BOOST_CXX14_CONSTEXPR typename enable_if_c< - rational_detail::is_compatible_integer<T, IntType>::value && rational_detail::is_compatible_integer<U, IntType>::value, rational & - >::type assign(const T& n, const U& d) - { - return *this = rational<IntType>(static_cast<IntType>(n), static_cast<IntType>(d)); - } - // - // The following overloads should probably *not* be provided - - // but are provided for backwards compatibity reasons only. - // These allow for construction/assignment from types that - // are wider than IntType only if there is an implicit - // conversion from T to IntType, they will throw a bad_rational - // if the conversion results in loss of precision or undefined behaviour. - // - template <class T>//, typename enable_if_c<!is_array<T>::value>::type> - BOOST_CXX14_CONSTEXPR rational(const T& n, typename enable_if_c< - rational_detail::is_backward_compatible_integer<T, IntType>::value - >::type const* = 0) - { - assign(n, static_cast<T>(1)); - } - template <class T, class U> - BOOST_CXX14_CONSTEXPR rational(const T& n, const U& d, typename enable_if_c< - (!rational_detail::is_compatible_integer<T, IntType>::value - || !rational_detail::is_compatible_integer<U, IntType>::value) - && std::numeric_limits<T>::is_specialized && std::numeric_limits<T>::is_integer - && (std::numeric_limits<T>::radix == std::numeric_limits<IntType>::radix) - && is_convertible<T, IntType>::value && - std::numeric_limits<U>::is_specialized && std::numeric_limits<U>::is_integer - && (std::numeric_limits<U>::radix == std::numeric_limits<IntType>::radix) - && is_convertible<U, IntType>::value - >::type const* = 0) - { - assign(n, d); - } - template <class T> - BOOST_CXX14_CONSTEXPR typename enable_if_c< - std::numeric_limits<T>::is_specialized && std::numeric_limits<T>::is_integer - && !rational_detail::is_compatible_integer<T, IntType>::value - && (std::numeric_limits<T>::radix == std::numeric_limits<IntType>::radix) - && is_convertible<T, IntType>::value, - rational & - >::type operator=(const T& n) { return assign(n, static_cast<T>(1)); } - - template <class T, class U> - BOOST_CXX14_CONSTEXPR typename enable_if_c< - (!rational_detail::is_compatible_integer<T, IntType>::value - || !rational_detail::is_compatible_integer<U, IntType>::value) - && std::numeric_limits<T>::is_specialized && std::numeric_limits<T>::is_integer - && (std::numeric_limits<T>::radix == std::numeric_limits<IntType>::radix) - && is_convertible<T, IntType>::value && - std::numeric_limits<U>::is_specialized && std::numeric_limits<U>::is_integer - && (std::numeric_limits<U>::radix == std::numeric_limits<IntType>::radix) - && is_convertible<U, IntType>::value, - rational & - >::type assign(const T& n, const U& d) - { - if(!is_safe_narrowing_conversion(n) || !is_safe_narrowing_conversion(d)) - BOOST_THROW_EXCEPTION(bad_rational()); - return *this = rational<IntType>(static_cast<IntType>(n), static_cast<IntType>(d)); - } - - // Access to representation - BOOST_CONSTEXPR - const IntType& numerator() const { return num; } - BOOST_CONSTEXPR - const IntType& denominator() const { return den; } - - // Arithmetic assignment operators - BOOST_CXX14_CONSTEXPR rational& operator+= (const rational& r); - BOOST_CXX14_CONSTEXPR rational& operator-= (const rational& r); - BOOST_CXX14_CONSTEXPR rational& operator*= (const rational& r); - BOOST_CXX14_CONSTEXPR rational& operator/= (const rational& r); - - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, rational&>::type operator+= (const T& i) - { - num += i * den; - return *this; - } - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, rational&>::type operator-= (const T& i) - { - num -= i * den; - return *this; - } - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, rational&>::type operator*= (const T& i) - { - // Avoid overflow and preserve normalization - IntType gcd = integer::gcd(static_cast<IntType>(i), den); - num *= i / gcd; - den /= gcd; - return *this; - } - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, rational&>::type operator/= (const T& i) - { - // Avoid repeated construction - IntType const zero(0); - - if(i == zero) BOOST_THROW_EXCEPTION(bad_rational()); - if(num == zero) return *this; - - // Avoid overflow and preserve normalization - IntType const gcd = integer::gcd(num, static_cast<IntType>(i)); - num /= gcd; - den *= i / gcd; - - if(den < zero) { - num = -num; - den = -den; - } - - return *this; - } - - // Increment and decrement - BOOST_CXX14_CONSTEXPR const rational& operator++() { num += den; return *this; } - BOOST_CXX14_CONSTEXPR const rational& operator--() { num -= den; return *this; } - - BOOST_CXX14_CONSTEXPR rational operator++(int) - { - rational t(*this); - ++(*this); - return t; - } - BOOST_CXX14_CONSTEXPR rational operator--(int) - { - rational t(*this); - --(*this); - return t; - } - - // Operator not - BOOST_CONSTEXPR - bool operator!() const { return !num; } - - // Boolean conversion - -#if BOOST_WORKAROUND(__MWERKS__,<=0x3003) - // The "ISO C++ Template Parser" option in CW 8.3 chokes on the - // following, hence we selectively disable that option for the - // offending memfun. -#pragma parse_mfunc_templ off -#endif - - BOOST_CONSTEXPR - operator bool_type() const { return operator !() ? 0 : &helper::parts; } - -#if BOOST_WORKAROUND(__MWERKS__,<=0x3003) -#pragma parse_mfunc_templ reset -#endif - - // Comparison operators - BOOST_CXX14_CONSTEXPR bool operator< (const rational& r) const; - BOOST_CXX14_CONSTEXPR bool operator> (const rational& r) const { return r < *this; } - BOOST_CONSTEXPR - bool operator== (const rational& r) const; - - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, bool>::type operator< (const T& i) const - { - // Avoid repeated construction - int_type const zero(0); - - // Break value into mixed-fraction form, w/ always-nonnegative remainder - BOOST_ASSERT(this->den > zero); - int_type q = this->num / this->den, r = this->num % this->den; - while(r < zero) { r += this->den; --q; } - - // Compare with just the quotient, since the remainder always bumps the - // value up. [Since q = floor(n/d), and if n/d < i then q < i, if n/d == i - // then q == i, if n/d == i + r/d then q == i, and if n/d >= i + 1 then - // q >= i + 1 > i; therefore n/d < i iff q < i.] - return q < i; - } - template <class T> - BOOST_CXX14_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, bool>::type operator>(const T& i) const - { - return operator==(i) ? false : !operator<(i); - } - template <class T> - BOOST_CONSTEXPR typename boost::enable_if_c<rational_detail::is_compatible_integer<T, IntType>::value, bool>::type operator== (const T& i) const - { - return ((den == IntType(1)) && (num == i)); - } - -private: - // Implementation - numerator and denominator (normalized). - // Other possibilities - separate whole-part, or sign, fields? - IntType num; - IntType den; - - // Helper functions - static BOOST_CONSTEXPR - int_type inner_gcd( param_type a, param_type b, int_type const &zero = - int_type(0) ) - { return b == zero ? a : inner_gcd(b, a % b, zero); } - - static BOOST_CONSTEXPR - int_type inner_abs( param_type x, int_type const &zero = int_type(0) ) - { return x < zero ? -x : +x; } - - // Representation note: Fractions are kept in normalized form at all - // times. normalized form is defined as gcd(num,den) == 1 and den > 0. - // In particular, note that the implementation of abs() below relies - // on den always being positive. - BOOST_CXX14_CONSTEXPR bool test_invariant() const; - BOOST_CXX14_CONSTEXPR void normalize(); - - static BOOST_CONSTEXPR - bool is_normalized( param_type n, param_type d, int_type const &zero = - int_type(0), int_type const &one = int_type(1) ) - { - return d > zero && ( n != zero || d == one ) && inner_abs( inner_gcd(n, - d, zero), zero ) == one; - } - // - // Conversion checks: - // - // (1) From an unsigned type with more digits than IntType: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits > std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == false), bool>::type is_safe_narrowing_conversion(const T& val) - { - return val < (T(1) << std::numeric_limits<IntType>::digits); - } - // - // (2) From a signed type with more digits than IntType, and IntType also signed: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits > std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == true) && (std::numeric_limits<IntType>::is_signed == true), bool>::type is_safe_narrowing_conversion(const T& val) - { - // Note that this check assumes IntType has a 2's complement representation, - // we don't want to try to convert a std::numeric_limits<IntType>::min() to - // a T because that conversion may not be allowed (this happens when IntType - // is from Boost.Multiprecision). - return (val < (T(1) << std::numeric_limits<IntType>::digits)) && (val >= -(T(1) << std::numeric_limits<IntType>::digits)); - } - // - // (3) From a signed type with more digits than IntType, and IntType unsigned: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits > std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == true) && (std::numeric_limits<IntType>::is_signed == false), bool>::type is_safe_narrowing_conversion(const T& val) - { - return (val < (T(1) << std::numeric_limits<IntType>::digits)) && (val >= 0); - } - // - // (4) From a signed type with fewer digits than IntType, and IntType unsigned: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits <= std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == true) && (std::numeric_limits<IntType>::is_signed == false), bool>::type is_safe_narrowing_conversion(const T& val) - { - return val >= 0; - } - // - // (5) From an unsigned type with fewer digits than IntType, and IntType signed: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits <= std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == false) && (std::numeric_limits<IntType>::is_signed == true), bool>::type is_safe_narrowing_conversion(const T&) - { - return true; - } - // - // (6) From an unsigned type with fewer digits than IntType, and IntType unsigned: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits <= std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == false) && (std::numeric_limits<IntType>::is_signed == false), bool>::type is_safe_narrowing_conversion(const T&) - { - return true; - } - // - // (7) From an signed type with fewer digits than IntType, and IntType signed: - // - template <class T> - BOOST_CONSTEXPR static typename boost::enable_if_c<(std::numeric_limits<T>::digits <= std::numeric_limits<IntType>::digits) && (std::numeric_limits<T>::is_signed == true) && (std::numeric_limits<IntType>::is_signed == true), bool>::type is_safe_narrowing_conversion(const T&) - { - return true; - } -}; - -// Unary plus and minus -template <typename IntType> -BOOST_CONSTEXPR -inline rational<IntType> operator+ (const rational<IntType>& r) -{ - return r; -} - -template <typename IntType> -BOOST_CXX14_CONSTEXPR -inline rational<IntType> operator- (const rational<IntType>& r) -{ - return rational<IntType>(static_cast<IntType>(-r.numerator()), r.denominator()); -} - -// Arithmetic assignment operators -template <typename IntType> -BOOST_CXX14_CONSTEXPR rational<IntType>& rational<IntType>::operator+= (const rational<IntType>& r) -{ - // This calculation avoids overflow, and minimises the number of expensive - // calculations. Thanks to Nickolay Mladenov for this algorithm. - // - // Proof: - // We have to compute a/b + c/d, where gcd(a,b)=1 and gcd(b,c)=1. - // Let g = gcd(b,d), and b = b1*g, d=d1*g. Then gcd(b1,d1)=1 - // - // The result is (a*d1 + c*b1) / (b1*d1*g). - // Now we have to normalize this ratio. - // Let's assume h | gcd((a*d1 + c*b1), (b1*d1*g)), and h > 1 - // If h | b1 then gcd(h,d1)=1 and hence h|(a*d1+c*b1) => h|a. - // But since gcd(a,b1)=1 we have h=1. - // Similarly h|d1 leads to h=1. - // So we have that h | gcd((a*d1 + c*b1) , (b1*d1*g)) => h|g - // Finally we have gcd((a*d1 + c*b1), (b1*d1*g)) = gcd((a*d1 + c*b1), g) - // Which proves that instead of normalizing the result, it is better to - // divide num and den by gcd((a*d1 + c*b1), g) - - // Protect against self-modification - IntType r_num = r.num; - IntType r_den = r.den; - - IntType g = integer::gcd(den, r_den); - den /= g; // = b1 from the calculations above - num = num * (r_den / g) + r_num * den; - g = integer::gcd(num, g); - num /= g; - den *= r_den/g; - - return *this; -} - -template <typename IntType> -BOOST_CXX14_CONSTEXPR rational<IntType>& rational<IntType>::operator-= (const rational<IntType>& r) -{ - // Protect against self-modification - IntType r_num = r.num; - IntType r_den = r.den; - - // This calculation avoids overflow, and minimises the number of expensive - // calculations. It corresponds exactly to the += case above - IntType g = integer::gcd(den, r_den); - den /= g; - num = num * (r_den / g) - r_num * den; - g = integer::gcd(num, g); - num /= g; - den *= r_den/g; - - return *this; -} - -template <typename IntType> -BOOST_CXX14_CONSTEXPR rational<IntType>& rational<IntType>::operator*= (const rational<IntType>& r) -{ - // Protect against self-modification - IntType r_num = r.num; - IntType r_den = r.den; - - // Avoid overflow and preserve normalization - IntType gcd1 = integer::gcd(num, r_den); - IntType gcd2 = integer::gcd(r_num, den); - num = (num/gcd1) * (r_num/gcd2); - den = (den/gcd2) * (r_den/gcd1); - return *this; -} - -template <typename IntType> -BOOST_CXX14_CONSTEXPR rational<IntType>& rational<IntType>::operator/= (const rational<IntType>& r) -{ - // Protect against self-modification - IntType r_num = r.num; - IntType r_den = r.den; - - // Avoid repeated construction - IntType zero(0); - - // Trap division by zero - if (r_num == zero) - BOOST_THROW_EXCEPTION(bad_rational()); - if (num == zero) - return *this; - - // Avoid overflow and preserve normalization - IntType gcd1 = integer::gcd(num, r_num); - IntType gcd2 = integer::gcd(r_den, den); - num = (num/gcd1) * (r_den/gcd2); - den = (den/gcd2) * (r_num/gcd1); - - if (den < zero) { - num = -num; - den = -den; - } - return *this; -} - - -// -// Non-member operators: previously these were provided by Boost.Operator, but these had a number of -// drawbacks, most notably, that in order to allow inter-operability with IntType code such as this: -// -// rational<int> r(3); -// assert(r == 3.5); // compiles and passes!! -// -// Happens to be allowed as well :-( -// -// There are three possible cases for each operator: -// 1) rational op rational. -// 2) rational op integer -// 3) integer op rational -// Cases (1) and (2) are folded into the one function. -// -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, rational<IntType> >::type - operator + (const rational<IntType>& a, const Arg& b) -{ - rational<IntType> t(a); - return t += b; -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, rational<IntType> >::type - operator + (const Arg& b, const rational<IntType>& a) -{ - rational<IntType> t(a); - return t += b; -} - -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, rational<IntType> >::type - operator - (const rational<IntType>& a, const Arg& b) -{ - rational<IntType> t(a); - return t -= b; -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, rational<IntType> >::type - operator - (const Arg& b, const rational<IntType>& a) -{ - rational<IntType> t(a); - return -(t -= b); -} - -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, rational<IntType> >::type - operator * (const rational<IntType>& a, const Arg& b) -{ - rational<IntType> t(a); - return t *= b; -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, rational<IntType> >::type - operator * (const Arg& b, const rational<IntType>& a) -{ - rational<IntType> t(a); - return t *= b; -} - -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, rational<IntType> >::type - operator / (const rational<IntType>& a, const Arg& b) -{ - rational<IntType> t(a); - return t /= b; -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, rational<IntType> >::type - operator / (const Arg& b, const rational<IntType>& a) -{ - rational<IntType> t(b); - return t /= a; -} - -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, bool>::type - operator <= (const rational<IntType>& a, const Arg& b) -{ - return !(a > b); -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator <= (const Arg& b, const rational<IntType>& a) -{ - return a >= b; -} - -template <class IntType, class Arg> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, bool>::type - operator >= (const rational<IntType>& a, const Arg& b) -{ - return !(a < b); -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator >= (const Arg& b, const rational<IntType>& a) -{ - return a <= b; -} - -template <class IntType, class Arg> -BOOST_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value || is_same<rational<IntType>, Arg>::value, bool>::type - operator != (const rational<IntType>& a, const Arg& b) -{ - return !(a == b); -} -template <class Arg, class IntType> -BOOST_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator != (const Arg& b, const rational<IntType>& a) -{ - return !(b == a); -} - -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator < (const Arg& b, const rational<IntType>& a) -{ - return a > b; -} -template <class Arg, class IntType> -BOOST_CXX14_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator > (const Arg& b, const rational<IntType>& a) -{ - return a < b; -} -template <class Arg, class IntType> -BOOST_CONSTEXPR -inline typename boost::enable_if_c < - rational_detail::is_compatible_integer<Arg, IntType>::value, bool>::type - operator == (const Arg& b, const rational<IntType>& a) -{ - return a == b; -} - -// Comparison operators -template <typename IntType> -BOOST_CXX14_CONSTEXPR -bool rational<IntType>::operator< (const rational<IntType>& r) const -{ - // Avoid repeated construction - int_type const zero( 0 ); - - // This should really be a class-wide invariant. The reason for these - // checks is that for 2's complement systems, INT_MIN has no corresponding - // positive, so negating it during normalization keeps it INT_MIN, which - // is bad for later calculations that assume a positive denominator. - BOOST_ASSERT( this->den > zero ); - BOOST_ASSERT( r.den > zero ); - - // Determine relative order by expanding each value to its simple continued - // fraction representation using the Euclidian GCD algorithm. - struct { int_type n, d, q, r; } - ts = { this->num, this->den, static_cast<int_type>(this->num / this->den), - static_cast<int_type>(this->num % this->den) }, - rs = { r.num, r.den, static_cast<int_type>(r.num / r.den), - static_cast<int_type>(r.num % r.den) }; - unsigned reverse = 0u; - - // Normalize negative moduli by repeatedly adding the (positive) denominator - // and decrementing the quotient. Later cycles should have all positive - // values, so this only has to be done for the first cycle. (The rules of - // C++ require a nonnegative quotient & remainder for a nonnegative dividend - // & positive divisor.) - while ( ts.r < zero ) { ts.r += ts.d; --ts.q; } - while ( rs.r < zero ) { rs.r += rs.d; --rs.q; } - - // Loop through and compare each variable's continued-fraction components - for ( ;; ) - { - // The quotients of the current cycle are the continued-fraction - // components. Comparing two c.f. is comparing their sequences, - // stopping at the first difference. - if ( ts.q != rs.q ) - { - // Since reciprocation changes the relative order of two variables, - // and c.f. use reciprocals, the less/greater-than test reverses - // after each index. (Start w/ non-reversed @ whole-number place.) - return reverse ? ts.q > rs.q : ts.q < rs.q; - } - - // Prepare the next cycle - reverse ^= 1u; - - if ( (ts.r == zero) || (rs.r == zero) ) - { - // At least one variable's c.f. expansion has ended - break; - } - - ts.n = ts.d; ts.d = ts.r; - ts.q = ts.n / ts.d; ts.r = ts.n % ts.d; - rs.n = rs.d; rs.d = rs.r; - rs.q = rs.n / rs.d; rs.r = rs.n % rs.d; - } - - // Compare infinity-valued components for otherwise equal sequences - if ( ts.r == rs.r ) - { - // Both remainders are zero, so the next (and subsequent) c.f. - // components for both sequences are infinity. Therefore, the sequences - // and their corresponding values are equal. - return false; - } - else - { -#ifdef BOOST_MSVC -#pragma warning(push) -#pragma warning(disable:4800) -#endif - // Exactly one of the remainders is zero, so all following c.f. - // components of that variable are infinity, while the other variable - // has a finite next c.f. component. So that other variable has the - // lesser value (modulo the reversal flag!). - return ( ts.r != zero ) != static_cast<bool>( reverse ); -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - } -} - -template <typename IntType> -BOOST_CONSTEXPR -inline bool rational<IntType>::operator== (const rational<IntType>& r) const -{ - return ((num == r.num) && (den == r.den)); -} - -// Invariant check -template <typename IntType> -BOOST_CXX14_CONSTEXPR -inline bool rational<IntType>::test_invariant() const -{ - return ( this->den > int_type(0) ) && ( integer::gcd(this->num, this->den) == - int_type(1) ); -} - -// Normalisation -template <typename IntType> -BOOST_CXX14_CONSTEXPR void rational<IntType>::normalize() -{ - // Avoid repeated construction - IntType zero(0); - - if (den == zero) - BOOST_THROW_EXCEPTION(bad_rational()); - - // Handle the case of zero separately, to avoid division by zero - if (num == zero) { - den = IntType(1); - return; - } - - IntType g = integer::gcd(num, den); - - num /= g; - den /= g; - - if (den < -(std::numeric_limits<IntType>::max)()) { - BOOST_THROW_EXCEPTION(bad_rational("bad rational: non-zero singular denominator")); - } - - // Ensure that the denominator is positive - if (den < zero) { - num = -num; - den = -den; - } - - BOOST_ASSERT( this->test_invariant() ); -} - -#ifndef BOOST_NO_IOSTREAM -namespace detail { - - // A utility class to reset the format flags for an istream at end - // of scope, even in case of exceptions - struct resetter { - resetter(std::istream& is) : is_(is), f_(is.flags()) {} - ~resetter() { is_.flags(f_); } - std::istream& is_; - std::istream::fmtflags f_; // old GNU c++ lib has no ios_base - }; - -} - -// Input and output -template <typename IntType> -std::istream& operator>> (std::istream& is, rational<IntType>& r) -{ - using std::ios; - - IntType n = IntType(0), d = IntType(1); - char c = 0; - detail::resetter sentry(is); - - if ( is >> n ) - { - if ( is.get(c) ) - { - if ( c == '/' ) - { - if ( is >> std::noskipws >> d ) - try { - r.assign( n, d ); - } catch ( bad_rational & ) { // normalization fail - try { is.setstate(ios::failbit); } - catch ( ... ) {} // don't throw ios_base::failure... - if ( is.exceptions() & ios::failbit ) - throw; // ...but the original exception instead - // ELSE: suppress the exception, use just error flags - } - } - else - is.setstate( ios::failbit ); - } - } - - return is; -} - -// Add manipulators for output format? -template <typename IntType> -std::ostream& operator<< (std::ostream& os, const rational<IntType>& r) -{ - // The slash directly precedes the denominator, which has no prefixes. - std::ostringstream ss; - - ss.copyfmt( os ); - ss.tie( NULL ); - ss.exceptions( std::ios::goodbit ); - ss.width( 0 ); - ss << std::noshowpos << std::noshowbase << '/' << r.denominator(); - - // The numerator holds the showpos, internal, and showbase flags. - std::string const tail = ss.str(); - std::streamsize const w = - os.width() - static_cast<std::streamsize>( tail.size() ); - - ss.clear(); - ss.str( "" ); - ss.flags( os.flags() ); - ss << std::setw( w < 0 || (os.flags() & std::ios::adjustfield) != - std::ios::internal ? 0 : w ) << r.numerator(); - return os << ss.str() + tail; -} -#endif // BOOST_NO_IOSTREAM - -// Type conversion -template <typename T, typename IntType> -BOOST_CONSTEXPR -inline T rational_cast(const rational<IntType>& src) -{ - return static_cast<T>(src.numerator())/static_cast<T>(src.denominator()); -} - -// Do not use any abs() defined on IntType - it isn't worth it, given the -// difficulties involved (Koenig lookup required, there may not *be* an abs() -// defined, etc etc). -template <typename IntType> -BOOST_CXX14_CONSTEXPR -inline rational<IntType> abs(const rational<IntType>& r) -{ - return r.numerator() >= IntType(0)? r: -r; -} - -namespace integer { - -template <typename IntType> -struct gcd_evaluator< rational<IntType> > -{ - typedef rational<IntType> result_type, - first_argument_type, second_argument_type; - result_type operator() ( first_argument_type const &a - , second_argument_type const &b - ) const - { - return result_type(integer::gcd(a.numerator(), b.numerator()), - integer::lcm(a.denominator(), b.denominator())); - } -}; - -template <typename IntType> -struct lcm_evaluator< rational<IntType> > -{ - typedef rational<IntType> result_type, - first_argument_type, second_argument_type; - result_type operator() ( first_argument_type const &a - , second_argument_type const &b - ) const - { - return result_type(integer::lcm(a.numerator(), b.numerator()), - integer::gcd(a.denominator(), b.denominator())); - } -}; - -} // namespace integer - -} // namespace boost - -#endif // BOOST_RATIONAL_HPP diff --git a/ThirdParty/boost/shared_container_iterator.hpp b/ThirdParty/boost/shared_container_iterator.hpp deleted file mode 100644 index 8adcaf7ec62823c16fd377bd0e17e89069ff1ff9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/shared_container_iterator.hpp +++ /dev/null @@ -1,69 +0,0 @@ -// (C) Copyright Ronald Garcia 2002. Permission to copy, use, modify, sell and -// distribute this software is granted provided this copyright notice appears -// in all copies. This software is provided "as is" without express or implied -// warranty, and with no claim as to its suitability for any purpose. - -// See http://www.boost.org/libs/utility/shared_container_iterator.html for documentation. - -#ifndef BOOST_SHARED_CONTAINER_ITERATOR_HPP -#define BOOST_SHARED_CONTAINER_ITERATOR_HPP - -#include "boost/iterator_adaptors.hpp" -#include "boost/shared_ptr.hpp" -#include <utility> - -namespace boost { -namespace iterators { - -template <typename Container> -class shared_container_iterator : public iterator_adaptor< - shared_container_iterator<Container>, - typename Container::iterator> { - - typedef iterator_adaptor< - shared_container_iterator<Container>, - typename Container::iterator> super_t; - - typedef typename Container::iterator iterator_t; - typedef boost::shared_ptr<Container> container_ref_t; - - container_ref_t container_ref; -public: - shared_container_iterator() { } - - shared_container_iterator(iterator_t const& x,container_ref_t const& c) : - super_t(x), container_ref(c) { } - - -}; - -template <typename Container> -inline shared_container_iterator<Container> -make_shared_container_iterator(typename Container::iterator iter, - boost::shared_ptr<Container> const& container) { - typedef shared_container_iterator<Container> iterator; - return iterator(iter,container); -} - - - -template <typename Container> -inline std::pair< - shared_container_iterator<Container>, - shared_container_iterator<Container> > -make_shared_container_range(boost::shared_ptr<Container> const& container) { - return - std::make_pair( - make_shared_container_iterator(container->begin(),container), - make_shared_container_iterator(container->end(),container)); -} - -} // namespace iterators - -using iterators::shared_container_iterator; -using iterators::make_shared_container_iterator; -using iterators::make_shared_container_range; - -} // namespace boost - -#endif diff --git a/ThirdParty/boost/smart_ptr/allocate_shared_array.hpp b/ThirdParty/boost/smart_ptr/allocate_shared_array.hpp deleted file mode 100644 index bca98650d77f0755656fe5d73c79c9a2f154a130..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/allocate_shared_array.hpp +++ /dev/null @@ -1,362 +0,0 @@ -/* -Copyright 2012-2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_SMART_PTR_ALLOCATE_SHARED_ARRAY_HPP -#define BOOST_SMART_PTR_ALLOCATE_SHARED_ARRAY_HPP - -#include <boost/core/alloc_construct.hpp> -#include <boost/core/first_scalar.hpp> -#include <boost/smart_ptr/shared_ptr.hpp> -#include <boost/type_traits/alignment_of.hpp> -#include <boost/type_traits/enable_if.hpp> -#include <boost/type_traits/extent.hpp> -#include <boost/type_traits/is_bounded_array.hpp> -#include <boost/type_traits/is_unbounded_array.hpp> -#include <boost/type_traits/remove_cv.hpp> -#include <boost/type_traits/remove_extent.hpp> -#include <boost/type_traits/type_with_alignment.hpp> - -namespace boost { -namespace detail { - -template<class T> -struct sp_array_element { - typedef typename boost::remove_cv<typename - boost::remove_extent<T>::type>::type type; -}; - -template<class T> -struct sp_array_count { - enum { - value = 1 - }; -}; - -template<class T, std::size_t N> -struct sp_array_count<T[N]> { - enum { - value = N * sp_array_count<T>::value - }; -}; - -template<std::size_t N, std::size_t M> -struct sp_max_size { - enum { - value = N < M ? M : N - }; -}; - -template<std::size_t N, std::size_t M> -struct sp_align_up { - enum { - value = (N + M - 1) & ~(M - 1) - }; -}; - -#if !defined(BOOST_NO_CXX11_ALLOCATOR) -template<class A, class T> -struct sp_bind_allocator { - typedef typename std::allocator_traits<A>::template rebind_alloc<T> type; -}; -#else -template<class A, class T> -struct sp_bind_allocator { - typedef typename A::template rebind<T>::other type; -}; -#endif - -template<class T> -BOOST_CONSTEXPR inline std::size_t -sp_objects(std::size_t size) BOOST_SP_NOEXCEPT -{ - return (size + sizeof(T) - 1) / sizeof(T); -} - -template<class A> -class sp_array_state { -public: - typedef A type; - - template<class U> - sp_array_state(const U& _allocator, std::size_t _size) BOOST_SP_NOEXCEPT - : allocator_(_allocator), - size_(_size) { } - - A& allocator() BOOST_SP_NOEXCEPT { - return allocator_; - } - - std::size_t size() const BOOST_SP_NOEXCEPT { - return size_; - } - -private: - A allocator_; - std::size_t size_; -}; - -template<class A, std::size_t N> -class sp_size_array_state { -public: - typedef A type; - - template<class U> - sp_size_array_state(const U& _allocator, std::size_t) BOOST_SP_NOEXCEPT - : allocator_(_allocator) { } - - A& allocator() BOOST_SP_NOEXCEPT { - return allocator_; - } - - BOOST_CONSTEXPR std::size_t size() const BOOST_SP_NOEXCEPT { - return N; - } - -private: - A allocator_; -}; - -template<class T, class U> -struct sp_array_alignment { - enum { - value = sp_max_size<boost::alignment_of<T>::value, - boost::alignment_of<U>::value>::value - }; -}; - -template<class T, class U> -struct sp_array_offset { - enum { - value = sp_align_up<sizeof(T), sp_array_alignment<T, U>::value>::value - }; -}; - -template<class U, class T> -inline U* -sp_array_start(T* base) BOOST_SP_NOEXCEPT -{ - enum { - size = sp_array_offset<T, U>::value - }; - return reinterpret_cast<U*>(reinterpret_cast<char*>(base) + size); -} - -template<class A, class T> -class sp_array_creator { - typedef typename A::value_type element; - - enum { - offset = sp_array_offset<T, element>::value - }; - - typedef typename boost::type_with_alignment<sp_array_alignment<T, - element>::value>::type type; - -public: - template<class U> - sp_array_creator(const U& other, std::size_t size) BOOST_SP_NOEXCEPT - : other_(other), - size_(sp_objects<type>(offset + sizeof(element) * size)) { } - - T* create() { - return reinterpret_cast<T*>(other_.allocate(size_)); - } - - void destroy(T* base) { - other_.deallocate(reinterpret_cast<type*>(base), size_); - } - -private: - typename sp_bind_allocator<A, type>::type other_; - std::size_t size_; -}; - -template<class T> -class BOOST_SYMBOL_VISIBLE sp_array_base - : public sp_counted_base { - typedef typename T::type allocator; - -public: - typedef typename allocator::value_type type; - - template<class A> - sp_array_base(const A& other, type* start, std::size_t size) - : state_(other, size) { - boost::alloc_construct_n(state_.allocator(), - boost::first_scalar(start), - state_.size() * sp_array_count<type>::value); - } - - template<class A, class U> - sp_array_base(const A& other, type* start, std::size_t size, const U& list) - : state_(other, size) { - enum { - count = sp_array_count<type>::value - }; - boost::alloc_construct_n(state_.allocator(), - boost::first_scalar(start), state_.size() * count, - boost::first_scalar(&list), count); - } - - T& state() BOOST_SP_NOEXCEPT { - return state_; - } - - virtual void dispose() BOOST_SP_NOEXCEPT { - boost::alloc_destroy_n(state_.allocator(), - boost::first_scalar(sp_array_start<type>(this)), - state_.size() * sp_array_count<type>::value); - } - - virtual void destroy() BOOST_SP_NOEXCEPT { - sp_array_creator<allocator, sp_array_base> other(state_.allocator(), - state_.size()); - this->~sp_array_base(); - other.destroy(this); - } - - virtual void* get_deleter(const sp_typeinfo_&) BOOST_SP_NOEXCEPT { - return 0; - } - - virtual void* get_local_deleter(const sp_typeinfo_&) BOOST_SP_NOEXCEPT { - return 0; - } - - virtual void* get_untyped_deleter() BOOST_SP_NOEXCEPT { - return 0; - } - -private: - T state_; -}; - -template<class A, class T> -struct sp_array_result { -public: - template<class U> - sp_array_result(const U& other, std::size_t size) - : creator_(other, size), - result_(creator_.create()) { } - - ~sp_array_result() { - if (result_) { - creator_.destroy(result_); - } - } - - T* get() const BOOST_SP_NOEXCEPT { - return result_; - } - - void release() BOOST_SP_NOEXCEPT { - result_ = 0; - } - -private: - sp_array_result(const sp_array_result&); - sp_array_result& operator=(const sp_array_result&); - - sp_array_creator<A, T> creator_; - T* result_; -}; - -} /* detail */ - -template<class T, class A> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -allocate_shared(const A& allocator, std::size_t count) -{ - typedef typename detail::sp_array_element<T>::type element; - typedef typename detail::sp_bind_allocator<A, element>::type other; - typedef detail::sp_array_state<other> state; - typedef detail::sp_array_base<state> base; - detail::sp_array_result<other, base> result(allocator, count); - base* node = result.get(); - element* start = detail::sp_array_start<element>(node); - ::new(static_cast<void*>(node)) base(allocator, start, count); - result.release(); - return shared_ptr<T>(detail::sp_internal_constructor_tag(), start, - detail::shared_count(static_cast<detail::sp_counted_base*>(node))); -} - -template<class T, class A> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -allocate_shared(const A& allocator) -{ - enum { - count = extent<T>::value - }; - typedef typename detail::sp_array_element<T>::type element; - typedef typename detail::sp_bind_allocator<A, element>::type other; - typedef detail::sp_size_array_state<other, extent<T>::value> state; - typedef detail::sp_array_base<state> base; - detail::sp_array_result<other, base> result(allocator, count); - base* node = result.get(); - element* start = detail::sp_array_start<element>(node); - ::new(static_cast<void*>(node)) base(allocator, start, count); - result.release(); - return shared_ptr<T>(detail::sp_internal_constructor_tag(), start, - detail::shared_count(static_cast<detail::sp_counted_base*>(node))); -} - -template<class T, class A> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -allocate_shared(const A& allocator, std::size_t count, - const typename remove_extent<T>::type& value) -{ - typedef typename detail::sp_array_element<T>::type element; - typedef typename detail::sp_bind_allocator<A, element>::type other; - typedef detail::sp_array_state<other> state; - typedef detail::sp_array_base<state> base; - detail::sp_array_result<other, base> result(allocator, count); - base* node = result.get(); - element* start = detail::sp_array_start<element>(node); - ::new(static_cast<void*>(node)) base(allocator, start, count, value); - result.release(); - return shared_ptr<T>(detail::sp_internal_constructor_tag(), start, - detail::shared_count(static_cast<detail::sp_counted_base*>(node))); -} - -template<class T, class A> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -allocate_shared(const A& allocator, - const typename remove_extent<T>::type& value) -{ - enum { - count = extent<T>::value - }; - typedef typename detail::sp_array_element<T>::type element; - typedef typename detail::sp_bind_allocator<A, element>::type other; - typedef detail::sp_size_array_state<other, extent<T>::value> state; - typedef detail::sp_array_base<state> base; - detail::sp_array_result<other, base> result(allocator, count); - base* node = result.get(); - element* start = detail::sp_array_start<element>(node); - ::new(static_cast<void*>(node)) base(allocator, start, count, value); - result.release(); - return shared_ptr<T>(detail::sp_internal_constructor_tag(), start, - detail::shared_count(static_cast<detail::sp_counted_base*>(node))); -} - -template<class T, class A> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -allocate_shared_noinit(const A& allocator, std::size_t count) -{ - return boost::allocate_shared<T>(boost::noinit_adapt(allocator), count); -} - -template<class T, class A> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -allocate_shared_noinit(const A& allocator) -{ - return boost::allocate_shared<T>(boost::noinit_adapt(allocator)); -} - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/smart_ptr/detail/atomic_count_std_atomic.hpp b/ThirdParty/boost/smart_ptr/detail/atomic_count_std_atomic.hpp deleted file mode 100644 index 3d5fb78fcb997d757cdd79dfb10b31b752705d11..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/atomic_count_std_atomic.hpp +++ /dev/null @@ -1,60 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_ATOMIC_COUNT_STD_ATOMIC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_ATOMIC_COUNT_STD_ATOMIC_HPP_INCLUDED - -// -// boost/detail/atomic_count_std_atomic.hpp -// -// atomic_count for std::atomic -// -// Copyright 2013 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 <atomic> -#include <cstdint> - -namespace boost -{ - -namespace detail -{ - -class atomic_count -{ -public: - - explicit atomic_count( long v ): value_( static_cast< std::int_least32_t >( v ) ) - { - } - - long operator++() - { - return value_.fetch_add( 1, std::memory_order_acq_rel ) + 1; - } - - long operator--() - { - return value_.fetch_sub( 1, std::memory_order_acq_rel ) - 1; - } - - operator long() const - { - return value_.load( std::memory_order_acquire ); - } - -private: - - atomic_count(atomic_count const &); - atomic_count & operator=(atomic_count const &); - - std::atomic_int_least32_t value_; -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_ATOMIC_COUNT_STD_ATOMIC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/lightweight_mutex.hpp b/ThirdParty/boost/smart_ptr/detail/lightweight_mutex.hpp deleted file mode 100644 index 7b098c4d9d3681d643d162cd116f462638e58367..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/lightweight_mutex.hpp +++ /dev/null @@ -1,39 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/detail/lightweight_mutex.hpp - lightweight mutex -// -// Copyright (c) 2002, 2003 Peter Dimov and Multi Media Ltd. -// -// 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) -// -// typedef <unspecified> boost::detail::lightweight_mutex; -// -// boost::detail::lightweight_mutex is a header-only implementation of -// a subset of the Mutex concept requirements: -// -// http://www.boost.org/doc/html/threads/concepts.html#threads.concepts.Mutex -// -// It maps to a CRITICAL_SECTION on Windows or a pthread_mutex on POSIX. -// - -#include <boost/config.hpp> - -#if !defined(BOOST_NO_CXX11_HDR_MUTEX ) -# include <boost/smart_ptr/detail/lwm_std_mutex.hpp> -#elif defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__) -# include <boost/smart_ptr/detail/lwm_win32_cs.hpp> -#else -# include <boost/smart_ptr/detail/lwm_pthreads.hpp> -#endif - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/lwm_std_mutex.hpp b/ThirdParty/boost/smart_ptr/detail/lwm_std_mutex.hpp deleted file mode 100644 index 5cb7490f00254259bbac98a55e1bdc326ae626a2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/lwm_std_mutex.hpp +++ /dev/null @@ -1,62 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_LWM_STD_MUTEX_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_LWM_STD_MUTEX_HPP_INCLUDED - -// Copyright 2020 Peter Dimov -// Distributed under the Boost Software License, Version 1.0. -// https://www.boost.org/LICENSE_1_0.txt) - -#include <boost/assert.hpp> -#include <mutex> - -namespace boost -{ - -namespace detail -{ - -class lightweight_mutex -{ -private: - - std::mutex m_; - - lightweight_mutex(lightweight_mutex const &); - lightweight_mutex & operator=(lightweight_mutex const &); - -public: - - lightweight_mutex() - { - } - - class scoped_lock; - friend class scoped_lock; - - class scoped_lock - { - private: - - std::mutex & m_; - - scoped_lock(scoped_lock const &); - scoped_lock & operator=(scoped_lock const &); - - public: - - scoped_lock( lightweight_mutex & m ): m_( m.m_ ) - { - m_.lock(); - } - - ~scoped_lock() - { - m_.unlock(); - } - }; -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_LWM_STD_MUTEX_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/lwm_win32_cs.hpp b/ThirdParty/boost/smart_ptr/detail/lwm_win32_cs.hpp deleted file mode 100644 index 90decb2a321120728a4f6319fb5f9fecc5b4ce61..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/lwm_win32_cs.hpp +++ /dev/null @@ -1,123 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_LWM_WIN32_CS_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_LWM_WIN32_CS_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/detail/lwm_win32_cs.hpp -// -// Copyright (c) 2002, 2003 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) -// - -#ifdef BOOST_USE_WINDOWS_H - -#include <windows.h> - -#else - -struct _RTL_CRITICAL_SECTION; - -#endif - -namespace boost -{ - -namespace detail -{ - -#ifndef BOOST_USE_WINDOWS_H - -struct critical_section -{ - struct critical_section_debug * DebugInfo; - long LockCount; - long RecursionCount; - void * OwningThread; - void * LockSemaphore; -#if defined(_WIN64) - unsigned __int64 SpinCount; -#else - unsigned long SpinCount; -#endif -}; - -extern "C" __declspec(dllimport) void __stdcall InitializeCriticalSection(::_RTL_CRITICAL_SECTION *); -extern "C" __declspec(dllimport) void __stdcall EnterCriticalSection(::_RTL_CRITICAL_SECTION *); -extern "C" __declspec(dllimport) void __stdcall LeaveCriticalSection(::_RTL_CRITICAL_SECTION *); -extern "C" __declspec(dllimport) void __stdcall DeleteCriticalSection(::_RTL_CRITICAL_SECTION *); - -typedef ::_RTL_CRITICAL_SECTION rtl_critical_section; - -#else // #ifndef BOOST_USE_WINDOWS_H - -typedef ::CRITICAL_SECTION critical_section; - -using ::InitializeCriticalSection; -using ::EnterCriticalSection; -using ::LeaveCriticalSection; -using ::DeleteCriticalSection; - -typedef ::CRITICAL_SECTION rtl_critical_section; - -#endif // #ifndef BOOST_USE_WINDOWS_H - -class lightweight_mutex -{ -private: - - critical_section cs_; - - lightweight_mutex(lightweight_mutex const &); - lightweight_mutex & operator=(lightweight_mutex const &); - -public: - - lightweight_mutex() - { - boost::detail::InitializeCriticalSection(reinterpret_cast< rtl_critical_section* >(&cs_)); - } - - ~lightweight_mutex() - { - boost::detail::DeleteCriticalSection(reinterpret_cast< rtl_critical_section* >(&cs_)); - } - - class scoped_lock; - friend class scoped_lock; - - class scoped_lock - { - private: - - lightweight_mutex & m_; - - scoped_lock(scoped_lock const &); - scoped_lock & operator=(scoped_lock const &); - - public: - - explicit scoped_lock(lightweight_mutex & m): m_(m) - { - boost::detail::EnterCriticalSection(reinterpret_cast< rtl_critical_section* >(&m_.cs_)); - } - - ~scoped_lock() - { - boost::detail::LeaveCriticalSection(reinterpret_cast< rtl_critical_section* >(&m_.cs_)); - } - }; -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_LWM_WIN32_CS_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/shared_count.hpp b/ThirdParty/boost/smart_ptr/detail/shared_count.hpp deleted file mode 100644 index d56718fe7e01b15c03698c09d98660b06bdf08fd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/shared_count.hpp +++ /dev/null @@ -1,668 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SHARED_COUNT_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SHARED_COUNT_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/shared_count.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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) -// - -#ifdef __BORLANDC__ -# pragma warn -8027 // Functions containing try are not expanded inline -#endif - -#include <boost/config.hpp> -#include <boost/checked_delete.hpp> -#include <boost/throw_exception.hpp> -#include <boost/smart_ptr/bad_weak_ptr.hpp> -#include <boost/smart_ptr/detail/sp_counted_base.hpp> -#include <boost/smart_ptr/detail/sp_counted_impl.hpp> -#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/config/workaround.hpp> -// In order to avoid circular dependencies with Boost.TR1 -// we make sure that our include of <memory> doesn't try to -// pull in the TR1 headers: that's why we use this header -// rather than including <memory> directly: -#include <boost/config/no_tr1/memory.hpp> // std::auto_ptr -#include <functional> // std::less - -#ifdef BOOST_NO_EXCEPTIONS -# include <new> // std::bad_alloc -#endif - -#include <boost/core/addressof.hpp> - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#endif - -namespace boost -{ - -namespace movelib -{ - -template< class T, class D > class unique_ptr; - -} // namespace movelib - -namespace detail -{ - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - -int const shared_count_id = 0x2C35F101; -int const weak_count_id = 0x298C38A4; - -#endif - -struct sp_nothrow_tag {}; - -template< class D > struct sp_inplace_tag -{ -}; - -template< class T > class sp_reference_wrapper -{ -public: - - explicit sp_reference_wrapper( T & t): t_( boost::addressof( t ) ) - { - } - - template< class Y > void operator()( Y * p ) const - { - (*t_)( p ); - } - -private: - - T * t_; -}; - -template< class D > struct sp_convert_reference -{ - typedef D type; -}; - -template< class D > struct sp_convert_reference< D& > -{ - typedef sp_reference_wrapper< D > type; -}; - -class weak_count; - -class shared_count -{ -private: - - sp_counted_base * pi_; - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - int id_; -#endif - - friend class weak_count; - -public: - - BOOST_CONSTEXPR shared_count() BOOST_SP_NOEXCEPT: pi_(0) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - } - - BOOST_CONSTEXPR explicit shared_count( sp_counted_base * pi ) BOOST_SP_NOEXCEPT: pi_( pi ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - } - - template<class Y> explicit shared_count( Y * p ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { -#ifndef BOOST_NO_EXCEPTIONS - - try - { - pi_ = new sp_counted_impl_p<Y>( p ); - } - catch(...) - { - boost::checked_delete( p ); - throw; - } - -#else - - pi_ = new sp_counted_impl_p<Y>( p ); - - if( pi_ == 0 ) - { - boost::checked_delete( p ); - boost::throw_exception( std::bad_alloc() ); - } - -#endif - } - -#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, <= 1200 ) - template<class Y, class D> shared_count( Y * p, D d ): pi_(0) -#else - template<class P, class D> shared_count( P p, D d ): pi_(0) -#endif -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { -#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, <= 1200 ) - typedef Y* P; -#endif -#ifndef BOOST_NO_EXCEPTIONS - - try - { - pi_ = new sp_counted_impl_pd<P, D>(p, d); - } - catch(...) - { - d(p); // delete p - throw; - } - -#else - - pi_ = new sp_counted_impl_pd<P, D>(p, d); - - if(pi_ == 0) - { - d(p); // delete p - boost::throw_exception(std::bad_alloc()); - } - -#endif - } - -#if !defined( BOOST_NO_FUNCTION_TEMPLATE_ORDERING ) - - template< class P, class D > shared_count( P p, sp_inplace_tag<D> ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { -#ifndef BOOST_NO_EXCEPTIONS - - try - { - pi_ = new sp_counted_impl_pd< P, D >( p ); - } - catch( ... ) - { - D::operator_fn( p ); // delete p - throw; - } - -#else - - pi_ = new sp_counted_impl_pd< P, D >( p ); - - if( pi_ == 0 ) - { - D::operator_fn( p ); // delete p - boost::throw_exception( std::bad_alloc() ); - } - -#endif // #ifndef BOOST_NO_EXCEPTIONS - } - -#endif // !defined( BOOST_NO_FUNCTION_TEMPLATE_ORDERING ) - - template<class P, class D, class A> shared_count( P p, D d, A a ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - typedef sp_counted_impl_pda<P, D, A> impl_type; - -#if !defined( BOOST_NO_CXX11_ALLOCATOR ) - - typedef typename std::allocator_traits<A>::template rebind_alloc< impl_type > A2; - -#else - - typedef typename A::template rebind< impl_type >::other A2; - -#endif - - A2 a2( a ); - -#ifndef BOOST_NO_EXCEPTIONS - - try - { - pi_ = a2.allocate( 1 ); - ::new( static_cast< void* >( pi_ ) ) impl_type( p, d, a ); - } - catch(...) - { - d( p ); - - if( pi_ != 0 ) - { - a2.deallocate( static_cast< impl_type* >( pi_ ), 1 ); - } - - throw; - } - -#else - - pi_ = a2.allocate( 1 ); - - if( pi_ != 0 ) - { - ::new( static_cast< void* >( pi_ ) ) impl_type( p, d, a ); - } - else - { - d( p ); - boost::throw_exception( std::bad_alloc() ); - } - -#endif - } - -#if !defined( BOOST_NO_FUNCTION_TEMPLATE_ORDERING ) - - template< class P, class D, class A > shared_count( P p, sp_inplace_tag< D >, A a ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - typedef sp_counted_impl_pda< P, D, A > impl_type; - -#if !defined( BOOST_NO_CXX11_ALLOCATOR ) - - typedef typename std::allocator_traits<A>::template rebind_alloc< impl_type > A2; - -#else - - typedef typename A::template rebind< impl_type >::other A2; - -#endif - - A2 a2( a ); - -#ifndef BOOST_NO_EXCEPTIONS - - try - { - pi_ = a2.allocate( 1 ); - ::new( static_cast< void* >( pi_ ) ) impl_type( p, a ); - } - catch(...) - { - D::operator_fn( p ); - - if( pi_ != 0 ) - { - a2.deallocate( static_cast< impl_type* >( pi_ ), 1 ); - } - - throw; - } - -#else - - pi_ = a2.allocate( 1 ); - - if( pi_ != 0 ) - { - ::new( static_cast< void* >( pi_ ) ) impl_type( p, a ); - } - else - { - D::operator_fn( p ); - boost::throw_exception( std::bad_alloc() ); - } - -#endif // #ifndef BOOST_NO_EXCEPTIONS - } - -#endif // !defined( BOOST_NO_FUNCTION_TEMPLATE_ORDERING ) - -#ifndef BOOST_NO_AUTO_PTR - - // auto_ptr<Y> is special cased to provide the strong guarantee - - template<class Y> - explicit shared_count( std::auto_ptr<Y> & r ): pi_( new sp_counted_impl_p<Y>( r.get() ) ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { -#ifdef BOOST_NO_EXCEPTIONS - - if( pi_ == 0 ) - { - boost::throw_exception(std::bad_alloc()); - } - -#endif - - r.release(); - } - -#endif - -#if !defined( BOOST_NO_CXX11_SMART_PTR ) - - template<class Y, class D> - explicit shared_count( std::unique_ptr<Y, D> & r ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - typedef typename sp_convert_reference<D>::type D2; - - D2 d2( r.get_deleter() ); - pi_ = new sp_counted_impl_pd< typename std::unique_ptr<Y, D>::pointer, D2 >( r.get(), d2 ); - -#ifdef BOOST_NO_EXCEPTIONS - - if( pi_ == 0 ) - { - boost::throw_exception( std::bad_alloc() ); - } - -#endif - - r.release(); - } - -#endif - - template<class Y, class D> - explicit shared_count( boost::movelib::unique_ptr<Y, D> & r ): pi_( 0 ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - typedef typename sp_convert_reference<D>::type D2; - - D2 d2( r.get_deleter() ); - pi_ = new sp_counted_impl_pd< typename boost::movelib::unique_ptr<Y, D>::pointer, D2 >( r.get(), d2 ); - -#ifdef BOOST_NO_EXCEPTIONS - - if( pi_ == 0 ) - { - boost::throw_exception( std::bad_alloc() ); - } - -#endif - - r.release(); - } - - ~shared_count() /*BOOST_SP_NOEXCEPT*/ - { - if( pi_ != 0 ) pi_->release(); -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - id_ = 0; -#endif - } - - shared_count(shared_count const & r) BOOST_SP_NOEXCEPT: pi_(r.pi_) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - if( pi_ != 0 ) pi_->add_ref_copy(); - } - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - shared_count(shared_count && r) BOOST_SP_NOEXCEPT: pi_(r.pi_) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif - { - r.pi_ = 0; - } - -#endif - - explicit shared_count(weak_count const & r); // throws bad_weak_ptr when r.use_count() == 0 - shared_count( weak_count const & r, sp_nothrow_tag ) BOOST_SP_NOEXCEPT; // constructs an empty *this when r.use_count() == 0 - - shared_count & operator= (shared_count const & r) BOOST_SP_NOEXCEPT - { - sp_counted_base * tmp = r.pi_; - - if( tmp != pi_ ) - { - if( tmp != 0 ) tmp->add_ref_copy(); - if( pi_ != 0 ) pi_->release(); - pi_ = tmp; - } - - return *this; - } - - void swap(shared_count & r) BOOST_SP_NOEXCEPT - { - sp_counted_base * tmp = r.pi_; - r.pi_ = pi_; - pi_ = tmp; - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return pi_ != 0? pi_->use_count(): 0; - } - - bool unique() const BOOST_SP_NOEXCEPT - { - return use_count() == 1; - } - - bool empty() const BOOST_SP_NOEXCEPT - { - return pi_ == 0; - } - - friend inline bool operator==(shared_count const & a, shared_count const & b) BOOST_SP_NOEXCEPT - { - return a.pi_ == b.pi_; - } - - friend inline bool operator<(shared_count const & a, shared_count const & b) BOOST_SP_NOEXCEPT - { - return std::less<sp_counted_base *>()( a.pi_, b.pi_ ); - } - - void * get_deleter( sp_typeinfo_ const & ti ) const BOOST_SP_NOEXCEPT - { - return pi_? pi_->get_deleter( ti ): 0; - } - - void * get_local_deleter( sp_typeinfo_ const & ti ) const BOOST_SP_NOEXCEPT - { - return pi_? pi_->get_local_deleter( ti ): 0; - } - - void * get_untyped_deleter() const BOOST_SP_NOEXCEPT - { - return pi_? pi_->get_untyped_deleter(): 0; - } -}; - - -class weak_count -{ -private: - - sp_counted_base * pi_; - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - int id_; -#endif - - friend class shared_count; - -public: - - BOOST_CONSTEXPR weak_count() BOOST_SP_NOEXCEPT: pi_(0) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(weak_count_id) -#endif - { - } - - weak_count(shared_count const & r) BOOST_SP_NOEXCEPT: pi_(r.pi_) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(weak_count_id) -#endif - { - if(pi_ != 0) pi_->weak_add_ref(); - } - - weak_count(weak_count const & r) BOOST_SP_NOEXCEPT: pi_(r.pi_) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(weak_count_id) -#endif - { - if(pi_ != 0) pi_->weak_add_ref(); - } - -// Move support - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - weak_count(weak_count && r) BOOST_SP_NOEXCEPT: pi_(r.pi_) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(weak_count_id) -#endif - { - r.pi_ = 0; - } - -#endif - - ~weak_count() /*BOOST_SP_NOEXCEPT*/ - { - if(pi_ != 0) pi_->weak_release(); -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - id_ = 0; -#endif - } - - weak_count & operator= (shared_count const & r) BOOST_SP_NOEXCEPT - { - sp_counted_base * tmp = r.pi_; - - if( tmp != pi_ ) - { - if(tmp != 0) tmp->weak_add_ref(); - if(pi_ != 0) pi_->weak_release(); - pi_ = tmp; - } - - return *this; - } - - weak_count & operator= (weak_count const & r) BOOST_SP_NOEXCEPT - { - sp_counted_base * tmp = r.pi_; - - if( tmp != pi_ ) - { - if(tmp != 0) tmp->weak_add_ref(); - if(pi_ != 0) pi_->weak_release(); - pi_ = tmp; - } - - return *this; - } - - void swap(weak_count & r) BOOST_SP_NOEXCEPT - { - sp_counted_base * tmp = r.pi_; - r.pi_ = pi_; - pi_ = tmp; - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return pi_ != 0? pi_->use_count(): 0; - } - - bool empty() const BOOST_SP_NOEXCEPT - { - return pi_ == 0; - } - - friend inline bool operator==(weak_count const & a, weak_count const & b) BOOST_SP_NOEXCEPT - { - return a.pi_ == b.pi_; - } - - friend inline bool operator<(weak_count const & a, weak_count const & b) BOOST_SP_NOEXCEPT - { - return std::less<sp_counted_base *>()(a.pi_, b.pi_); - } -}; - -inline shared_count::shared_count( weak_count const & r ): pi_( r.pi_ ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif -{ - if( pi_ == 0 || !pi_->add_ref_lock() ) - { - boost::throw_exception( boost::bad_weak_ptr() ); - } -} - -inline shared_count::shared_count( weak_count const & r, sp_nothrow_tag ) BOOST_SP_NOEXCEPT: pi_( r.pi_ ) -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - , id_(shared_count_id) -#endif -{ - if( pi_ != 0 && !pi_->add_ref_lock() ) - { - pi_ = 0; - } -} - -} // namespace detail - -} // namespace boost - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic pop -#endif - -#ifdef __BORLANDC__ -# pragma warn .8027 // Functions containing try are not expanded inline -#endif - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SHARED_COUNT_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_acc_ia64.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_acc_ia64.hpp deleted file mode 100644 index 07c07e236bffe51a18a19d92948d365f3d3c8c5d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_acc_ia64.hpp +++ /dev/null @@ -1,153 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_ACC_IA64_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_ACC_IA64_HPP_INCLUDED - -// -// detail/sp_counted_base_acc_ia64.hpp - aC++ on HP-UX IA64 -// -// Copyright 2007 Baruch Zilber -// Copyright 2007 Boris Gubenko -// -// 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> -#include <machine/sys/inline.h> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int * pw ) -{ - // ++*pw; - - _Asm_fetchadd(_FASZ_W, _SEM_REL, pw, +1, _LDHINT_NONE); -} - -inline int atomic_decrement( int * pw ) -{ - // return --*pw; - - int r = static_cast<int>(_Asm_fetchadd(_FASZ_W, _SEM_REL, pw, -1, _LDHINT_NONE)); - if (1 == r) - { - _Asm_mf(); - } - - return r - 1; -} - -inline int atomic_conditional_increment( int * pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - int v = *pw; - - for (;;) - { - if (0 == v) - { - return 0; - } - - _Asm_mov_to_ar(_AREG_CCV, - v, - (_UP_CALL_FENCE | _UP_SYS_FENCE | _DOWN_CALL_FENCE | _DOWN_SYS_FENCE)); - int r = static_cast<int>(_Asm_cmpxchg(_SZ_W, _SEM_ACQ, pw, v + 1, _LDHINT_NONE)); - if (r == v) - { - return r + 1; - } - - v = r; - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<int const volatile &>( use_count_ ); // TODO use ld.acq here - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_ACC_IA64_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_aix.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_aix.hpp deleted file mode 100644 index 072c667e29bc0e496b7e782d06ef2f17d10134b2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_aix.hpp +++ /dev/null @@ -1,145 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_AIX_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_AIX_HPP_INCLUDED - -// -// detail/sp_counted_base_aix.hpp -// based on: detail/sp_counted_base_w32.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 Peter Dimov -// Copyright 2006 Michael van der Westhuizen -// -// 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> -#include <builtins.h> -#include <sys/atomic_op.h> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int32_t* pw ) -{ - // ++*pw; - - fetch_and_add( pw, 1 ); -} - -inline int32_t atomic_decrement( int32_t * pw ) -{ - // return --*pw; - - int32_t originalValue; - - __lwsync(); - originalValue = fetch_and_add( pw, -1 ); - __isync(); - - return (originalValue - 1); -} - -inline int32_t atomic_conditional_increment( int32_t * pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - int32_t tmp = fetch_and_add( pw, 0 ); - for( ;; ) - { - if( tmp == 0 ) return 0; - if( compare_and_swap( pw, &tmp, tmp + 1 ) ) return (tmp + 1); - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int32_t use_count_; // #shared - int32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return fetch_and_add( const_cast<int32_t*>(&use_count_), 0 ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_AIX_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_clang.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_clang.hpp deleted file mode 100644 index 89bcfb80a744b6f337d91f28459f410f1a0aa562..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_clang.hpp +++ /dev/null @@ -1,152 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CLANG_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CLANG_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_counted_base_clang.hpp - __c11 clang intrinsics -// -// Copyright (c) 2007, 2013, 2015 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/config.hpp> -#include <boost/cstdint.hpp> - -namespace boost -{ - -namespace detail -{ - -typedef _Atomic( boost::int_least32_t ) atomic_int_least32_t; - -inline void atomic_increment( atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - __c11_atomic_fetch_add( pw, 1, __ATOMIC_RELAXED ); -} - -inline boost::int_least32_t atomic_decrement( atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - return __c11_atomic_fetch_sub( pw, 1, __ATOMIC_ACQ_REL ); -} - -inline boost::int_least32_t atomic_conditional_increment( atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - // long r = *pw; - // if( r != 0 ) ++*pw; - // return r; - - boost::int_least32_t r = __c11_atomic_load( pw, __ATOMIC_RELAXED ); - - for( ;; ) - { - if( r == 0 ) - { - return r; - } - - if( __c11_atomic_compare_exchange_weak( pw, &r, r + 1, __ATOMIC_RELAXED, __ATOMIC_RELAXED ) ) - { - return r; - } - } -} - -#if defined(__clang__) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Wweak-vtables" -#endif - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - atomic_int_least32_t use_count_; // #shared - atomic_int_least32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base() BOOST_SP_NOEXCEPT - { - __c11_atomic_init( &use_count_, 1 ); - __c11_atomic_init( &weak_count_, 1 ); - } - - virtual ~sp_counted_base() /*BOOST_SP_NOEXCEPT*/ - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() BOOST_SP_NOEXCEPT = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() BOOST_SP_NOEXCEPT // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT = 0; - - void add_ref_copy() BOOST_SP_NOEXCEPT - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() BOOST_SP_NOEXCEPT // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() BOOST_SP_NOEXCEPT - { - if( atomic_decrement( &use_count_ ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() BOOST_SP_NOEXCEPT - { - atomic_increment( &weak_count_ ); - } - - void weak_release() BOOST_SP_NOEXCEPT - { - if( atomic_decrement( &weak_count_ ) == 1 ) - { - destroy(); - } - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return __c11_atomic_load( const_cast< atomic_int_least32_t* >( &use_count_ ), __ATOMIC_ACQUIRE ); - } -}; - -#if defined(__clang__) -# pragma clang diagnostic pop -#endif - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CLANG_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_cw_ppc.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_cw_ppc.hpp deleted file mode 100644 index 8e5a414dabb1b46737f7b922c8316eb2fd7203ec..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_cw_ppc.hpp +++ /dev/null @@ -1,173 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CW_PPC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CW_PPC_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_cw_ppc.hpp - CodeWarrior on PowerPC -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( register long * pw ) -{ - register int a; - - asm - { -loop: - - lwarx a, 0, pw - addi a, a, 1 - stwcx. a, 0, pw - bne- loop - } -} - -inline long atomic_decrement( register long * pw ) -{ - register int a; - - asm - { - sync - -loop: - - lwarx a, 0, pw - addi a, a, -1 - stwcx. a, 0, pw - bne- loop - - isync - } - - return a; -} - -inline long atomic_conditional_increment( register long * pw ) -{ - register int a; - - asm - { -loop: - - lwarx a, 0, pw - cmpwi a, 0 - beq store - - addi a, a, 1 - -store: - - stwcx. a, 0, pw - bne- loop - } - - return a; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - long use_count_; // #shared - long weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<long const volatile &>( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_CW_PPC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ia64.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ia64.hpp deleted file mode 100644 index 73d4533800080eb7a9d606dc5ef92cbea85e998b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ia64.hpp +++ /dev/null @@ -1,160 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_IA64_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_IA64_HPP_INCLUDED - -// -// detail/sp_counted_base_gcc_ia64.hpp - g++ on IA64 -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2006 Peter Dimov -// Copyright 2005 Ben Hutchings -// -// 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int * pw ) -{ - // ++*pw; - - int tmp; - - // No barrier is required here but fetchadd always has an acquire or - // release barrier associated with it. We choose release as it should be - // cheaper. - __asm__ ("fetchadd4.rel %0=%1,1" : - "=r"(tmp), "=m"(*pw) : - "m"( *pw )); -} - -inline int atomic_decrement( int * pw ) -{ - // return --*pw; - - int rv; - - __asm__ (" fetchadd4.rel %0=%1,-1 ;; \n" - " cmp.eq p7,p0=1,%0 ;; \n" - "(p7) ld4.acq %0=%1 " : - "=&r"(rv), "=m"(*pw) : - "m"( *pw ) : - "p7"); - - return rv; -} - -inline int atomic_conditional_increment( int * pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - int rv, tmp, tmp2; - - __asm__ ("0: ld4 %0=%3 ;; \n" - " cmp.eq p7,p0=0,%0 ;; \n" - "(p7) br.cond.spnt 1f \n" - " mov ar.ccv=%0 \n" - " add %1=1,%0 ;; \n" - " cmpxchg4.acq %2=%3,%1,ar.ccv ;; \n" - " cmp.ne p7,p0=%0,%2 ;; \n" - "(p7) br.cond.spnt 0b \n" - " mov %0=%1 ;; \n" - "1:" : - "=&r"(rv), "=&r"(tmp), "=&r"(tmp2), "=m"(*pw) : - "m"( *pw ) : - "ar.ccv", "p7"); - - return rv; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<int const volatile &>( use_count_ ); // TODO use ld.acq here - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_IA64_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp deleted file mode 100644 index f109f6579f5ec368f1c86f5c8739bd97ff773d58..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp +++ /dev/null @@ -1,190 +0,0 @@ -#ifndef BOOST_DETAIL_SP_COUNTED_BASE_GCC_MIPS_HPP_INCLUDED -#define BOOST_DETAIL_SP_COUNTED_BASE_GCC_MIPS_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_gcc_mips.hpp - g++ on MIPS -// -// Copyright (c) 2009, Spirent Communications, Inc. -// -// 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int * pw ) -{ - // ++*pw; - - int tmp; - - __asm__ __volatile__ - ( - "0:\n\t" - ".set push\n\t" -#if !defined(__mips_isa_rev) || (__mips_isa_rev < 6) - ".set mips2\n\t" -#endif - "ll %0, %1\n\t" - "addiu %0, 1\n\t" - "sc %0, %1\n\t" - ".set pop\n\t" - "beqz %0, 0b": - "=&r"( tmp ), "=m"( *pw ): - "m"( *pw ) - ); -} - -inline int atomic_decrement( int * pw ) -{ - // return --*pw; - - int rv, tmp; - - __asm__ __volatile__ - ( - "0:\n\t" - ".set push\n\t" -#if !defined(__mips_isa_rev) || (__mips_isa_rev < 6) - ".set mips2\n\t" -#endif - "ll %1, %2\n\t" - "addiu %0, %1, -1\n\t" - "sc %0, %2\n\t" - ".set pop\n\t" - "beqz %0, 0b\n\t" - "addiu %0, %1, -1": - "=&r"( rv ), "=&r"( tmp ), "=m"( *pw ): - "m"( *pw ): - "memory" - ); - - return rv; -} - -inline int atomic_conditional_increment( int * pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - int rv, tmp; - - __asm__ __volatile__ - ( - "0:\n\t" - ".set push\n\t" -#if !defined(__mips_isa_rev) || (__mips_isa_rev < 6) - ".set mips2\n\t" -#endif - "ll %0, %2\n\t" - "beqz %0, 1f\n\t" - "addiu %1, %0, 1\n\t" - "sc %1, %2\n\t" - ".set pop\n\t" - "beqz %1, 0b\n\t" - "addiu %0, %0, 1\n\t" - "1:": - "=&r"( rv ), "=&r"( tmp ), "=m"( *pw ): - "m"( *pw ): - "memory" - ); - - return rv; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<int const volatile &>( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_DETAIL_SP_COUNTED_BASE_GCC_MIPS_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp deleted file mode 100644 index 5dce1cf6ac3581fa8d29b776e078e61514ba8719..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp +++ /dev/null @@ -1,184 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_PPC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_PPC_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_gcc_ppc.hpp - g++ on PowerPC -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int * pw ) -{ - // ++*pw; - - int tmp; - - __asm__ - ( - "0:\n\t" - "lwarx %1, 0, %2\n\t" - "addi %1, %1, 1\n\t" - "stwcx. %1, 0, %2\n\t" - "bne- 0b": - - "=m"( *pw ), "=&b"( tmp ): - "r"( pw ), "m"( *pw ): - "cc" - ); -} - -inline int atomic_decrement( int * pw ) -{ - // return --*pw; - - int rv; - - __asm__ __volatile__ - ( - "sync\n\t" - "0:\n\t" - "lwarx %1, 0, %2\n\t" - "addi %1, %1, -1\n\t" - "stwcx. %1, 0, %2\n\t" - "bne- 0b\n\t" - "isync": - - "=m"( *pw ), "=&b"( rv ): - "r"( pw ), "m"( *pw ): - "memory", "cc" - ); - - return rv; -} - -inline int atomic_conditional_increment( int * pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - int rv; - - __asm__ - ( - "0:\n\t" - "lwarx %1, 0, %2\n\t" - "cmpwi %1, 0\n\t" - "beq 1f\n\t" - "addi %1, %1, 1\n\t" - "1:\n\t" - "stwcx. %1, 0, %2\n\t" - "bne- 0b": - - "=m"( *pw ), "=&b"( rv ): - "r"( pw ), "m"( *pw ): - "cc" - ); - - return rv; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<int const volatile &>( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_PPC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp deleted file mode 100644 index a3d7295865dcd93fef68c60294accf5dfba4c081..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp +++ /dev/null @@ -1,169 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_SPARC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_SPARC_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_counted_base_gcc_sparc.hpp - g++ on Sparc V8+ -// -// Copyright (c) 2006 Piotr Wyderski -// Copyright (c) 2006 Tomas Puverle -// Copyright (c) 2006 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 -// -// Thanks to Michael van der Westhuizen - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> -#include <inttypes.h> // int32_t - -namespace boost -{ - -namespace detail -{ - -inline int32_t compare_and_swap( int32_t * dest_, int32_t compare_, int32_t swap_ ) -{ - __asm__ __volatile__( "cas [%1], %2, %0" - : "+r" (swap_) - : "r" (dest_), "r" (compare_) - : "memory" ); - - return swap_; -} - -inline int32_t atomic_fetch_and_add( int32_t * pw, int32_t dv ) -{ - // long r = *pw; - // *pw += dv; - // return r; - - for( ;; ) - { - int32_t r = *pw; - - if( __builtin_expect((compare_and_swap(pw, r, r + dv) == r), 1) ) - { - return r; - } - } -} - -inline void atomic_increment( int32_t * pw ) -{ - atomic_fetch_and_add( pw, 1 ); -} - -inline int32_t atomic_decrement( int32_t * pw ) -{ - return atomic_fetch_and_add( pw, -1 ); -} - -inline int32_t atomic_conditional_increment( int32_t * pw ) -{ - // long r = *pw; - // if( r != 0 ) ++*pw; - // return r; - - for( ;; ) - { - int32_t r = *pw; - - if( r == 0 ) - { - return r; - } - - if( __builtin_expect( ( compare_and_swap( pw, r, r + 1 ) == r ), 1 ) ) - { - return r; - } - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int32_t use_count_; // #shared - int32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 1 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return const_cast< int32_t const volatile & >( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_SPARC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp deleted file mode 100644 index ebbea502642e7fca912fcc91a186e98e260277d9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp +++ /dev/null @@ -1,176 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_gcc_x86.hpp - g++ on 486+ or AMD64 -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline int atomic_exchange_and_add( int * pw, int dv ) -{ - // int r = *pw; - // *pw += dv; - // return r; - - int r; - - __asm__ __volatile__ - ( - "lock\n\t" - "xadd %1, %0": - "=m"( *pw ), "=r"( r ): // outputs (%0, %1) - "m"( *pw ), "1"( dv ): // inputs (%2, %3 == %1) - "memory", "cc" // clobbers - ); - - return r; -} - -inline void atomic_increment( int * pw ) -{ - //atomic_exchange_and_add( pw, 1 ); - - __asm__ - ( - "lock\n\t" - "incl %0": - "=m"( *pw ): // output (%0) - "m"( *pw ): // input (%1) - "cc" // clobbers - ); -} - -inline int atomic_conditional_increment( int * pw ) -{ - // int rv = *pw; - // if( rv != 0 ) ++*pw; - // return rv; - - int rv, tmp; - - __asm__ - ( - "movl %0, %%eax\n\t" - "0:\n\t" - "test %%eax, %%eax\n\t" - "je 1f\n\t" - "movl %%eax, %2\n\t" - "incl %2\n\t" - "lock\n\t" - "cmpxchgl %2, %0\n\t" - "jne 0b\n\t" - "1:": - "=m"( *pw ), "=&a"( rv ), "=&r"( tmp ): // outputs (%0, %1, %2) - "m"( *pw ): // input (%3) - "cc" // clobbers - ); - - return rv; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_exchange_and_add( &use_count_, -1 ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_exchange_and_add( &weak_count_, -1 ) == 1 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<int const volatile &>( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_nt.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_nt.hpp deleted file mode 100644 index 08300505bb6742fe914a64e8d6c03d35e1b2ffb7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_nt.hpp +++ /dev/null @@ -1,112 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_NT_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_NT_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_nt.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/config.hpp> -#include <boost/cstdint.hpp> - -namespace boost -{ - -namespace detail -{ - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - boost::int_least32_t use_count_; // #shared - boost::int_least32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base() BOOST_SP_NOEXCEPT: use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() /*BOOST_SP_NOEXCEPT*/ - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() BOOST_SP_NOEXCEPT = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() BOOST_SP_NOEXCEPT // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT = 0; - - void add_ref_copy() BOOST_SP_NOEXCEPT - { - ++use_count_; - } - - bool add_ref_lock() BOOST_SP_NOEXCEPT // true on success - { - if( use_count_ == 0 ) return false; - ++use_count_; - return true; - } - - void release() BOOST_SP_NOEXCEPT - { - if( --use_count_ == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() BOOST_SP_NOEXCEPT - { - ++weak_count_; - } - - void weak_release() BOOST_SP_NOEXCEPT - { - if( --weak_count_ == 0 ) - { - destroy(); - } - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return use_count_; - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_NT_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_pt.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_pt.hpp deleted file mode 100644 index ec850fe6bdc8ea2b47327b36a93c8cd19b3de53d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_pt.hpp +++ /dev/null @@ -1,140 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_PT_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_PT_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_pt.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/assert.hpp> -#include <boost/config.hpp> -#include <boost/cstdint.hpp> -#include <pthread.h> - -namespace boost -{ - -namespace detail -{ - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - boost::int_least32_t use_count_; // #shared - boost::int_least32_t weak_count_; // #weak + (#shared != 0) - - mutable pthread_mutex_t m_; - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { -// HPUX 10.20 / DCE has a nonstandard pthread_mutex_init - -#if defined(__hpux) && defined(_DECTHREADS_) - BOOST_VERIFY( pthread_mutex_init( &m_, pthread_mutexattr_default ) == 0 ); -#else - BOOST_VERIFY( pthread_mutex_init( &m_, 0 ) == 0 ); -#endif - } - - virtual ~sp_counted_base() // nothrow - { - BOOST_VERIFY( pthread_mutex_destroy( &m_ ) == 0 ); - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - ++use_count_; - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - } - - bool add_ref_lock() // true on success - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - bool r = use_count_ == 0? false: ( ++use_count_, true ); - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - return r; - } - - void release() // nothrow - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - boost::int_least32_t new_use_count = --use_count_; - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - - if( new_use_count == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - ++weak_count_; - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - } - - void weak_release() // nothrow - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - boost::int_least32_t new_weak_count = --weak_count_; - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - - if( new_weak_count == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - BOOST_VERIFY( pthread_mutex_lock( &m_ ) == 0 ); - boost::int_least32_t r = use_count_; - BOOST_VERIFY( pthread_mutex_unlock( &m_ ) == 0 ); - - return r; - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_PT_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_snc_ps3.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_snc_ps3.hpp deleted file mode 100644 index f38eee65f594257307835bf6b4ae4cb81a78c4bb..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_snc_ps3.hpp +++ /dev/null @@ -1,164 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SNC_PS3_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SNC_PS3_HPP_INCLUDED - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_counted_base_gcc_sparc.hpp - g++ on Sparc V8+ -// -// Copyright (c) 2006 Piotr Wyderski -// Copyright (c) 2006 Tomas Puverle -// Copyright (c) 2006 Peter Dimov -// Copyright (c) 2011 Emil Dotchevski -// -// 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 -// -// Thanks to Michael van der Westhuizen - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> -#include <inttypes.h> // uint32_t - -namespace boost -{ - -namespace detail -{ - -inline uint32_t compare_and_swap( uint32_t * dest_, uint32_t compare_, uint32_t swap_ ) -{ - return __builtin_cellAtomicCompareAndSwap32(dest_,compare_,swap_); -} - -inline uint32_t atomic_fetch_and_add( uint32_t * pw, uint32_t dv ) -{ - // long r = *pw; - // *pw += dv; - // return r; - - for( ;; ) - { - uint32_t r = *pw; - - if( __builtin_expect((compare_and_swap(pw, r, r + dv) == r), 1) ) - { - return r; - } - } -} - -inline void atomic_increment( uint32_t * pw ) -{ - (void) __builtin_cellAtomicIncr32( pw ); -} - -inline uint32_t atomic_decrement( uint32_t * pw ) -{ - return __builtin_cellAtomicDecr32( pw ); -} - -inline uint32_t atomic_conditional_increment( uint32_t * pw ) -{ - // long r = *pw; - // if( r != 0 ) ++*pw; - // return r; - - for( ;; ) - { - uint32_t r = *pw; - - if( r == 0 ) - { - return r; - } - - if( __builtin_expect( ( compare_and_swap( pw, r, r + 1 ) == r ), 1 ) ) - { - return r; - } - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - uint32_t use_count_; // #shared - uint32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 1 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return const_cast< uint32_t const volatile & >( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SNC_PS3_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_spin.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_spin.hpp deleted file mode 100644 index 56911bdb09c86fe1f3a03680f40e5799faf892ff..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_spin.hpp +++ /dev/null @@ -1,134 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SPIN_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SPIN_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_spin.hpp - spinlock pool atomic emulation -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2008 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/smart_ptr/detail/spinlock_pool.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -inline int atomic_exchange_and_add( int * pw, int dv ) -{ - spinlock_pool<1>::scoped_lock lock( pw ); - - int r = *pw; - *pw += dv; - return r; -} - -inline void atomic_increment( int * pw ) -{ - spinlock_pool<1>::scoped_lock lock( pw ); - ++*pw; -} - -inline int atomic_conditional_increment( int * pw ) -{ - spinlock_pool<1>::scoped_lock lock( pw ); - - int rv = *pw; - if( rv != 0 ) ++*pw; - return rv; -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_exchange_and_add( &use_count_, -1 ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_exchange_and_add( &weak_count_, -1 ) == 1 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - spinlock_pool<1>::scoped_lock lock( &use_count_ ); - return use_count_; - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SPIN_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_std_atomic.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_std_atomic.hpp deleted file mode 100644 index 338eeea718d58fc91bf9bf2e08a448dbd81f846c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_std_atomic.hpp +++ /dev/null @@ -1,140 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_STD_ATOMIC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_STD_ATOMIC_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_counted_base_std_atomic.hpp - C++11 std::atomic -// -// Copyright (c) 2007, 2013 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/config.hpp> -#include <atomic> -#include <cstdint> - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( std::atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - pw->fetch_add( 1, std::memory_order_relaxed ); -} - -inline std::int_least32_t atomic_decrement( std::atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - return pw->fetch_sub( 1, std::memory_order_acq_rel ); -} - -inline std::int_least32_t atomic_conditional_increment( std::atomic_int_least32_t * pw ) BOOST_SP_NOEXCEPT -{ - // long r = *pw; - // if( r != 0 ) ++*pw; - // return r; - - std::int_least32_t r = pw->load( std::memory_order_relaxed ); - - for( ;; ) - { - if( r == 0 ) - { - return r; - } - - if( pw->compare_exchange_weak( r, r + 1, std::memory_order_relaxed, std::memory_order_relaxed ) ) - { - return r; - } - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - std::atomic_int_least32_t use_count_; // #shared - std::atomic_int_least32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base() BOOST_SP_NOEXCEPT: use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() /*BOOST_SP_NOEXCEPT*/ - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() BOOST_SP_NOEXCEPT = 0; - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() BOOST_SP_NOEXCEPT - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT = 0; - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT = 0; - - void add_ref_copy() BOOST_SP_NOEXCEPT - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() BOOST_SP_NOEXCEPT // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() BOOST_SP_NOEXCEPT - { - if( atomic_decrement( &use_count_ ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() BOOST_SP_NOEXCEPT - { - atomic_increment( &weak_count_ ); - } - - void weak_release() BOOST_SP_NOEXCEPT - { - if( atomic_decrement( &weak_count_ ) == 1 ) - { - destroy(); - } - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return use_count_.load( std::memory_order_acquire ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_STD_ATOMIC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_sync.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_sync.hpp deleted file mode 100644 index 8446560e0ac407bb715b68bcf8fa09589fe8b1f0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_sync.hpp +++ /dev/null @@ -1,158 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SYNC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SYNC_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_counted_base_sync.hpp - g++ 4.1+ __sync intrinsics -// -// Copyright (c) 2007 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/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> -#include <limits.h> - -#if defined( __ia64__ ) && defined( __INTEL_COMPILER ) -# include <ia64intrin.h> -#endif - -namespace boost -{ - -namespace detail -{ - -#if INT_MAX >= 2147483647 - -typedef int sp_int32_t; - -#else - -typedef long sp_int32_t; - -#endif - -inline void atomic_increment( sp_int32_t * pw ) -{ - __sync_fetch_and_add( pw, 1 ); -} - -inline sp_int32_t atomic_decrement( sp_int32_t * pw ) -{ - return __sync_fetch_and_add( pw, -1 ); -} - -inline sp_int32_t atomic_conditional_increment( sp_int32_t * pw ) -{ - // long r = *pw; - // if( r != 0 ) ++*pw; - // return r; - - sp_int32_t r = *pw; - - for( ;; ) - { - if( r == 0 ) - { - return r; - } - - sp_int32_t r2 = __sync_val_compare_and_swap( pw, r, r + 1 ); - - if( r2 == r ) - { - return r; - } - else - { - r = r2; - } - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - sp_int32_t use_count_; // #shared - sp_int32_t weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 1 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 1 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return const_cast< sp_int32_t const volatile & >( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_SYNC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_vacpp_ppc.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_vacpp_ppc.hpp deleted file mode 100644 index 2467e95a17ff48de61501d4833aef5cfaf4236a2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_vacpp_ppc.hpp +++ /dev/null @@ -1,153 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_VACPP_PPC_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_VACPP_PPC_HPP_INCLUDED - -// -// detail/sp_counted_base_vacpp_ppc.hpp - xlC(vacpp) on POWER -// based on: detail/sp_counted_base_w32.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 Peter Dimov -// Copyright 2006 Michael van der Westhuizen -// Copyright 2012 IBM Corp. -// -// 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config.hpp> - -extern "builtin" void __lwsync(void); -extern "builtin" void __isync(void); -extern "builtin" int __fetch_and_add(volatile int* addr, int val); -extern "builtin" int __compare_and_swap(volatile int*, int*, int); - -namespace boost -{ - -namespace detail -{ - -inline void atomic_increment( int *pw ) -{ - // ++*pw; - __lwsync(); - __fetch_and_add(pw, 1); - __isync(); -} - -inline int atomic_decrement( int *pw ) -{ - // return --*pw; - __lwsync(); - int originalValue = __fetch_and_add(pw, -1); - __isync(); - - return (originalValue - 1); -} - -inline int atomic_conditional_increment( int *pw ) -{ - // if( *pw != 0 ) ++*pw; - // return *pw; - - __lwsync(); - int v = *const_cast<volatile int*>(pw); - for (;;) - // loop until state is known - { - if (v == 0) return 0; - if (__compare_and_swap(pw, &v, v + 1)) - { - __isync(); return (v + 1); - } - } -} - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - int use_count_; // #shared - int weak_count_; // #weak + (#shared != 0) - char pad[64] __attribute__((__aligned__(64))); - // pad to prevent false sharing -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - atomic_increment( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - return atomic_conditional_increment( &use_count_ ) != 0; - } - - void release() // nothrow - { - if( atomic_decrement( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - atomic_increment( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( atomic_decrement( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return *const_cast<volatile int*>(&use_count_); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_VACPP_PPC_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_w32.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_base_w32.hpp deleted file mode 100644 index 15853f9fff881afef532a1447067ff034adf0942..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_base_w32.hpp +++ /dev/null @@ -1,133 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_W32_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_W32_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_base_w32.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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) -// -// -// Lock-free algorithm by Alexander Terekhov -// -// Thanks to Ben Hitchings for the #weak + (#shared != 0) -// formulation -// - -#include <boost/smart_ptr/detail/sp_interlocked.hpp> -#include <boost/smart_ptr/detail/sp_typeinfo_.hpp> -#include <boost/config/workaround.hpp> -#include <boost/config.hpp> - -namespace boost -{ - -namespace detail -{ - -class BOOST_SYMBOL_VISIBLE sp_counted_base -{ -private: - - sp_counted_base( sp_counted_base const & ); - sp_counted_base & operator= ( sp_counted_base const & ); - - long use_count_; // #shared - long weak_count_; // #weak + (#shared != 0) - -public: - - sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) - { - } - - virtual ~sp_counted_base() // nothrow - { - } - - // dispose() is called when use_count_ drops to zero, to release - // the resources managed by *this. - - virtual void dispose() = 0; // nothrow - - // destroy() is called when weak_count_ drops to zero. - - virtual void destroy() // nothrow - { - delete this; - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) = 0; - virtual void * get_untyped_deleter() = 0; - - void add_ref_copy() - { - BOOST_SP_INTERLOCKED_INCREMENT( &use_count_ ); - } - - bool add_ref_lock() // true on success - { - for( ;; ) - { - long tmp = static_cast< long const volatile& >( use_count_ ); - if( tmp == 0 ) return false; - -#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, == 1200 ) - - // work around a code generation bug - - long tmp2 = tmp + 1; - if( BOOST_SP_INTERLOCKED_COMPARE_EXCHANGE( &use_count_, tmp2, tmp ) == tmp2 - 1 ) return true; - -#else - - if( BOOST_SP_INTERLOCKED_COMPARE_EXCHANGE( &use_count_, tmp + 1, tmp ) == tmp ) return true; - -#endif - } - } - - void release() // nothrow - { - if( BOOST_SP_INTERLOCKED_DECREMENT( &use_count_ ) == 0 ) - { - dispose(); - weak_release(); - } - } - - void weak_add_ref() // nothrow - { - BOOST_SP_INTERLOCKED_INCREMENT( &weak_count_ ); - } - - void weak_release() // nothrow - { - if( BOOST_SP_INTERLOCKED_DECREMENT( &weak_count_ ) == 0 ) - { - destroy(); - } - } - - long use_count() const // nothrow - { - return static_cast<long const volatile &>( use_count_ ); - } -}; - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_W32_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_counted_impl.hpp b/ThirdParty/boost/smart_ptr/detail/sp_counted_impl.hpp deleted file mode 100644 index 96c9da383070acc4a2d1f3fe87deddaf1f6a428b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_counted_impl.hpp +++ /dev/null @@ -1,293 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_IMPL_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_IMPL_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/sp_counted_impl.hpp -// -// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd. -// Copyright 2004-2005 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_SP_USE_STD_ALLOCATOR) && defined(BOOST_SP_USE_QUICK_ALLOCATOR) -# error BOOST_SP_USE_STD_ALLOCATOR and BOOST_SP_USE_QUICK_ALLOCATOR are incompatible. -#endif - -#include <boost/checked_delete.hpp> -#include <boost/smart_ptr/detail/sp_counted_base.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/core/addressof.hpp> - -#if defined(BOOST_SP_USE_QUICK_ALLOCATOR) -#include <boost/smart_ptr/detail/quick_allocator.hpp> -#endif - -#if defined(BOOST_SP_USE_STD_ALLOCATOR) -#include <memory> // std::allocator -#endif - -#include <cstddef> // std::size_t - -namespace boost -{ - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - -void sp_scalar_constructor_hook( void * px, std::size_t size, void * pn ); -void sp_scalar_destructor_hook( void * px, std::size_t size, void * pn ); - -#endif - -namespace detail -{ - -// get_local_deleter - -template<class D> class local_sp_deleter; - -template<class D> D * get_local_deleter( D * /*p*/ ) BOOST_SP_NOEXCEPT -{ - return 0; -} - -template<class D> D * get_local_deleter( local_sp_deleter<D> * p ) BOOST_SP_NOEXCEPT; - -// - -template<class X> class BOOST_SYMBOL_VISIBLE sp_counted_impl_p: public sp_counted_base -{ -private: - - X * px_; - - sp_counted_impl_p( sp_counted_impl_p const & ); - sp_counted_impl_p & operator= ( sp_counted_impl_p const & ); - - typedef sp_counted_impl_p<X> this_type; - -public: - - explicit sp_counted_impl_p( X * px ): px_( px ) - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_scalar_constructor_hook( px, sizeof(X), this ); -#endif - } - - virtual void dispose() BOOST_SP_NOEXCEPT - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_scalar_destructor_hook( px_, sizeof(X), this ); -#endif - boost::checked_delete( px_ ); - } - - virtual void * get_deleter( sp_typeinfo_ const & ) BOOST_SP_NOEXCEPT - { - return 0; - } - - virtual void * get_local_deleter( sp_typeinfo_ const & ) BOOST_SP_NOEXCEPT - { - return 0; - } - - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT - { - return 0; - } - -#if defined(BOOST_SP_USE_STD_ALLOCATOR) - - void * operator new( std::size_t ) - { - return std::allocator<this_type>().allocate( 1, static_cast<this_type *>(0) ); - } - - void operator delete( void * p ) - { - std::allocator<this_type>().deallocate( static_cast<this_type *>(p), 1 ); - } - -#endif - -#if defined(BOOST_SP_USE_QUICK_ALLOCATOR) - - void * operator new( std::size_t ) - { - return quick_allocator<this_type>::alloc(); - } - - void operator delete( void * p ) - { - quick_allocator<this_type>::dealloc( p ); - } - -#endif -}; - -// -// Borland's Codeguard trips up over the -Vx- option here: -// -#ifdef __CODEGUARD__ -# pragma option push -Vx- -#endif - -template<class P, class D> class BOOST_SYMBOL_VISIBLE sp_counted_impl_pd: public sp_counted_base -{ -private: - - P ptr; // copy constructor must not throw - D del; // copy constructor must not throw - - sp_counted_impl_pd( sp_counted_impl_pd const & ); - sp_counted_impl_pd & operator= ( sp_counted_impl_pd const & ); - - typedef sp_counted_impl_pd<P, D> this_type; - -public: - - // pre: d(p) must not throw - - sp_counted_impl_pd( P p, D & d ): ptr( p ), del( d ) - { - } - - sp_counted_impl_pd( P p ): ptr( p ), del() - { - } - - virtual void dispose() BOOST_SP_NOEXCEPT - { - del( ptr ); - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT - { - return ti == BOOST_SP_TYPEID_(D)? &reinterpret_cast<char&>( del ): 0; - } - - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT - { - return ti == BOOST_SP_TYPEID_(D)? boost::detail::get_local_deleter( boost::addressof( del ) ): 0; - } - - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT - { - return &reinterpret_cast<char&>( del ); - } - -#if defined(BOOST_SP_USE_STD_ALLOCATOR) - - void * operator new( std::size_t ) - { - return std::allocator<this_type>().allocate( 1, static_cast<this_type *>(0) ); - } - - void operator delete( void * p ) - { - std::allocator<this_type>().deallocate( static_cast<this_type *>(p), 1 ); - } - -#endif - -#if defined(BOOST_SP_USE_QUICK_ALLOCATOR) - - void * operator new( std::size_t ) - { - return quick_allocator<this_type>::alloc(); - } - - void operator delete( void * p ) - { - quick_allocator<this_type>::dealloc( p ); - } - -#endif -}; - -template<class P, class D, class A> class BOOST_SYMBOL_VISIBLE sp_counted_impl_pda: public sp_counted_base -{ -private: - - P p_; // copy constructor must not throw - D d_; // copy constructor must not throw - A a_; // copy constructor must not throw - - sp_counted_impl_pda( sp_counted_impl_pda const & ); - sp_counted_impl_pda & operator= ( sp_counted_impl_pda const & ); - - typedef sp_counted_impl_pda<P, D, A> this_type; - -public: - - // pre: d( p ) must not throw - - sp_counted_impl_pda( P p, D & d, A a ): p_( p ), d_( d ), a_( a ) - { - } - - sp_counted_impl_pda( P p, A a ): p_( p ), d_( a ), a_( a ) - { - } - - virtual void dispose() BOOST_SP_NOEXCEPT - { - d_( p_ ); - } - - virtual void destroy() BOOST_SP_NOEXCEPT - { -#if !defined( BOOST_NO_CXX11_ALLOCATOR ) - - typedef typename std::allocator_traits<A>::template rebind_alloc< this_type > A2; - -#else - - typedef typename A::template rebind< this_type >::other A2; - -#endif - - A2 a2( a_ ); - - this->~this_type(); - - a2.deallocate( this, 1 ); - } - - virtual void * get_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT - { - return ti == BOOST_SP_TYPEID_( D )? &reinterpret_cast<char&>( d_ ): 0; - } - - virtual void * get_local_deleter( sp_typeinfo_ const & ti ) BOOST_SP_NOEXCEPT - { - return ti == BOOST_SP_TYPEID_( D )? boost::detail::get_local_deleter( boost::addressof( d_ ) ): 0; - } - - virtual void * get_untyped_deleter() BOOST_SP_NOEXCEPT - { - return &reinterpret_cast<char&>( d_ ); - } -}; - -#ifdef __CODEGUARD__ -# pragma option pop -#endif - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_IMPL_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/sp_typeinfo_.hpp b/ThirdParty/boost/smart_ptr/detail/sp_typeinfo_.hpp deleted file mode 100644 index 287bf728189d4853bd2c000b6b52d3c4799b22f6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/sp_typeinfo_.hpp +++ /dev/null @@ -1,58 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_SP_TYPEINFO_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_SP_TYPEINFO_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// smart_ptr/detail/sp_typeinfo_.hpp -// -// Copyright 2007, 2019 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_NO_TYPEID ) || defined( BOOST_NO_STD_TYPEINFO ) - -#include <boost/core/typeinfo.hpp> - -namespace boost -{ - -namespace detail -{ - -typedef boost::core::typeinfo sp_typeinfo_; - -} // namespace detail - -} // namespace boost - -#define BOOST_SP_TYPEID_(T) BOOST_CORE_TYPEID(T) - -#else // defined( BOOST_NO_TYPEID ) || defined( BOOST_NO_STD_TYPEINFO ) - -#include <typeinfo> - -namespace boost -{ - -namespace detail -{ - -typedef std::type_info sp_typeinfo_; - -} // namespace detail - -} // namespace boost - -#define BOOST_SP_TYPEID_(T) typeid(T) - -#endif // defined( BOOST_NO_TYPEID ) || defined( BOOST_NO_STD_TYPEINFO ) - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_TYPEINFO_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/detail/yield_k.hpp b/ThirdParty/boost/smart_ptr/detail/yield_k.hpp deleted file mode 100644 index fa259174bd7b5dbb31dab7072c59dae090e4e69c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/detail/yield_k.hpp +++ /dev/null @@ -1,169 +0,0 @@ -#ifndef BOOST_SMART_PTR_DETAIL_YIELD_K_HPP_INCLUDED -#define BOOST_SMART_PTR_DETAIL_YIELD_K_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// yield_k.hpp -// -// Copyright (c) 2008 Peter Dimov -// -// void yield( unsigned k ); -// -// Typical use: -// -// for( unsigned k = 0; !try_lock(); ++k ) yield( k ); -// -// 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> - -// BOOST_SMT_PAUSE - -#if defined(_MSC_VER) && _MSC_VER >= 1310 && ( defined(_M_IX86) || defined(_M_X64) ) && !defined(__c2__) - -extern "C" void _mm_pause(); - -#define BOOST_SMT_PAUSE _mm_pause(); - -#elif defined(__GNUC__) && ( defined(__i386__) || defined(__x86_64__) ) - -#define BOOST_SMT_PAUSE __asm__ __volatile__( "rep; nop" : : : "memory" ); - -#endif - -// - -#if defined( WIN32 ) || defined( _WIN32 ) || defined( __WIN32__ ) || defined( __CYGWIN__ ) - -#if defined( BOOST_USE_WINDOWS_H ) -# include <windows.h> -#endif - -namespace boost -{ - -namespace detail -{ - -#if !defined( BOOST_USE_WINDOWS_H ) - -#if defined(__clang__) && defined(__x86_64__) -// clang x64 warns that __stdcall is ignored -# define BOOST_SP_STDCALL -#else -# define BOOST_SP_STDCALL __stdcall -#endif - -#if defined(__LP64__) // Cygwin 64 - extern "C" __declspec(dllimport) void BOOST_SP_STDCALL Sleep( unsigned int ms ); -#else - extern "C" __declspec(dllimport) void BOOST_SP_STDCALL Sleep( unsigned long ms ); -#endif - -#undef BOOST_SP_STDCALL - -#endif // !defined( BOOST_USE_WINDOWS_H ) - -inline void yield( unsigned k ) BOOST_NOEXCEPT -{ - if( k < 4 ) - { - } -#if defined( BOOST_SMT_PAUSE ) - else if( k < 16 ) - { - BOOST_SMT_PAUSE - } -#endif - else if( k < 32 ) - { - Sleep( 0 ); - } - else - { - Sleep( 1 ); - } -} - -} // namespace detail - -} // namespace boost - -#elif defined( BOOST_HAS_PTHREADS ) - -#ifndef _AIX -#include <sched.h> -#else - // AIX's sched.h defines ::var which sometimes conflicts with Lambda's var - extern "C" int sched_yield(void); -#endif - -#include <time.h> - -namespace boost -{ - -namespace detail -{ - -inline void yield( unsigned k ) -{ - if( k < 4 ) - { - } -#if defined( BOOST_SMT_PAUSE ) - else if( k < 16 ) - { - BOOST_SMT_PAUSE - } -#endif - else if( k < 32 || k & 1 ) - { - sched_yield(); - } - else - { - // g++ -Wextra warns on {} or {0} - struct timespec rqtp = { 0, 0 }; - - // POSIX says that timespec has tv_sec and tv_nsec - // But it doesn't guarantee order or placement - - rqtp.tv_sec = 0; - rqtp.tv_nsec = 1000; - - nanosleep( &rqtp, 0 ); - } -} - -} // namespace detail - -} // namespace boost - -#else - -namespace boost -{ - -namespace detail -{ - -inline void yield( unsigned ) -{ -} - -} // namespace detail - -} // namespace boost - -#endif - -#endif // #ifndef BOOST_SMART_PTR_DETAIL_YIELD_K_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/intrusive_ptr.hpp b/ThirdParty/boost/smart_ptr/intrusive_ptr.hpp deleted file mode 100644 index ba23e5adfbeafdd9265b4a716602ee2efe6c38f6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/intrusive_ptr.hpp +++ /dev/null @@ -1,388 +0,0 @@ -#ifndef BOOST_SMART_PTR_INTRUSIVE_PTR_HPP_INCLUDED -#define BOOST_SMART_PTR_INTRUSIVE_PTR_HPP_INCLUDED - -// -// intrusive_ptr.hpp -// -// Copyright (c) 2001, 2002 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) -// -// See http://www.boost.org/libs/smart_ptr/ for documentation. -// - -#include <boost/config.hpp> - -#include <boost/assert.hpp> -#include <boost/config/workaround.hpp> -#include <boost/smart_ptr/detail/sp_convertible.hpp> -#include <boost/smart_ptr/detail/sp_nullptr_t.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> - -#include <boost/config/no_tr1/functional.hpp> // for std::less - -#if !defined(BOOST_NO_IOSTREAM) -#if !defined(BOOST_NO_IOSFWD) -#include <iosfwd> // for std::basic_ostream -#else -#include <ostream> -#endif -#endif - - -namespace boost -{ - -// -// intrusive_ptr -// -// A smart pointer that uses intrusive reference counting. -// -// Relies on unqualified calls to -// -// void intrusive_ptr_add_ref(T * p); -// void intrusive_ptr_release(T * p); -// -// (p != 0) -// -// The object is responsible for destroying itself. -// - -template<class T> class intrusive_ptr -{ -private: - - typedef intrusive_ptr this_type; - -public: - - typedef T element_type; - - BOOST_CONSTEXPR intrusive_ptr() BOOST_SP_NOEXCEPT : px( 0 ) - { - } - - intrusive_ptr( T * p, bool add_ref = true ): px( p ) - { - if( px != 0 && add_ref ) intrusive_ptr_add_ref( px ); - } - -#if !defined(BOOST_NO_MEMBER_TEMPLATES) || defined(BOOST_MSVC6_MEMBER_TEMPLATES) - - template<class U> -#if !defined( BOOST_SP_NO_SP_CONVERTIBLE ) - - intrusive_ptr( intrusive_ptr<U> const & rhs, typename boost::detail::sp_enable_if_convertible<U,T>::type = boost::detail::sp_empty() ) - -#else - - intrusive_ptr( intrusive_ptr<U> const & rhs ) - -#endif - : px( rhs.get() ) - { - if( px != 0 ) intrusive_ptr_add_ref( px ); - } - -#endif - - intrusive_ptr(intrusive_ptr const & rhs): px( rhs.px ) - { - if( px != 0 ) intrusive_ptr_add_ref( px ); - } - - ~intrusive_ptr() - { - if( px != 0 ) intrusive_ptr_release( px ); - } - -#if !defined(BOOST_NO_MEMBER_TEMPLATES) || defined(BOOST_MSVC6_MEMBER_TEMPLATES) - - template<class U> intrusive_ptr & operator=(intrusive_ptr<U> const & rhs) - { - this_type(rhs).swap(*this); - return *this; - } - -#endif - -// Move support - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - intrusive_ptr(intrusive_ptr && rhs) BOOST_SP_NOEXCEPT : px( rhs.px ) - { - rhs.px = 0; - } - - intrusive_ptr & operator=(intrusive_ptr && rhs) BOOST_SP_NOEXCEPT - { - this_type( static_cast< intrusive_ptr && >( rhs ) ).swap(*this); - return *this; - } - - template<class U> friend class intrusive_ptr; - - template<class U> -#if !defined( BOOST_SP_NO_SP_CONVERTIBLE ) - - intrusive_ptr(intrusive_ptr<U> && rhs, typename boost::detail::sp_enable_if_convertible<U,T>::type = boost::detail::sp_empty()) - -#else - - intrusive_ptr(intrusive_ptr<U> && rhs) - -#endif - : px( rhs.px ) - { - rhs.px = 0; - } - - template<class U> - intrusive_ptr & operator=(intrusive_ptr<U> && rhs) BOOST_SP_NOEXCEPT - { - this_type( static_cast< intrusive_ptr<U> && >( rhs ) ).swap(*this); - return *this; - } - -#endif - - intrusive_ptr & operator=(intrusive_ptr const & rhs) - { - this_type(rhs).swap(*this); - return *this; - } - - intrusive_ptr & operator=(T * rhs) - { - this_type(rhs).swap(*this); - return *this; - } - - void reset() - { - this_type().swap( *this ); - } - - void reset( T * rhs ) - { - this_type( rhs ).swap( *this ); - } - - void reset( T * rhs, bool add_ref ) - { - this_type( rhs, add_ref ).swap( *this ); - } - - T * get() const BOOST_SP_NOEXCEPT - { - return px; - } - - T * detach() BOOST_SP_NOEXCEPT - { - T * ret = px; - px = 0; - return ret; - } - - T & operator*() const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return *px; - } - - T * operator->() const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return px; - } - -// implicit conversion to "bool" -#include <boost/smart_ptr/detail/operator_bool.hpp> - - void swap(intrusive_ptr & rhs) BOOST_SP_NOEXCEPT - { - T * tmp = px; - px = rhs.px; - rhs.px = tmp; - } - -private: - - T * px; -}; - -template<class T, class U> inline bool operator==(intrusive_ptr<T> const & a, intrusive_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() == b.get(); -} - -template<class T, class U> inline bool operator!=(intrusive_ptr<T> const & a, intrusive_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() != b.get(); -} - -template<class T, class U> inline bool operator==(intrusive_ptr<T> const & a, U * b) BOOST_SP_NOEXCEPT -{ - return a.get() == b; -} - -template<class T, class U> inline bool operator!=(intrusive_ptr<T> const & a, U * b) BOOST_SP_NOEXCEPT -{ - return a.get() != b; -} - -template<class T, class U> inline bool operator==(T * a, intrusive_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a == b.get(); -} - -template<class T, class U> inline bool operator!=(T * a, intrusive_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a != b.get(); -} - -#if __GNUC__ == 2 && __GNUC_MINOR__ <= 96 - -// Resolve the ambiguity between our op!= and the one in rel_ops - -template<class T> inline bool operator!=(intrusive_ptr<T> const & a, intrusive_ptr<T> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() != b.get(); -} - -#endif - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - -template<class T> inline bool operator==( intrusive_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator==( boost::detail::sp_nullptr_t, intrusive_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator!=( intrusive_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, intrusive_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -#endif - -template<class T> inline bool operator<(intrusive_ptr<T> const & a, intrusive_ptr<T> const & b) BOOST_SP_NOEXCEPT -{ - return std::less<T *>()(a.get(), b.get()); -} - -template<class T> void swap(intrusive_ptr<T> & lhs, intrusive_ptr<T> & rhs) BOOST_SP_NOEXCEPT -{ - lhs.swap(rhs); -} - -// mem_fn support - -template<class T> T * get_pointer(intrusive_ptr<T> const & p) BOOST_SP_NOEXCEPT -{ - return p.get(); -} - -// pointer casts - -template<class T, class U> intrusive_ptr<T> static_pointer_cast(intrusive_ptr<U> const & p) -{ - return static_cast<T *>(p.get()); -} - -template<class T, class U> intrusive_ptr<T> const_pointer_cast(intrusive_ptr<U> const & p) -{ - return const_cast<T *>(p.get()); -} - -template<class T, class U> intrusive_ptr<T> dynamic_pointer_cast(intrusive_ptr<U> const & p) -{ - return dynamic_cast<T *>(p.get()); -} - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -template<class T, class U> intrusive_ptr<T> static_pointer_cast( intrusive_ptr<U> && p ) BOOST_SP_NOEXCEPT -{ - return intrusive_ptr<T>( static_cast<T*>( p.detach() ), false ); -} - -template<class T, class U> intrusive_ptr<T> const_pointer_cast( intrusive_ptr<U> && p ) BOOST_SP_NOEXCEPT -{ - return intrusive_ptr<T>( const_cast<T*>( p.detach() ), false ); -} - -template<class T, class U> intrusive_ptr<T> dynamic_pointer_cast( intrusive_ptr<U> && p ) BOOST_SP_NOEXCEPT -{ - T * p2 = dynamic_cast<T*>( p.get() ); - - intrusive_ptr<T> r( p2, false ); - - if( p2 ) p.detach(); - - return r; -} - -#endif // defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -// operator<< - -#if !defined(BOOST_NO_IOSTREAM) - -#if defined(BOOST_NO_TEMPLATED_IOSTREAMS) || ( defined(__GNUC__) && (__GNUC__ < 3) ) - -template<class Y> std::ostream & operator<< (std::ostream & os, intrusive_ptr<Y> const & p) -{ - os << p.get(); - return os; -} - -#else - -// in STLport's no-iostreams mode no iostream symbols can be used -#ifndef _STLP_NO_IOSTREAMS - -# if defined(BOOST_MSVC) && BOOST_WORKAROUND(BOOST_MSVC, < 1300 && __SGI_STL_PORT) -// MSVC6 has problems finding std::basic_ostream through the using declaration in namespace _STL -using std::basic_ostream; -template<class E, class T, class Y> basic_ostream<E, T> & operator<< (basic_ostream<E, T> & os, intrusive_ptr<Y> const & p) -# else -template<class E, class T, class Y> std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os, intrusive_ptr<Y> const & p) -# endif -{ - os << p.get(); - return os; -} - -#endif // _STLP_NO_IOSTREAMS - -#endif // __GNUC__ < 3 - -#endif // !defined(BOOST_NO_IOSTREAM) - -// hash_value - -template< class T > struct hash; - -template< class T > std::size_t hash_value( boost::intrusive_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return boost::hash< T* >()( p.get() ); -} - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_INTRUSIVE_PTR_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/make_shared_array.hpp b/ThirdParty/boost/smart_ptr/make_shared_array.hpp deleted file mode 100644 index 785eb875fc5c0fea8f62095632a2c8165ec36e2a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/make_shared_array.hpp +++ /dev/null @@ -1,66 +0,0 @@ -/* -Copyright 2012-2019 Glen Joseph Fernandes -(glenjofe@gmail.com) - -Distributed under the Boost Software License, Version 1.0. -(http://www.boost.org/LICENSE_1_0.txt) -*/ -#ifndef BOOST_SMART_PTR_MAKE_SHARED_ARRAY_HPP -#define BOOST_SMART_PTR_MAKE_SHARED_ARRAY_HPP - -#include <boost/core/default_allocator.hpp> -#include <boost/smart_ptr/allocate_shared_array.hpp> - -namespace boost { - -template<class T> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -make_shared() -{ - return boost::allocate_shared<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>()); -} - -template<class T> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -make_shared(const typename remove_extent<T>::type& value) -{ - return boost::allocate_shared<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>(), value); -} - -template<class T> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -make_shared(std::size_t size) -{ - return boost::allocate_shared<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>(), size); -} - -template<class T> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -make_shared(std::size_t size, const typename remove_extent<T>::type& value) -{ - return boost::allocate_shared<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>(), size, value); -} - -template<class T> -inline typename enable_if_<is_bounded_array<T>::value, shared_ptr<T> >::type -make_shared_noinit() -{ - return boost::allocate_shared_noinit<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>()); -} - -template<class T> -inline typename enable_if_<is_unbounded_array<T>::value, shared_ptr<T> >::type -make_shared_noinit(std::size_t size) -{ - return boost::allocate_shared_noinit<T>(boost::default_allocator<typename - detail::sp_array_element<T>::type>(), size); -} - -} /* boost */ - -#endif diff --git a/ThirdParty/boost/smart_ptr/scoped_array.hpp b/ThirdParty/boost/smart_ptr/scoped_array.hpp deleted file mode 100644 index d56112cfa05030db9e9b8464757679c6b413b7c7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/scoped_array.hpp +++ /dev/null @@ -1,132 +0,0 @@ -#ifndef BOOST_SMART_PTR_SCOPED_ARRAY_HPP_INCLUDED -#define BOOST_SMART_PTR_SCOPED_ARRAY_HPP_INCLUDED - -// (C) Copyright Greg Colvin and Beman Dawes 1998, 1999. -// Copyright (c) 2001, 2002 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) -// -// See http://www.boost.org/libs/smart_ptr/ for documentation. - -#include <boost/config.hpp> -#include <boost/assert.hpp> -#include <boost/checked_delete.hpp> -#include <boost/smart_ptr/detail/sp_nullptr_t.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> - -#include <boost/config/workaround.hpp> - -#include <cstddef> // for std::ptrdiff_t - -namespace boost -{ - -// Debug hooks - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - -void sp_array_constructor_hook(void * p); -void sp_array_destructor_hook(void * p); - -#endif - -// scoped_array extends scoped_ptr to arrays. Deletion of the array pointed to -// is guaranteed, either on destruction of the scoped_array or via an explicit -// reset(). Use shared_array or std::vector if your needs are more complex. - -template<class T> class scoped_array // noncopyable -{ -private: - - T * px; - - scoped_array(scoped_array const &); - scoped_array & operator=(scoped_array const &); - - typedef scoped_array<T> this_type; - - void operator==( scoped_array const& ) const; - void operator!=( scoped_array const& ) const; - -public: - - typedef T element_type; - - explicit scoped_array( T * p = 0 ) BOOST_SP_NOEXCEPT : px( p ) - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_array_constructor_hook( px ); -#endif - } - - ~scoped_array() BOOST_SP_NOEXCEPT - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_array_destructor_hook( px ); -#endif - boost::checked_array_delete( px ); - } - - void reset(T * p = 0) BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( p == 0 || p != px ); // catch self-reset errors - this_type(p).swap(*this); - } - - T & operator[](std::ptrdiff_t i) const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - BOOST_ASSERT( i >= 0 ); - return px[i]; - } - - T * get() const BOOST_SP_NOEXCEPT - { - return px; - } - -// implicit conversion to "bool" -#include <boost/smart_ptr/detail/operator_bool.hpp> - - void swap(scoped_array & b) BOOST_SP_NOEXCEPT - { - T * tmp = b.px; - b.px = px; - px = tmp; - } -}; - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - -template<class T> inline bool operator==( scoped_array<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator==( boost::detail::sp_nullptr_t, scoped_array<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator!=( scoped_array<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, scoped_array<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -#endif - -template<class T> inline void swap(scoped_array<T> & a, scoped_array<T> & b) BOOST_SP_NOEXCEPT -{ - a.swap(b); -} - -} // namespace boost - -#endif // #ifndef BOOST_SMART_PTR_SCOPED_ARRAY_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/scoped_ptr.hpp b/ThirdParty/boost/smart_ptr/scoped_ptr.hpp deleted file mode 100644 index 9cf9566e01196df933fc885e53d580b66ed01fd3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/scoped_ptr.hpp +++ /dev/null @@ -1,167 +0,0 @@ -#ifndef BOOST_SMART_PTR_SCOPED_PTR_HPP_INCLUDED -#define BOOST_SMART_PTR_SCOPED_PTR_HPP_INCLUDED - -// (C) Copyright Greg Colvin and Beman Dawes 1998, 1999. -// Copyright (c) 2001, 2002 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) -// -// See http://www.boost.org/libs/smart_ptr/ for documentation. - -#include <boost/config.hpp> -#include <boost/assert.hpp> -#include <boost/checked_delete.hpp> -#include <boost/smart_ptr/detail/sp_nullptr_t.hpp> -#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> -#include <boost/config/workaround.hpp> - -#ifndef BOOST_NO_AUTO_PTR -# include <memory> // for std::auto_ptr -#endif - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#endif - -namespace boost -{ - -// Debug hooks - -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - -void sp_scalar_constructor_hook(void * p); -void sp_scalar_destructor_hook(void * p); - -#endif - -// scoped_ptr mimics a built-in pointer except that it guarantees deletion -// of the object pointed to, either on destruction of the scoped_ptr or via -// an explicit reset(). scoped_ptr is a simple solution for simple needs; -// use shared_ptr or std::auto_ptr if your needs are more complex. - -template<class T> class scoped_ptr // noncopyable -{ -private: - - T * px; - - scoped_ptr(scoped_ptr const &); - scoped_ptr & operator=(scoped_ptr const &); - - typedef scoped_ptr<T> this_type; - - void operator==( scoped_ptr const& ) const; - void operator!=( scoped_ptr const& ) const; - -public: - - typedef T element_type; - - explicit scoped_ptr( T * p = 0 ) BOOST_SP_NOEXCEPT : px( p ) - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_scalar_constructor_hook( px ); -#endif - } - -#ifndef BOOST_NO_AUTO_PTR - - explicit scoped_ptr( std::auto_ptr<T> p ) BOOST_SP_NOEXCEPT : px( p.release() ) - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_scalar_constructor_hook( px ); -#endif - } - -#endif - - ~scoped_ptr() BOOST_SP_NOEXCEPT - { -#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) - boost::sp_scalar_destructor_hook( px ); -#endif - boost::checked_delete( px ); - } - - void reset(T * p = 0) BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( p == 0 || p != px ); // catch self-reset errors - this_type(p).swap(*this); - } - - T & operator*() const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return *px; - } - - T * operator->() const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return px; - } - - T * get() const BOOST_SP_NOEXCEPT - { - return px; - } - -// implicit conversion to "bool" -#include <boost/smart_ptr/detail/operator_bool.hpp> - - void swap(scoped_ptr & b) BOOST_SP_NOEXCEPT - { - T * tmp = b.px; - b.px = px; - px = tmp; - } -}; - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - -template<class T> inline bool operator==( scoped_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator==( boost::detail::sp_nullptr_t, scoped_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator!=( scoped_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, scoped_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -#endif - -template<class T> inline void swap(scoped_ptr<T> & a, scoped_ptr<T> & b) BOOST_SP_NOEXCEPT -{ - a.swap(b); -} - -// get_pointer(p) is a generic way to say p.get() - -template<class T> inline T * get_pointer(scoped_ptr<T> const & p) BOOST_SP_NOEXCEPT -{ - return p.get(); -} - -} // namespace boost - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic pop -#endif - -#endif // #ifndef BOOST_SMART_PTR_SCOPED_PTR_HPP_INCLUDED diff --git a/ThirdParty/boost/smart_ptr/shared_ptr.hpp b/ThirdParty/boost/smart_ptr/shared_ptr.hpp deleted file mode 100644 index 0405ab05819ff55e5297fd759b580f74b187571a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/smart_ptr/shared_ptr.hpp +++ /dev/null @@ -1,1191 +0,0 @@ -#ifndef BOOST_SMART_PTR_SHARED_PTR_HPP_INCLUDED -#define BOOST_SMART_PTR_SHARED_PTR_HPP_INCLUDED - -// -// shared_ptr.hpp -// -// (C) Copyright Greg Colvin and Beman Dawes 1998, 1999. -// Copyright (c) 2001-2008 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) -// -// See http://www.boost.org/libs/smart_ptr/ for documentation. -// - -#include <boost/config.hpp> // for broken compiler workarounds - -// In order to avoid circular dependencies with Boost.TR1 -// we make sure that our include of <memory> doesn't try to -// pull in the TR1 headers: that's why we use this header -// rather than including <memory> directly: -#include <boost/config/no_tr1/memory.hpp> // std::auto_ptr - -#include <boost/assert.hpp> -#include <boost/checked_delete.hpp> -#include <boost/throw_exception.hpp> -#include <boost/smart_ptr/detail/shared_count.hpp> -#include <boost/config/workaround.hpp> -#include <boost/smart_ptr/detail/sp_convertible.hpp> -#include <boost/smart_ptr/detail/sp_nullptr_t.hpp> -#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp> -#include <boost/smart_ptr/detail/sp_noexcept.hpp> - -#if !defined(BOOST_SP_NO_ATOMIC_ACCESS) -#include <boost/smart_ptr/detail/spinlock_pool.hpp> -#endif - -#include <algorithm> // for std::swap -#include <functional> // for std::less -#include <typeinfo> // for std::bad_cast -#include <cstddef> // for std::size_t - -#if !defined(BOOST_NO_IOSTREAM) -#if !defined(BOOST_NO_IOSFWD) -#include <iosfwd> // for std::basic_ostream -#else -#include <ostream> -#endif -#endif - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#endif - -namespace boost -{ - -template<class T> class shared_ptr; -template<class T> class weak_ptr; -template<class T> class enable_shared_from_this; -class enable_shared_from_raw; - -namespace movelib -{ - - template< class T, class D > class unique_ptr; - -} // namespace movelib - -namespace detail -{ - -// sp_element, element_type - -template< class T > struct sp_element -{ - typedef T type; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T > struct sp_element< T[] > -{ - typedef T type; -}; - -#if !defined( __BORLANDC__ ) || !BOOST_WORKAROUND( __BORLANDC__, < 0x600 ) - -template< class T, std::size_t N > struct sp_element< T[N] > -{ - typedef T type; -}; - -#endif - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// sp_dereference, return type of operator* - -template< class T > struct sp_dereference -{ - typedef T & type; -}; - -template<> struct sp_dereference< void > -{ - typedef void type; -}; - -#if !defined(BOOST_NO_CV_VOID_SPECIALIZATIONS) - -template<> struct sp_dereference< void const > -{ - typedef void type; -}; - -template<> struct sp_dereference< void volatile > -{ - typedef void type; -}; - -template<> struct sp_dereference< void const volatile > -{ - typedef void type; -}; - -#endif // !defined(BOOST_NO_CV_VOID_SPECIALIZATIONS) - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T > struct sp_dereference< T[] > -{ - typedef void type; -}; - -#if !defined( __BORLANDC__ ) || !BOOST_WORKAROUND( __BORLANDC__, < 0x600 ) - -template< class T, std::size_t N > struct sp_dereference< T[N] > -{ - typedef void type; -}; - -#endif - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// sp_member_access, return type of operator-> - -template< class T > struct sp_member_access -{ - typedef T * type; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T > struct sp_member_access< T[] > -{ - typedef void type; -}; - -#if !defined( __BORLANDC__ ) || !BOOST_WORKAROUND( __BORLANDC__, < 0x600 ) - -template< class T, std::size_t N > struct sp_member_access< T[N] > -{ - typedef void type; -}; - -#endif - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// sp_array_access, return type of operator[] - -template< class T > struct sp_array_access -{ - typedef void type; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T > struct sp_array_access< T[] > -{ - typedef T & type; -}; - -#if !defined( __BORLANDC__ ) || !BOOST_WORKAROUND( __BORLANDC__, < 0x600 ) - -template< class T, std::size_t N > struct sp_array_access< T[N] > -{ - typedef T & type; -}; - -#endif - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// sp_extent, for operator[] index check - -template< class T > struct sp_extent -{ - enum _vt { value = 0 }; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T, std::size_t N > struct sp_extent< T[N] > -{ - enum _vt { value = N }; -}; - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// enable_shared_from_this support - -template< class X, class Y, class T > inline void sp_enable_shared_from_this( boost::shared_ptr<X> const * ppx, Y const * py, boost::enable_shared_from_this< T > const * pe ) -{ - if( pe != 0 ) - { - pe->_internal_accept_owner( ppx, const_cast< Y* >( py ) ); - } -} - -template< class X, class Y > inline void sp_enable_shared_from_this( boost::shared_ptr<X> * ppx, Y const * py, boost::enable_shared_from_raw const * pe ); - -#ifdef _MANAGED - -// Avoid C4793, ... causes native code generation - -struct sp_any_pointer -{ - template<class T> sp_any_pointer( T* ) {} -}; - -inline void sp_enable_shared_from_this( sp_any_pointer, sp_any_pointer, sp_any_pointer ) -{ -} - -#else // _MANAGED - -inline void sp_enable_shared_from_this( ... ) -{ -} - -#endif // _MANAGED - -#if !defined( BOOST_NO_SFINAE ) && !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) && !defined( BOOST_NO_AUTO_PTR ) - -// rvalue auto_ptr support based on a technique by Dave Abrahams - -template< class T, class R > struct sp_enable_if_auto_ptr -{ -}; - -template< class T, class R > struct sp_enable_if_auto_ptr< std::auto_ptr< T >, R > -{ - typedef R type; -}; - -#endif - -// sp_assert_convertible - -template< class Y, class T > inline void sp_assert_convertible() BOOST_SP_NOEXCEPT -{ -#if !defined( BOOST_SP_NO_SP_CONVERTIBLE ) - - // static_assert( sp_convertible< Y, T >::value ); - typedef char tmp[ sp_convertible< Y, T >::value? 1: -1 ]; - (void)sizeof( tmp ); - -#else - - T* p = static_cast< Y* >( 0 ); - (void)p; - -#endif -} - -// pointer constructor helper - -template< class T, class Y > inline void sp_pointer_construct( boost::shared_ptr< T > * ppx, Y * p, boost::detail::shared_count & pn ) -{ - boost::detail::shared_count( p ).swap( pn ); - boost::detail::sp_enable_shared_from_this( ppx, p, p ); -} - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T, class Y > inline void sp_pointer_construct( boost::shared_ptr< T[] > * /*ppx*/, Y * p, boost::detail::shared_count & pn ) -{ - sp_assert_convertible< Y[], T[] >(); - boost::detail::shared_count( p, boost::checked_array_deleter< T >() ).swap( pn ); -} - -template< class T, std::size_t N, class Y > inline void sp_pointer_construct( boost::shared_ptr< T[N] > * /*ppx*/, Y * p, boost::detail::shared_count & pn ) -{ - sp_assert_convertible< Y[N], T[N] >(); - boost::detail::shared_count( p, boost::checked_array_deleter< T >() ).swap( pn ); -} - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -// deleter constructor helper - -template< class T, class Y > inline void sp_deleter_construct( boost::shared_ptr< T > * ppx, Y * p ) -{ - boost::detail::sp_enable_shared_from_this( ppx, p, p ); -} - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class T, class Y > inline void sp_deleter_construct( boost::shared_ptr< T[] > * /*ppx*/, Y * /*p*/ ) -{ - sp_assert_convertible< Y[], T[] >(); -} - -template< class T, std::size_t N, class Y > inline void sp_deleter_construct( boost::shared_ptr< T[N] > * /*ppx*/, Y * /*p*/ ) -{ - sp_assert_convertible< Y[N], T[N] >(); -} - -#endif // !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -struct sp_internal_constructor_tag -{ -}; - -} // namespace detail - - -// -// shared_ptr -// -// An enhanced relative of scoped_ptr with reference counted copy semantics. -// The object pointed to is deleted when the last shared_ptr pointing to it -// is destroyed or reset. -// - -template<class T> class shared_ptr -{ -private: - - // Borland 5.5.1 specific workaround - typedef shared_ptr<T> this_type; - -public: - - typedef typename boost::detail::sp_element< T >::type element_type; - - BOOST_CONSTEXPR shared_ptr() BOOST_SP_NOEXCEPT : px( 0 ), pn() - { - } - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - - BOOST_CONSTEXPR shared_ptr( boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT : px( 0 ), pn() - { - } - -#endif - - BOOST_CONSTEXPR shared_ptr( boost::detail::sp_internal_constructor_tag, element_type * px_, boost::detail::shared_count const & pn_ ) BOOST_SP_NOEXCEPT : px( px_ ), pn( pn_ ) - { - } - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - BOOST_CONSTEXPR shared_ptr( boost::detail::sp_internal_constructor_tag, element_type * px_, boost::detail::shared_count && pn_ ) BOOST_SP_NOEXCEPT : px( px_ ), pn( std::move( pn_ ) ) - { - } - -#endif - - template<class Y> - explicit shared_ptr( Y * p ): px( p ), pn() // Y must be complete - { - boost::detail::sp_pointer_construct( this, p, pn ); - } - - // - // Requirements: D's copy constructor must not throw - // - // shared_ptr will release p by calling d(p) - // - - template<class Y, class D> shared_ptr( Y * p, D d ): px( p ), pn( p, d ) - { - boost::detail::sp_deleter_construct( this, p ); - } - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - - template<class D> shared_ptr( boost::detail::sp_nullptr_t p, D d ): px( p ), pn( p, d ) - { - } - -#endif - - // As above, but with allocator. A's copy constructor shall not throw. - - template<class Y, class D, class A> shared_ptr( Y * p, D d, A a ): px( p ), pn( p, d, a ) - { - boost::detail::sp_deleter_construct( this, p ); - } - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - - template<class D, class A> shared_ptr( boost::detail::sp_nullptr_t p, D d, A a ): px( p ), pn( p, d, a ) - { - } - -#endif - -// generated copy constructor, destructor are fine... - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -// ... except in C++0x, move disables the implicit copy - - shared_ptr( shared_ptr const & r ) BOOST_SP_NOEXCEPT : px( r.px ), pn( r.pn ) - { - } - -#endif - - template<class Y> - explicit shared_ptr( weak_ptr<Y> const & r ): pn( r.pn ) // may throw - { - boost::detail::sp_assert_convertible< Y, T >(); - - // it is now safe to copy r.px, as pn(r.pn) did not throw - px = r.px; - } - - template<class Y> - shared_ptr( weak_ptr<Y> const & r, boost::detail::sp_nothrow_tag ) - BOOST_SP_NOEXCEPT : px( 0 ), pn( r.pn, boost::detail::sp_nothrow_tag() ) - { - if( !pn.empty() ) - { - px = r.px; - } - } - - template<class Y> -#if !defined( BOOST_SP_NO_SP_CONVERTIBLE ) - - shared_ptr( shared_ptr<Y> const & r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) - -#else - - shared_ptr( shared_ptr<Y> const & r ) - -#endif - BOOST_SP_NOEXCEPT : px( r.px ), pn( r.pn ) - { - boost::detail::sp_assert_convertible< Y, T >(); - } - - // aliasing - template< class Y > - shared_ptr( shared_ptr<Y> const & r, element_type * p ) BOOST_SP_NOEXCEPT : px( p ), pn( r.pn ) - { - } - -#ifndef BOOST_NO_AUTO_PTR - - template<class Y> - explicit shared_ptr( std::auto_ptr<Y> & r ): px(r.get()), pn() - { - boost::detail::sp_assert_convertible< Y, T >(); - - Y * tmp = r.get(); - pn = boost::detail::shared_count( r ); - - boost::detail::sp_deleter_construct( this, tmp ); - } - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - template<class Y> - shared_ptr( std::auto_ptr<Y> && r ): px(r.get()), pn() - { - boost::detail::sp_assert_convertible< Y, T >(); - - Y * tmp = r.get(); - pn = boost::detail::shared_count( r ); - - boost::detail::sp_deleter_construct( this, tmp ); - } - -#elif !defined( BOOST_NO_SFINAE ) && !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - - template<class Ap> - explicit shared_ptr( Ap r, typename boost::detail::sp_enable_if_auto_ptr<Ap, int>::type = 0 ): px( r.get() ), pn() - { - typedef typename Ap::element_type Y; - - boost::detail::sp_assert_convertible< Y, T >(); - - Y * tmp = r.get(); - pn = boost::detail::shared_count( r ); - - boost::detail::sp_deleter_construct( this, tmp ); - } - -#endif // BOOST_NO_SFINAE, BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -#endif // BOOST_NO_AUTO_PTR - -#if !defined( BOOST_NO_CXX11_SMART_PTR ) && !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - template< class Y, class D > - shared_ptr( std::unique_ptr< Y, D > && r ): px( r.get() ), pn() - { - boost::detail::sp_assert_convertible< Y, T >(); - - typename std::unique_ptr< Y, D >::pointer tmp = r.get(); - - if( tmp != 0 ) - { - pn = boost::detail::shared_count( r ); - boost::detail::sp_deleter_construct( this, tmp ); - } - } - -#endif - - template< class Y, class D > - shared_ptr( boost::movelib::unique_ptr< Y, D > r ): px( r.get() ), pn() - { - boost::detail::sp_assert_convertible< Y, T >(); - - typename boost::movelib::unique_ptr< Y, D >::pointer tmp = r.get(); - - if( tmp != 0 ) - { - pn = boost::detail::shared_count( r ); - boost::detail::sp_deleter_construct( this, tmp ); - } - } - - // assignment - - shared_ptr & operator=( shared_ptr const & r ) BOOST_SP_NOEXCEPT - { - this_type(r).swap(*this); - return *this; - } - -#if !defined(BOOST_MSVC) || (BOOST_MSVC >= 1400) - - template<class Y> - shared_ptr & operator=(shared_ptr<Y> const & r) BOOST_SP_NOEXCEPT - { - this_type(r).swap(*this); - return *this; - } - -#endif - -#ifndef BOOST_NO_AUTO_PTR - - template<class Y> - shared_ptr & operator=( std::auto_ptr<Y> & r ) - { - this_type( r ).swap( *this ); - return *this; - } - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - template<class Y> - shared_ptr & operator=( std::auto_ptr<Y> && r ) - { - this_type( static_cast< std::auto_ptr<Y> && >( r ) ).swap( *this ); - return *this; - } - -#elif !defined( BOOST_NO_SFINAE ) && !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - - template<class Ap> - typename boost::detail::sp_enable_if_auto_ptr< Ap, shared_ptr & >::type operator=( Ap r ) - { - this_type( r ).swap( *this ); - return *this; - } - -#endif // BOOST_NO_SFINAE, BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -#endif // BOOST_NO_AUTO_PTR - -#if !defined( BOOST_NO_CXX11_SMART_PTR ) && !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - template<class Y, class D> - shared_ptr & operator=( std::unique_ptr<Y, D> && r ) - { - this_type( static_cast< std::unique_ptr<Y, D> && >( r ) ).swap(*this); - return *this; - } - -#endif - - template<class Y, class D> - shared_ptr & operator=( boost::movelib::unique_ptr<Y, D> r ) - { - // this_type( static_cast< unique_ptr<Y, D> && >( r ) ).swap( *this ); - - boost::detail::sp_assert_convertible< Y, T >(); - - typename boost::movelib::unique_ptr< Y, D >::pointer p = r.get(); - - shared_ptr tmp; - - if( p != 0 ) - { - tmp.px = p; - tmp.pn = boost::detail::shared_count( r ); - - boost::detail::sp_deleter_construct( &tmp, p ); - } - - tmp.swap( *this ); - - return *this; - } - -// Move support - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - shared_ptr( shared_ptr && r ) BOOST_SP_NOEXCEPT : px( r.px ), pn() - { - pn.swap( r.pn ); - r.px = 0; - } - - template<class Y> -#if !defined( BOOST_SP_NO_SP_CONVERTIBLE ) - - shared_ptr( shared_ptr<Y> && r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) - -#else - - shared_ptr( shared_ptr<Y> && r ) - -#endif - BOOST_SP_NOEXCEPT : px( r.px ), pn() - { - boost::detail::sp_assert_convertible< Y, T >(); - - pn.swap( r.pn ); - r.px = 0; - } - - shared_ptr & operator=( shared_ptr && r ) BOOST_SP_NOEXCEPT - { - this_type( static_cast< shared_ptr && >( r ) ).swap( *this ); - return *this; - } - - template<class Y> - shared_ptr & operator=( shared_ptr<Y> && r ) BOOST_SP_NOEXCEPT - { - this_type( static_cast< shared_ptr<Y> && >( r ) ).swap( *this ); - return *this; - } - - // aliasing move - template<class Y> - shared_ptr( shared_ptr<Y> && r, element_type * p ) BOOST_SP_NOEXCEPT : px( p ), pn() - { - pn.swap( r.pn ); - r.px = 0; - } - -#endif - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - - shared_ptr & operator=( boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT - { - this_type().swap(*this); - return *this; - } - -#endif - - void reset() BOOST_SP_NOEXCEPT - { - this_type().swap(*this); - } - - template<class Y> void reset( Y * p ) // Y must be complete - { - BOOST_ASSERT( p == 0 || p != px ); // catch self-reset errors - this_type( p ).swap( *this ); - } - - template<class Y, class D> void reset( Y * p, D d ) - { - this_type( p, d ).swap( *this ); - } - - template<class Y, class D, class A> void reset( Y * p, D d, A a ) - { - this_type( p, d, a ).swap( *this ); - } - - template<class Y> void reset( shared_ptr<Y> const & r, element_type * p ) BOOST_SP_NOEXCEPT - { - this_type( r, p ).swap( *this ); - } - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - - template<class Y> void reset( shared_ptr<Y> && r, element_type * p ) BOOST_SP_NOEXCEPT - { - this_type( static_cast< shared_ptr<Y> && >( r ), p ).swap( *this ); - } - -#endif - - typename boost::detail::sp_dereference< T >::type operator* () const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return *px; - } - - typename boost::detail::sp_member_access< T >::type operator-> () const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - return px; - } - - typename boost::detail::sp_array_access< T >::type operator[] ( std::ptrdiff_t i ) const BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( px != 0 ); - BOOST_ASSERT( i >= 0 && ( i < boost::detail::sp_extent< T >::value || boost::detail::sp_extent< T >::value == 0 ) ); - - return static_cast< typename boost::detail::sp_array_access< T >::type >( px[ i ] ); - } - - element_type * get() const BOOST_SP_NOEXCEPT - { - return px; - } - -// implicit conversion to "bool" -#include <boost/smart_ptr/detail/operator_bool.hpp> - - bool unique() const BOOST_SP_NOEXCEPT - { - return pn.unique(); - } - - long use_count() const BOOST_SP_NOEXCEPT - { - return pn.use_count(); - } - - void swap( shared_ptr & other ) BOOST_SP_NOEXCEPT - { - std::swap(px, other.px); - pn.swap(other.pn); - } - - template<class Y> bool owner_before( shared_ptr<Y> const & rhs ) const BOOST_SP_NOEXCEPT - { - return pn < rhs.pn; - } - - template<class Y> bool owner_before( weak_ptr<Y> const & rhs ) const BOOST_SP_NOEXCEPT - { - return pn < rhs.pn; - } - - void * _internal_get_deleter( boost::detail::sp_typeinfo_ const & ti ) const BOOST_SP_NOEXCEPT - { - return pn.get_deleter( ti ); - } - - void * _internal_get_local_deleter( boost::detail::sp_typeinfo_ const & ti ) const BOOST_SP_NOEXCEPT - { - return pn.get_local_deleter( ti ); - } - - void * _internal_get_untyped_deleter() const BOOST_SP_NOEXCEPT - { - return pn.get_untyped_deleter(); - } - - bool _internal_equiv( shared_ptr const & r ) const BOOST_SP_NOEXCEPT - { - return px == r.px && pn == r.pn; - } - - boost::detail::shared_count _internal_count() const BOOST_SP_NOEXCEPT - { - return pn; - } - -// Tasteless as this may seem, making all members public allows member templates -// to work in the absence of member template friends. (Matthew Langston) - -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS - -private: - - template<class Y> friend class shared_ptr; - template<class Y> friend class weak_ptr; - - -#endif - - element_type * px; // contained pointer - boost::detail::shared_count pn; // reference counter - -}; // shared_ptr - -template<class T, class U> inline bool operator==(shared_ptr<T> const & a, shared_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() == b.get(); -} - -template<class T, class U> inline bool operator!=(shared_ptr<T> const & a, shared_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() != b.get(); -} - -#if __GNUC__ == 2 && __GNUC_MINOR__ <= 96 - -// Resolve the ambiguity between our op!= and the one in rel_ops - -template<class T> inline bool operator!=(shared_ptr<T> const & a, shared_ptr<T> const & b) BOOST_SP_NOEXCEPT -{ - return a.get() != b.get(); -} - -#endif - -#if !defined( BOOST_NO_CXX11_NULLPTR ) - -template<class T> inline bool operator==( shared_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator==( boost::detail::sp_nullptr_t, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() == 0; -} - -template<class T> inline bool operator!=( shared_ptr<T> const & p, boost::detail::sp_nullptr_t ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return p.get() != 0; -} - -#endif - -template<class T, class U> inline bool operator<(shared_ptr<T> const & a, shared_ptr<U> const & b) BOOST_SP_NOEXCEPT -{ - return a.owner_before( b ); -} - -template<class T> inline void swap(shared_ptr<T> & a, shared_ptr<T> & b) BOOST_SP_NOEXCEPT -{ - a.swap(b); -} - -template<class T, class U> shared_ptr<T> static_pointer_cast( shared_ptr<U> const & r ) BOOST_SP_NOEXCEPT -{ - (void) static_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = static_cast< E* >( r.get() ); - return shared_ptr<T>( r, p ); -} - -template<class T, class U> shared_ptr<T> const_pointer_cast( shared_ptr<U> const & r ) BOOST_SP_NOEXCEPT -{ - (void) const_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = const_cast< E* >( r.get() ); - return shared_ptr<T>( r, p ); -} - -template<class T, class U> shared_ptr<T> dynamic_pointer_cast( shared_ptr<U> const & r ) BOOST_SP_NOEXCEPT -{ - (void) dynamic_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = dynamic_cast< E* >( r.get() ); - return p? shared_ptr<T>( r, p ): shared_ptr<T>(); -} - -template<class T, class U> shared_ptr<T> reinterpret_pointer_cast( shared_ptr<U> const & r ) BOOST_SP_NOEXCEPT -{ - (void) reinterpret_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = reinterpret_cast< E* >( r.get() ); - return shared_ptr<T>( r, p ); -} - -#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -template<class T, class U> shared_ptr<T> static_pointer_cast( shared_ptr<U> && r ) BOOST_SP_NOEXCEPT -{ - (void) static_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = static_cast< E* >( r.get() ); - return shared_ptr<T>( std::move(r), p ); -} - -template<class T, class U> shared_ptr<T> const_pointer_cast( shared_ptr<U> && r ) BOOST_SP_NOEXCEPT -{ - (void) const_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = const_cast< E* >( r.get() ); - return shared_ptr<T>( std::move(r), p ); -} - -template<class T, class U> shared_ptr<T> dynamic_pointer_cast( shared_ptr<U> && r ) BOOST_SP_NOEXCEPT -{ - (void) dynamic_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = dynamic_cast< E* >( r.get() ); - return p? shared_ptr<T>( std::move(r), p ): shared_ptr<T>(); -} - -template<class T, class U> shared_ptr<T> reinterpret_pointer_cast( shared_ptr<U> && r ) BOOST_SP_NOEXCEPT -{ - (void) reinterpret_cast< T* >( static_cast< U* >( 0 ) ); - - typedef typename shared_ptr<T>::element_type E; - - E * p = reinterpret_cast< E* >( r.get() ); - return shared_ptr<T>( std::move(r), p ); -} - -#endif // !defined( BOOST_NO_CXX11_RVALUE_REFERENCES ) - -// get_pointer() enables boost::mem_fn to recognize shared_ptr - -template<class T> inline typename shared_ptr<T>::element_type * get_pointer(shared_ptr<T> const & p) BOOST_SP_NOEXCEPT -{ - return p.get(); -} - -// operator<< - -#if !defined(BOOST_NO_IOSTREAM) - -#if defined(BOOST_NO_TEMPLATED_IOSTREAMS) || ( defined(__GNUC__) && (__GNUC__ < 3) ) - -template<class Y> std::ostream & operator<< (std::ostream & os, shared_ptr<Y> const & p) -{ - os << p.get(); - return os; -} - -#else - -// in STLport's no-iostreams mode no iostream symbols can be used -#ifndef _STLP_NO_IOSTREAMS - -# if defined(BOOST_MSVC) && BOOST_WORKAROUND(BOOST_MSVC, < 1300 && __SGI_STL_PORT) -// MSVC6 has problems finding std::basic_ostream through the using declaration in namespace _STL -using std::basic_ostream; -template<class E, class T, class Y> basic_ostream<E, T> & operator<< (basic_ostream<E, T> & os, shared_ptr<Y> const & p) -# else -template<class E, class T, class Y> std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os, shared_ptr<Y> const & p) -# endif -{ - os << p.get(); - return os; -} - -#endif // _STLP_NO_IOSTREAMS - -#endif // __GNUC__ < 3 - -#endif // !defined(BOOST_NO_IOSTREAM) - -// get_deleter - -namespace detail -{ - -template<class D, class T> D * basic_get_deleter( shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return static_cast<D *>( p._internal_get_deleter(BOOST_SP_TYPEID_(D)) ); -} - -template<class D, class T> D * basic_get_local_deleter( D *, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT; -template<class D, class T> D const * basic_get_local_deleter( D const *, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT; - -class esft2_deleter_wrapper -{ -private: - - shared_ptr<void const volatile> deleter_; - -public: - - esft2_deleter_wrapper() BOOST_SP_NOEXCEPT - { - } - - template< class T > void set_deleter( shared_ptr<T> const & deleter ) BOOST_SP_NOEXCEPT - { - deleter_ = deleter; - } - - template<typename D> D* get_deleter() const BOOST_SP_NOEXCEPT - { - return boost::detail::basic_get_deleter<D>( deleter_ ); - } - - template< class T> void operator()( T* ) BOOST_SP_NOEXCEPT_WITH_ASSERT - { - BOOST_ASSERT( deleter_.use_count() <= 1 ); - deleter_.reset(); - } -}; - -} // namespace detail - -template<class D, class T> D * get_deleter( shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - D * d = boost::detail::basic_get_deleter<D>( p ); - - if( d == 0 ) - { - d = boost::detail::basic_get_local_deleter( d, p ); - } - - if( d == 0 ) - { - boost::detail::esft2_deleter_wrapper *del_wrapper = boost::detail::basic_get_deleter<boost::detail::esft2_deleter_wrapper>(p); -// The following get_deleter method call is fully qualified because -// older versions of gcc (2.95, 3.2.3) fail to compile it when written del_wrapper->get_deleter<D>() - if(del_wrapper) d = del_wrapper->::boost::detail::esft2_deleter_wrapper::get_deleter<D>(); - } - - return d; -} - -// atomic access - -#if !defined(BOOST_SP_NO_ATOMIC_ACCESS) - -template<class T> inline bool atomic_is_lock_free( shared_ptr<T> const * /*p*/ ) BOOST_SP_NOEXCEPT -{ - return false; -} - -template<class T> shared_ptr<T> atomic_load( shared_ptr<T> const * p ) BOOST_SP_NOEXCEPT -{ - boost::detail::spinlock_pool<2>::scoped_lock lock( p ); - return *p; -} - -template<class T, class M> inline shared_ptr<T> atomic_load_explicit( shared_ptr<T> const * p, /*memory_order mo*/ M ) BOOST_SP_NOEXCEPT -{ - return atomic_load( p ); -} - -template<class T> void atomic_store( shared_ptr<T> * p, shared_ptr<T> r ) BOOST_SP_NOEXCEPT -{ - boost::detail::spinlock_pool<2>::scoped_lock lock( p ); - p->swap( r ); -} - -template<class T, class M> inline void atomic_store_explicit( shared_ptr<T> * p, shared_ptr<T> r, /*memory_order mo*/ M ) BOOST_SP_NOEXCEPT -{ - atomic_store( p, r ); // std::move( r ) -} - -template<class T> shared_ptr<T> atomic_exchange( shared_ptr<T> * p, shared_ptr<T> r ) BOOST_SP_NOEXCEPT -{ - boost::detail::spinlock & sp = boost::detail::spinlock_pool<2>::spinlock_for( p ); - - sp.lock(); - p->swap( r ); - sp.unlock(); - - return r; // return std::move( r ) -} - -template<class T, class M> shared_ptr<T> inline atomic_exchange_explicit( shared_ptr<T> * p, shared_ptr<T> r, /*memory_order mo*/ M ) BOOST_SP_NOEXCEPT -{ - return atomic_exchange( p, r ); // std::move( r ) -} - -template<class T> bool atomic_compare_exchange( shared_ptr<T> * p, shared_ptr<T> * v, shared_ptr<T> w ) BOOST_SP_NOEXCEPT -{ - boost::detail::spinlock & sp = boost::detail::spinlock_pool<2>::spinlock_for( p ); - - sp.lock(); - - if( p->_internal_equiv( *v ) ) - { - p->swap( w ); - - sp.unlock(); - - return true; - } - else - { - shared_ptr<T> tmp( *p ); - - sp.unlock(); - - tmp.swap( *v ); - return false; - } -} - -template<class T, class M> inline bool atomic_compare_exchange_explicit( shared_ptr<T> * p, shared_ptr<T> * v, shared_ptr<T> w, /*memory_order success*/ M, /*memory_order failure*/ M ) BOOST_SP_NOEXCEPT -{ - return atomic_compare_exchange( p, v, w ); // std::move( w ) -} - -#endif // !defined(BOOST_SP_NO_ATOMIC_ACCESS) - -// hash_value - -template< class T > struct hash; - -template< class T > std::size_t hash_value( boost::shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return boost::hash< typename boost::shared_ptr<T>::element_type* >()( p.get() ); -} - -} // namespace boost - -#include <boost/smart_ptr/detail/local_sp_deleter.hpp> - -namespace boost -{ - -namespace detail -{ - -template<class D, class T> D * basic_get_local_deleter( D *, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return static_cast<D *>( p._internal_get_local_deleter( BOOST_SP_TYPEID_(local_sp_deleter<D>) ) ); -} - -template<class D, class T> D const * basic_get_local_deleter( D const *, shared_ptr<T> const & p ) BOOST_SP_NOEXCEPT -{ - return static_cast<D *>( p._internal_get_local_deleter( BOOST_SP_TYPEID_(local_sp_deleter<D>) ) ); -} - -} // namespace detail - -#if defined(__cpp_deduction_guides) - -template<class T> shared_ptr( weak_ptr<T> ) -> shared_ptr<T>; -template<class T, class D> shared_ptr( std::unique_ptr<T, D> ) -> shared_ptr<T>; - -#endif - -} // namespace boost - -#if defined( BOOST_SP_DISABLE_DEPRECATED ) -#pragma GCC diagnostic pop -#endif - -#endif // #ifndef BOOST_SMART_PTR_SHARED_PTR_HPP_INCLUDED diff --git a/ThirdParty/boost/system/detail/config.hpp b/ThirdParty/boost/system/detail/config.hpp deleted file mode 100644 index 5742a94d1403d2008e309292fe3a5d710d71702d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/system/detail/config.hpp +++ /dev/null @@ -1,51 +0,0 @@ -#ifndef BOOST_SYSTEM_DETAIL_CONFIG_HPP_INCLUDED -#define BOOST_SYSTEM_DETAIL_CONFIG_HPP_INCLUDED - -// Copyright 2018 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) -// -// See http://www.boost.org/libs/system for documentation. - -#include <boost/config.hpp> -#include <boost/config/workaround.hpp> - -// BOOST_SYSTEM_HAS_SYSTEM_ERROR - -#if !defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) -# define BOOST_SYSTEM_HAS_SYSTEM_ERROR -#endif - -#if BOOST_WORKAROUND(BOOST_GCC, < 40600) -// g++ 4.4's <map> is not good enough -# undef BOOST_SYSTEM_HAS_SYSTEM_ERROR -#endif - -#if defined(BOOST_NO_CXX11_HDR_MUTEX) -// Required for thread-safe map manipulation -# undef BOOST_SYSTEM_HAS_SYSTEM_ERROR -#endif - -// BOOST_SYSTEM_NOEXCEPT -// Retained for backward compatibility - -#define BOOST_SYSTEM_NOEXCEPT BOOST_NOEXCEPT - -// BOOST_SYSTEM_HAS_CONSTEXPR - -#if !defined(BOOST_NO_CXX14_CONSTEXPR) -# define BOOST_SYSTEM_HAS_CONSTEXPR -#endif - -#if BOOST_WORKAROUND(BOOST_GCC, < 60000) -# undef BOOST_SYSTEM_HAS_CONSTEXPR -#endif - -#if defined(BOOST_SYSTEM_HAS_CONSTEXPR) -# define BOOST_SYSTEM_CONSTEXPR constexpr -#else -# define BOOST_SYSTEM_CONSTEXPR -#endif - -#endif // BOOST_SYSTEM_DETAIL_CONFIG_HPP_INCLUDED diff --git a/ThirdParty/boost/system/detail/std_interoperability.hpp b/ThirdParty/boost/system/detail/std_interoperability.hpp deleted file mode 100644 index 30a378f5aca9c57e974884a950f8760fde997107..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/system/detail/std_interoperability.hpp +++ /dev/null @@ -1,182 +0,0 @@ -// Support for interoperability between Boost.System and <system_error> -// -// Copyright 2018 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) -// -// See library home page at http://www.boost.org/libs/system - -#include <system_error> -#include <map> -#include <memory> -#include <mutex> - -// - -namespace boost -{ - -namespace system -{ - -namespace detail -{ - -class BOOST_SYMBOL_VISIBLE std_category: public std::error_category -{ -private: - - boost::system::error_category const * pc_; - -public: - - explicit std_category( boost::system::error_category const * pc, unsigned id ): pc_( pc ) - { - if( id != 0 ) - { -#if defined(_MSC_VER) && defined(_CPPLIB_VER) && _MSC_VER >= 1900 && _MSC_VER < 2000 - - // Poking into the protected _Addr member of std::error_category - // is not a particularly good programming practice, but what can - // you do - - _Addr = id; - -#endif - } - } - - virtual const char * name() const BOOST_NOEXCEPT - { - return pc_->name(); - } - - virtual std::string message( int ev ) const - { - return pc_->message( ev ); - } - - virtual std::error_condition default_error_condition( int ev ) const BOOST_NOEXCEPT - { - return pc_->default_error_condition( ev ); - } - - virtual bool equivalent( int code, const std::error_condition & condition ) const BOOST_NOEXCEPT; - virtual bool equivalent( const std::error_code & code, int condition ) const BOOST_NOEXCEPT; -}; - -#if !defined(__SUNPRO_CC) // trailing __global is not supported -inline std::error_category const & to_std_category( boost::system::error_category const & cat ) BOOST_SYMBOL_VISIBLE; -#endif - -struct cat_ptr_less -{ - bool operator()( boost::system::error_category const * p1, boost::system::error_category const * p2 ) const BOOST_NOEXCEPT - { - return *p1 < *p2; - } -}; - -inline std::error_category const & to_std_category( boost::system::error_category const & cat ) -{ - if( cat == boost::system::system_category() ) - { - static const std_category system_instance( &cat, 0x1F4D7 ); - return system_instance; - } - else if( cat == boost::system::generic_category() ) - { - static const std_category generic_instance( &cat, 0x1F4D3 ); - return generic_instance; - } - else - { - typedef std::map< boost::system::error_category const *, std::unique_ptr<std_category>, cat_ptr_less > map_type; - - static map_type map_; - static std::mutex map_mx_; - - std::lock_guard<std::mutex> guard( map_mx_ ); - - map_type::iterator i = map_.find( &cat ); - - if( i == map_.end() ) - { - std::unique_ptr<std_category> p( new std_category( &cat, 0 ) ); - - std::pair<map_type::iterator, bool> r = map_.insert( map_type::value_type( &cat, std::move( p ) ) ); - - i = r.first; - } - - return *i->second; - } -} - -inline bool std_category::equivalent( int code, const std::error_condition & condition ) const BOOST_NOEXCEPT -{ - if( condition.category() == *this ) - { - boost::system::error_condition bn( condition.value(), *pc_ ); - return pc_->equivalent( code, bn ); - } - else if( condition.category() == std::generic_category() || condition.category() == boost::system::generic_category() ) - { - boost::system::error_condition bn( condition.value(), boost::system::generic_category() ); - return pc_->equivalent( code, bn ); - } - -#ifndef BOOST_NO_RTTI - - else if( std_category const* pc2 = dynamic_cast< std_category const* >( &condition.category() ) ) - { - boost::system::error_condition bn( condition.value(), *pc2->pc_ ); - return pc_->equivalent( code, bn ); - } - -#endif - - else - { - return default_error_condition( code ) == condition; - } -} - -inline bool std_category::equivalent( const std::error_code & code, int condition ) const BOOST_NOEXCEPT -{ - if( code.category() == *this ) - { - boost::system::error_code bc( code.value(), *pc_ ); - return pc_->equivalent( bc, condition ); - } - else if( code.category() == std::generic_category() || code.category() == boost::system::generic_category() ) - { - boost::system::error_code bc( code.value(), boost::system::generic_category() ); - return pc_->equivalent( bc, condition ); - } - -#ifndef BOOST_NO_RTTI - - else if( std_category const* pc2 = dynamic_cast< std_category const* >( &code.category() ) ) - { - boost::system::error_code bc( code.value(), *pc2->pc_ ); - return pc_->equivalent( bc, condition ); - } -#endif - - else if( *pc_ == boost::system::generic_category() ) - { - return std::generic_category().equivalent( code, condition ); - } - else - { - return false; - } -} - -} // namespace detail - -} // namespace system - -} // namespace boost diff --git a/ThirdParty/boost/system/detail/system_category_win32.hpp b/ThirdParty/boost/system/detail/system_category_win32.hpp deleted file mode 100644 index da256e1d705debc1a97aa66c2926bc28ddbfbca8..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/system/detail/system_category_win32.hpp +++ /dev/null @@ -1,341 +0,0 @@ -// Windows implementation of system_error_category -// -// Copyright Beman Dawes 2002, 2006 -// Copyright (c) Microsoft Corporation 2014 -// Copyright 2018 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) -// -// See library home page at http://www.boost.org/libs/system - -#include <boost/winapi/error_codes.hpp> -#include <boost/winapi/error_handling.hpp> -#include <boost/winapi/character_code_conversion.hpp> -#include <boost/winapi/local_memory.hpp> -#include <cstdio> - -// - -namespace boost -{ - -namespace system -{ - -namespace detail -{ - -#if ( defined(_MSC_VER) && _MSC_VER < 1900 ) || ( defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) ) - -inline char const * unknown_message_win32( int ev, char * buffer, std::size_t len ) -{ -# if defined( BOOST_MSVC ) -# pragma warning( push ) -# pragma warning( disable: 4996 ) -# endif - - _snprintf( buffer, len - 1, "Unknown error (%d)", ev ); - - buffer[ len - 1 ] = 0; - return buffer; - -# if defined( BOOST_MSVC ) -# pragma warning( pop ) -# endif -} - -#else - -inline char const * unknown_message_win32( int ev, char * buffer, std::size_t len ) -{ - std::snprintf( buffer, len, "Unknown error (%d)", ev ); - return buffer; -} - -#endif - -inline boost::winapi::UINT_ message_cp_win32() -{ -#if defined(BOOST_SYSTEM_USE_UTF8) - - return boost::winapi::CP_UTF8_; - -#else - - return boost::winapi::CP_ACP_; - -#endif -} - -inline char const * system_category_message_win32( int ev, char * buffer, std::size_t len ) BOOST_NOEXCEPT -{ - if( len == 0 ) - { - return buffer; - } - - if( len == 1 ) - { - buffer[0] = 0; - return buffer; - } - - boost::winapi::UINT_ const code_page = message_cp_win32(); - - int r = 0; - -#if !defined(BOOST_NO_ANSI_APIS) - - if( code_page == boost::winapi::CP_ACP_ ) - { - using namespace boost::winapi; - - DWORD_ retval = boost::winapi::FormatMessageA( - FORMAT_MESSAGE_FROM_SYSTEM_ | FORMAT_MESSAGE_IGNORE_INSERTS_, - NULL, - ev, - MAKELANGID_( LANG_NEUTRAL_, SUBLANG_DEFAULT_ ), // Default language - buffer, - static_cast<DWORD_>( len ), - NULL - ); - - r = static_cast<int>( retval ); - } - else - -#endif - - { - using namespace boost::winapi; - - wchar_t * lpMsgBuf = 0; - - DWORD_ retval = boost::winapi::FormatMessageW( - FORMAT_MESSAGE_ALLOCATE_BUFFER_ | FORMAT_MESSAGE_FROM_SYSTEM_ | FORMAT_MESSAGE_IGNORE_INSERTS_, - NULL, - ev, - MAKELANGID_( LANG_NEUTRAL_, SUBLANG_DEFAULT_ ), // Default language - (LPWSTR_) &lpMsgBuf, - 0, - NULL - ); - - if( retval != 0 ) - { - r = boost::winapi::WideCharToMultiByte( code_page, 0, lpMsgBuf, -1, buffer, static_cast<int>( len ), NULL, NULL ); - boost::winapi::LocalFree( lpMsgBuf ); - if ( r != 0 ) --r; // exclude null terminator - } - } - - if( r == 0 ) - { - return unknown_message_win32( ev, buffer, len ); - } - - while( r > 0 && ( buffer[ r-1 ] == '\n' || buffer[ r-1 ] == '\r' ) ) - { - buffer[ --r ] = 0; - } - - if( r > 0 && buffer[ r-1 ] == '.' ) - { - buffer[ --r ] = 0; - } - - return buffer; -} - -struct local_free -{ - void * p_; - - ~local_free() - { - boost::winapi::LocalFree( p_ ); - } -}; - -inline std::string unknown_message_win32( int ev ) -{ - char buffer[ 38 ]; - return unknown_message_win32( ev, buffer, sizeof( buffer ) ); -} - -inline std::string system_category_message_win32( int ev ) -{ - using namespace boost::winapi; - - wchar_t * lpMsgBuf = 0; - - DWORD_ retval = boost::winapi::FormatMessageW( - FORMAT_MESSAGE_ALLOCATE_BUFFER_ | FORMAT_MESSAGE_FROM_SYSTEM_ | FORMAT_MESSAGE_IGNORE_INSERTS_, - NULL, - ev, - MAKELANGID_( LANG_NEUTRAL_, SUBLANG_DEFAULT_ ), // Default language - (LPWSTR_) &lpMsgBuf, - 0, - NULL - ); - - if( retval == 0 ) - { - return unknown_message_win32( ev ); - } - - local_free lf_ = { lpMsgBuf }; - (void)lf_; - - UINT_ const code_page = message_cp_win32(); - - int r = boost::winapi::WideCharToMultiByte( code_page, 0, lpMsgBuf, -1, 0, 0, NULL, NULL ); - - if( r == 0 ) - { - return unknown_message_win32( ev ); - } - - std::string buffer( r, char() ); - - r = boost::winapi::WideCharToMultiByte( code_page, 0, lpMsgBuf, -1, &buffer[0], r, NULL, NULL ); - - if( r == 0 ) - { - return unknown_message_win32( ev ); - } - - --r; // exclude null terminator - - while( r > 0 && ( buffer[ r-1 ] == '\n' || buffer[ r-1 ] == '\r' ) ) - { - --r; - } - - if( r > 0 && buffer[ r-1 ] == '.' ) - { - --r; - } - - buffer.resize( r ); - - return buffer; -} - -inline error_condition system_category_default_error_condition_win32( int ev ) BOOST_NOEXCEPT -{ - // When using the Windows Runtime, most system errors are reported as HRESULTs. - // We want to map the common Win32 errors to their equivalent error condition, - // whether or not they are reported via an HRESULT. - -#define BOOST_SYSTEM_FAILED(hr) ((hr) < 0) -#define BOOST_SYSTEM_HRESULT_FACILITY(hr) (((hr) >> 16) & 0x1fff) -#define BOOST_SYSTEM_HRESULT_CODE(hr) ((hr) & 0xFFFF) -#define BOOST_SYSTEM_FACILITY_WIN32 7 - - if( BOOST_SYSTEM_FAILED( ev ) && BOOST_SYSTEM_HRESULT_FACILITY( ev ) == BOOST_SYSTEM_FACILITY_WIN32 ) - { - ev = BOOST_SYSTEM_HRESULT_CODE( ev ); - } - -#undef BOOST_SYSTEM_FAILED -#undef BOOST_SYSTEM_HRESULT_FACILITY -#undef BOOST_SYSTEM_HRESULT_CODE -#undef BOOST_SYSTEM_FACILITY_WIN32 - - using namespace boost::winapi; - using namespace errc; - - // Windows system -> posix_errno decode table - // see WinError.h comments for descriptions of errors - - switch ( ev ) - { - case 0: return make_error_condition( success ); - - case ERROR_ACCESS_DENIED_: return make_error_condition( permission_denied ); - case ERROR_ALREADY_EXISTS_: return make_error_condition( file_exists ); - case ERROR_BAD_UNIT_: return make_error_condition( no_such_device ); - case ERROR_BUFFER_OVERFLOW_: return make_error_condition( filename_too_long ); - case ERROR_BUSY_: return make_error_condition( device_or_resource_busy ); - case ERROR_BUSY_DRIVE_: return make_error_condition( device_or_resource_busy ); - case ERROR_CANNOT_MAKE_: return make_error_condition( permission_denied ); - case ERROR_CANTOPEN_: return make_error_condition( io_error ); - case ERROR_CANTREAD_: return make_error_condition( io_error ); - case ERROR_CANTWRITE_: return make_error_condition( io_error ); - case ERROR_CONNECTION_ABORTED_: return make_error_condition( connection_aborted ); - case ERROR_CURRENT_DIRECTORY_: return make_error_condition( permission_denied ); - case ERROR_DEV_NOT_EXIST_: return make_error_condition( no_such_device ); - case ERROR_DEVICE_IN_USE_: return make_error_condition( device_or_resource_busy ); - case ERROR_DIR_NOT_EMPTY_: return make_error_condition( directory_not_empty ); - case ERROR_DIRECTORY_: return make_error_condition( invalid_argument ); // WinError.h: "The directory name is invalid" - case ERROR_DISK_FULL_: return make_error_condition( no_space_on_device ); - case ERROR_FILE_EXISTS_: return make_error_condition( file_exists ); - case ERROR_FILE_NOT_FOUND_: return make_error_condition( no_such_file_or_directory ); - case ERROR_HANDLE_DISK_FULL_: return make_error_condition( no_space_on_device ); - case ERROR_INVALID_ACCESS_: return make_error_condition( permission_denied ); - case ERROR_INVALID_DRIVE_: return make_error_condition( no_such_device ); - case ERROR_INVALID_FUNCTION_: return make_error_condition( function_not_supported ); - case ERROR_INVALID_HANDLE_: return make_error_condition( invalid_argument ); - case ERROR_INVALID_NAME_: return make_error_condition( invalid_argument ); - case ERROR_LOCK_VIOLATION_: return make_error_condition( no_lock_available ); - case ERROR_LOCKED_: return make_error_condition( no_lock_available ); - case ERROR_NEGATIVE_SEEK_: return make_error_condition( invalid_argument ); - case ERROR_NOACCESS_: return make_error_condition( permission_denied ); - case ERROR_NOT_ENOUGH_MEMORY_: return make_error_condition( not_enough_memory ); - case ERROR_NOT_READY_: return make_error_condition( resource_unavailable_try_again ); - case ERROR_NOT_SAME_DEVICE_: return make_error_condition( cross_device_link ); - case ERROR_OPEN_FAILED_: return make_error_condition( io_error ); - case ERROR_OPEN_FILES_: return make_error_condition( device_or_resource_busy ); - case ERROR_OPERATION_ABORTED_: return make_error_condition( operation_canceled ); - case ERROR_OUTOFMEMORY_: return make_error_condition( not_enough_memory ); - case ERROR_PATH_NOT_FOUND_: return make_error_condition( no_such_file_or_directory ); - case ERROR_READ_FAULT_: return make_error_condition( io_error ); - case ERROR_RETRY_: return make_error_condition( resource_unavailable_try_again ); - case ERROR_SEEK_: return make_error_condition( io_error ); - case ERROR_SHARING_VIOLATION_: return make_error_condition( permission_denied ); - case ERROR_TOO_MANY_OPEN_FILES_: return make_error_condition( too_many_files_open ); - case ERROR_WRITE_FAULT_: return make_error_condition( io_error ); - case ERROR_WRITE_PROTECT_: return make_error_condition( permission_denied ); - case WSAEACCES_: return make_error_condition( permission_denied ); - case WSAEADDRINUSE_: return make_error_condition( address_in_use ); - case WSAEADDRNOTAVAIL_: return make_error_condition( address_not_available ); - case WSAEAFNOSUPPORT_: return make_error_condition( address_family_not_supported ); - case WSAEALREADY_: return make_error_condition( connection_already_in_progress ); - case WSAEBADF_: return make_error_condition( bad_file_descriptor ); - case WSAECONNABORTED_: return make_error_condition( connection_aborted ); - case WSAECONNREFUSED_: return make_error_condition( connection_refused ); - case WSAECONNRESET_: return make_error_condition( connection_reset ); - case WSAEDESTADDRREQ_: return make_error_condition( destination_address_required ); - case WSAEFAULT_: return make_error_condition( bad_address ); - case WSAEHOSTUNREACH_: return make_error_condition( host_unreachable ); - case WSAEINPROGRESS_: return make_error_condition( operation_in_progress ); - case WSAEINTR_: return make_error_condition( interrupted ); - case WSAEINVAL_: return make_error_condition( invalid_argument ); - case WSAEISCONN_: return make_error_condition( already_connected ); - case WSAEMFILE_: return make_error_condition( too_many_files_open ); - case WSAEMSGSIZE_: return make_error_condition( message_size ); - case WSAENAMETOOLONG_: return make_error_condition( filename_too_long ); - case WSAENETDOWN_: return make_error_condition( network_down ); - case WSAENETRESET_: return make_error_condition( network_reset ); - case WSAENETUNREACH_: return make_error_condition( network_unreachable ); - case WSAENOBUFS_: return make_error_condition( no_buffer_space ); - case WSAENOPROTOOPT_: return make_error_condition( no_protocol_option ); - case WSAENOTCONN_: return make_error_condition( not_connected ); - case WSAENOTSOCK_: return make_error_condition( not_a_socket ); - case WSAEOPNOTSUPP_: return make_error_condition( operation_not_supported ); - case WSAEPROTONOSUPPORT_: return make_error_condition( protocol_not_supported ); - case WSAEPROTOTYPE_: return make_error_condition( wrong_protocol_type ); - case WSAETIMEDOUT_: return make_error_condition( timed_out ); - case WSAEWOULDBLOCK_: return make_error_condition( operation_would_block ); - - default: return error_condition( ev, system_category() ); - } -} - -} // namespace detail - -} // namespace system - -} // namespace boost diff --git a/ThirdParty/boost/system/error_code.hpp b/ThirdParty/boost/system/error_code.hpp deleted file mode 100644 index df80592ea0c097664708b07cb963dedc35e59e69..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/system/error_code.hpp +++ /dev/null @@ -1,972 +0,0 @@ -#ifndef BOOST_SYSTEM_ERROR_CODE_HPP_INCLUDED -#define BOOST_SYSTEM_ERROR_CODE_HPP_INCLUDED - -// Copyright Beman Dawes 2006, 2007 -// Copyright Christoper Kohlhoff 2007 -// Copyright Peter Dimov 2017, 2018 -// -// 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) -// -// See library home page at http://www.boost.org/libs/system - -#include <boost/system/api_config.hpp> -#include <boost/system/detail/config.hpp> -#include <boost/cstdint.hpp> -#include <boost/config.hpp> -#include <ostream> -#include <string> -#include <functional> -#include <cstring> - -// TODO: undef these macros if not already defined -#include <boost/cerrno.hpp> - -#if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) -# include <system_error> -#endif - -#if !defined(BOOST_POSIX_API) && !defined(BOOST_WINDOWS_API) -# error BOOST_POSIX_API or BOOST_WINDOWS_API must be defined -#endif - -namespace boost -{ - -namespace system -{ - -class error_code; // values defined by the operating system -class error_condition; // portable generic values defined below, but ultimately - // based on the POSIX standard - -// "Concept" helpers - -template<class T> struct is_error_code_enum -{ - static const bool value = false; -}; - -template<class T> struct is_error_condition_enum -{ - static const bool value = false; -}; - -// Generic error_conditions - -namespace errc -{ - -enum errc_t -{ - success = 0, - address_family_not_supported = EAFNOSUPPORT, - address_in_use = EADDRINUSE, - address_not_available = EADDRNOTAVAIL, - already_connected = EISCONN, - argument_list_too_long = E2BIG, - argument_out_of_domain = EDOM, - bad_address = EFAULT, - bad_file_descriptor = EBADF, - bad_message = EBADMSG, - broken_pipe = EPIPE, - connection_aborted = ECONNABORTED, - connection_already_in_progress = EALREADY, - connection_refused = ECONNREFUSED, - connection_reset = ECONNRESET, - cross_device_link = EXDEV, - destination_address_required = EDESTADDRREQ, - device_or_resource_busy = EBUSY, - directory_not_empty = ENOTEMPTY, - executable_format_error = ENOEXEC, - file_exists = EEXIST, - file_too_large = EFBIG, - filename_too_long = ENAMETOOLONG, - function_not_supported = ENOSYS, - host_unreachable = EHOSTUNREACH, - identifier_removed = EIDRM, - illegal_byte_sequence = EILSEQ, - inappropriate_io_control_operation = ENOTTY, - interrupted = EINTR, - invalid_argument = EINVAL, - invalid_seek = ESPIPE, - io_error = EIO, - is_a_directory = EISDIR, - message_size = EMSGSIZE, - network_down = ENETDOWN, - network_reset = ENETRESET, - network_unreachable = ENETUNREACH, - no_buffer_space = ENOBUFS, - no_child_process = ECHILD, - no_link = ENOLINK, - no_lock_available = ENOLCK, - no_message_available = ENODATA, - no_message = ENOMSG, - no_protocol_option = ENOPROTOOPT, - no_space_on_device = ENOSPC, - no_stream_resources = ENOSR, - no_such_device_or_address = ENXIO, - no_such_device = ENODEV, - no_such_file_or_directory = ENOENT, - no_such_process = ESRCH, - not_a_directory = ENOTDIR, - not_a_socket = ENOTSOCK, - not_a_stream = ENOSTR, - not_connected = ENOTCONN, - not_enough_memory = ENOMEM, - not_supported = ENOTSUP, - operation_canceled = ECANCELED, - operation_in_progress = EINPROGRESS, - operation_not_permitted = EPERM, - operation_not_supported = EOPNOTSUPP, - operation_would_block = EWOULDBLOCK, - owner_dead = EOWNERDEAD, - permission_denied = EACCES, - protocol_error = EPROTO, - protocol_not_supported = EPROTONOSUPPORT, - read_only_file_system = EROFS, - resource_deadlock_would_occur = EDEADLK, - resource_unavailable_try_again = EAGAIN, - result_out_of_range = ERANGE, - state_not_recoverable = ENOTRECOVERABLE, - stream_timeout = ETIME, - text_file_busy = ETXTBSY, - timed_out = ETIMEDOUT, - too_many_files_open_in_system = ENFILE, - too_many_files_open = EMFILE, - too_many_links = EMLINK, - too_many_symbolic_link_levels = ELOOP, - value_too_large = EOVERFLOW, - wrong_protocol_type = EPROTOTYPE -}; - -} // namespace errc - -#ifdef BOOST_SYSTEM_ENABLE_DEPRECATED - -namespace posix = errc; -namespace posix_error = errc; - -#endif - -template<> struct is_error_condition_enum<errc::errc_t> -{ - static const bool value = true; -}; - -// class error_category -#if ( defined( BOOST_GCC ) && BOOST_GCC >= 40600 ) || defined( BOOST_CLANG ) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wnon-virtual-dtor" -#endif - -#ifdef BOOST_MSVC -#pragma warning( push ) -// 'this' : used in base member initializer list -#pragma warning( disable: 4355 ) -#endif - -std::size_t hash_value( error_code const & ec ); - -class BOOST_SYMBOL_VISIBLE error_category -{ -private: - - friend std::size_t hash_value( error_code const & ec ); - -#if !defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) -public: - - error_category( error_category const & ) = delete; - error_category& operator=( error_category const & ) = delete; - -#else -private: - - error_category( error_category const & ); - error_category& operator=( error_category const & ); - -#endif - -private: - - boost::ulong_long_type id_; - -protected: - -#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) && !defined(BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS) - - ~error_category() = default; - -#else - - // We'd like to make the destructor protected, to make code that deletes - // an error_category* not compile; unfortunately, doing the below makes - // the destructor user-provided and hence breaks use after main, as the - // categories may get destroyed before code that uses them - - // ~error_category() {} - -#endif - - BOOST_SYSTEM_CONSTEXPR error_category() BOOST_NOEXCEPT: id_( 0 ) - { - } - - explicit BOOST_SYSTEM_CONSTEXPR error_category( boost::ulong_long_type id ) BOOST_NOEXCEPT: id_( id ) - { - } - -public: - - virtual const char * name() const BOOST_NOEXCEPT = 0; - - virtual error_condition default_error_condition( int ev ) const BOOST_NOEXCEPT; - virtual bool equivalent( int code, const error_condition & condition ) const BOOST_NOEXCEPT; - virtual bool equivalent( const error_code & code, int condition ) const BOOST_NOEXCEPT; - - virtual std::string message( int ev ) const = 0; - virtual char const * message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT; - - virtual bool failed( int ev ) const BOOST_NOEXCEPT; - - BOOST_SYSTEM_CONSTEXPR bool operator==( const error_category & rhs ) const BOOST_NOEXCEPT - { - return rhs.id_ == 0? this == &rhs: id_ == rhs.id_; - } - - BOOST_SYSTEM_CONSTEXPR bool operator!=( const error_category & rhs ) const BOOST_NOEXCEPT - { - return !( *this == rhs ); - } - - BOOST_SYSTEM_CONSTEXPR bool operator<( const error_category & rhs ) const BOOST_NOEXCEPT - { - if( id_ < rhs.id_ ) - { - return true; - } - - if( id_ > rhs.id_ ) - { - return false; - } - - if( rhs.id_ != 0 ) - { - return false; // equal - } - - return std::less<error_category const *>()( this, &rhs ); - } - -#if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) - - operator std::error_category const & () const; - -#endif -}; - -#ifdef BOOST_MSVC -#pragma warning( pop ) -#endif - -// predefined error categories - -namespace detail -{ - -class BOOST_SYMBOL_VISIBLE generic_error_category: public error_category -{ -public: - - // clang++ 3.8 and below: initialization of const object - // requires a user-provided default constructor - BOOST_SYSTEM_CONSTEXPR generic_error_category() BOOST_NOEXCEPT: - error_category( ( boost::ulong_long_type( 0xB2AB117A ) << 32 ) + 0x257EDF0D ) - { - } - - const char * name() const BOOST_NOEXCEPT - { - return "generic"; - } - - std::string message( int ev ) const; - char const * message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT; -}; - -class BOOST_SYMBOL_VISIBLE system_error_category: public error_category -{ -public: - - BOOST_SYSTEM_CONSTEXPR system_error_category() BOOST_NOEXCEPT: - error_category( ( boost::ulong_long_type( 0x8FAFD21E ) << 32 ) + 0x25C5E09B ) - { - } - - const char * name() const BOOST_NOEXCEPT - { - return "system"; - } - - error_condition default_error_condition( int ev ) const BOOST_NOEXCEPT; - - std::string message( int ev ) const; - char const * message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT; -}; - -} // namespace detail - -#if ( defined( BOOST_GCC ) && BOOST_GCC >= 40600 ) || defined( BOOST_CLANG ) -#pragma GCC diagnostic pop -#endif - -// generic_category(), system_category() - -#if defined(BOOST_SYSTEM_HAS_CONSTEXPR) - -namespace detail -{ - -template<class T> struct BOOST_SYMBOL_VISIBLE cat_holder -{ - static constexpr system_error_category system_category_instance{}; - static constexpr generic_error_category generic_category_instance{}; -}; - -// Before C++17 it was mandatory to redeclare all static constexpr -#if defined(BOOST_NO_CXX17_INLINE_VARIABLES) -template<class T> constexpr system_error_category cat_holder<T>::system_category_instance; -template<class T> constexpr generic_error_category cat_holder<T>::generic_category_instance; -#endif - -} // namespace detail - -constexpr error_category const & system_category() BOOST_NOEXCEPT -{ - return detail::cat_holder<void>::system_category_instance; -} - -constexpr error_category const & generic_category() BOOST_NOEXCEPT -{ - return detail::cat_holder<void>::generic_category_instance; -} - -#else // #if defined(BOOST_SYSTEM_HAS_CONSTEXPR) - -#if !defined(__SUNPRO_CC) // trailing __global is not supported -inline error_category const & system_category() BOOST_NOEXCEPT BOOST_SYMBOL_VISIBLE; -inline error_category const & generic_category() BOOST_NOEXCEPT BOOST_SYMBOL_VISIBLE; -#endif - -inline error_category const & system_category() BOOST_NOEXCEPT -{ - static const detail::system_error_category system_category_instance; - return system_category_instance; -} - -inline error_category const & generic_category() BOOST_NOEXCEPT -{ - static const detail::generic_error_category generic_category_instance; - return generic_category_instance; -} - -#endif // #if defined(BOOST_SYSTEM_HAS_CONSTEXPR) - -// deprecated synonyms - -#ifdef BOOST_SYSTEM_ENABLE_DEPRECATED - -inline const error_category & get_system_category() { return system_category(); } -inline const error_category & get_generic_category() { return generic_category(); } -inline const error_category & get_posix_category() { return generic_category(); } -static const error_category & posix_category BOOST_ATTRIBUTE_UNUSED = generic_category(); -static const error_category & errno_ecat BOOST_ATTRIBUTE_UNUSED = generic_category(); -static const error_category & native_ecat BOOST_ATTRIBUTE_UNUSED = system_category(); - -#endif - -// enable_if - -namespace detail -{ - -template<bool C, class T = void> struct enable_if -{ - typedef T type; -}; - -template<class T> struct enable_if<false, T> -{ -}; - -// failed_impl - -#if !defined(BOOST_SYSTEM_HAS_CONSTEXPR) - -inline bool failed_impl( int ev, error_category const & cat ) -{ - return cat.failed( ev ); -} - -#else - -BOOST_SYSTEM_CONSTEXPR inline bool failed_impl( int ev, error_category const & cat ) -{ - if( cat == system_category() || cat == generic_category() ) - { - return ev != 0; - } - else - { - return cat.failed( ev ); - } -} - -#endif - -} // namespace detail - -// class error_condition - -// error_conditions are portable, error_codes are system or library specific - -class error_condition -{ -private: - - int val_; - bool failed_; - error_category const * cat_; - -public: - - // constructors: - - BOOST_SYSTEM_CONSTEXPR error_condition() BOOST_NOEXCEPT: - val_( 0 ), failed_( false ), cat_( &generic_category() ) - { - } - - BOOST_SYSTEM_CONSTEXPR error_condition( int val, const error_category & cat ) BOOST_NOEXCEPT: - val_( val ), failed_( detail::failed_impl( val, cat ) ), cat_( &cat ) - { - } - - template<class ErrorConditionEnum> BOOST_SYSTEM_CONSTEXPR error_condition( ErrorConditionEnum e, - typename detail::enable_if<is_error_condition_enum<ErrorConditionEnum>::value>::type* = 0) BOOST_NOEXCEPT - { - *this = make_error_condition( e ); - } - - // modifiers: - - BOOST_SYSTEM_CONSTEXPR void assign( int val, const error_category & cat ) BOOST_NOEXCEPT - { - val_ = val; - failed_ = detail::failed_impl( val, cat ); - cat_ = &cat; - } - - template<typename ErrorConditionEnum> - BOOST_SYSTEM_CONSTEXPR typename detail::enable_if<is_error_condition_enum<ErrorConditionEnum>::value, error_condition>::type & - operator=( ErrorConditionEnum val ) BOOST_NOEXCEPT - { - *this = make_error_condition( val ); - return *this; - } - - BOOST_SYSTEM_CONSTEXPR void clear() BOOST_NOEXCEPT - { - val_ = 0; - failed_ = false; - cat_ = &generic_category(); - } - - // observers: - - BOOST_SYSTEM_CONSTEXPR int value() const BOOST_NOEXCEPT - { - return val_; - } - - BOOST_SYSTEM_CONSTEXPR const error_category & category() const BOOST_NOEXCEPT - { - return *cat_; - } - - std::string message() const - { - return cat_->message( value() ); - } - - char const * message( char * buffer, std::size_t len ) const BOOST_NOEXCEPT - { - return cat_->message( value(), buffer, len ); - } - - BOOST_SYSTEM_CONSTEXPR bool failed() const BOOST_NOEXCEPT - { - return failed_; - } - -#if !defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) - - BOOST_SYSTEM_CONSTEXPR explicit operator bool() const BOOST_NOEXCEPT // true if error - { - return val_ != 0; - } - -#else - - typedef void (*unspecified_bool_type)(); - static void unspecified_bool_true() {} - - BOOST_SYSTEM_CONSTEXPR operator unspecified_bool_type() const BOOST_NOEXCEPT // true if error - { - return val_ != 0? unspecified_bool_true: 0; - } - - BOOST_SYSTEM_CONSTEXPR bool operator!() const BOOST_NOEXCEPT // true if no error - { - return val_ == 0; - } - -#endif - - // relationals: - // the more symmetrical non-member syntax allows enum - // conversions work for both rhs and lhs. - - BOOST_SYSTEM_CONSTEXPR inline friend bool operator==( const error_condition & lhs, const error_condition & rhs ) BOOST_NOEXCEPT - { - return lhs.val_ == rhs.val_ && *lhs.cat_ == *rhs.cat_; - } - - BOOST_SYSTEM_CONSTEXPR inline friend bool operator<( const error_condition & lhs, const error_condition & rhs ) BOOST_NOEXCEPT - { - return *lhs.cat_ < *rhs.cat_ || ( *lhs.cat_ == *rhs.cat_ && lhs.val_ < rhs.val_ ); - } - -#if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) - - operator std::error_condition () const - { - return std::error_condition( value(), category() ); - } - -#endif -}; - -// class error_code - -// We want error_code to be a value type that can be copied without slicing -// and without requiring heap allocation, but we also want it to have -// polymorphic behavior based on the error category. This is achieved by -// abstract base class error_category supplying the polymorphic behavior, -// and error_code containing a pointer to an object of a type derived -// from error_category. - -class error_code -{ -private: - - int val_; - bool failed_; - const error_category * cat_; - -public: - - // constructors: - - BOOST_SYSTEM_CONSTEXPR error_code() BOOST_NOEXCEPT: - val_( 0 ), failed_( false ), cat_( &system_category() ) - { - } - - BOOST_SYSTEM_CONSTEXPR error_code( int val, const error_category & cat ) BOOST_NOEXCEPT: - val_( val ), failed_( detail::failed_impl( val, cat ) ), cat_( &cat ) - { - } - - template<class ErrorCodeEnum> BOOST_SYSTEM_CONSTEXPR error_code( ErrorCodeEnum e, - typename detail::enable_if<is_error_code_enum<ErrorCodeEnum>::value>::type* = 0 ) BOOST_NOEXCEPT - { - *this = make_error_code( e ); - } - - // modifiers: - - BOOST_SYSTEM_CONSTEXPR void assign( int val, const error_category & cat ) BOOST_NOEXCEPT - { - val_ = val; - failed_ = detail::failed_impl( val, cat ); - cat_ = &cat; - } - - template<typename ErrorCodeEnum> - BOOST_SYSTEM_CONSTEXPR typename detail::enable_if<is_error_code_enum<ErrorCodeEnum>::value, error_code>::type & - operator=( ErrorCodeEnum val ) BOOST_NOEXCEPT - { - *this = make_error_code( val ); - return *this; - } - - BOOST_SYSTEM_CONSTEXPR void clear() BOOST_NOEXCEPT - { - val_ = 0; - failed_ = false; - cat_ = &system_category(); - } - - // observers: - - BOOST_SYSTEM_CONSTEXPR int value() const BOOST_NOEXCEPT - { - return val_; - } - - BOOST_SYSTEM_CONSTEXPR const error_category & category() const BOOST_NOEXCEPT - { - return *cat_; - } - - error_condition default_error_condition() const BOOST_NOEXCEPT - { - return cat_->default_error_condition( value() ); - } - - std::string message() const - { - return cat_->message( value() ); - } - - char const * message( char * buffer, std::size_t len ) const BOOST_NOEXCEPT - { - return cat_->message( value(), buffer, len ); - } - - BOOST_SYSTEM_CONSTEXPR bool failed() const BOOST_NOEXCEPT - { - return failed_; - } - -#if !defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) - - BOOST_SYSTEM_CONSTEXPR explicit operator bool() const BOOST_NOEXCEPT // true if error - { - return val_ != 0; - } - -#else - - typedef void (*unspecified_bool_type)(); - static void unspecified_bool_true() {} - - BOOST_SYSTEM_CONSTEXPR operator unspecified_bool_type() const BOOST_NOEXCEPT // true if error - { - return val_ != 0? unspecified_bool_true: 0; - } - - BOOST_SYSTEM_CONSTEXPR bool operator!() const BOOST_NOEXCEPT // true if no error - { - return val_ == 0; - } - -#endif - - // relationals: - - // the more symmetrical non-member syntax allows enum - // conversions work for both rhs and lhs. - - BOOST_SYSTEM_CONSTEXPR inline friend bool operator==( const error_code & lhs, const error_code & rhs ) BOOST_NOEXCEPT - { - return lhs.val_ == rhs.val_ && *lhs.cat_ == *rhs.cat_; - } - - BOOST_SYSTEM_CONSTEXPR inline friend bool operator<( const error_code & lhs, const error_code & rhs ) BOOST_NOEXCEPT - { - return *lhs.cat_ < *rhs.cat_ || ( *lhs.cat_ == *rhs.cat_ && lhs.val_ < rhs.val_ ); - } - -#if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) - - operator std::error_code () const - { - return std::error_code( value(), category() ); - } - -#endif -}; - -} // namespace system - -// boost::throws() - -namespace detail -{ - -// Misuse of the error_code object is turned into a noisy failure by -// poisoning the reference. This particular implementation doesn't -// produce warnings or errors from popular compilers, is very efficient -// (as determined by inspecting generated code), and does not suffer -// from order of initialization problems. In practice, it also seems -// cause user function error handling implementation errors to be detected -// very early in the development cycle. - -inline system::error_code* throws() -{ - // See github.com/boostorg/system/pull/12 by visigoth for why the return - // is poisoned with nonzero rather than (0). A test, test_throws_usage(), - // has been added to error_code_test.cpp, and as visigoth mentioned it - // fails on clang for release builds with a return of 0 but works fine - // with (1). - // Since the undefined behavior sanitizer (-fsanitize=undefined) does not - // allow a reference to be formed to the unaligned address of (1), we use - // (8) instead. - - return reinterpret_cast<system::error_code*>(8); -} - -} // namespace detail - -inline system::error_code& throws() -{ - return *detail::throws(); -} - -// non-member functions of error_code and error_condition - -namespace system -{ - -BOOST_SYSTEM_CONSTEXPR inline bool operator!=( const error_code & lhs, const error_code & rhs ) BOOST_NOEXCEPT -{ - return !( lhs == rhs ); -} - -BOOST_SYSTEM_CONSTEXPR inline bool operator!=( const error_condition & lhs, const error_condition & rhs ) BOOST_NOEXCEPT -{ - return !( lhs == rhs ); -} - -inline bool operator==( const error_code & code, const error_condition & condition ) BOOST_NOEXCEPT -{ - return code.category().equivalent( code.value(), condition ) || condition.category().equivalent( code, condition.value() ); -} - -inline bool operator!=( const error_code & lhs, const error_condition & rhs ) BOOST_NOEXCEPT -{ - return !( lhs == rhs ); -} - -inline bool operator==( const error_condition & condition, const error_code & code ) BOOST_NOEXCEPT -{ - return code.category().equivalent( code.value(), condition ) || condition.category().equivalent( code, condition.value() ); -} - -inline bool operator!=( const error_condition & lhs, const error_code & rhs ) BOOST_NOEXCEPT -{ - return !( lhs == rhs ); -} - -template <class charT, class traits> - inline std::basic_ostream<charT,traits>& - operator<< (std::basic_ostream<charT,traits>& os, error_code ec) -{ - os << ec.category().name() << ':' << ec.value(); - return os; -} - -inline std::size_t hash_value( error_code const & ec ) -{ - error_category const & cat = ec.category(); - - boost::ulong_long_type id_ = cat.id_; - - if( id_ == 0 ) - { - id_ = reinterpret_cast<boost::uintptr_t>( &cat ); - } - - boost::ulong_long_type hv = ( boost::ulong_long_type( 0xCBF29CE4 ) << 32 ) + 0x84222325; - boost::ulong_long_type const prime = ( boost::ulong_long_type( 0x00000100 ) << 32 ) + 0x000001B3; - - // id - - hv ^= id_; - hv *= prime; - - // value - - hv ^= static_cast<unsigned>( ec.value() ); - hv *= prime; - - return static_cast<std::size_t>( hv ); -} - -// make_* functions for errc::errc_t - -namespace errc -{ - -// explicit conversion: -BOOST_SYSTEM_CONSTEXPR inline error_code make_error_code( errc_t e ) BOOST_NOEXCEPT -{ - return error_code( e, generic_category() ); -} - -// implicit conversion: -BOOST_SYSTEM_CONSTEXPR inline error_condition make_error_condition( errc_t e ) BOOST_NOEXCEPT -{ - return error_condition( e, generic_category() ); -} - -} // namespace errc - -// error_category default implementation - -inline error_condition error_category::default_error_condition( int ev ) const BOOST_NOEXCEPT -{ - return error_condition( ev, *this ); -} - -inline bool error_category::equivalent( int code, const error_condition & condition ) const BOOST_NOEXCEPT -{ - return default_error_condition( code ) == condition; -} - -inline bool error_category::equivalent( const error_code & code, int condition ) const BOOST_NOEXCEPT -{ - return *this == code.category() && code.value() == condition; -} - -inline char const * error_category::message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT -{ - if( len == 0 ) - { - return buffer; - } - - if( len == 1 ) - { - buffer[0] = 0; - return buffer; - } - -#if !defined(BOOST_NO_EXCEPTIONS) - try -#endif - { - std::string m = this->message( ev ); - -# if defined( BOOST_MSVC ) -# pragma warning( push ) -# pragma warning( disable: 4996 ) -# elif defined(__clang__) && defined(__has_warning) -# pragma clang diagnostic push -# if __has_warning("-Wdeprecated-declarations") -# pragma clang diagnostic ignored "-Wdeprecated-declarations" -# endif -# endif - - std::strncpy( buffer, m.c_str(), len - 1 ); - buffer[ len-1 ] = 0; - -# if defined( BOOST_MSVC ) -# pragma warning( pop ) -# elif defined(__clang__) && defined(__has_warning) -# pragma clang diagnostic pop -# endif - - return buffer; - } -#if !defined(BOOST_NO_EXCEPTIONS) - catch( ... ) - { - return "Message text unavailable"; - } -#endif -} - -inline bool error_category::failed( int ev ) const BOOST_NOEXCEPT -{ - return ev != 0; -} - -} // namespace system - -} // namespace boost - -// generic_error_category implementation - -#include <boost/system/detail/generic_category.hpp> - -inline std::string boost::system::detail::generic_error_category::message( int ev ) const -{ - return generic_error_category_message( ev ); -} - -inline char const * boost::system::detail::generic_error_category::message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT -{ - return generic_error_category_message( ev, buffer, len ); -} - -// system_error_category implementation - -#if defined(BOOST_WINDOWS_API) - -#include <boost/system/detail/system_category_win32.hpp> - -inline boost::system::error_condition boost::system::detail::system_error_category::default_error_condition( int ev ) const BOOST_NOEXCEPT -{ - return system_category_default_error_condition_win32( ev ); -} - -inline std::string boost::system::detail::system_error_category::message( int ev ) const -{ - return system_category_message_win32( ev ); -} - -inline char const * boost::system::detail::system_error_category::message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT -{ - return system_category_message_win32( ev, buffer, len ); -} - -#else // #if defined(BOOST_WINDOWS_API) - -#include <boost/system/detail/system_category_posix.hpp> - -inline boost::system::error_condition boost::system::detail::system_error_category::default_error_condition( int ev ) const BOOST_NOEXCEPT -{ - return system_category_default_error_condition_posix( ev ); -} - -inline std::string boost::system::detail::system_error_category::message( int ev ) const -{ - return generic_error_category_message( ev ); -} - -inline char const * boost::system::detail::system_error_category::message( int ev, char * buffer, std::size_t len ) const BOOST_NOEXCEPT -{ - return generic_error_category_message( ev, buffer, len ); -} - -#endif // #if defined(BOOST_WINDOWS_API) - -// interoperability with std::error_code, std::error_condition - -#if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) - -#include <boost/system/detail/std_interoperability.hpp> - -inline boost::system::error_category::operator std::error_category const & () const -{ - return boost::system::detail::to_std_category( *this ); -} - -#endif // #if defined(BOOST_SYSTEM_HAS_SYSTEM_ERROR) - -#endif // BOOST_SYSTEM_ERROR_CODE_HPP_INCLUDED diff --git a/ThirdParty/boost/test/detail/config.hpp b/ThirdParty/boost/test/detail/config.hpp deleted file mode 100644 index 8d0f7c41f1d8150b668266ecd826fd195d999783..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/detail/config.hpp +++ /dev/null @@ -1,169 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief a central place for global configuration switches -// *************************************************************************** - -#ifndef BOOST_TEST_CONFIG_HPP_071894GER -#define BOOST_TEST_CONFIG_HPP_071894GER - -// Boost -#include <boost/config.hpp> // compilers workarounds -#include <boost/detail/workaround.hpp> - -#if defined(_WIN32) && !defined(BOOST_DISABLE_WIN32) && \ - (!defined(__COMO__) && !defined(__MWERKS__) && !defined(__GNUC__) || \ - BOOST_WORKAROUND(__MWERKS__, >= 0x3000)) -# define BOOST_SEH_BASED_SIGNAL_HANDLING -#endif - -#if defined(__COMO__) && defined(_MSC_VER) -// eh.h uses type_info without declaring it. -class type_info; -# define BOOST_SEH_BASED_SIGNAL_HANDLING -#endif - -//____________________________________________________________________________// - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x570)) || \ - BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) || \ - (defined __sgi && BOOST_WORKAROUND(_COMPILER_VERSION, BOOST_TESTED_AT(730))) -# define BOOST_TEST_SHIFTED_LINE -#endif - -//____________________________________________________________________________// - -#if defined(BOOST_MSVC) || (defined(__BORLANDC__) && !defined(BOOST_DISABLE_WIN32)) -# define BOOST_TEST_CALL_DECL __cdecl -#else -# define BOOST_TEST_CALL_DECL /**/ -#endif - -//____________________________________________________________________________// - -#if !defined(BOOST_NO_STD_LOCALE) && !defined(__MWERKS__) -# define BOOST_TEST_USE_STD_LOCALE 1 -#endif - -//____________________________________________________________________________// - -#if BOOST_WORKAROUND(__BORLANDC__, <= 0x570) || \ - BOOST_WORKAROUND( __COMO__, <= 0x433 ) || \ - BOOST_WORKAROUND( __INTEL_COMPILER, <= 800 ) || \ - defined(__sgi) && _COMPILER_VERSION <= 730 || \ - BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) || \ - defined(__DECCXX) || \ - defined(__DMC__) -# define BOOST_TEST_NO_PROTECTED_USING -#endif - -//____________________________________________________________________________// - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1400) -#define BOOST_TEST_PROTECTED_VIRTUAL -#else -#define BOOST_TEST_PROTECTED_VIRTUAL virtual -#endif - -//____________________________________________________________________________// - -#if !defined(__BORLANDC__) && !BOOST_WORKAROUND( __SUNPRO_CC, < 0x5100 ) -#define BOOST_TEST_SUPPORT_TOKEN_ITERATOR 1 -#endif - -//____________________________________________________________________________// - -// Sun compiler does not support visibility on enums -#if defined(__SUNPRO_CC) -#define BOOST_TEST_ENUM_SYMBOL_VISIBLE -#else -#define BOOST_TEST_ENUM_SYMBOL_VISIBLE BOOST_SYMBOL_VISIBLE -#endif - -//____________________________________________________________________________// - -#if defined(BOOST_ALL_DYN_LINK) && !defined(BOOST_TEST_DYN_LINK) -# define BOOST_TEST_DYN_LINK -#endif - -// in case any of the define from cmake/b2 is set -#if !defined(BOOST_TEST_DYN_LINK) \ - && (defined(BOOST_UNIT_TEST_FRAMEWORK_DYN_LINK) \ - || defined(BOOST_TEST_EXEC_MONITOR_DYN_LINK) \ - || defined(BOOST_PRG_EXEC_MONITOR_DYN_LINK) ) -# define BOOST_TEST_DYN_LINK -#endif - -#if defined(BOOST_TEST_INCLUDED) -# undef BOOST_TEST_DYN_LINK -#endif - -#if defined(BOOST_TEST_DYN_LINK) -# define BOOST_TEST_ALTERNATIVE_INIT_API - -# ifdef BOOST_TEST_SOURCE -# define BOOST_TEST_DECL BOOST_SYMBOL_EXPORT BOOST_SYMBOL_VISIBLE -# else -# define BOOST_TEST_DECL BOOST_SYMBOL_IMPORT BOOST_SYMBOL_VISIBLE -# endif // BOOST_TEST_SOURCE -#else -# if defined(BOOST_TEST_INCLUDED) -# define BOOST_TEST_DECL -# else -# define BOOST_TEST_DECL BOOST_SYMBOL_VISIBLE -# endif -#endif - -#if !defined(BOOST_TEST_MAIN) && defined(BOOST_AUTO_TEST_MAIN) -#define BOOST_TEST_MAIN BOOST_AUTO_TEST_MAIN -#endif - -#if !defined(BOOST_TEST_MAIN) && defined(BOOST_TEST_MODULE) -#define BOOST_TEST_MAIN BOOST_TEST_MODULE -#endif - - - -#ifndef BOOST_PP_VARIADICS /* we can change this only if not already defined */ - -#ifdef __PGI -#define BOOST_PP_VARIADICS 1 -#endif - -#if BOOST_CLANG -#define BOOST_PP_VARIADICS 1 -#endif - -#if defined(BOOST_GCC) && (BOOST_GCC >= 4 * 10000 + 8 * 100) -#define BOOST_PP_VARIADICS 1 -#endif - -#if defined(__NVCC__) -#define BOOST_PP_VARIADICS 1 -#endif - -#endif /* ifndef BOOST_PP_VARIADICS */ - -// some versions of VC exibit a manifest error with this BOOST_UNREACHABLE_RETURN -#if BOOST_WORKAROUND(BOOST_MSVC, < 1910) -# define BOOST_TEST_UNREACHABLE_RETURN(x) return x -#else -# define BOOST_TEST_UNREACHABLE_RETURN(x) BOOST_UNREACHABLE_RETURN(x) -#endif - -//____________________________________________________________________________// -// string_view support -//____________________________________________________________________________// -// note the code should always be compatible with compiled version of boost.test -// using a pre-c++17 compiler - -#ifndef BOOST_NO_CXX17_HDR_STRING_VIEW -#define BOOST_TEST_STRING_VIEW -#endif - -#endif // BOOST_TEST_CONFIG_HPP_071894GER diff --git a/ThirdParty/boost/test/detail/suppress_warnings.hpp b/ThirdParty/boost/test/detail/suppress_warnings.hpp deleted file mode 100644 index 2145da5f91574712a0835588f21ce548783e1f7c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/detail/suppress_warnings.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief suppress some warnings -// *************************************************************************** - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable: 4511) // copy constructor can't not be generated -# pragma warning(disable: 4512) // assignment operator can't not be generated -# pragma warning(disable: 4100) // unreferenced formal parameter -# pragma warning(disable: 4996) // <symbol> was declared deprecated -# pragma warning(disable: 4355) // 'this' : used in base member initializer list -# pragma warning(disable: 4706) // assignment within conditional expression -# pragma warning(disable: 4251) // class 'A<T>' needs to have dll-interface to be used by clients of class 'B' -# pragma warning(disable: 4127) // conditional expression is constant -# pragma warning(disable: 4290) // C++ exception specification ignored except to ... -# pragma warning(disable: 4180) // qualifier applied to function type has no meaning; ignored -# pragma warning(disable: 4275) // non dll-interface class ... used as base for dll-interface class ... -# pragma warning(disable: 4267) // 'var' : conversion from 'size_t' to 'type', possible loss of data -# pragma warning(disable: 4511) // 'class' : copy constructor could not be generated -#endif - -#if defined(BOOST_CLANG) && (BOOST_CLANG == 1) -# pragma clang diagnostic push -# pragma clang diagnostic ignored "-Wvariadic-macros" -# pragma clang diagnostic ignored "-Wmissing-declarations" -#endif - -#if defined(BOOST_GCC) && (BOOST_GCC >= 4 * 10000 + 6 * 100) -# pragma GCC diagnostic push -# pragma GCC diagnostic ignored "-Wvariadic-macros" -# pragma GCC diagnostic ignored "-Wmissing-declarations" -// # pragma GCC diagnostic ignored "-Wattributes" -#endif - diff --git a/ThirdParty/boost/test/framework.hpp b/ThirdParty/boost/test/framework.hpp deleted file mode 100644 index 1a139e099c045286effba0baea9ebe418b6fd8c0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/framework.hpp +++ /dev/null @@ -1,307 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief Defines Unit Test Framework mono-state interfaces. -//! The framework interfaces are based on Monostate design pattern. -// *************************************************************************** - -#ifndef BOOST_TEST_FRAMEWORK_HPP_020805GER -#define BOOST_TEST_FRAMEWORK_HPP_020805GER - -// Boost.Test -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/fwd_decl.hpp> -#include <boost/test/detail/throw_exception.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -// STL -#include <stdexcept> - -//____________________________________________________________________________// - -namespace boost { - -/// Main namespace for the Unit Test Framework interfaces and implementation -namespace unit_test { - -// ************************************************************************** // -// ************** init_unit_test_func ************** // -// ************************************************************************** // - -/// Test module initialization routine signature - -/// Different depending on whether BOOST_TEST_ALTERNATIVE_INIT_API is defined or not -#ifdef BOOST_TEST_ALTERNATIVE_INIT_API -typedef bool (*init_unit_test_func)(); -#else -typedef test_suite* (*init_unit_test_func)( int, char* [] ); -#endif - -// ************************************************************************** // -// ************** framework ************** // -// ************************************************************************** // - -/// Namespace of the Unit Test Framework mono-state -namespace framework { - -/// @name Unit Test Framework initialization and shutdown -/// @{ - -/// @brief This function performs initialization of the framework mono-state. -/// -/// It needs to be called every time before the test is started. -/// @param[in] init_func test module initialization routine -/// @param[in] argc command line arguments collection -/// @param[in] argv command line arguments collection -BOOST_TEST_DECL void init( init_unit_test_func init_func, int argc, char* argv[] ); - -/// This function applies all the decorators and figures out default run status. This argument facilitates an -/// ability of the test cases to prepare some other test units (primarily used internally for self testing). -/// @param[in] tu Optional id of the test unit representing root of test tree. If absent, master test suite is used -BOOST_TEST_DECL void finalize_setup_phase( test_unit_id tu = INV_TEST_UNIT_ID); - -/// This function returns true when testing is in progress (setup is finished). -BOOST_TEST_DECL bool test_in_progress(); - -/// This function shuts down the framework and clears up its mono-state. -/// -/// It needs to be at the very end of test module execution -BOOST_TEST_DECL void shutdown(); -/// @} - -/// @name Test unit registration -/// @{ - -/// Provides both read and write access to current "leaf" auto test suite during the test unit registration phase. -/// -/// During auto-registration phase the framework maintain a FIFO queue of test units being registered. New test units become children -/// of the current "leaf" test suite and if this is test suite it is pushed back into queue and becomes a new leaf. -/// When test suite registration is completed, a test suite is popped from the back of the queue. Only automatically registered test suites -/// should be added to this queue. Master test suite is always a zero element in this queue, so if no other test suites are registered -/// all test cases are added to master test suite. - -/// This function facilitates all three possible actions: -/// - if no argument are provided it returns the current queue leaf test suite -/// - if test suite is provided and no second argument are set, test suite is added to the queue -/// - if no test suite are provided and last argument is false, the semantic of this function is similar to queue pop: last element is popped from the queue -/// @param[in] ts test suite to push back to the queue -/// @param[in] push_or_pop should we push ts to the queue or pop leaf test suite instead -/// @returns a reference to the currently active/"leaf" test suite -BOOST_TEST_DECL test_suite& current_auto_test_suite( test_suite* ts = 0, bool push_or_pop = true ); - -/// This function add new test case into the global collection of test units the framework aware of. - -/// This function also assignes unique test unit id for every test case. Later on one can use this id to locate -/// the test case if necessary. This is the way for the framework to maintain weak references between test units. -/// @param[in] tc test case to register -BOOST_TEST_DECL void register_test_unit( test_case* tc ); - -/// This function add new test suite into the global collection of test units the framework aware of. - -/// This function also assignes unique test unit id for every test suite. Later on one can use this id to locate -/// the test case if necessary. This is the way for the framework to maintain weak references between test units. -/// @param[in] ts test suite to register -BOOST_TEST_DECL void register_test_unit( test_suite* ts ); - -/// This function removes the test unit from the collection of known test units and destroys the test unit object. - -/// This function also assigns unique test unit id for every test case. Later on one can use this id to located -/// the test case if necessary. This is the way for the framework to maintain weak references between test units. -/// @param[in] tu test unit to deregister -BOOST_TEST_DECL void deregister_test_unit( test_unit* tu ); - -// This function clears up the framework mono-state. - -/// After this call the framework can be reinitialized to perform a second test run during the same program lifetime. -BOOST_TEST_DECL void clear(); -/// @} - -/// @name Test observer registration -/// @{ -/// Adds new test execution observer object into the framework's list of test observers. - -/// Observer lifetime should exceed the the testing execution timeframe -/// @param[in] to test observer object to add -BOOST_TEST_DECL void register_observer( test_observer& to ); - -/// Excludes the observer object form the framework's list of test observers -/// @param[in] to test observer object to exclude -BOOST_TEST_DECL void deregister_observer( test_observer& to ); - -/// @} - -/// @name Global fixtures registration -/// @{ - -/// Adds a new global fixture to be setup before any other tests starts and tore down after -/// any other tests finished. -/// Test unit fixture lifetime should exceed the testing execution timeframe -/// @param[in] tuf fixture to add -BOOST_TEST_DECL void register_global_fixture( global_fixture& tuf ); - -/// Removes a test global fixture from the framework -/// -/// Test unit fixture lifetime should exceed the testing execution timeframe -/// @param[in] tuf fixture to remove -BOOST_TEST_DECL void deregister_global_fixture( global_fixture& tuf ); -/// @} - -/// @name Assertion/uncaught exception context support -/// @{ -/// Context accessor -struct BOOST_TEST_DECL context_generator { - context_generator() : m_curr_frame( 0 ) {} - - /// Is there any context? - bool is_empty() const; - - /// Give me next frame; empty - last frame - const_string next() const; - -private: - // Data members - mutable unsigned m_curr_frame; -}; - -/// Records context frame message. - -/// Some context frames are sticky - they can only explicitly cleared by specifying context id. Other (non sticky) context frames cleared after every assertion. -/// @param[in] context_descr context frame message -/// @param[in] sticky is this sticky frame or not -/// @returns id of the newly created frame -BOOST_TEST_DECL int add_context( lazy_ostream const& context_descr, bool sticky ); -/// Erases context frame (when test exits context scope) - -/// If context_id is passed clears that specific context frame identified by this id, otherwise clears all non sticky contexts. -BOOST_TEST_DECL void clear_context( int context_id = -1 ); -/// Produces an instance of small "delegate" object, which facilitates access to collected context. -BOOST_TEST_DECL context_generator get_context(); -/// @} - -/// @name Access to registered test units. -/// @{ -/// This function provides access to the master test suite. - -/// There is only only master test suite per test module. -/// @returns a reference the master test suite instance -BOOST_TEST_DECL master_test_suite_t& master_test_suite(); - -/// This function provides an access to the test unit currently being executed. - -/// The difference with current_test_case is about the time between a test-suite -/// is being set up or torn down (fixtures) and when the test-cases of that suite start. - -/// This function is only valid during test execution phase. -/// @see current_test_case_id, current_test_case -BOOST_TEST_DECL test_unit const& current_test_unit(); - -/// This function provides an access to the test case currently being executed. - -/// This function is only valid during test execution phase. -/// @see current_test_case_id -BOOST_TEST_DECL test_case const& current_test_case(); - -/// This function provides an access to an id of the test case currently being executed. - -/// This function safer than current_test_case, cause if wont throw if no test case is being executed. -/// @see current_test_case -BOOST_TEST_DECL test_unit_id current_test_case_id(); /* safe version of above */ - -/// This function provides access to a test unit by id and type combination. It will throw if no test unit located. -/// @param[in] tu_id id of a test unit to locate -/// @param[in] tu_type type of a test unit to locate -/// @returns located test unit -BOOST_TEST_DECL test_unit& get( test_unit_id tu_id, test_unit_type tu_type ); - -/// This function template provides access to a typed test unit by id - -/// It will throw if you specify incorrect test unit type -/// @tparam UnitType compile time type of test unit to get (test_suite or test_case) -/// @param id id of test unit to get -template<typename UnitType> -inline UnitType& get( test_unit_id id ) -{ - return static_cast<UnitType&>( get( id, static_cast<test_unit_type>(UnitType::type) ) ); -} -///@} - -/// @name Test initiation interface -/// @{ - -/// Initiates test execution - -/// This function is used to start the test execution from a specific "root" test unit. -/// If no root provided, test is started from master test suite. This second argument facilitates an ability of the test cases to -/// start some other test units (primarily used internally for self testing). -/// @param[in] tu Optional id of the test unit or test unit itself from which the test is started. If absent, master test suite is used -/// @param[in] continue_test true == continue test if it was already started, false == restart the test from scratch regardless -BOOST_TEST_DECL void run( test_unit_id tu = INV_TEST_UNIT_ID, bool continue_test = true ); -/// Initiates test execution. Same as other overload -BOOST_TEST_DECL void run( test_unit const* tu, bool continue_test = true ); -/// @} - -/// @name Test events dispatchers -/// @{ -/// Reports results of assertion to all test observers -BOOST_TEST_DECL void assertion_result( unit_test::assertion_result ar ); -/// Reports uncaught exception to all test observers -BOOST_TEST_DECL void exception_caught( execution_exception const& ); -/// Reports aborted test unit to all test observers -BOOST_TEST_DECL void test_unit_aborted( test_unit const& ); -/// Reports aborted test module to all test observers -BOOST_TEST_DECL void test_aborted( ); -/// @} - -namespace impl { -// exclusively for self test -BOOST_TEST_DECL void setup_for_execution( test_unit const& ); -BOOST_TEST_DECL void setup_loggers( ); - -// Helper for setting the name of the master test suite globally -struct BOOST_TEST_DECL master_test_suite_name_setter { - master_test_suite_name_setter( const_string name ); -}; - -} // namespace impl - -// ************************************************************************** // -// ************** framework errors ************** // -// ************************************************************************** // - -/// This exception type is used to report internal Boost.Test framework errors. -struct BOOST_TEST_DECL internal_error : public std::runtime_error { - internal_error( const_string m ) : std::runtime_error( std::string( m.begin(), m.size() ) ) {} -}; - -//____________________________________________________________________________// - -/// This exception type is used to report test module setup errors. -struct BOOST_TEST_DECL setup_error : public std::runtime_error { - setup_error( const_string m ) : std::runtime_error( std::string( m.begin(), m.size() ) ) {} -}; - -#define BOOST_TEST_SETUP_ASSERT( cond, msg ) BOOST_TEST_I_ASSRT( cond, unit_test::framework::setup_error( msg ) ) - -//____________________________________________________________________________// - -struct nothing_to_test { - explicit nothing_to_test( int rc ) : m_result_code( rc ) {} - - int m_result_code; -}; - -//____________________________________________________________________________// - -} // namespace framework -} // unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_FRAMEWORK_HPP_020805GER diff --git a/ThirdParty/boost/test/impl/compiler_log_formatter.ipp b/ThirdParty/boost/test/impl/compiler_log_formatter.ipp deleted file mode 100644 index 4c99a9338d8209b88b766762f1f1c297197b1b84..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/compiler_log_formatter.ipp +++ /dev/null @@ -1,293 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : implements compiler like Log formatter -// *************************************************************************** - -#ifndef BOOST_TEST_COMPILER_LOG_FORMATTER_IPP_020105GER -#define BOOST_TEST_COMPILER_LOG_FORMATTER_IPP_020105GER - -// Boost.Test -#include <boost/test/output/compiler_log_formatter.hpp> - -#include <boost/test/framework.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/unit_test_parameters.hpp> - -#include <boost/test/tree/test_unit.hpp> - -#include <boost/test/utils/basic_cstring/io.hpp> -#include <boost/test/utils/lazy_ostream.hpp> - -// Boost -#include <boost/version.hpp> - -// STL -#include <iostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace output { - -// ************************************************************************** // -// ************** compiler_log_formatter ************** // -// ************************************************************************** // - -namespace { - -std::string -test_phase_identifier() -{ - return framework::test_in_progress() ? framework::current_test_unit().full_name() : std::string( "Test setup" ); -} - -} // local namespace - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_start( std::ostream& output, counter_t test_cases_amount ) -{ - m_color_output = runtime_config::get<bool>( runtime_config::btrt_color_output ); - - if( test_cases_amount > 0 ) - output << "Running " << test_cases_amount << " test " - << (test_cases_amount > 1 ? "cases" : "case") << "...\n"; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_finish( std::ostream& ostr ) -{ - ostr.flush(); -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_build_info( std::ostream& output, bool log_build_info ) -{ - if(log_build_info) { - output << "Platform: " << BOOST_PLATFORM << '\n' - << "Compiler: " << BOOST_COMPILER << '\n' - << "STL : " << BOOST_STDLIB << '\n' - << "Boost : " << BOOST_VERSION/100000 << "." - << BOOST_VERSION/100 % 1000 << "." - << BOOST_VERSION % 100 << std::endl; - } -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::test_unit_start( std::ostream& output, test_unit const& tu ) -{ - BOOST_TEST_SCOPE_SETCOLOR( m_color_output, output, term_attr::BRIGHT, term_color::BLUE ); - - print_prefix( output, tu.p_file_name, tu.p_line_num ); - - output << "Entering test " << tu.p_type_name << " \"" << tu.p_name << "\"" << std::endl; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::test_unit_finish( std::ostream& output, test_unit const& tu, unsigned long elapsed ) -{ - BOOST_TEST_SCOPE_SETCOLOR( m_color_output, output, term_attr::BRIGHT, term_color::BLUE ); - - print_prefix( output, tu.p_file_name, tu.p_line_num ); - - output << "Leaving test " << tu.p_type_name << " \"" << tu.p_name << "\""; - - if( elapsed > 0 ) { - output << "; testing time: "; - if( elapsed % 1000 == 0 ) - output << elapsed/1000 << "ms"; - else - output << elapsed << "us"; - } - - output << std::endl; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::test_unit_skipped( std::ostream& output, test_unit const& tu, const_string reason ) -{ - BOOST_TEST_SCOPE_SETCOLOR( m_color_output, output, term_attr::BRIGHT, term_color::YELLOW ); - - print_prefix( output, tu.p_file_name, tu.p_line_num ); - - output << "Test " << tu.p_type_name << " \"" << tu.full_name() << "\"" << " is skipped because " << reason << std::endl; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_exception_start( std::ostream& output, log_checkpoint_data const& checkpoint_data, execution_exception const& ex ) -{ - execution_exception::location const& loc = ex.where(); - - print_prefix( output, loc.m_file_name, loc.m_line_num ); - - { - BOOST_TEST_SCOPE_SETCOLOR( m_color_output, output, term_attr::UNDERLINE, term_color::RED ); - - output << "fatal error: in \"" << (loc.m_function.is_empty() ? test_phase_identifier() : loc.m_function ) << "\": " - << ex.what(); - } - - if( !checkpoint_data.m_file_name.is_empty() ) { - output << '\n'; - print_prefix( output, checkpoint_data.m_file_name, checkpoint_data.m_line_num ); - - BOOST_TEST_SCOPE_SETCOLOR( m_color_output, output, term_attr::BRIGHT, term_color::CYAN ); - - output << "last checkpoint"; - if( !checkpoint_data.m_message.empty() ) - output << ": " << checkpoint_data.m_message; - } -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_exception_finish( std::ostream& output ) -{ - output << std::endl; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_entry_start( std::ostream& output, log_entry_data const& entry_data, log_entry_types let ) -{ - using namespace utils; - - switch( let ) { - case BOOST_UTL_ET_INFO: - print_prefix( output, entry_data.m_file_name, entry_data.m_line_num ); - output << setcolor( m_color_output, term_attr::BRIGHT, term_color::GREEN, term_color::ORIGINAL, &m_color_state); - output << "info: "; - break; - case BOOST_UTL_ET_MESSAGE: - output << setcolor( m_color_output, term_attr::BRIGHT, term_color::CYAN, term_color::ORIGINAL, &m_color_state); - break; - case BOOST_UTL_ET_WARNING: - print_prefix( output, entry_data.m_file_name, entry_data.m_line_num ); - output << setcolor( m_color_output, term_attr::BRIGHT, term_color::YELLOW, term_color::ORIGINAL, &m_color_state); - output << "warning: in \"" << test_phase_identifier() << "\": "; - break; - case BOOST_UTL_ET_ERROR: - print_prefix( output, entry_data.m_file_name, entry_data.m_line_num ); - output << setcolor( m_color_output, term_attr::BRIGHT, term_color::RED, term_color::ORIGINAL, &m_color_state); - output << "error: in \"" << test_phase_identifier() << "\": "; - break; - case BOOST_UTL_ET_FATAL_ERROR: - print_prefix( output, entry_data.m_file_name, entry_data.m_line_num ); - output << setcolor( m_color_output, term_attr::UNDERLINE, term_color::RED, term_color::ORIGINAL, &m_color_state); - output << "fatal error: in \"" << test_phase_identifier() << "\": "; - break; - } -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_entry_value( std::ostream& output, const_string value ) -{ - output << value; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_entry_value( std::ostream& output, lazy_ostream const& value ) -{ - output << value; -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_entry_finish( std::ostream& output ) -{ - if( m_color_output ) - output << utils::setcolor(m_color_output, &m_color_state); - - output << std::endl; -} - - -//____________________________________________________________________________// - -void -compiler_log_formatter::print_prefix( std::ostream& output, const_string file_name, std::size_t line_num ) -{ - if( !file_name.empty() ) { -#ifdef __APPLE_CC__ - // Xcode-compatible logging format, idea by Richard Dingwall at - // <http://richarddingwall.name/2008/06/01/using-the-boost-unit-test-framework-with-xcode-3/>. - output << file_name << ':' << line_num << ": "; -#else - output << file_name << '(' << line_num << "): "; -#endif - } -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::entry_context_start( std::ostream& output, log_level l ) -{ - if( l == log_messages ) { - output << "\n[context:"; - } - else { - output << (l == log_successful_tests ? "\nAssertion" : "\nFailure" ) << " occurred in a following context:"; - } -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::entry_context_finish( std::ostream& output, log_level l ) -{ - if( l == log_messages ) { - output << "]"; - } - output.flush(); -} - -//____________________________________________________________________________// - -void -compiler_log_formatter::log_entry_context( std::ostream& output, log_level /*l*/, const_string context_descr ) -{ - output << "\n " << context_descr; -} - -//____________________________________________________________________________// - -} // namespace output -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_COMPILER_LOG_FORMATTER_IPP_020105GER diff --git a/ThirdParty/boost/test/impl/debug.ipp b/ThirdParty/boost/test/impl/debug.ipp deleted file mode 100644 index 8d0e258e643c90b2c03b37f1da3c6142666d696b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/debug.ipp +++ /dev/null @@ -1,1013 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// Use, modification, and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : debug interfaces implementation -// *************************************************************************** - -#ifndef BOOST_TEST_DEBUG_API_IPP_112006GER -#define BOOST_TEST_DEBUG_API_IPP_112006GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/detail/global_typedef.hpp> - -#include <boost/test/debug.hpp> -#include <boost/test/debug_config.hpp> - -#include <boost/core/ignore_unused.hpp> - -// Implementation on Windows -#if defined(_WIN32) && !defined(UNDER_CE) && !defined(BOOST_DISABLE_WIN32) // ******* WIN32 - -# define BOOST_WIN32_BASED_DEBUG - -// SYSTEM API -# include <windows.h> -# include <winreg.h> -# include <cstdio> -# include <cstring> - -# if !defined(NDEBUG) && defined(_MSC_VER) -# define BOOST_MS_CRT_BASED_DEBUG -# include <crtdbg.h> -# endif - - -# ifdef BOOST_NO_STDC_NAMESPACE -namespace std { using ::memset; using ::sprintf; } -# endif - -#elif defined(unix) || defined(__unix) // ********************* UNIX - -# define BOOST_UNIX_BASED_DEBUG - -// Boost.Test -#include <boost/test/utils/class_properties.hpp> -#include <boost/test/utils/algorithm.hpp> - -// STL -#include <cstring> // std::memcpy -#include <map> -#include <cstdio> -#include <stdarg.h> // !! ?? cstdarg - -// SYSTEM API -# include <unistd.h> -# include <signal.h> -# include <fcntl.h> - -# include <sys/types.h> -# include <sys/stat.h> -# include <sys/wait.h> -# include <sys/time.h> -# include <stdio.h> -# include <stdlib.h> - -# if defined(sun) || defined(__sun) - -# define BOOST_SUN_BASED_DEBUG - -# ifndef BOOST_TEST_DBG_LIST -# define BOOST_TEST_DBG_LIST dbx;gdb -# endif - -# define BOOST_TEST_CNL_DBG dbx -# define BOOST_TEST_GUI_DBG dbx-ddd - -# include <procfs.h> - -# elif defined(linux) || defined(__linux__) - -# define BOOST_LINUX_BASED_DEBUG - -# include <sys/ptrace.h> - -# ifndef BOOST_TEST_STAT_LINE_MAX -# define BOOST_TEST_STAT_LINE_MAX 500 -# endif - -# ifndef BOOST_TEST_DBG_LIST -# define BOOST_TEST_DBG_LIST gdb -# endif - -# define BOOST_TEST_CNL_DBG gdb -# define BOOST_TEST_GUI_DBG gdb-xterm - -# endif - -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace debug { - -using unit_test::const_string; - -// ************************************************************************** // -// ************** debug::info_t ************** // -// ************************************************************************** // - -namespace { - -#if defined(BOOST_WIN32_BASED_DEBUG) // *********************** WIN32 - -template<typename T> -inline void -dyn_symbol( T& res, char const* module_name, char const* symbol_name ) -{ - HMODULE m = ::GetModuleHandleA( module_name ); - - if( !m ) - m = ::LoadLibraryA( module_name ); - - res = reinterpret_cast<T>( ::GetProcAddress( m, symbol_name ) ); -} - -//____________________________________________________________________________// - -static struct info_t { - typedef BOOL (WINAPI* IsDebuggerPresentT)(); - typedef LONG (WINAPI* RegQueryValueExT)( HKEY, char const* /*LPTSTR*/, LPDWORD, LPDWORD, LPBYTE, LPDWORD ); - typedef LONG (WINAPI* RegOpenKeyT)( HKEY, char const* /*LPCTSTR*/, PHKEY ); - typedef LONG (WINAPI* RegCloseKeyT)( HKEY ); - - info_t(); - - IsDebuggerPresentT m_is_debugger_present; - RegOpenKeyT m_reg_open_key; - RegQueryValueExT m_reg_query_value; - RegCloseKeyT m_reg_close_key; - -} s_info; - -//____________________________________________________________________________// - -info_t::info_t() -{ - dyn_symbol( m_is_debugger_present, "kernel32", "IsDebuggerPresent" ); - dyn_symbol( m_reg_open_key, "advapi32", "RegOpenKeyA" ); - dyn_symbol( m_reg_query_value, "advapi32", "RegQueryValueExA" ); - dyn_symbol( m_reg_close_key, "advapi32", "RegCloseKey" ); -} - -//____________________________________________________________________________// - -#elif defined(BOOST_UNIX_BASED_DEBUG) - -// ************************************************************************** // -// ************** fd_holder ************** // -// ************************************************************************** // - -struct fd_holder { - explicit fd_holder( int fd ) : m_fd( fd ) {} - ~fd_holder() - { - if( m_fd != -1 ) - ::close( m_fd ); - } - - operator int() { return m_fd; } - -private: - // Data members - int m_fd; -}; - - -// ************************************************************************** // -// ************** process_info ************** // -// ************************************************************************** // - -struct process_info { - // Constructor - explicit process_info( int pid ); - - // access methods - int parent_pid() const { return m_parent_pid; } - const_string binary_name() const { return m_binary_name; } - const_string binary_path() const { return m_binary_path; } - -private: - // Data members - int m_parent_pid; - const_string m_binary_name; - const_string m_binary_path; - -#if defined(BOOST_SUN_BASED_DEBUG) - struct psinfo m_psi; - char m_binary_path_buff[500+1]; // !! ?? -#elif defined(BOOST_LINUX_BASED_DEBUG) - char m_stat_line[BOOST_TEST_STAT_LINE_MAX+1]; - char m_binary_path_buff[500+1]; // !! ?? -#endif -}; - -//____________________________________________________________________________// - -process_info::process_info( int pid ) -: m_parent_pid( 0 ) -{ -#if defined(BOOST_SUN_BASED_DEBUG) - char fname_buff[30]; - - ::snprintf( fname_buff, sizeof(fname_buff), "/proc/%d/psinfo", pid ); - - fd_holder psinfo_fd( ::open( fname_buff, O_RDONLY ) ); - - if( psinfo_fd == -1 ) - return; - - if( ::read( psinfo_fd, &m_psi, sizeof(m_psi) ) == -1 ) - return; - - m_parent_pid = m_psi.pr_ppid; - - m_binary_name.assign( m_psi.pr_fname ); - - //-------------------------- // - - ::snprintf( fname_buff, sizeof(fname_buff), "/proc/%d/as", pid ); - - fd_holder as_fd( ::open( fname_buff, O_RDONLY ) ); - uintptr_t binary_name_pos; - - // !! ?? could we avoid reading whole m_binary_path_buff? - if( as_fd == -1 || - ::lseek( as_fd, m_psi.pr_argv, SEEK_SET ) == -1 || - ::read ( as_fd, &binary_name_pos, sizeof(binary_name_pos) ) == -1 || - ::lseek( as_fd, binary_name_pos, SEEK_SET ) == -1 || - ::read ( as_fd, m_binary_path_buff, sizeof(m_binary_path_buff) ) == -1 ) - return; - - m_binary_path.assign( m_binary_path_buff ); - -#elif defined(BOOST_LINUX_BASED_DEBUG) - char fname_buff[30]; - - ::snprintf( fname_buff, sizeof(fname_buff), "/proc/%d/stat", pid ); - - fd_holder psinfo_fd( ::open( fname_buff, O_RDONLY ) ); - - if( psinfo_fd == -1 ) - return; - - ssize_t num_read = ::read( psinfo_fd, m_stat_line, sizeof(m_stat_line)-1 ); - if( num_read == -1 ) - return; - - m_stat_line[num_read] = 0; - - char const* name_beg = m_stat_line; - while( *name_beg && *name_beg != '(' ) - ++name_beg; - - char const* name_end = name_beg+1; - while( *name_end && *name_end != ')' ) - ++name_end; - - std::sscanf( name_end+1, "%*s%d", &m_parent_pid ); - - m_binary_name.assign( name_beg+1, name_end ); - - ::snprintf( fname_buff, sizeof(fname_buff), "/proc/%d/exe", pid ); - num_read = ::readlink( fname_buff, m_binary_path_buff, sizeof(m_binary_path_buff)-1 ); - - if( num_read == -1 ) - return; - - m_binary_path_buff[num_read] = 0; - m_binary_path.assign( m_binary_path_buff, num_read ); -#endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** prepare_window_title ************** // -// ************************************************************************** // - -static char* -prepare_window_title( dbg_startup_info const& dsi ) -{ - typedef unit_test::const_string str_t; - - static char title_str[50]; - - str_t path_sep( "\\/" ); - - str_t::iterator it = unit_test::utils::find_last_of( dsi.binary_path.begin(), dsi.binary_path.end(), - path_sep.begin(), path_sep.end() ); - - if( it == dsi.binary_path.end() ) - it = dsi.binary_path.begin(); - else - ++it; - - ::snprintf( title_str, sizeof(title_str), "%*s %ld", (int)(dsi.binary_path.end()-it), it, dsi.pid ); - - return title_str; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** save_execlp ************** // -// ************************************************************************** // - -typedef unit_test::basic_cstring<char> mbuffer; - -inline char* -copy_arg( mbuffer& dest, const_string arg ) -{ - if( dest.size() < arg.size()+1 ) - return 0; - - char* res = dest.begin(); - - std::memcpy( res, arg.begin(), arg.size()+1 ); - - dest.trim_left( arg.size()+1 ); - - return res; -} - -//____________________________________________________________________________// - -bool -safe_execlp( char const* file, ... ) -{ - static char* argv_buff[200]; - - va_list args; - char const* arg; - - // first calculate actual number of arguments - int num_args = 2; // file name and 0 at least - - va_start( args, file ); - while( !!(arg = va_arg( args, char const* )) ) - num_args++; - va_end( args ); - - // reserve space for the argument pointers array - char** argv_it = argv_buff; - mbuffer work_buff( reinterpret_cast<char*>(argv_buff), sizeof(argv_buff) ); - work_buff.trim_left( num_args * sizeof(char*) ); - - // copy all the argument values into local storage - if( !(*argv_it++ = copy_arg( work_buff, file )) ) - return false; - - printf( "!! %s\n", file ); - - va_start( args, file ); - while( !!(arg = va_arg( args, char const* )) ) { - printf( "!! %s\n", arg ); - if( !(*argv_it++ = copy_arg( work_buff, arg )) ) { - va_end( args ); - return false; - } - } - va_end( args ); - - *argv_it = 0; - - return ::execvp( file, argv_buff ) != -1; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** start_debugger_in_emacs ************** // -// ************************************************************************** // - -static void -start_debugger_in_emacs( dbg_startup_info const& dsi, char const* emacs_name, char const* dbg_command ) -{ - char const* title = prepare_window_title( dsi ); - - if( !title ) - return; - - dsi.display.is_empty() - ? safe_execlp( emacs_name, "-title", title, "--eval", dbg_command, 0 ) - : safe_execlp( emacs_name, "-title", title, "-display", dsi.display.begin(), "--eval", dbg_command, 0 ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** gdb starters ************** // -// ************************************************************************** // - -static char const* -prepare_gdb_cmnd_file( dbg_startup_info const& dsi ) -{ - // prepare pid value - char pid_buff[16]; - ::snprintf( pid_buff, sizeof(pid_buff), "%ld", dsi.pid ); - unit_test::const_string pid_str( pid_buff ); - - static char cmd_file_name[] = "/tmp/btl_gdb_cmd_XXXXXX"; // !! ?? - - // prepare commands - const mode_t cur_umask = ::umask( S_IRWXO | S_IRWXG ); - fd_holder cmd_fd( ::mkstemp( cmd_file_name ) ); - ::umask( cur_umask ); - - if( cmd_fd == -1 ) - return 0; - -#define WRITE_STR( str ) if( ::write( cmd_fd, str.begin(), str.size() ) == -1 ) return 0; -#define WRITE_CSTR( str ) if( ::write( cmd_fd, str, sizeof( str )-1 ) == -1 ) return 0; - - WRITE_CSTR( "file " ); - WRITE_STR( dsi.binary_path ); - WRITE_CSTR( "\nattach " ); - WRITE_STR( pid_str ); - WRITE_CSTR( "\nshell unlink " ); - WRITE_STR( dsi.init_done_lock ); - WRITE_CSTR( "\ncont" ); - if( dsi.break_or_continue ) - WRITE_CSTR( "\nup 4" ); - - WRITE_CSTR( "\necho \\n" ); // !! ?? - WRITE_CSTR( "\nlist -" ); - WRITE_CSTR( "\nlist" ); - WRITE_CSTR( "\nshell unlink " ); - WRITE_CSTR( cmd_file_name ); - - return cmd_file_name; -} - -//____________________________________________________________________________// - -static void -start_gdb_in_console( dbg_startup_info const& dsi ) -{ - char const* cmnd_file_name = prepare_gdb_cmnd_file( dsi ); - - if( !cmnd_file_name ) - return; - - safe_execlp( "gdb", "-q", "-x", cmnd_file_name, 0 ); -} - -//____________________________________________________________________________// - -static void -start_gdb_in_xterm( dbg_startup_info const& dsi ) -{ - char const* title = prepare_window_title( dsi ); - char const* cmnd_file_name = prepare_gdb_cmnd_file( dsi ); - - if( !title || !cmnd_file_name ) - return; - - safe_execlp( "xterm", "-T", title, "-display", dsi.display.begin(), - "-bg", "black", "-fg", "white", "-geometry", "88x30+10+10", "-fn", "9x15", "-e", - "gdb", "-q", "-x", cmnd_file_name, 0 ); -} - -//____________________________________________________________________________// - -static void -start_gdb_in_emacs( dbg_startup_info const& dsi ) -{ - char const* cmnd_file_name = prepare_gdb_cmnd_file( dsi ); - if( !cmnd_file_name ) - return; - - char dbg_cmd_buff[500]; // !! ?? - ::snprintf( dbg_cmd_buff, sizeof(dbg_cmd_buff), "(progn (gdb \"gdb -q -x %s\"))", cmnd_file_name ); - - start_debugger_in_emacs( dsi, "emacs", dbg_cmd_buff ); -} - -//____________________________________________________________________________// - -static void -start_gdb_in_xemacs( dbg_startup_info const& ) -{ - // !! ?? -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** dbx starters ************** // -// ************************************************************************** // - -static char const* -prepare_dbx_cmd_line( dbg_startup_info const& dsi, bool list_source = true ) -{ - static char cmd_line_buff[500]; // !! ?? - - ::snprintf( cmd_line_buff, sizeof(cmd_line_buff), "unlink %s;cont;%s%s", - dsi.init_done_lock.begin(), - dsi.break_or_continue ? "up 2;": "", - list_source ? "echo \" \";list -w3;" : "" ); - - return cmd_line_buff; -} - -//____________________________________________________________________________// - -static void -start_dbx_in_console( dbg_startup_info const& dsi ) -{ - char pid_buff[16]; - ::snprintf( pid_buff, sizeof(pid_buff), "%ld", dsi.pid ); - - safe_execlp( "dbx", "-q", "-c", prepare_dbx_cmd_line( dsi ), dsi.binary_path.begin(), pid_buff, 0 ); -} - -//____________________________________________________________________________// - -static void -start_dbx_in_xterm( dbg_startup_info const& dsi ) -{ - char const* title = prepare_window_title( dsi ); - if( !title ) - return; - - char pid_buff[16]; // !! ?? - ::snprintf( pid_buff, sizeof(pid_buff), "%ld", dsi.pid ); - - safe_execlp( "xterm", "-T", title, "-display", dsi.display.begin(), - "-bg", "black", "-fg", "white", "-geometry", "88x30+10+10", "-fn", "9x15", "-e", - "dbx", "-q", "-c", prepare_dbx_cmd_line( dsi ), dsi.binary_path.begin(), pid_buff, 0 ); -} - -//____________________________________________________________________________// - -static void -start_dbx_in_emacs( dbg_startup_info const& /*dsi*/ ) -{ -// char dbg_cmd_buff[500]; // !! ?? -// -// ::snprintf( dbg_cmd_buff, sizeof(dbg_cmd_buff), "(progn (dbx \"dbx -q -c cont %s %ld\"))", dsi.binary_path.begin(), dsi.pid ); - -// start_debugger_in_emacs( dsi, "emacs", dbg_cmd_buff ); -} - -//____________________________________________________________________________// - -static void -start_dbx_in_xemacs( dbg_startup_info const& ) -{ - // !! ?? -} - -//____________________________________________________________________________// - -static void -start_dbx_in_ddd( dbg_startup_info const& dsi ) -{ - char const* title = prepare_window_title( dsi ); - if( !title ) - return; - - char pid_buff[16]; // !! ?? - ::snprintf( pid_buff, sizeof(pid_buff), "%ld", dsi.pid ); - - safe_execlp( "ddd", "-display", dsi.display.begin(), - "--dbx", "-q", "-c", prepare_dbx_cmd_line( dsi, false ), dsi.binary_path.begin(), pid_buff, 0 ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** debug::info_t ************** // -// ************************************************************************** // - -static struct info_t { - // Constructor - info_t(); - - // Public properties - unit_test::readwrite_property<std::string> p_dbg; - - // Data members - std::map<std::string,dbg_starter> m_dbg_starter_reg; -} s_info; - -//____________________________________________________________________________// - -info_t::info_t() -{ - p_dbg.value = ::getenv( "DISPLAY" ) - ? std::string( BOOST_STRINGIZE( BOOST_TEST_GUI_DBG ) ) - : std::string( BOOST_STRINGIZE( BOOST_TEST_CNL_DBG ) ); - - m_dbg_starter_reg[std::string("gdb")] = &start_gdb_in_console; - m_dbg_starter_reg[std::string("gdb-emacs")] = &start_gdb_in_emacs; - m_dbg_starter_reg[std::string("gdb-xterm")] = &start_gdb_in_xterm; - m_dbg_starter_reg[std::string("gdb-xemacs")] = &start_gdb_in_xemacs; - - m_dbg_starter_reg[std::string("dbx")] = &start_dbx_in_console; - m_dbg_starter_reg[std::string("dbx-emacs")] = &start_dbx_in_emacs; - m_dbg_starter_reg[std::string("dbx-xterm")] = &start_dbx_in_xterm; - m_dbg_starter_reg[std::string("dbx-xemacs")] = &start_dbx_in_xemacs; - m_dbg_starter_reg[std::string("dbx-ddd")] = &start_dbx_in_ddd; -} - -//____________________________________________________________________________// - -#endif - -} // local namespace - -// ************************************************************************** // -// ************** check if program is running under debugger ************** // -// ************************************************************************** // - -bool -under_debugger() -{ -#if defined(BOOST_WIN32_BASED_DEBUG) // *********************** WIN32 - - return !!s_info.m_is_debugger_present && s_info.m_is_debugger_present(); - -#elif defined(BOOST_UNIX_BASED_DEBUG) // ********************** UNIX - - // !! ?? could/should we cache the result somehow? - const_string dbg_list = BOOST_TEST_STRINGIZE( BOOST_TEST_DBG_LIST ); - - pid_t pid = ::getpid(); - - while( pid != 0 ) { - process_info pi( pid ); - - // !! ?? should we use tokenizer here instead? - if( dbg_list.find( pi.binary_name() ) != const_string::npos ) - return true; - - pid = (pi.parent_pid() == pid ? 0 : pi.parent_pid()); - } - - return false; - -#else // ****************************************************** default - - return false; - -#endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** cause program to break execution ************** // -// ************** in debugger at call point ************** // -// ************************************************************************** // - -void -debugger_break() -{ - // !! ?? auto-start debugger? - -#if defined(BOOST_WIN32_BASED_DEBUG) // *********************** WIN32 - -#if defined(__GNUC__) && !defined(__MINGW32__) || \ - defined(__INTEL_COMPILER) -# define BOOST_DEBUG_BREAK __debugbreak -#else -# define BOOST_DEBUG_BREAK DebugBreak -#endif - -#ifndef __MINGW32__ - if( !under_debugger() ) { - __try { - __try { - BOOST_DEBUG_BREAK(); - } - __except( UnhandledExceptionFilter(GetExceptionInformation()) ) - { - // User opted to ignore the breakpoint - return; - } - } - __except (EXCEPTION_EXECUTE_HANDLER) - { - // If we got here, the user has pushed Debug. Debugger is already attached to our process and we - // continue to let the another BOOST_DEBUG_BREAK to be called. - } - } -#endif - - BOOST_DEBUG_BREAK(); - -#elif defined(BOOST_UNIX_BASED_DEBUG) // ********************** UNIX - - ::kill( ::getpid(), SIGTRAP ); - -#else // ****************************************************** default - -#endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** console debugger setup ************** // -// ************************************************************************** // - -#if defined(BOOST_UNIX_BASED_DEBUG) // ************************ UNIX - -std::string -set_debugger( unit_test::const_string dbg_id, dbg_starter s ) -{ - std::string old = s_info.p_dbg; - - assign_op( s_info.p_dbg.value, dbg_id, 0 ); - - if( !!s ) - s_info.m_dbg_starter_reg[s_info.p_dbg.get()] = s; - - return old; -} - -#else // ***************************************************** default - -std::string -set_debugger( unit_test::const_string, dbg_starter ) -{ - return std::string(); -} - -#endif - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** attach debugger to the current process ************** // -// ************************************************************************** // - -#if defined(BOOST_WIN32_BASED_DEBUG) - -struct safe_handle_helper -{ - HANDLE& handle; - safe_handle_helper(HANDLE &handle_) : handle(handle_) {} - - void close_handle() - { - if( handle != INVALID_HANDLE_VALUE ) - { - ::CloseHandle( handle ); - handle = INVALID_HANDLE_VALUE; - } - } - - ~safe_handle_helper() - { - close_handle(); - } -}; -#endif - -bool -attach_debugger( bool break_or_continue ) -{ - if( under_debugger() ) - return false; - -#if defined(BOOST_WIN32_BASED_DEBUG) // *********************** WIN32 - - const int MAX_CMD_LINE = 200; - - // *************************************************** // - // Debugger "ready" event - - SECURITY_ATTRIBUTES attr; - attr.nLength = sizeof(attr); - attr.lpSecurityDescriptor = NULL; - attr.bInheritHandle = true; - - // manual resettable, initially non signaled, unnamed event, - // that will signal me that debugger initialization is done - HANDLE dbg_init_done_ev = ::CreateEvent( - &attr, // pointer to security attributes - true, // flag for manual-reset event - false, // flag for initial state - NULL // pointer to event-object name - ); - - if( !dbg_init_done_ev ) - return false; - - safe_handle_helper safe_handle_obj( dbg_init_done_ev ); - - // *************************************************** // - // Debugger command line format - - HKEY reg_key; - - if( !s_info.m_reg_open_key || (*s_info.m_reg_open_key)( - HKEY_LOCAL_MACHINE, // handle of open key - "Software\\Microsoft\\Windows NT\\CurrentVersion\\AeDebug", // name of subkey to open - ®_key ) != ERROR_SUCCESS ) // address of handle of open key - return false; - - char format[MAX_CMD_LINE]; - DWORD format_size = MAX_CMD_LINE; - DWORD type = REG_SZ; - - bool b_read_key = s_info.m_reg_query_value && - ((*s_info.m_reg_query_value)( - reg_key, // handle of open key - "Debugger", // name of subkey to query - 0, // reserved - &type, // value type - (LPBYTE)format, // buffer for returned string - &format_size ) == ERROR_SUCCESS ); // in: buffer size; out: actual size of returned string - - if( !s_info.m_reg_close_key || (*s_info.m_reg_close_key)( reg_key ) != ERROR_SUCCESS ) - return false; - - if( !b_read_key ) - return false; - - // *************************************************** // - // Debugger command line - - char cmd_line[MAX_CMD_LINE]; - std::sprintf( cmd_line, format, ::GetCurrentProcessId(), dbg_init_done_ev ); - - // *************************************************** // - // Debugger window parameters - - STARTUPINFOA startup_info; - std::memset( &startup_info, 0, sizeof(startup_info) ); - - startup_info.cb = sizeof(startup_info); - startup_info.dwFlags = STARTF_USESHOWWINDOW; - startup_info.wShowWindow = SW_SHOWNORMAL; - - // debugger process s_info - PROCESS_INFORMATION debugger_info; - - bool created = !!::CreateProcessA( - NULL, // pointer to name of executable module; NULL - use the one in command line - cmd_line, // pointer to command line string - NULL, // pointer to process security attributes; NULL - debugger's handle can't be inherited - NULL, // pointer to thread security attributes; NULL - debugger's handle can't be inherited - true, // debugger inherit opened handles - 0, // priority flags; 0 - normal priority - NULL, // pointer to new environment block; NULL - use this process environment - NULL, // pointer to current directory name; NULL - use this process correct directory - &startup_info, // pointer to STARTUPINFO that specifies main window appearance - &debugger_info // pointer to PROCESS_INFORMATION that will contain the new process identification - ); - - bool debugger_run_ok = false; - if( created ) - { - DWORD ret_code = ::WaitForSingleObject( dbg_init_done_ev, INFINITE ); - debugger_run_ok = ( ret_code == WAIT_OBJECT_0 ); - } - - safe_handle_obj.close_handle(); - - if( !created || !debugger_run_ok ) - return false; - - if( break_or_continue ) - debugger_break(); - - return true; - -#elif defined(BOOST_UNIX_BASED_DEBUG) // ********************** UNIX - - char init_done_lock_fn[] = "/tmp/btl_dbg_init_done_XXXXXX"; - const mode_t cur_umask = ::umask( S_IRWXO | S_IRWXG ); - fd_holder init_done_lock_fd( ::mkstemp( init_done_lock_fn ) ); - ::umask( cur_umask ); - - if( init_done_lock_fd == -1 ) - return false; - - pid_t child_pid = fork(); - - if( child_pid == -1 ) - return false; - - if( child_pid != 0 ) { // parent process - here we will start the debugger - dbg_startup_info dsi; - - process_info pi( child_pid ); - if( pi.binary_path().is_empty() ) - ::exit( -1 ); - - dsi.pid = child_pid; - dsi.break_or_continue = break_or_continue; - dsi.binary_path = pi.binary_path(); - dsi.display = ::getenv( "DISPLAY" ); - dsi.init_done_lock = init_done_lock_fn; - - dbg_starter starter = s_info.m_dbg_starter_reg[s_info.p_dbg]; - if( !!starter ) - starter( dsi ); - - ::perror( "Boost.Test execution monitor failed to start a debugger:" ); - - ::exit( -1 ); - } - - // child process - here we will continue our test module execution ; // !! ?? should it be vice versa - - while( ::access( init_done_lock_fn, F_OK ) == 0 ) { - struct timeval to = { 0, 100 }; - - ::select( 0, 0, 0, 0, &to ); - } - -// char dummy; -// while( ::read( init_done_lock_fd, &dummy, sizeof(char) ) == 0 ); - - if( break_or_continue ) - debugger_break(); - - return true; - -#else // ****************************************************** default - (void) break_or_continue; // silence 'unused variable' warning - return false; - -#endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** switch on/off detect memory leaks feature ************** // -// ************************************************************************** // - -void -detect_memory_leaks( bool on_off, unit_test::const_string report_file ) -{ - boost::ignore_unused( on_off ); - -#ifdef BOOST_MS_CRT_BASED_DEBUG - int flags = _CrtSetDbgFlag( _CRTDBG_REPORT_FLAG ); - - if( !on_off ) - flags &= ~_CRTDBG_LEAK_CHECK_DF; - else { - flags |= _CRTDBG_LEAK_CHECK_DF; - _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE); - - if( report_file.is_empty() ) - _CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR); - else { - HANDLE hreport_f = ::CreateFileA( report_file.begin(), - GENERIC_WRITE, FILE_SHARE_WRITE, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); - _CrtSetReportFile(_CRT_WARN, hreport_f ); - } - } - - _CrtSetDbgFlag ( flags ); -#else - boost::ignore_unused( report_file ); -#endif // BOOST_MS_CRT_BASED_DEBUG -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** cause program to break execution in ************** // -// ************** debugger at specific allocation point ************** // -// ************************************************************************** // - -void -break_memory_alloc( long mem_alloc_order_num ) -{ - boost::ignore_unused( mem_alloc_order_num ); - -#ifdef BOOST_MS_CRT_BASED_DEBUG - // only set the value if one was supplied (do not use default used by UTF just as a indicator to enable leak detection) - if( mem_alloc_order_num > 1 ) - _CrtSetBreakAlloc( mem_alloc_order_num ); -#endif // BOOST_MS_CRT_BASED_DEBUG -} - -//____________________________________________________________________________// - -} // namespace debug -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_DEBUG_API_IPP_112006GER diff --git a/ThirdParty/boost/test/impl/decorator.ipp b/ThirdParty/boost/test/impl/decorator.ipp deleted file mode 100644 index 3a0ebb7061f5ef001ed40c295e62d48ab0bcd7fd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/decorator.ipp +++ /dev/null @@ -1,244 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// Description : unit test decorators implementation -// *************************************************************************** - -#ifndef BOOST_TEST_TREE_DECORATOR_IPP_091911GER -#define BOOST_TEST_TREE_DECORATOR_IPP_091911GER - -// Boost.Test -#include <boost/test/tree/decorator.hpp> -#include <boost/test/tree/test_unit.hpp> - -#include <boost/test/framework.hpp> -#if BOOST_TEST_SUPPORT_TOKEN_ITERATOR -#include <boost/test/utils/iterator/token_iterator.hpp> -#endif - -#include <boost/test/detail/throw_exception.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace decorator { - -// ************************************************************************** // -// ************** decorator::collector_t ************** // -// ************************************************************************** // - -// singleton pattern -BOOST_TEST_SINGLETON_CONS_IMPL(collector_t) - - -collector_t& -collector_t::operator*( base const& d ) -{ - m_tu_decorators_stack.begin()->push_back( d.clone() ); - - return *this; -} - -//____________________________________________________________________________// - -void -collector_t::store_in( test_unit& tu ) -{ - tu.p_decorators.value.insert( - tu.p_decorators.value.end(), - m_tu_decorators_stack.begin()->begin(), - m_tu_decorators_stack.begin()->end() ); -} - -//____________________________________________________________________________// - -void -collector_t::reset() -{ - if(m_tu_decorators_stack.size() > 1) { - m_tu_decorators_stack.erase(m_tu_decorators_stack.begin()); - } - else { - assert(m_tu_decorators_stack.size() == 1); - m_tu_decorators_stack.begin()->clear(); - } -} - -void -collector_t::stack() -{ - assert(m_tu_decorators_stack.size() >= 1); - m_tu_decorators_stack.insert(m_tu_decorators_stack.begin(), std::vector<base_ptr>()); -} - -//____________________________________________________________________________// - -std::vector<base_ptr> -collector_t::get_lazy_decorators() const -{ - return *m_tu_decorators_stack.begin(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::base ************** // -// ************************************************************************** // - -collector_t& -base::operator*() const -{ - return collector_t::instance() * *this; -} - -// ************************************************************************** // -// ************** decorator::stack_decorator ************** // -// ************************************************************************** // - -collector_t& -stack_decorator::operator*() const -{ - collector_t& instance = collector_t::instance(); - instance.stack(); - return instance * *this; -} - -void -stack_decorator::apply( test_unit& /*tu*/ ) -{ - // does nothing by definition -} - -// ************************************************************************** // -// ************** decorator::label ************** // -// ************************************************************************** // - -void -label::apply( test_unit& tu ) -{ - tu.add_label( m_label ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::expected_failures ************** // -// ************************************************************************** // - -void -expected_failures::apply( test_unit& tu ) -{ - tu.increase_exp_fail( m_exp_fail ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::timeout ************** // -// ************************************************************************** // - -void -timeout::apply( test_unit& tu ) -{ - tu.p_timeout.value = m_timeout; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::description ************** // -// ************************************************************************** // - -void -description::apply( test_unit& tu ) -{ - tu.p_description.value += m_description; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::depends_on ************** // -// ************************************************************************** // - -void -depends_on::apply( test_unit& tu ) -{ -#if !BOOST_TEST_SUPPORT_TOKEN_ITERATOR - BOOST_TEST_SETUP_ASSERT( false, "depends_on decorator is not supported on this platform" ); -#else - utils::string_token_iterator tit( m_dependency, (utils::dropped_delimeters = "/", utils::kept_delimeters = utils::dt_none) ); - - test_unit* dep = &framework::master_test_suite(); - while( tit != utils::string_token_iterator() ) { - BOOST_TEST_SETUP_ASSERT( dep->p_type == TUT_SUITE, std::string( "incorrect dependency specification " ) + m_dependency ); - - test_unit_id next_id = static_cast<test_suite*>(dep)->get( *tit ); - - BOOST_TEST_SETUP_ASSERT( next_id != INV_TEST_UNIT_ID, - std::string( "incorrect dependency specification " ) + m_dependency ); - - dep = &framework::get( next_id, TUT_ANY ); - ++tit; - } - - tu.depends_on( dep ); -#endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::enable_if/enabled/disabled ************** // -// ************************************************************************** // - -void -enable_if_impl::apply_impl( test_unit& tu, bool condition ) -{ - BOOST_TEST_SETUP_ASSERT(tu.p_default_status == test_unit::RS_INHERIT, - "Can't apply multiple enabled/disabled decorators " - "to the same test unit " + tu.full_name()); - - tu.p_default_status.value = condition ? test_unit::RS_ENABLED : test_unit::RS_DISABLED; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::fixture ************** // -// ************************************************************************** // - -void -fixture_t::apply( test_unit& tu ) -{ - tu.p_fixtures.value.push_back( m_impl ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** decorator::depends_on ************** // -// ************************************************************************** // - -void -precondition::apply( test_unit& tu ) -{ - tu.add_precondition( m_precondition ); -} - -//____________________________________________________________________________// - -} // namespace decorator -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TREE_DECORATOR_IPP_091911GER diff --git a/ThirdParty/boost/test/impl/execution_monitor.ipp b/ThirdParty/boost/test/impl/execution_monitor.ipp deleted file mode 100644 index 3eca20dfb9f6697aa1c675e82f272ece2441d674..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/execution_monitor.ipp +++ /dev/null @@ -1,1524 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// (C) Copyright Beman Dawes and Ullrich Koethe 1995-2001. -// Use, modification, and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Provides execution monitor implementation for all supported -/// configurations, including Microsoft structured exception based, unix signals -/// based and special workarounds for borland -/// -/// Note that when testing requirements or user wishes preclude use of this -/// file as a separate compilation unit, it may be included as a header file. -/// -/// Header dependencies are deliberately restricted to reduce coupling to other -/// boost libraries. -// *************************************************************************** - -#ifndef BOOST_TEST_EXECUTION_MONITOR_IPP_012205GER -#define BOOST_TEST_EXECUTION_MONITOR_IPP_012205GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/detail/throw_exception.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/debug.hpp> - -// Boost -#include <boost/cstdlib.hpp> // for exit codes -#include <boost/config.hpp> // for workarounds -#include <boost/core/ignore_unused.hpp> // for ignore_unused -#ifndef BOOST_NO_EXCEPTIONS -#include <boost/exception/get_error_info.hpp> // for get_error_info -#include <boost/exception/current_exception_cast.hpp> // for current_exception_cast -#include <boost/exception/diagnostic_information.hpp> -#endif - -// STL -#include <string> // for std::string -#include <new> // for std::bad_alloc -#include <typeinfo> // for std::bad_cast, std::bad_typeid -#include <exception> // for std::exception, std::bad_exception -#include <stdexcept> // for std exception hierarchy -#include <cstring> // for C string API -#include <cassert> // for assert -#include <cstddef> // for NULL -#include <cstdio> // for vsnprintf -#include <stdio.h> -#include <cstdarg> // for varargs -#include <stdarg.h> -#include <cmath> // for ceil - -#include <iostream> // for varargs - -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std { using ::strerror; using ::strlen; using ::strncat; using ::ceil; } -#endif - -// to use vsnprintf -#if defined(__SUNPRO_CC) || defined(__SunOS) || defined(__QNXNTO__) || defined(__VXWORKS__) -using std::va_list; -#endif - -#if defined(__VXWORKS__) -# define BOOST_TEST_LIMITED_SIGNAL_DETAILS -#endif - -#ifdef BOOST_SEH_BASED_SIGNAL_HANDLING - -# if !defined(_WIN32_WINNT) // WinXP -# define _WIN32_WINNT 0x0501 -# endif - -# include <windows.h> - -# if defined(__MWERKS__) || (defined(_MSC_VER) && !defined(UNDER_CE)) -# include <eh.h> -# endif - -# if defined(__BORLANDC__) && __BORLANDC__ >= 0x560 || defined(__MWERKS__) -# include <stdint.h> -# endif - -# if defined(__BORLANDC__) && __BORLANDC__ < 0x560 - typedef unsigned uintptr_t; -# endif - -# if defined(UNDER_CE) && BOOST_WORKAROUND(_MSC_VER, < 1500 ) - typedef void* uintptr_t; -# elif defined(UNDER_CE) -# include <crtdefs.h> -# endif - -# if !defined(NDEBUG) && defined(_MSC_VER) && !defined(UNDER_CE) -# include <crtdbg.h> -# define BOOST_TEST_CRT_HOOK_TYPE _CRT_REPORT_HOOK -# define BOOST_TEST_CRT_ASSERT _CRT_ASSERT -# define BOOST_TEST_CRT_ERROR _CRT_ERROR -# define BOOST_TEST_CRT_SET_HOOK(H) _CrtSetReportHook(H) -# else -# define BOOST_TEST_CRT_HOOK_TYPE void* -# define BOOST_TEST_CRT_ASSERT 2 -# define BOOST_TEST_CRT_ERROR 1 -# define BOOST_TEST_CRT_SET_HOOK(H) (void*)(H) -# endif - -# if defined(_WIN32_WINNT) && (_WIN32_WINNT >= 0x0501) /* WinXP */ -# define BOOST_TEST_WIN32_WAITABLE_TIMERS -# endif - -# if (!BOOST_WORKAROUND(_MSC_VER, >= 1400 ) && \ - !defined(BOOST_COMO)) || defined(UNDER_CE) - -typedef void* _invalid_parameter_handler; - -inline _invalid_parameter_handler -_set_invalid_parameter_handler( _invalid_parameter_handler arg ) -{ - return arg; -} - -# endif - -# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x0564)) || defined(UNDER_CE) - -namespace { void _set_se_translator( void* ) {} } - -# endif - -#elif defined(BOOST_HAS_SIGACTION) - -# define BOOST_SIGACTION_BASED_SIGNAL_HANDLING - -# include <unistd.h> -# include <signal.h> -# include <setjmp.h> - -# if defined(__FreeBSD__) - -# include <osreldate.h> - -# ifndef SIGPOLL -# define SIGPOLL SIGIO -# endif - -# if (__FreeBSD_version < 70100) - -# define ILL_ILLADR 0 // ILL_RESAD_FAULT -# define ILL_PRVOPC ILL_PRIVIN_FAULT -# define ILL_ILLOPN 2 // ILL_RESOP_FAULT -# define ILL_COPROC ILL_FPOP_FAULT - -# define BOOST_TEST_LIMITED_SIGNAL_DETAILS - -# endif -# endif - -# if defined(__ANDROID__) -# include <android/api-level.h> -# endif - -// documentation of BOOST_TEST_DISABLE_ALT_STACK in execution_monitor.hpp -# if !defined(__CYGWIN__) && !defined(__QNXNTO__) && !defined(__bgq__) && \ - (!defined(__ANDROID__) || __ANDROID_API__ >= 8) && \ - !defined(BOOST_TEST_DISABLE_ALT_STACK) -# define BOOST_TEST_USE_ALT_STACK -# endif - -# if defined(SIGPOLL) && !defined(__CYGWIN__) && \ - !(defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) && \ - !defined(__NetBSD__) && \ - !defined(__QNXNTO__) -# define BOOST_TEST_CATCH_SIGPOLL -# endif - -# ifdef BOOST_TEST_USE_ALT_STACK -# define BOOST_TEST_ALT_STACK_SIZE SIGSTKSZ -# endif - - -#else - -# define BOOST_NO_SIGNAL_HANDLING - -#endif - -#ifndef UNDER_CE -#include <errno.h> -#endif - -#if !defined(BOOST_NO_TYPEID) && !defined(BOOST_NO_RTTI) -# include <boost/core/demangle.hpp> -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { - -// ************************************************************************** // -// ************** throw_exception ************** // -// ************************************************************************** // - -#ifdef BOOST_NO_EXCEPTIONS -void throw_exception( std::exception const & e ) { abort(); } -#endif - -// ************************************************************************** // -// ************** report_error ************** // -// ************************************************************************** // - -namespace detail { - -#ifdef __BORLANDC__ -# define BOOST_TEST_VSNPRINTF( a1, a2, a3, a4 ) std::vsnprintf( (a1), (a2), (a3), (a4) ) -#elif BOOST_WORKAROUND(_MSC_VER, <= 1310) || \ - BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3000)) || \ - defined(UNDER_CE) || \ - (defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR)) -# define BOOST_TEST_VSNPRINTF( a1, a2, a3, a4 ) _vsnprintf( (a1), (a2), (a3), (a4) ) -#else -# define BOOST_TEST_VSNPRINTF( a1, a2, a3, a4 ) vsnprintf( (a1), (a2), (a3), (a4) ) -#endif - -#ifndef BOOST_NO_EXCEPTIONS - -template <typename ErrorInfo> -typename ErrorInfo::value_type -extract( boost::exception const* ex ) -{ - if( !ex ) - return 0; - - typename ErrorInfo::value_type const * val = boost::get_error_info<ErrorInfo>( *ex ); - - return val ? *val : 0; -} - -//____________________________________________________________________________// - -static void -#if __GNUC__ >= 3 -__attribute__((__format__ (__printf__, 3, 0))) -#endif -report_error( execution_exception::error_code ec, boost::exception const* be, char const* format, va_list* args ) -{ - static const int REPORT_ERROR_BUFFER_SIZE = 4096; - static char buf[REPORT_ERROR_BUFFER_SIZE]; - - BOOST_TEST_VSNPRINTF( buf, sizeof(buf)-1, format, *args ); - buf[sizeof(buf)-1] = 0; - - va_end( *args ); - - BOOST_TEST_I_THROW(execution_exception( ec, buf, execution_exception::location( extract<throw_file>( be ), - (size_t)extract<throw_line>( be ), - extract<throw_function>( be ) ) )); -} - -//____________________________________________________________________________// - -static void -#if __GNUC__ >= 3 -__attribute__((__format__ (__printf__, 3, 4))) -#endif -report_error( execution_exception::error_code ec, boost::exception const* be, char const* format, ... ) -{ - va_list args; - va_start( args, format ); - - report_error( ec, be, format, &args ); -} - -#endif - -//____________________________________________________________________________// - -static void -#if __GNUC__ >= 3 -__attribute__((__format__ (__printf__, 2, 3))) -#endif -report_error( execution_exception::error_code ec, char const* format, ... ) -{ - va_list args; - va_start( args, format ); - - report_error( ec, 0, format, &args ); -} - -//____________________________________________________________________________// - -template<typename Tr,typename Functor> -inline int -do_invoke( Tr const& tr, Functor const& F ) -{ - return tr ? (*tr)( F ) : F(); -} - -//____________________________________________________________________________// - -struct fpe_except_guard { - explicit fpe_except_guard( unsigned detect_fpe ) - : m_detect_fpe( detect_fpe ) - { - // prepare fp exceptions control - m_previously_enabled = fpe::disable( fpe::BOOST_FPE_ALL ); - if( m_previously_enabled != fpe::BOOST_FPE_INV && detect_fpe != fpe::BOOST_FPE_OFF ) - fpe::enable( detect_fpe ); - } - ~fpe_except_guard() - { - if( m_detect_fpe != fpe::BOOST_FPE_OFF ) - fpe::disable( m_detect_fpe ); - if( m_previously_enabled != fpe::BOOST_FPE_INV ) - fpe::enable( m_previously_enabled ); - } - - unsigned m_detect_fpe; - unsigned m_previously_enabled; -}; - - -// ************************************************************************** // -// ************** typeid_name ************** // -// ************************************************************************** // - -#if !defined(BOOST_NO_TYPEID) && !defined(BOOST_NO_RTTI) -template<typename T> -std::string -typeid_name( T const& t ) -{ - return boost::core::demangle(typeid(t).name()); -} -#endif - -} // namespace detail - -#if defined(BOOST_SIGACTION_BASED_SIGNAL_HANDLING) - -// ************************************************************************** // -// ************** Sigaction based signal handling ************** // -// ************************************************************************** // - -namespace detail { - -// ************************************************************************** // -// ************** boost::detail::system_signal_exception ************** // -// ************************************************************************** // - -class system_signal_exception { -public: - // Constructor - system_signal_exception() - : m_sig_info( 0 ) - , m_context( 0 ) - {} - - // Access methods - void operator()( siginfo_t* i, void* c ) - { - m_sig_info = i; - m_context = c; - } - void report() const; - -private: - // Data members - siginfo_t* m_sig_info; // system signal detailed info - void* m_context; // signal context -}; - -//____________________________________________________________________________// - -void -system_signal_exception::report() const -{ - if( !m_sig_info ) - return; // no error actually occur? - - switch( m_sig_info->si_code ) { -#ifdef __VXWORKS__ -// a bit of a hack to adapt code to small m_sig_info VxWorks uses -#define si_addr si_value.sival_int -#define si_band si_value.sival_int -#else - case SI_USER: - report_error( execution_exception::system_error, - "signal: generated by kill() (or family); uid=%d; pid=%d", - (int)m_sig_info->si_uid, (int)m_sig_info->si_pid ); - break; -#endif - case SI_QUEUE: - report_error( execution_exception::system_error, - "signal: sent by sigqueue()" ); - break; - case SI_TIMER: - report_error( execution_exception::system_error, - "signal: the expiration of a timer set by timer_settimer()" ); - break; -// OpenBSD was missing SI_ASYNCIO and SI_MESGQ -#ifdef SI_ASYNCIO - case SI_ASYNCIO: - report_error( execution_exception::system_error, - "signal: generated by the completion of an asynchronous I/O request" ); - break; -#endif -#ifdef SI_MESGQ - case SI_MESGQ: - report_error( execution_exception::system_error, - "signal: generated by the the arrival of a message on an empty message queue" ); - break; -#endif - default: - break; - } - - switch( m_sig_info->si_signo ) { - case SIGILL: - switch( m_sig_info->si_code ) { -#ifndef BOOST_TEST_LIMITED_SIGNAL_DETAILS - case ILL_ILLOPC: - report_error( execution_exception::system_fatal_error, - "signal: illegal opcode; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_ILLTRP: - report_error( execution_exception::system_fatal_error, - "signal: illegal trap; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_PRVREG: - report_error( execution_exception::system_fatal_error, - "signal: privileged register; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_BADSTK: - report_error( execution_exception::system_fatal_error, - "signal: internal stack error; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; -#endif - case ILL_ILLOPN: - report_error( execution_exception::system_fatal_error, - "signal: illegal operand; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_ILLADR: - report_error( execution_exception::system_fatal_error, - "signal: illegal addressing mode; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_PRVOPC: - report_error( execution_exception::system_fatal_error, - "signal: privileged opcode; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case ILL_COPROC: - report_error( execution_exception::system_fatal_error, - "signal: co-processor error; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - default: - report_error( execution_exception::system_fatal_error, - "signal: SIGILL, si_code: %d (illegal instruction; address of failing instruction: 0x%08lx)", - m_sig_info->si_code, (uintptr_t) m_sig_info->si_addr ); - break; - } - break; - - case SIGFPE: - switch( m_sig_info->si_code ) { - case FPE_INTDIV: - report_error( execution_exception::system_error, - "signal: integer divide by zero; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_INTOVF: - report_error( execution_exception::system_error, - "signal: integer overflow; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTDIV: - report_error( execution_exception::system_error, - "signal: floating point divide by zero; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTOVF: - report_error( execution_exception::system_error, - "signal: floating point overflow; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTUND: - report_error( execution_exception::system_error, - "signal: floating point underflow; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTRES: - report_error( execution_exception::system_error, - "signal: floating point inexact result; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTINV: - report_error( execution_exception::system_error, - "signal: invalid floating point operation; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - case FPE_FLTSUB: - report_error( execution_exception::system_error, - "signal: subscript out of range; address of failing instruction: 0x%08lx", - (uintptr_t) m_sig_info->si_addr ); - break; - default: - report_error( execution_exception::system_error, - "signal: SIGFPE, si_code: %d (errnoneous arithmetic operations; address of failing instruction: 0x%08lx)", - m_sig_info->si_code, (uintptr_t) m_sig_info->si_addr ); - break; - } - break; - - case SIGSEGV: - switch( m_sig_info->si_code ) { -#ifndef BOOST_TEST_LIMITED_SIGNAL_DETAILS - case SEGV_MAPERR: - report_error( execution_exception::system_fatal_error, - "memory access violation at address: 0x%08lx: no mapping at fault address", - (uintptr_t) m_sig_info->si_addr ); - break; - case SEGV_ACCERR: - report_error( execution_exception::system_fatal_error, - "memory access violation at address: 0x%08lx: invalid permissions", - (uintptr_t) m_sig_info->si_addr ); - break; -#endif - default: - report_error( execution_exception::system_fatal_error, - "signal: SIGSEGV, si_code: %d (memory access violation at address: 0x%08lx)", - m_sig_info->si_code, (uintptr_t) m_sig_info->si_addr ); - break; - } - break; - - case SIGBUS: - switch( m_sig_info->si_code ) { -#ifndef BOOST_TEST_LIMITED_SIGNAL_DETAILS - case BUS_ADRALN: - report_error( execution_exception::system_fatal_error, - "memory access violation at address: 0x%08lx: invalid address alignment", - (uintptr_t) m_sig_info->si_addr ); - break; - case BUS_ADRERR: - report_error( execution_exception::system_fatal_error, - "memory access violation at address: 0x%08lx: non-existent physical address", - (uintptr_t) m_sig_info->si_addr ); - break; - case BUS_OBJERR: - report_error( execution_exception::system_fatal_error, - "memory access violation at address: 0x%08lx: object specific hardware error", - (uintptr_t) m_sig_info->si_addr ); - break; -#endif - default: - report_error( execution_exception::system_fatal_error, - "signal: SIGSEGV, si_code: %d (memory access violation at address: 0x%08lx)", - m_sig_info->si_code, (uintptr_t) m_sig_info->si_addr ); - break; - } - break; - -#if defined(BOOST_TEST_CATCH_SIGPOLL) - - case SIGPOLL: - switch( m_sig_info->si_code ) { -#ifndef BOOST_TEST_LIMITED_SIGNAL_DETAILS - case POLL_IN: - report_error( execution_exception::system_error, - "data input available; band event %d", - (int)m_sig_info->si_band ); - break; - case POLL_OUT: - report_error( execution_exception::system_error, - "output buffers available; band event %d", - (int)m_sig_info->si_band ); - break; - case POLL_MSG: - report_error( execution_exception::system_error, - "input message available; band event %d", - (int)m_sig_info->si_band ); - break; - case POLL_ERR: - report_error( execution_exception::system_error, - "i/o error; band event %d", - (int)m_sig_info->si_band ); - break; - case POLL_PRI: - report_error( execution_exception::system_error, - "high priority input available; band event %d", - (int)m_sig_info->si_band ); - break; -#if defined(POLL_ERR) && defined(POLL_HUP) && (POLL_ERR - POLL_HUP) - case POLL_HUP: - report_error( execution_exception::system_error, - "device disconnected; band event %d", - (int)m_sig_info->si_band ); - break; -#endif -#endif - default: - report_error( execution_exception::system_error, - "signal: SIGPOLL, si_code: %d (asynchronous I/O event occurred; band event %d)", - m_sig_info->si_code, (int)m_sig_info->si_band ); - break; - } - break; - -#endif - - case SIGABRT: - report_error( execution_exception::system_error, - "signal: SIGABRT (application abort requested)" ); - break; - - case SIGALRM: - report_error( execution_exception::timeout_error, - "signal: SIGALRM (timeout while executing function)" ); - break; - - default: - report_error( execution_exception::system_error, - "unrecognized signal %d", m_sig_info->si_signo ); - } -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** boost::detail::signal_action ************** // -// ************************************************************************** // - -// Forward declaration -extern "C" { -static void boost_execution_monitor_jumping_signal_handler( int sig, siginfo_t* info, void* context ); -static void boost_execution_monitor_attaching_signal_handler( int sig, siginfo_t* info, void* context ); -} - -class signal_action { - typedef struct sigaction* sigaction_ptr; -public: - //Constructor - signal_action(); - signal_action( int sig, bool install, bool attach_dbg, char* alt_stack ); - ~signal_action(); - -private: - // Data members - int m_sig; - bool m_installed; - struct sigaction m_new_action; - struct sigaction m_old_action; -}; - -//____________________________________________________________________________// - -signal_action::signal_action() -: m_installed( false ) -{} - -//____________________________________________________________________________// - -signal_action::signal_action( int sig, bool install, bool attach_dbg, char* alt_stack ) -: m_sig( sig ) -, m_installed( install ) -{ - if( !install ) - return; - - std::memset( &m_new_action, 0, sizeof(struct sigaction) ); - - BOOST_TEST_SYS_ASSERT( ::sigaction( m_sig , sigaction_ptr(), &m_new_action ) != -1 ); - - if( m_new_action.sa_sigaction || m_new_action.sa_handler ) { - m_installed = false; - return; - } - - m_new_action.sa_flags |= SA_SIGINFO; - m_new_action.sa_sigaction = attach_dbg ? &boost_execution_monitor_attaching_signal_handler - : &boost_execution_monitor_jumping_signal_handler; - BOOST_TEST_SYS_ASSERT( sigemptyset( &m_new_action.sa_mask ) != -1 ); - -#ifdef BOOST_TEST_USE_ALT_STACK - if( alt_stack ) - m_new_action.sa_flags |= SA_ONSTACK; -#endif - - BOOST_TEST_SYS_ASSERT( ::sigaction( m_sig, &m_new_action, &m_old_action ) != -1 ); -} - -//____________________________________________________________________________// - -signal_action::~signal_action() -{ - if( m_installed ) - ::sigaction( m_sig, &m_old_action , sigaction_ptr() ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** boost::detail::signal_handler ************** // -// ************************************************************************** // - -class signal_handler { -public: - // Constructor - explicit signal_handler( bool catch_system_errors, - bool detect_fpe, - unsigned long int timeout_microseconds, - bool attach_dbg, - char* alt_stack ); - - // Destructor - ~signal_handler(); - - // access methods - static sigjmp_buf& jump_buffer() - { - assert( !!s_active_handler ); - - return s_active_handler->m_sigjmp_buf; - } - - static system_signal_exception& sys_sig() - { - assert( !!s_active_handler ); - - return s_active_handler->m_sys_sig; - } - -private: - // Data members - signal_handler* m_prev_handler; - unsigned long int m_timeout_microseconds; - - // Note: We intentionality do not catch SIGCHLD. Users have to deal with it themselves - signal_action m_ILL_action; - signal_action m_FPE_action; - signal_action m_SEGV_action; - signal_action m_BUS_action; - signal_action m_CHLD_action; - signal_action m_POLL_action; - signal_action m_ABRT_action; - signal_action m_ALRM_action; - - sigjmp_buf m_sigjmp_buf; - system_signal_exception m_sys_sig; - - static signal_handler* s_active_handler; -}; - -// !! need to be placed in thread specific storage -typedef signal_handler* signal_handler_ptr; -signal_handler* signal_handler::s_active_handler = signal_handler_ptr(); - -//____________________________________________________________________________// - -signal_handler::signal_handler( bool catch_system_errors, - bool detect_fpe, - unsigned long int timeout_microseconds, - bool attach_dbg, - char* alt_stack ) -: m_prev_handler( s_active_handler ) -, m_timeout_microseconds( timeout_microseconds ) -, m_ILL_action ( SIGILL , catch_system_errors, attach_dbg, alt_stack ) -, m_FPE_action ( SIGFPE , detect_fpe , attach_dbg, alt_stack ) -, m_SEGV_action( SIGSEGV, catch_system_errors, attach_dbg, alt_stack ) -, m_BUS_action ( SIGBUS , catch_system_errors, attach_dbg, alt_stack ) -#ifdef BOOST_TEST_CATCH_SIGPOLL -, m_POLL_action( SIGPOLL, catch_system_errors, attach_dbg, alt_stack ) -#endif -, m_ABRT_action( SIGABRT, catch_system_errors, attach_dbg, alt_stack ) -, m_ALRM_action( SIGALRM, timeout_microseconds > 0, attach_dbg, alt_stack ) -{ - s_active_handler = this; - - if( m_timeout_microseconds > 0 ) { - ::alarm( 0 ); - ::alarm( static_cast<unsigned int>(std::ceil(timeout_microseconds / 1E6) )); // alarm has a precision to the seconds - } - -#ifdef BOOST_TEST_USE_ALT_STACK - if( alt_stack ) { - stack_t sigstk; - std::memset( &sigstk, 0, sizeof(stack_t) ); - - BOOST_TEST_SYS_ASSERT( ::sigaltstack( 0, &sigstk ) != -1 ); - - if( sigstk.ss_flags & SS_DISABLE ) { - sigstk.ss_sp = alt_stack; - sigstk.ss_size = BOOST_TEST_ALT_STACK_SIZE; - sigstk.ss_flags = 0; - BOOST_TEST_SYS_ASSERT( ::sigaltstack( &sigstk, 0 ) != -1 ); - } - } -#endif -} - -//____________________________________________________________________________// - -signal_handler::~signal_handler() -{ - assert( s_active_handler == this ); - - if( m_timeout_microseconds > 0 ) - ::alarm( 0 ); - -#ifdef BOOST_TEST_USE_ALT_STACK -#ifdef __GNUC__ - // We shouldn't need to explicitly initialize all the members here, - // but gcc warns if we don't, so add initializers for each of the - // members specified in the POSIX std: - stack_t sigstk = { 0, 0, 0 }; -#else - stack_t sigstk = { }; -#endif - - sigstk.ss_size = MINSIGSTKSZ; - sigstk.ss_flags = SS_DISABLE; - if( ::sigaltstack( &sigstk, 0 ) == -1 ) { - int error_n = errno; - std::cerr << "******** errors disabling the alternate stack:" << std::endl - << "\t#error:" << error_n << std::endl - << "\t" << std::strerror( error_n ) << std::endl; - } -#endif - - s_active_handler = m_prev_handler; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** execution_monitor_signal_handler ************** // -// ************************************************************************** // - -extern "C" { - -static void boost_execution_monitor_jumping_signal_handler( int sig, siginfo_t* info, void* context ) -{ - signal_handler::sys_sig()( info, context ); - - siglongjmp( signal_handler::jump_buffer(), sig ); -} - -//____________________________________________________________________________// - -static void boost_execution_monitor_attaching_signal_handler( int sig, siginfo_t* info, void* context ) -{ - if( !debug::attach_debugger( false ) ) - boost_execution_monitor_jumping_signal_handler( sig, info, context ); - - // debugger attached; it will handle the signal - BOOST_TEST_SYS_ASSERT( ::signal( sig, SIG_DFL ) != SIG_ERR ); -} - -//____________________________________________________________________________// - -} - -} // namespace detail - -// ************************************************************************** // -// ************** execution_monitor::catch_signals ************** // -// ************************************************************************** // - -int -execution_monitor::catch_signals( boost::function<int ()> const& F ) -{ - using namespace detail; - -#if defined(__CYGWIN__) - p_catch_system_errors.value = false; -#endif - -#ifdef BOOST_TEST_USE_ALT_STACK - if( !!p_use_alt_stack && !m_alt_stack ) - m_alt_stack.reset( new char[BOOST_TEST_ALT_STACK_SIZE] ); -#else - p_use_alt_stack.value = false; -#endif - - signal_handler local_signal_handler( p_catch_system_errors, - p_catch_system_errors || (p_detect_fp_exceptions != fpe::BOOST_FPE_OFF), - p_timeout, - p_auto_start_dbg, - !p_use_alt_stack ? 0 : m_alt_stack.get() ); - - if( !sigsetjmp( signal_handler::jump_buffer(), 1 ) ) - return detail::do_invoke( m_custom_translators , F ); - else - BOOST_TEST_I_THROW( local_signal_handler.sys_sig() ); -} - -//____________________________________________________________________________// - -#elif defined(BOOST_SEH_BASED_SIGNAL_HANDLING) - -// ************************************************************************** // -// ************** Microsoft structured exception handling ************** // -// ************************************************************************** // - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x0564)) -namespace { void _set_se_translator( void* ) {} } -#endif - -namespace detail { - -// ************************************************************************** // -// ************** boost::detail::system_signal_exception ************** // -// ************************************************************************** // - -class system_signal_exception { -public: - // Constructor - explicit system_signal_exception( execution_monitor* em ) - : m_em( em ) - , m_se_id( 0 ) - , m_fault_address( 0 ) - , m_dir( false ) - , m_timeout( false ) - {} - - void set_timed_out(); - void report() const; - int operator()( unsigned id, _EXCEPTION_POINTERS* exps ); - -private: - // Data members - execution_monitor* m_em; - - unsigned m_se_id; - void* m_fault_address; - bool m_dir; - bool m_timeout; -}; - -//____________________________________________________________________________// - -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1310) -static void -seh_catch_preventer( unsigned /* id */, _EXCEPTION_POINTERS* /* exps */ ) -{ - throw; -} -#endif - -//____________________________________________________________________________// - -void -system_signal_exception::set_timed_out() -{ - m_timeout = true; -} - -//____________________________________________________________________________// - -int -system_signal_exception::operator()( unsigned id, _EXCEPTION_POINTERS* exps ) -{ - const unsigned MSFT_CPP_EXCEPT = 0xE06d7363; // EMSC - - // C++ exception - allow to go through - if( id == MSFT_CPP_EXCEPT ) - return EXCEPTION_CONTINUE_SEARCH; - - // FPE detection is enabled, while system exception detection is not - check if this is actually FPE - if( !m_em->p_catch_system_errors ) { - if( !m_em->p_detect_fp_exceptions ) - return EXCEPTION_CONTINUE_SEARCH; - - switch( id ) { - case EXCEPTION_FLT_DIVIDE_BY_ZERO: - case EXCEPTION_FLT_STACK_CHECK: - case EXCEPTION_FLT_DENORMAL_OPERAND: - case EXCEPTION_FLT_INEXACT_RESULT: - case EXCEPTION_FLT_OVERFLOW: - case EXCEPTION_FLT_UNDERFLOW: - case EXCEPTION_FLT_INVALID_OPERATION: - case STATUS_FLOAT_MULTIPLE_FAULTS: - case STATUS_FLOAT_MULTIPLE_TRAPS: - break; - default: - return EXCEPTION_CONTINUE_SEARCH; - } - } - - if( !!m_em->p_auto_start_dbg && debug::attach_debugger( false ) ) { - m_em->p_catch_system_errors.value = false; -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1310) - _set_se_translator( &seh_catch_preventer ); -#endif - return EXCEPTION_CONTINUE_EXECUTION; - } - - m_se_id = id; - if( m_se_id == EXCEPTION_ACCESS_VIOLATION && exps->ExceptionRecord->NumberParameters == 2 ) { - m_fault_address = (void*)exps->ExceptionRecord->ExceptionInformation[1]; - m_dir = exps->ExceptionRecord->ExceptionInformation[0] == 0; - } - - return EXCEPTION_EXECUTE_HANDLER; -} - -//____________________________________________________________________________// - -void -system_signal_exception::report() const -{ - switch( m_se_id ) { - // cases classified as system_fatal_error - case EXCEPTION_ACCESS_VIOLATION: { - if( !m_fault_address ) - detail::report_error( execution_exception::system_fatal_error, "memory access violation" ); - else - detail::report_error( - execution_exception::system_fatal_error, - "memory access violation occurred at address 0x%08lx, while attempting to %s", - m_fault_address, - m_dir ? " read inaccessible data" - : " write to an inaccessible (or protected) address" - ); - break; - } - - case EXCEPTION_ILLEGAL_INSTRUCTION: - detail::report_error( execution_exception::system_fatal_error, "illegal instruction" ); - break; - - case EXCEPTION_PRIV_INSTRUCTION: - detail::report_error( execution_exception::system_fatal_error, "tried to execute an instruction whose operation is not allowed in the current machine mode" ); - break; - - case EXCEPTION_IN_PAGE_ERROR: - detail::report_error( execution_exception::system_fatal_error, "access to a memory page that is not present" ); - break; - - case EXCEPTION_STACK_OVERFLOW: - detail::report_error( execution_exception::system_fatal_error, "stack overflow" ); - break; - - case EXCEPTION_NONCONTINUABLE_EXCEPTION: - detail::report_error( execution_exception::system_fatal_error, "tried to continue execution after a non continuable exception occurred" ); - break; - - // cases classified as (non-fatal) system_trap - case EXCEPTION_DATATYPE_MISALIGNMENT: - detail::report_error( execution_exception::system_error, "data misalignment" ); - break; - - case EXCEPTION_INT_DIVIDE_BY_ZERO: - detail::report_error( execution_exception::system_error, "integer divide by zero" ); - break; - - case EXCEPTION_INT_OVERFLOW: - detail::report_error( execution_exception::system_error, "integer overflow" ); - break; - - case EXCEPTION_ARRAY_BOUNDS_EXCEEDED: - detail::report_error( execution_exception::system_error, "array bounds exceeded" ); - break; - - case EXCEPTION_FLT_DIVIDE_BY_ZERO: - detail::report_error( execution_exception::system_error, "floating point divide by zero" ); - break; - - case EXCEPTION_FLT_STACK_CHECK: - detail::report_error( execution_exception::system_error, - "stack overflowed or underflowed as the result of a floating-point operation" ); - break; - - case EXCEPTION_FLT_DENORMAL_OPERAND: - detail::report_error( execution_exception::system_error, - "operand of floating point operation is denormal" ); - break; - - case EXCEPTION_FLT_INEXACT_RESULT: - detail::report_error( execution_exception::system_error, - "result of a floating-point operation cannot be represented exactly" ); - break; - - case EXCEPTION_FLT_OVERFLOW: - detail::report_error( execution_exception::system_error, - "exponent of a floating-point operation is greater than the magnitude allowed by the corresponding type" ); - break; - - case EXCEPTION_FLT_UNDERFLOW: - detail::report_error( execution_exception::system_error, - "exponent of a floating-point operation is less than the magnitude allowed by the corresponding type" ); - break; - - case EXCEPTION_FLT_INVALID_OPERATION: - detail::report_error( execution_exception::system_error, "floating point error" ); - break; - - case STATUS_FLOAT_MULTIPLE_FAULTS: - detail::report_error( execution_exception::system_error, "multiple floating point errors" ); - break; - - case STATUS_FLOAT_MULTIPLE_TRAPS: - detail::report_error( execution_exception::system_error, "multiple floating point errors" ); - break; - - case EXCEPTION_BREAKPOINT: - detail::report_error( execution_exception::system_error, "breakpoint encountered" ); - break; - - default: - if( m_timeout ) { - detail::report_error(execution_exception::timeout_error, "timeout while executing function"); - } - else { - detail::report_error( execution_exception::system_error, "unrecognized exception. Id: 0x%08lx", m_se_id ); - } - break; - } -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** assert_reporting_function ************** // -// ************************************************************************** // - -int BOOST_TEST_CALL_DECL -assert_reporting_function( int reportType, char* userMessage, int* ) -{ - // write this way instead of switch to avoid unreachable statements - if( reportType == BOOST_TEST_CRT_ASSERT || reportType == BOOST_TEST_CRT_ERROR ) - detail::report_error( reportType == BOOST_TEST_CRT_ASSERT ? execution_exception::user_error : execution_exception::system_error, userMessage ); - - return 0; -} // assert_reporting_function - -//____________________________________________________________________________// - -void BOOST_TEST_CALL_DECL -invalid_param_handler( wchar_t const* /* expr */, - wchar_t const* /* func */, - wchar_t const* /* file */, - unsigned /* line */, - uintptr_t /* reserved */) -{ - detail::report_error( execution_exception::user_error, - "Invalid parameter detected by C runtime library" ); -} - -//____________________________________________________________________________// - -} // namespace detail - -// ************************************************************************** // -// ************** execution_monitor::catch_signals ************** // -// ************************************************************************** // - -int -execution_monitor::catch_signals( boost::function<int ()> const& F ) -{ - _invalid_parameter_handler old_iph = _invalid_parameter_handler(); - BOOST_TEST_CRT_HOOK_TYPE old_crt_hook = 0; - - if( p_catch_system_errors ) { - old_crt_hook = BOOST_TEST_CRT_SET_HOOK( &detail::assert_reporting_function ); - - old_iph = _set_invalid_parameter_handler( - reinterpret_cast<_invalid_parameter_handler>( &detail::invalid_param_handler ) ); - } else if( !p_detect_fp_exceptions ) { -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1310) - _set_se_translator( &detail::seh_catch_preventer ); -#endif - } - -#if defined(BOOST_TEST_WIN32_WAITABLE_TIMERS) - HANDLE htimer = INVALID_HANDLE_VALUE; - BOOL bTimerSuccess = FALSE; - - if( p_timeout ) { - htimer = ::CreateWaitableTimer( - NULL, - TRUE, - NULL); // naming the timer might create collisions - - if( htimer != INVALID_HANDLE_VALUE ) { - LARGE_INTEGER liDueTime; - liDueTime.QuadPart = - static_cast<LONGLONG>(p_timeout) * 10ll; // resolution of 100 ns - - bTimerSuccess = ::SetWaitableTimer( - htimer, - &liDueTime, - 0, - 0, - 0, - FALSE); // Do not restore a suspended system - } - } -#endif - - detail::system_signal_exception SSE( this ); - - int ret_val = 0; - // clang windows workaround: this not available in __finally scope - bool l_catch_system_errors = p_catch_system_errors; - - __try { - __try { - ret_val = detail::do_invoke( m_custom_translators, F ); - } - __except( SSE( GetExceptionCode(), GetExceptionInformation() ) ) { - throw SSE; - } - - // we check for time outs: we do not have any signaling facility on Win32 - // however, we signal a timeout as a hard error as for the other operating systems - // and throw the signal error handler - if( bTimerSuccess && htimer != INVALID_HANDLE_VALUE) { - if (::WaitForSingleObject(htimer, 0) == WAIT_OBJECT_0) { - SSE.set_timed_out(); - throw SSE; - } - } - - } - __finally { - -#if defined(BOOST_TEST_WIN32_WAITABLE_TIMERS) - if( htimer != INVALID_HANDLE_VALUE ) { - ::CloseHandle(htimer); - } -#endif - - if( l_catch_system_errors ) { - BOOST_TEST_CRT_SET_HOOK( old_crt_hook ); - - _set_invalid_parameter_handler( old_iph ); - } - } - - return ret_val; -} - -//____________________________________________________________________________// - -#else // default signal handler - -namespace detail { - -class system_signal_exception { -public: - void report() const {} -}; - -} // namespace detail - -int -execution_monitor::catch_signals( boost::function<int ()> const& F ) -{ - return detail::do_invoke( m_custom_translators , F ); -} - -//____________________________________________________________________________// - -#endif // choose signal handler - -// ************************************************************************** // -// ************** execution_monitor ************** // -// ************************************************************************** // - -execution_monitor::execution_monitor() -: p_catch_system_errors( true ) -, p_auto_start_dbg( false ) -, p_timeout( 0 ) -, p_use_alt_stack( true ) -, p_detect_fp_exceptions( fpe::BOOST_FPE_OFF ) -{} - -//____________________________________________________________________________// - -int -execution_monitor::execute( boost::function<int ()> const& F ) -{ - if( debug::under_debugger() ) - p_catch_system_errors.value = false; - - BOOST_TEST_I_TRY { - detail::fpe_except_guard G( p_detect_fp_exceptions ); - boost::ignore_unused( G ); - - return catch_signals( F ); - } - -#ifndef BOOST_NO_EXCEPTIONS - - // Catch-clause reference arguments are a bit different from function - // arguments (ISO 15.3 paragraphs 18 & 19). Apparently const isn't - // required. Programmers ask for const anyhow, so we supply it. That's - // easier than answering questions about non-const usage. - - catch( char const* ex ) - { detail::report_error( execution_exception::cpp_exception_error, - "C string: %s", ex ); } - catch( std::string const& ex ) - { detail::report_error( execution_exception::cpp_exception_error, - "std::string: %s", ex.c_str() ); } - - // boost::exception (before std::exception, with extended diagnostic) - catch( boost::exception const& ex ) - { detail::report_error( execution_exception::cpp_exception_error, - &ex, - "%s", boost::diagnostic_information(ex).c_str() ); } - - // std:: exceptions -#if defined(BOOST_NO_TYPEID) || defined(BOOST_NO_RTTI) -#define CATCH_AND_REPORT_STD_EXCEPTION( ex_name ) \ - catch( ex_name const& ex ) \ - { detail::report_error( execution_exception::cpp_exception_error, \ - current_exception_cast<boost::exception const>(), \ - #ex_name ": %s", ex.what() ); } \ -/**/ -#else -#define CATCH_AND_REPORT_STD_EXCEPTION( ex_name ) \ - catch( ex_name const& ex ) \ - { detail::report_error( execution_exception::cpp_exception_error, \ - current_exception_cast<boost::exception const>(), \ - "%s: %s", detail::typeid_name(ex).c_str(), ex.what() ); } \ -/**/ -#endif - - CATCH_AND_REPORT_STD_EXCEPTION( std::bad_alloc ) - CATCH_AND_REPORT_STD_EXCEPTION( std::bad_cast ) - CATCH_AND_REPORT_STD_EXCEPTION( std::bad_typeid ) - CATCH_AND_REPORT_STD_EXCEPTION( std::bad_exception ) - CATCH_AND_REPORT_STD_EXCEPTION( std::domain_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::invalid_argument ) - CATCH_AND_REPORT_STD_EXCEPTION( std::length_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::out_of_range ) - CATCH_AND_REPORT_STD_EXCEPTION( std::range_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::overflow_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::underflow_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::logic_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::runtime_error ) - CATCH_AND_REPORT_STD_EXCEPTION( std::exception ) -#undef CATCH_AND_REPORT_STD_EXCEPTION - - // system errors - catch( system_error const& ex ) - { detail::report_error( execution_exception::cpp_exception_error, - "system_error produced by: %s: %s", ex.p_failed_exp, std::strerror( ex.p_errno ) ); } - catch( detail::system_signal_exception const& ex ) - { ex.report(); } - - // not an error - catch( execution_aborted const& ) - { return 0; } - - // just forward - catch( execution_exception const& ) - { throw; } - - // unknown error - catch( ... ) - { detail::report_error( execution_exception::cpp_exception_error, "unknown type" ); } - -#endif // !BOOST_NO_EXCEPTIONS - - BOOST_TEST_UNREACHABLE_RETURN(0); // never reached; supplied to quiet compiler warnings -} // execute - -//____________________________________________________________________________// - -namespace detail { - -struct forward { - explicit forward( boost::function<void ()> const& F ) : m_F( F ) {} - - int operator()() { m_F(); return 0; } - - boost::function<void ()> const& m_F; -}; - -} // namespace detail -void -execution_monitor::vexecute( boost::function<void ()> const& F ) -{ - execute( detail::forward( F ) ); -} - -// ************************************************************************** // -// ************** system_error ************** // -// ************************************************************************** // - -system_error::system_error( char const* exp ) -#ifdef UNDER_CE -: p_errno( GetLastError() ) -#else -: p_errno( errno ) -#endif -, p_failed_exp( exp ) -{} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** execution_exception ************** // -// ************************************************************************** // - -execution_exception::execution_exception( error_code ec_, const_string what_msg_, location const& location_ ) -: m_error_code( ec_ ) -, m_what( what_msg_.empty() ? BOOST_TEST_L( "uncaught exception, system error or abort requested" ) : what_msg_ ) -, m_location( location_ ) -{} - -//____________________________________________________________________________// - -execution_exception::location::location( char const* file_name, size_t line_num, char const* func ) -: m_file_name( file_name ? file_name : "unknown location" ) -, m_line_num( line_num ) -, m_function( func ) -{} - -execution_exception::location::location(const_string file_name, size_t line_num, char const* func ) -: m_file_name( file_name ) -, m_line_num( line_num ) -, m_function( func ) -{} - -//____________________________________________________________________________// - -// ************************************************************************** // -// **************Floating point exception management interface ************** // -// ************************************************************************** // - -namespace fpe { - -unsigned -enable( unsigned mask ) -{ - boost::ignore_unused(mask); -#if defined(BOOST_TEST_FPE_SUPPORT_WITH_SEH__) - _clearfp(); - -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1310) - unsigned old_cw = ::_controlfp( 0, 0 ); - ::_controlfp( old_cw & ~mask, BOOST_FPE_ALL ); -#else - unsigned old_cw; - if( ::_controlfp_s( &old_cw, 0, 0 ) != 0 ) - return BOOST_FPE_INV; - - // Set the control word - if( ::_controlfp_s( 0, old_cw & ~mask, BOOST_FPE_ALL ) != 0 ) - return BOOST_FPE_INV; -#endif - return ~old_cw & BOOST_FPE_ALL; - -#elif defined(BOOST_TEST_FPE_SUPPORT_WITH_GLIBC_EXTENSIONS__) - // same macro definition as in execution_monitor.hpp - if (BOOST_FPE_ALL == BOOST_FPE_OFF) - /* Not Implemented */ - return BOOST_FPE_OFF; - feclearexcept(BOOST_FPE_ALL); - int res = feenableexcept( mask ); - return res == -1 ? (unsigned)BOOST_FPE_INV : (unsigned)res; -#else - /* Not Implemented */ - return BOOST_FPE_OFF; -#endif -} - -//____________________________________________________________________________// - -unsigned -disable( unsigned mask ) -{ - boost::ignore_unused(mask); - -#if defined(BOOST_TEST_FPE_SUPPORT_WITH_SEH__) - _clearfp(); -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1310) - unsigned old_cw = ::_controlfp( 0, 0 ); - ::_controlfp( old_cw | mask, BOOST_FPE_ALL ); -#else - unsigned old_cw; - if( ::_controlfp_s( &old_cw, 0, 0 ) != 0 ) - return BOOST_FPE_INV; - - // Set the control word - if( ::_controlfp_s( 0, old_cw | mask, BOOST_FPE_ALL ) != 0 ) - return BOOST_FPE_INV; -#endif - return ~old_cw & BOOST_FPE_ALL; - -#elif defined(BOOST_TEST_FPE_SUPPORT_WITH_GLIBC_EXTENSIONS__) - if (BOOST_FPE_ALL == BOOST_FPE_OFF) - /* Not Implemented */ - return BOOST_FPE_INV; - feclearexcept(BOOST_FPE_ALL); - int res = fedisableexcept( mask ); - return res == -1 ? (unsigned)BOOST_FPE_INV : (unsigned)res; -#else - /* Not Implemented */ - return BOOST_FPE_INV; -#endif -} - -//____________________________________________________________________________// - -} // namespace fpe - -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_EXECUTION_MONITOR_IPP_012205GER diff --git a/ThirdParty/boost/test/impl/framework.ipp b/ThirdParty/boost/test/impl/framework.ipp deleted file mode 100644 index 3ee3b07f8850bcd66b2f773039c29599d98ad1fc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/framework.ipp +++ /dev/null @@ -1,1818 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : implements framework API - main driver for the test -// *************************************************************************** - -#ifndef BOOST_TEST_FRAMEWORK_IPP_021005GER -#define BOOST_TEST_FRAMEWORK_IPP_021005GER - -// Boost.Test -#include <boost/test/framework.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/debug.hpp> -#include <boost/test/unit_test_parameters.hpp> - -#include <boost/test/unit_test_log.hpp> -#include <boost/test/unit_test_log_formatter.hpp> -#include <boost/test/unit_test_monitor.hpp> -#include <boost/test/results_collector.hpp> -#include <boost/test/progress_monitor.hpp> -#include <boost/test/results_reporter.hpp> -#include <boost/test/test_framework_init_observer.hpp> - -#include <boost/test/tree/observer.hpp> -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/visitor.hpp> -#include <boost/test/tree/traverse.hpp> -#include <boost/test/tree/test_case_counter.hpp> -#include <boost/test/tree/global_fixture.hpp> - -#if BOOST_TEST_SUPPORT_TOKEN_ITERATOR -#include <boost/test/utils/iterator/token_iterator.hpp> -#endif - -#include <boost/test/utils/foreach.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> -#include <boost/test/utils/basic_cstring/compare.hpp> - -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/throw_exception.hpp> - -// Boost -#include <boost/test/utils/timer.hpp> -#include <boost/bind/bind.hpp> - -// STL -#include <limits> -#include <map> -#include <set> -#include <cstdlib> -#include <ctime> -#include <numeric> -#include <cmath> -#include <iterator> - -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std { using ::time; using ::srand; } -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace framework { - -namespace impl { - -// ************************************************************************** // -// ************** order detection helpers ************** // -// ************************************************************************** // - -struct order_info { - order_info() : depth(-1) {} - - int depth; - std::vector<test_unit_id> dependant_siblings; -}; - -typedef std::set<test_unit_id> tu_id_set; -typedef std::map<test_unit_id,order_info> order_info_per_tu; // !! ?? unordered map - -//____________________________________________________________________________// - -static test_unit_id -get_tu_parent( test_unit_id tu_id ) -{ - return framework::get( tu_id, TUT_ANY ).p_parent_id; -} - -//____________________________________________________________________________// - -static int -tu_depth( test_unit_id tu_id, test_unit_id master_tu_id, order_info_per_tu& tuoi ) -{ - if( tu_id == master_tu_id ) - return 0; - - order_info& info = tuoi[tu_id]; - - if( info.depth == -1 ) - info.depth = tu_depth( get_tu_parent( tu_id ), master_tu_id, tuoi ) + 1; - - return info.depth; -} - -//____________________________________________________________________________// - -static void -collect_dependant_siblings( test_unit_id from, test_unit_id to, test_unit_id master_tu_id, order_info_per_tu& tuoi ) -{ - int from_depth = tu_depth( from, master_tu_id, tuoi ); - int to_depth = tu_depth( to, master_tu_id, tuoi ); - - while(from_depth > to_depth) { - from = get_tu_parent( from ); - --from_depth; - } - - while(from_depth < to_depth) { - to = get_tu_parent( to ); - --to_depth; - } - - while(true) { - test_unit_id from_parent = get_tu_parent( from ); - test_unit_id to_parent = get_tu_parent( to ); - if( from_parent == to_parent ) - break; - from = from_parent; - to = to_parent; - } - - tuoi[from].dependant_siblings.push_back( to ); -} - -//____________________________________________________________________________// - -static counter_t -assign_sibling_rank( test_unit_id tu_id, order_info_per_tu& tuoi ) -{ - test_unit& tu = framework::get( tu_id, TUT_ANY ); - - BOOST_TEST_SETUP_ASSERT( tu.p_sibling_rank != (std::numeric_limits<counter_t>::max)(), - "Cyclic dependency detected involving test unit \"" + tu.full_name() + "\"" ); - - if( tu.p_sibling_rank != 0 ) - return tu.p_sibling_rank; - - order_info const& info = tuoi[tu_id]; - - // indicate in progress - tu.p_sibling_rank.value = (std::numeric_limits<counter_t>::max)(); - - counter_t new_rank = 1; - BOOST_TEST_FOREACH( test_unit_id, sibling_id, info.dependant_siblings ) - new_rank = (std::max)(new_rank, assign_sibling_rank( sibling_id, tuoi ) + 1); - - return tu.p_sibling_rank.value = new_rank; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** test_init call wrapper ************** // -// ************************************************************************** // - -static void -invoke_init_func( init_unit_test_func init_func ) -{ -#ifdef BOOST_TEST_ALTERNATIVE_INIT_API - BOOST_TEST_I_ASSRT( (*init_func)(), std::runtime_error( "test module initialization failed" ) ); -#else - test_suite* manual_test_units = (*init_func)( framework::master_test_suite().argc, framework::master_test_suite().argv ); - - if( manual_test_units ) - framework::master_test_suite().add( manual_test_units ); -#endif -} - -// ************************************************************************** // -// ************** name_filter ************** // -// ************************************************************************** // - -class name_filter : public test_tree_visitor { - struct component { - component( const_string name ) // has to be implicit - { - if( name == "*" ) - m_kind = SFK_ALL; - else if( first_char( name ) == '*' && last_char( name ) == '*' ) { - m_kind = SFK_SUBSTR; - m_name = name.substr( 1, name.size()-1 ); - } - else if( first_char( name ) == '*' ) { - m_kind = SFK_TRAILING; - m_name = name.substr( 1 ); - } - else if( last_char( name ) == '*' ) { - m_kind = SFK_LEADING; - m_name = name.substr( 0, name.size()-1 ); - } - else { - m_kind = SFK_MATCH; - m_name = name; - } - } - - bool pass( test_unit const& tu ) const - { - const_string name( tu.p_name ); - - switch( m_kind ) { - default: - case SFK_ALL: - return true; - case SFK_LEADING: - return name.substr( 0, m_name.size() ) == m_name; - case SFK_TRAILING: - return name.size() >= m_name.size() && name.substr( name.size() - m_name.size() ) == m_name; - case SFK_SUBSTR: - return name.find( m_name ) != const_string::npos; - case SFK_MATCH: - return m_name == tu.p_name.get(); - } - } - enum kind { SFK_ALL, SFK_LEADING, SFK_TRAILING, SFK_SUBSTR, SFK_MATCH }; - - kind m_kind; - const_string m_name; - }; - -public: - // Constructor - name_filter( test_unit_id_list& targ_list, const_string filter_expr ) : m_targ_list( targ_list ), m_depth( 0 ) - { -#ifdef BOOST_TEST_SUPPORT_TOKEN_ITERATOR - utils::string_token_iterator tit( filter_expr, (utils::dropped_delimeters = "/", - utils::kept_delimeters = utils::dt_none) ); - - while( tit != utils::string_token_iterator() ) { - m_components.push_back( - std::vector<component>( utils::string_token_iterator( *tit, (utils::dropped_delimeters = ",", - utils::kept_delimeters = utils::dt_none) ), - utils::string_token_iterator() ) ); - - ++tit; - } -#endif - } - -private: - bool filter_unit( test_unit const& tu ) - { - // skip master test suite - if( m_depth == 0 ) - return true; - - // corresponding name filters are at level m_depth-1 - std::vector<component> const& filters = m_components[m_depth-1]; - - // look for match - using namespace boost::placeholders; - return std::find_if( filters.begin(), filters.end(), bind( &component::pass, _1, boost::ref(tu) ) ) != filters.end(); - } - - // test_tree_visitor interface - virtual void visit( test_case const& tc ) - { - // make sure we only accept test cases if we match last component of the filter - if( m_depth == m_components.size() && filter_unit( tc ) ) - m_targ_list.push_back( tc.p_id ); // found a test case - } - virtual bool test_suite_start( test_suite const& ts ) - { - if( !filter_unit( ts ) ) - return false; - - if( m_depth < m_components.size() ) { - ++m_depth; - return true; - } - - m_targ_list.push_back( ts.p_id ); // found a test suite - - return false; - } - virtual void test_suite_finish( test_suite const& /*ts*/ ) - { - --m_depth; - } - - // Data members - typedef std::vector<std::vector<component> > components_per_level; - - components_per_level m_components; - test_unit_id_list& m_targ_list; - unsigned m_depth; -}; - -// ************************************************************************** // -// ************** label_filter ************** // -// ************************************************************************** // - -class label_filter : public test_tree_visitor { -public: - label_filter( test_unit_id_list& targ_list, const_string label ) - : m_targ_list( targ_list ) - , m_label( label ) - {} - -private: - // test_tree_visitor interface - virtual bool visit( test_unit const& tu ) - { - if( tu.has_label( m_label ) ) { - // found a test unit; add it to list of tu to enable with children and stop recursion in case of suites - m_targ_list.push_back( tu.p_id ); - return false; - } - - return true; - } - - // Data members - test_unit_id_list& m_targ_list; - const_string m_label; -}; - -// ************************************************************************** // -// ************** set_run_status ************** // -// ************************************************************************** // - -class set_run_status : public test_tree_visitor { -public: - explicit set_run_status( test_unit::run_status rs, test_unit_id_list* dep_collector = 0 ) - : m_new_status( rs ) - , m_dep_collector( dep_collector ) - {} - - // test_tree_visitor interface - virtual bool visit( test_unit const& tu ) - { - const_cast<test_unit&>(tu).p_run_status.value = m_new_status == test_unit::RS_INVALID ? tu.p_default_status : m_new_status; - if( m_dep_collector ) { - BOOST_TEST_FOREACH( test_unit_id, dep_id, tu.p_dependencies.get() ) { - test_unit const& dep = framework::get( dep_id, TUT_ANY ); - - if( dep.p_run_status == tu.p_run_status ) - continue; - - BOOST_TEST_FRAMEWORK_MESSAGE( "Including test " << dep.p_type_name << ' ' << dep.full_name() << - " as a dependency of test " << tu.p_type_name << ' ' << tu.full_name() ); - - m_dep_collector->push_back( dep_id ); - } - } - return true; - } - -private: - // Data members - test_unit::run_status m_new_status; - test_unit_id_list* m_dep_collector; -}; - -// ************************************************************************** // -// ************** parse_filters ************** // -// ************************************************************************** // - -static void -add_filtered_test_units( test_unit_id master_tu_id, const_string filter, test_unit_id_list& targ ) -{ - // Choose between two kinds of filters - if( filter[0] == '@' ) { - filter.trim_left( 1 ); - label_filter lf( targ, filter ); - traverse_test_tree( master_tu_id, lf, true ); - } - else { - name_filter nf( targ, filter ); - traverse_test_tree( master_tu_id, nf, true ); - } -} - -//____________________________________________________________________________// - -static bool -parse_filters( test_unit_id master_tu_id, test_unit_id_list& tu_to_enable, test_unit_id_list& tu_to_disable ) -{ - // 10. collect tu to enable and disable based on filters - bool had_selector_filter = false; - - std::vector<std::string> const& filters = runtime_config::get<std::vector<std::string> >( runtime_config::btrt_run_filters ); - - BOOST_TEST_FOREACH( const_string, filter, filters ) { - BOOST_TEST_SETUP_ASSERT( !filter.is_empty(), "Invalid filter specification" ); - - // each --run_test command may also be separated by a ':' (environment variable) - utils::string_token_iterator t_filter_it( filter, (utils::dropped_delimeters = ":", - utils::kept_delimeters = utils::dt_none) ); - - while( t_filter_it != utils::string_token_iterator() ) { - const_string filter_token = *t_filter_it; - - enum { SELECTOR, ENABLER, DISABLER } filter_type = SELECTOR; - - // 11. Deduce filter type - if( filter_token[0] == '!' || filter_token[0] == '+' ) { - filter_type = filter_token[0] == '+' ? ENABLER : DISABLER; - filter_token.trim_left( 1 ); - BOOST_TEST_SETUP_ASSERT( !filter_token.is_empty(), "Invalid filter specification" ); - } - - had_selector_filter |= filter_type == SELECTOR; - - // 12. Add test units to corresponding list - switch( filter_type ) { - case SELECTOR: - case ENABLER: add_filtered_test_units( master_tu_id, filter_token, tu_to_enable ); break; - case DISABLER: add_filtered_test_units( master_tu_id, filter_token, tu_to_disable ); break; - } - - ++t_filter_it; - } - } - - return had_selector_filter; -} - -//____________________________________________________________________________// - -// a poor man's implementation of random_shuffle, deprecated in C++11 -template< class RandomIt, class RandomFunc > -void random_shuffle( RandomIt first, RandomIt last, RandomFunc &r ) -{ - typedef typename std::iterator_traits<RandomIt>::difference_type difference_type; - difference_type n = last - first; - for (difference_type i = n-1; i > 0; --i) { - difference_type j = r(i+1); - if (j != i) { - using std::swap; - swap(first[i], first[j]); - } - } -} - -// A simple handle for registering the global fixtures to the master test suite -// without deleting an existing static object (the global fixture itself) when the program -// terminates (shared_ptr). -class global_fixture_handle : public test_unit_fixture { -public: - global_fixture_handle(test_unit_fixture* fixture) : m_global_fixture(fixture) {} - ~global_fixture_handle() {} - - virtual void setup() { - m_global_fixture->setup(); - } - virtual void teardown() { - m_global_fixture->teardown(); - } - -private: - test_unit_fixture* m_global_fixture; -}; - - -} // namespace impl - -// ************************************************************************** // -// ************** framework::state ************** // -// ************************************************************************** // - -unsigned long int const TIMEOUT_EXCEEDED = static_cast<unsigned long int>( -1 ); - -class state { -public: - state() - : m_master_test_suite( 0 ) - , m_curr_test_unit( INV_TEST_UNIT_ID ) - , m_next_test_case_id( MIN_TEST_CASE_ID ) - , m_next_test_suite_id( MIN_TEST_SUITE_ID ) - , m_test_in_progress( false ) - , m_context_idx( 0 ) - , m_log_sinks( ) - , m_report_sink( std::cerr ) - { - } - - ~state() { clear(); } - - void clear() - { - while( !m_test_units.empty() ) { - test_unit_store::value_type const& tu = *m_test_units.begin(); - test_unit const* tu_ptr = tu.second; - - // the delete will erase this element from map - if( ut_detail::test_id_2_unit_type( tu.second->p_id ) == TUT_SUITE ) - delete static_cast<test_suite const*>(tu_ptr); - else - delete static_cast<test_case const*>(tu_ptr); - } - } - - void set_tu_id( test_unit& tu, test_unit_id id ) { tu.p_id.value = id; } - - ////////////////////////////////////////////////////////////////// - - // Validates the dependency graph and deduces the sibling dependency rank for each child - void deduce_siblings_order( test_unit_id tu_id, test_unit_id master_tu_id, impl::order_info_per_tu& tuoi ) - { - test_unit& tu = framework::get( tu_id, TUT_ANY ); - - // collect all sibling dependancy from tu own list - BOOST_TEST_FOREACH( test_unit_id, dep_id, tu.p_dependencies.get() ) - collect_dependant_siblings( tu_id, dep_id, master_tu_id, tuoi ); - - if( tu.p_type != TUT_SUITE ) - return; - - test_suite& ts = static_cast<test_suite&>(tu); - - // recursive call to children first - BOOST_TEST_FOREACH( test_unit_id, chld_id, ts.m_children ) - deduce_siblings_order( chld_id, master_tu_id, tuoi ); - - ts.m_ranked_children.clear(); - BOOST_TEST_FOREACH( test_unit_id, chld_id, ts.m_children ) { - counter_t rank = assign_sibling_rank( chld_id, tuoi ); - ts.m_ranked_children.insert( std::make_pair( rank, chld_id ) ); - } - } - - ////////////////////////////////////////////////////////////////// - - // Finalize default run status: - // 1) inherit run status from parent where applicable - // 2) if any of test units in test suite enabled enable it as well - bool finalize_default_run_status( test_unit_id tu_id, test_unit::run_status parent_status ) - { - test_unit& tu = framework::get( tu_id, TUT_ANY ); - - if( tu.p_default_status == test_suite::RS_INHERIT ) - tu.p_default_status.value = parent_status; - - // go through list of children - if( tu.p_type == TUT_SUITE ) { - bool has_enabled_child = false; - BOOST_TEST_FOREACH( test_unit_id, chld_id, static_cast<test_suite const&>(tu).m_children ) - has_enabled_child |= finalize_default_run_status( chld_id, tu.p_default_status ); - - tu.p_default_status.value = has_enabled_child ? test_suite::RS_ENABLED : test_suite::RS_DISABLED; - } - - return tu.p_default_status == test_suite::RS_ENABLED; - } - - ////////////////////////////////////////////////////////////////// - - bool finalize_run_status( test_unit_id tu_id ) - { - test_unit& tu = framework::get( tu_id, TUT_ANY ); - - // go through list of children - if( tu.p_type == TUT_SUITE ) { - bool has_enabled_child = false; - BOOST_TEST_FOREACH( test_unit_id, chld_id, static_cast<test_suite const&>(tu).m_children) - has_enabled_child |= finalize_run_status( chld_id ); - - tu.p_run_status.value = has_enabled_child ? test_suite::RS_ENABLED : test_suite::RS_DISABLED; - } - - return tu.is_enabled(); - } - - ////////////////////////////////////////////////////////////////// - - void deduce_run_status( test_unit_id master_tu_id ) - { - using namespace framework::impl; - test_unit_id_list tu_to_enable; - test_unit_id_list tu_to_disable; - - // 10. If there are any filters supplied, figure out lists of test units to enable/disable - bool had_selector_filter = !runtime_config::get<std::vector<std::string> >( runtime_config::btrt_run_filters ).empty() && - parse_filters( master_tu_id, tu_to_enable, tu_to_disable ); - - // 20. Set the stage: either use default run status or disable all test units - set_run_status initial_setter( had_selector_filter ? test_unit::RS_DISABLED : test_unit::RS_INVALID ); - traverse_test_tree( master_tu_id, initial_setter, true ); - - // 30. Apply all selectors and enablers. - while( !tu_to_enable.empty() ) { - test_unit& tu = framework::get( tu_to_enable.back(), TUT_ANY ); - - tu_to_enable.pop_back(); - - // 35. Ignore test units which are already enabled - if( tu.is_enabled() ) - continue; - - // set new status and add all dependencies into tu_to_enable - set_run_status enabler( test_unit::RS_ENABLED, &tu_to_enable ); - traverse_test_tree( tu.p_id, enabler, true ); - - // Add the dependencies of the parent suites, see trac #13149 - test_unit_id parent_id = tu.p_parent_id; - while( parent_id != INV_TEST_UNIT_ID - && parent_id != master_tu_id ) - { - // we do not use the traverse_test_tree as otherwise it would enable the sibblings and subtree - // of the test case we want to enable (we need to enable the parent suites and their dependencies only) - // the parent_id needs to be enabled in order to be properly parsed by finalize_run_status, the visit - // does the job - test_unit& tu_parent = framework::get( parent_id, TUT_ANY ); - enabler.visit( tu_parent ); - parent_id = tu_parent.p_parent_id; - } - } - - // 40. Apply all disablers - while( !tu_to_disable.empty() ) { - test_unit const& tu = framework::get( tu_to_disable.back(), TUT_ANY ); - - tu_to_disable.pop_back(); - - // 35. Ignore test units which already disabled - if( !tu.is_enabled() ) - continue; - - set_run_status disabler( test_unit::RS_DISABLED ); - traverse_test_tree( tu.p_id, disabler, true ); - } - - // 50. Make sure parents of enabled test units are also enabled - finalize_run_status( master_tu_id ); - } - - ////////////////////////////////////////////////////////////////// - - typedef unit_test_monitor_t::error_level execution_result; - - // Random generator using the std::rand function (seeded prior to the call) - struct random_generator_helper { - size_t operator()(size_t i) const { - return std::rand() % i; - } - }; - - // Executes the test tree with the root at specified test unit - execution_result execute_test_tree( test_unit_id tu_id, - unsigned long int timeout_microseconds = 0, - random_generator_helper const * const p_random_generator = 0) - { - test_unit const& tu = framework::get( tu_id, TUT_ANY ); - - execution_result result = unit_test_monitor_t::test_ok; - - if( !tu.is_enabled() ) { - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) - to->test_unit_skipped( tu, "disabled" ); - return result; - } - - // 10. Check preconditions, including zero time left for execution and - // successful execution of all dependencies - if( timeout_microseconds == TIMEOUT_EXCEEDED ) { - // notify all observers about skipped test unit - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) - to->test_unit_skipped( tu, "timeout for the test unit is exceeded" ); - - return unit_test_monitor_t::os_timeout; - } - else if( timeout_microseconds == 0 || (tu.p_timeout > 0 && timeout_microseconds > (tu.p_timeout * 1000000) ) ) // deduce timeout for this test unit - timeout_microseconds = tu.p_timeout * 1000000; - - - test_tools::assertion_result const precondition_res = tu.check_preconditions(); - if( !precondition_res ) { - // notify all observers about skipped test unit - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) - to->test_unit_skipped( tu, precondition_res.message() ); - - // It is not an error to skip the test if any of the parent tests - // have failed. This one should be reported as skipped as if it was - // disabled - return unit_test_monitor_t::test_ok; - } - - // 20. Notify all observers about the start of the test unit - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) - to->test_unit_start( tu ); - - // 30. Execute setup fixtures if any; any failure here leads to test unit abortion - BOOST_TEST_FOREACH( test_unit_fixture_ptr, F, tu.p_fixtures.get() ) { - ut_detail::test_unit_id_restore restore_current_test_unit(m_curr_test_unit, tu.p_id); - result = unit_test_monitor.execute_and_translate( boost::bind( &test_unit_fixture::setup, F ) ); - if( result != unit_test_monitor_t::test_ok ) - break; - test_results const& test_rslt = unit_test::results_collector.results( m_curr_test_unit ); - if( test_rslt.aborted() ) { - result = unit_test_monitor_t::test_setup_failure; - break; - } - } - - // This is the time we are going to spend executing the test unit (in microseconds - // as expected by test_observer::test_unit_finish) - unsigned long elapsed_microseconds = 0; - - if( result == unit_test_monitor_t::test_ok ) { - // 40. We are going to time the execution - boost::unit_test::timer::timer tu_timer; - - // we pass the random generator - const random_generator_helper& rand_gen = p_random_generator ? *p_random_generator : random_generator_helper(); - - if( tu.p_type == TUT_SUITE ) { - test_suite const& ts = static_cast<test_suite const&>( tu ); - - if( runtime_config::get<unsigned>( runtime_config::btrt_random_seed ) == 0 ) { - typedef std::pair<counter_t,test_unit_id> value_type; - - BOOST_TEST_FOREACH( value_type, chld, ts.m_ranked_children ) { - // tu_timer.elapsed() returns nanosec, timeout and child_timeout in microsec - unsigned long int chld_timeout = child_timeout( - timeout_microseconds, - static_cast<unsigned long int>( microsecond_wall_time(tu_timer.elapsed()) )); - - result = (std::min)( result, execute_test_tree( chld.second, chld_timeout, &rand_gen ) ); - - if( unit_test_monitor.is_critical_error( result ) ) - break; - - // we check for the time elapsed. If this is too high, we fail the current suite and return from here - elapsed_microseconds = static_cast<unsigned long int>( microsecond_wall_time(tu_timer.elapsed()) ); - - if( (timeout_microseconds > 0) && (elapsed_microseconds > timeout_microseconds) && (timeout_microseconds != TIMEOUT_EXCEEDED ) ) { - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) { - to->test_unit_timed_out(tu); - } - result = (std::min)( result, unit_test_monitor_t::os_timeout ); - timeout_microseconds = TIMEOUT_EXCEEDED; - //break; - // we continue to explore the children, such that we can at least update their - // status to skipped - } - } - } - else { - // Go through ranges of children with the same dependency rank and shuffle them - // independently. Execute each subtree in this order - test_unit_id_list children_with_the_same_rank; - - typedef test_suite::children_per_rank::const_iterator it_type; - it_type it = ts.m_ranked_children.begin(); - while( it != ts.m_ranked_children.end() ) { - children_with_the_same_rank.clear(); - - std::pair<it_type,it_type> range = ts.m_ranked_children.equal_range( it->first ); - it = range.first; - while( it != range.second ) { - children_with_the_same_rank.push_back( it->second ); - it++; - } - - impl::random_shuffle( children_with_the_same_rank.begin(), children_with_the_same_rank.end(), rand_gen ); - - BOOST_TEST_FOREACH( test_unit_id, chld, children_with_the_same_rank ) { - unsigned long int chld_timeout = child_timeout( - timeout_microseconds, - static_cast<unsigned long int>(microsecond_wall_time(tu_timer.elapsed())) ); - - result = (std::min)( result, execute_test_tree( chld, chld_timeout, &rand_gen ) ); - - if( unit_test_monitor.is_critical_error( result ) ) - break; - - // we check for the time elapsed. If this is too high, we fail the current suite and return from here - elapsed_microseconds = static_cast<unsigned long int>( microsecond_wall_time(tu_timer.elapsed()) ); - if( (timeout_microseconds > 0) && (elapsed_microseconds > timeout_microseconds) && (timeout_microseconds != TIMEOUT_EXCEEDED ) ) { - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) { - to->test_unit_timed_out(tu); - } - result = (std::min)( result, unit_test_monitor_t::os_timeout ); - timeout_microseconds = TIMEOUT_EXCEEDED; - //break; - // we continue to explore the children, such that we can at least update their - // status to skipped - } - } - } - } - } - else { // TUT_CASE - test_case const& tc = static_cast<test_case const&>( tu ); - - // setup contexts - m_context_idx = 0; - - // setup current test case - ut_detail::test_unit_id_restore restore_current_test_unit(m_curr_test_unit, tc.p_id); - - // execute the test case body, transforms the time out to seconds - result = unit_test_monitor.execute_and_translate( tc.p_test_func, timeout_microseconds ); - elapsed_microseconds = static_cast<unsigned long int>( microsecond_wall_time(tu_timer.elapsed()) ); - - // cleanup leftover context - m_context.clear(); - - // restore state (scope exit) and abort if necessary - } - } - - // if run error is critical skip teardown, who knows what the state of the program at this point - if( !unit_test_monitor.is_critical_error( result ) ) { - // execute teardown fixtures if any in reverse order - BOOST_TEST_REVERSE_FOREACH( test_unit_fixture_ptr, F, tu.p_fixtures.get() ) { - ut_detail::test_unit_id_restore restore_current_test_unit(m_curr_test_unit, tu.p_id); - result = (std::min)( result, unit_test_monitor.execute_and_translate( boost::bind( &test_unit_fixture::teardown, F ), 0 ) ); - - if( unit_test_monitor.is_critical_error( result ) ) - break; - } - } - - // notify all observers about abortion - if( unit_test_monitor.is_critical_error( result ) ) { - BOOST_TEST_FOREACH( test_observer*, to, m_observers ) - to->test_aborted(); - } - - // notify all observers about completion - BOOST_TEST_REVERSE_FOREACH( test_observer*, to, m_observers ) - to->test_unit_finish( tu, elapsed_microseconds ); - - return result; - } - - ////////////////////////////////////////////////////////////////// - - unsigned long int child_timeout( unsigned long tu_timeout_microseconds, unsigned long elpsed_microsec ) - { - if( tu_timeout_microseconds == 0UL || tu_timeout_microseconds == TIMEOUT_EXCEEDED) - return tu_timeout_microseconds; - - return tu_timeout_microseconds > elpsed_microsec ? - tu_timeout_microseconds - elpsed_microsec - : TIMEOUT_EXCEEDED; - } - - struct priority_order { - bool operator()( test_observer* lhs, test_observer* rhs ) const - { - return (lhs->priority() < rhs->priority()) || ((lhs->priority() == rhs->priority()) && (lhs < rhs)); - } - }; - - // Data members - typedef std::map<test_unit_id,test_unit*> test_unit_store; - typedef std::set<test_observer*,priority_order> observer_store; - struct context_frame { - context_frame( std::string const& d, int id, bool sticky ) - : descr( d ) - , frame_id( id ) - , is_sticky( sticky ) - {} - - std::string descr; - int frame_id; - bool is_sticky; - }; - typedef std::vector<context_frame> context_data; - - master_test_suite_t* m_master_test_suite; - std::vector<test_suite*> m_auto_test_suites; - - test_unit_id m_curr_test_unit; - test_unit_store m_test_units; - - test_unit_id m_next_test_case_id; - test_unit_id m_next_test_suite_id; - - bool m_test_in_progress; - - observer_store m_observers; - context_data m_context; - int m_context_idx; - - std::set<global_fixture*> m_global_fixtures; - - boost::execution_monitor m_aux_em; - - std::map<output_format, runtime_config::stream_holder> m_log_sinks; - runtime_config::stream_holder m_report_sink; -}; - -//____________________________________________________________________________// - -namespace impl { -namespace { - -#if defined(__CYGWIN__) -framework::state& s_frk_state() { static framework::state* the_inst = 0; if(!the_inst) the_inst = new framework::state; return *the_inst; } -#else -framework::state& s_frk_state() { static framework::state the_inst; return the_inst; } -#endif - -} // local namespace - -void -setup_for_execution( test_unit const& tu ) -{ - s_frk_state().deduce_run_status( tu.p_id ); -} - -struct sum_to_first_only { - sum_to_first_only() : is_first(true) {} - template <class T, class U> - T operator()(T const& l_, U const& r_) { - if(is_first) { - is_first = false; - return l_ + r_.first; - } - return l_ + ", " + r_.first; - } - - bool is_first; -}; - -void -shutdown_loggers_and_reports() -{ - s_frk_state().m_log_sinks.clear(); - s_frk_state().m_report_sink.setup( "stderr" ); -} - -void -unregister_global_fixture_and_configuration() -{ - // we make a copy as the set will change in the iteration - std::set<global_fixture*> gfixture_copy(s_frk_state().m_global_fixtures); - BOOST_TEST_FOREACH( global_fixture*, tuf, gfixture_copy ) { - tuf->unregister_from_framework(); - } - s_frk_state().m_global_fixtures.clear(); - - state::observer_store gobserver_copy(s_frk_state().m_observers); - BOOST_TEST_FOREACH( test_observer*, to, gobserver_copy ) { - framework::deregister_observer( *to ); - } - s_frk_state().m_observers.clear(); -} - -void -setup_loggers() -{ - - BOOST_TEST_I_TRY { - -#ifdef BOOST_TEST_SUPPORT_TOKEN_ITERATOR - bool has_combined_logger = runtime_config::has( runtime_config::btrt_combined_logger ) - && !runtime_config::get< std::vector<std::string> >( runtime_config::btrt_combined_logger ).empty(); -#else - bool has_combined_logger = false; -#endif - - if( !has_combined_logger ) { - unit_test_log.set_threshold_level( runtime_config::get<log_level>( runtime_config::btrt_log_level ) ); - const output_format format = runtime_config::get<output_format>( runtime_config::btrt_log_format ); - unit_test_log.set_format( format ); - - runtime_config::stream_holder& stream_logger = s_frk_state().m_log_sinks[format]; - if( runtime_config::has( runtime_config::btrt_log_sink ) ) { - // we remove all streams in this case, so we do not specify the format - boost::function< void () > log_cleaner = boost::bind( &unit_test_log_t::set_stream, - &unit_test_log, - boost::ref(std::cout) - ); - stream_logger.setup( runtime_config::get<std::string>( runtime_config::btrt_log_sink ), - log_cleaner ); - } - unit_test_log.set_stream( stream_logger.ref() ); - unit_test_log.configure(); - } - else - { - - const std::vector<std::string>& v_output_format = runtime_config::get< std::vector<std::string> >( runtime_config::btrt_combined_logger ) ; - - static const std::pair<const char*, log_level> all_log_levels[] = { - std::make_pair( "all" , log_successful_tests ), - std::make_pair( "success" , log_successful_tests ), - std::make_pair( "test_suite" , log_test_units ), - std::make_pair( "unit_scope" , log_test_units ), - std::make_pair( "message" , log_messages ), - std::make_pair( "warning" , log_warnings ), - std::make_pair( "error" , log_all_errors ), - std::make_pair( "cpp_exception" , log_cpp_exception_errors ), - std::make_pair( "system_error" , log_system_errors ), - std::make_pair( "fatal_error" , log_fatal_errors ), - std::make_pair( "nothing" , log_nothing ) - }; - - static const std::pair<const char*, output_format> all_formats[] = { - std::make_pair( "HRF" , OF_CLF ), - std::make_pair( "CLF" , OF_CLF ), - std::make_pair( "XML" , OF_XML ), - std::make_pair( "JUNIT", OF_JUNIT ) - }; - - - bool is_first = true; - - BOOST_TEST_FOREACH( const_string, current_multi_config, v_output_format ) { - - #ifdef BOOST_TEST_SUPPORT_TOKEN_ITERATOR - - // ':' may be used for file names: C:/tmp/mylogsink.xml - // we merge the tokens that start with / or \ with the previous one. - std::vector<std::string> v_processed_tokens; - - { - utils::string_token_iterator current_config( current_multi_config, (utils::dropped_delimeters = ":", - utils::kept_delimeters = utils::dt_none) ); - - for( ; current_config != utils::string_token_iterator() ; ++current_config) { - std::string str_copy(current_config->begin(), current_config->end()); - if( ( str_copy[0] == '\\' || str_copy[0] == '/' ) - && v_processed_tokens.size() > 0) { - v_processed_tokens.back() += ":" + str_copy; // ':' has been eaten up - } - else { - v_processed_tokens.push_back(str_copy); - } - } - } - - BOOST_TEST_FOREACH( std::string const&, current_config, v_processed_tokens ) { - - utils::string_token_iterator current_format_specs( current_config, (utils::keep_empty_tokens, - utils::dropped_delimeters = ",", - utils::kept_delimeters = utils::dt_none) ); - - output_format format = OF_INVALID ; // default - if( current_format_specs != utils::string_token_iterator() && - current_format_specs->size() ) { - - for(size_t elem=0; elem < sizeof(all_formats)/sizeof(all_formats[0]); elem++) { - if(const_string(all_formats[elem].first) == *current_format_specs) { - format = all_formats[elem].second; - break; - } - } - } - - BOOST_TEST_I_ASSRT( format != OF_INVALID, - boost::runtime::access_to_missing_argument() - << "Unable to determine the logger type from '" - << current_config - << "'. Possible choices are: " - << std::accumulate(all_formats, - all_formats + sizeof(all_formats)/sizeof(all_formats[0]), - std::string(""), - sum_to_first_only()) - ); - - // activates this format - if( is_first ) { - unit_test_log.set_format( format ); - } - else { - unit_test_log.add_format( format ); - } - is_first = false; - - unit_test_log_formatter * const formatter = unit_test_log.get_formatter(format); - BOOST_TEST_SETUP_ASSERT( formatter, "Logger setup error" ); - - log_level formatter_log_level = invalid_log_level; - ++current_format_specs ; - if( !current_format_specs->size() ) { - formatter_log_level = formatter->get_log_level(); // default log level given by the formatter - } - else if( current_format_specs != utils::string_token_iterator() ) { - - for(size_t elem=0; elem < sizeof(all_log_levels)/sizeof(all_log_levels[0]); elem++) { - if(const_string(all_log_levels[elem].first) == *current_format_specs) { - formatter_log_level = all_log_levels[elem].second; - break; - } - } - } - - BOOST_TEST_I_ASSRT( formatter_log_level != invalid_log_level, - boost::runtime::access_to_missing_argument() - << "Unable to determine the log level from '" - << current_config - << "'. Possible choices are: " - << std::accumulate(all_log_levels, - all_log_levels + sizeof(all_log_levels)/sizeof(all_log_levels[0]), - std::string(""), - sum_to_first_only()) - ); - - unit_test_log.set_threshold_level( format, formatter_log_level ); - - runtime_config::stream_holder& stream_logger = s_frk_state().m_log_sinks[format]; - boost::function< void () > log_cleaner = boost::bind( &unit_test_log_t::set_stream, - &unit_test_log, - format, - boost::ref(std::cout) ); - if( ++current_format_specs != utils::string_token_iterator() && - current_format_specs->size() ) { - stream_logger.setup( *current_format_specs, - log_cleaner ); - } - else { - stream_logger.setup( formatter->get_default_stream_description(), - log_cleaner ); - } - unit_test_log.set_stream( format, stream_logger.ref() ); - } - #endif - } // for each logger - - } // if/else new logger API - } // BOOST_TEST_I_TRY - BOOST_TEST_I_CATCH( boost::runtime::init_error, ex ) { - BOOST_TEST_SETUP_ASSERT( false, ex.msg ); - } - BOOST_TEST_I_CATCH( boost::runtime::input_error, ex ) { - std::cerr << ex.msg << "\n\n"; - - BOOST_TEST_I_THROW( framework::nothing_to_test( boost::exit_exception_failure ) ); - } - - -} - -//____________________________________________________________________________// - -} // namespace impl - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** framework::init ************** // -// ************************************************************************** // - -void -init( init_unit_test_func init_func, int argc, char* argv[] ) -{ - using namespace impl; - - // 10. Set up runtime parameters - runtime_config::init( argc, argv ); - - // 20. Set the desired log level, format and sink - impl::setup_loggers(); - - // 30. Set the desired report level, format and sink - results_reporter::set_level( runtime_config::get<report_level>( runtime_config::btrt_report_level ) ); - results_reporter::set_format( runtime_config::get<output_format>( runtime_config::btrt_report_format ) ); - - if( runtime_config::has( runtime_config::btrt_report_sink ) ) { - boost::function< void () > report_cleaner = boost::bind( &results_reporter::set_stream, - boost::ref(std::cerr) - ); - s_frk_state().m_report_sink.setup( runtime_config::get<std::string>( runtime_config::btrt_report_sink ), - report_cleaner ); - } - - results_reporter::set_stream( s_frk_state().m_report_sink.ref() ); - - // 40. Register default test observers - register_observer( results_collector ); - register_observer( unit_test_log ); - - if( runtime_config::get<bool>( runtime_config::btrt_show_progress ) ) { - progress_monitor.set_stream( std::cout ); // defaults to stdout - register_observer( progress_monitor ); - } - - // 50. Set up memory leak detection - unsigned long detect_mem_leak = runtime_config::get<unsigned long>( runtime_config::btrt_detect_mem_leaks ); - if( detect_mem_leak > 0 ) { - debug::detect_memory_leaks( true, runtime_config::get<std::string>( runtime_config::btrt_report_mem_leaks ) ); - debug::break_memory_alloc( (long)detect_mem_leak ); - } - - // 60. Initialize master unit test suite - master_test_suite().argc = argc; - master_test_suite().argv = argv; - - // 70. Invoke test module initialization routine - BOOST_TEST_I_TRY { - s_frk_state().m_aux_em.vexecute( boost::bind( &impl::invoke_init_func, init_func ) ); - } - BOOST_TEST_I_CATCH( execution_exception, ex ) { - BOOST_TEST_SETUP_ASSERT( false, ex.what() ); - } -} - -//____________________________________________________________________________// - -void -finalize_setup_phase( test_unit_id master_tu_id ) -{ - if( master_tu_id == INV_TEST_UNIT_ID ) - master_tu_id = master_test_suite().p_id; - - // 10. Apply all decorators to the auto test units - // 10. checks for consistency (duplicate names, etc) - class apply_decorators : public test_tree_visitor { - private: - // test_tree_visitor interface - - virtual bool test_suite_start( test_suite const& ts) - { - const_cast<test_suite&>(ts).generate(); - const_cast<test_suite&>(ts).check_for_duplicate_test_cases(); - return test_tree_visitor::test_suite_start(ts); - } - - virtual bool visit( test_unit const& tu ) - { - BOOST_TEST_FOREACH( decorator::base_ptr, d, tu.p_decorators.get() ) - d->apply( const_cast<test_unit&>(tu) ); - - return true; - } - } ad; - traverse_test_tree( master_tu_id, ad, true ); - - // 20. Finalize setup phase - impl::order_info_per_tu tuoi; - impl::s_frk_state().deduce_siblings_order( master_tu_id, master_tu_id, tuoi ); - impl::s_frk_state().finalize_default_run_status( master_tu_id, test_unit::RS_INVALID ); -} - -// ************************************************************************** // -// ************** test_in_progress ************** // -// ************************************************************************** // - -bool -test_in_progress() -{ - return impl::s_frk_state().m_test_in_progress; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** framework::shutdown ************** // -// ************************************************************************** // - -void -shutdown() -{ - // shuts down the loggers singleton to avoid any further reference to the - // framework during the destruction of those - impl::shutdown_loggers_and_reports(); - - // unregisters any global fixture and configuration object - impl::unregister_global_fixture_and_configuration(); - - // eliminating some fake memory leak reports. See for more details: - // http://connect.microsoft.com/VisualStudio/feedback/details/106937/memory-leaks-reported-by-debug-crt-inside-typeinfo-name - -# if BOOST_WORKAROUND(BOOST_MSVC, <= 1600 ) && !defined(_DLL) && defined(_DEBUG) -# if BOOST_WORKAROUND(BOOST_MSVC, < 1600 ) -#define _Next next -#define _MemPtr memPtr -#endif - __type_info_node* pNode = __type_info_root_node._Next; - __type_info_node* tmpNode = &__type_info_root_node; - - for( ; pNode!=NULL; pNode = tmpNode ) { - tmpNode = pNode->_Next; - delete pNode->_MemPtr; - delete pNode; - } -# if BOOST_WORKAROUND(BOOST_MSVC, < 1600 ) -#undef _Next -#undef _MemPtr -#endif -# endif -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** register_test_unit ************** // -// ************************************************************************** // - -void -register_test_unit( test_case* tc ) -{ - BOOST_TEST_SETUP_ASSERT( tc->p_id == INV_TEST_UNIT_ID, BOOST_TEST_L( "test case already registered" ) ); - - test_unit_id new_id = impl::s_frk_state().m_next_test_case_id; - - BOOST_TEST_SETUP_ASSERT( new_id != MAX_TEST_CASE_ID, BOOST_TEST_L( "too many test cases" ) ); - - typedef state::test_unit_store::value_type map_value_type; - - impl::s_frk_state().m_test_units.insert( map_value_type( new_id, tc ) ); - impl::s_frk_state().m_next_test_case_id++; - - impl::s_frk_state().set_tu_id( *tc, new_id ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** register_test_unit ************** // -// ************************************************************************** // - -void -register_test_unit( test_suite* ts ) -{ - BOOST_TEST_SETUP_ASSERT( ts->p_id == INV_TEST_UNIT_ID, BOOST_TEST_L( "test suite already registered" ) ); - - test_unit_id new_id = impl::s_frk_state().m_next_test_suite_id; - - BOOST_TEST_SETUP_ASSERT( new_id != MAX_TEST_SUITE_ID, BOOST_TEST_L( "too many test suites" ) ); - - typedef state::test_unit_store::value_type map_value_type; - - impl::s_frk_state().m_test_units.insert( map_value_type( new_id, ts ) ); - impl::s_frk_state().m_next_test_suite_id++; - - impl::s_frk_state().set_tu_id( *ts, new_id ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** deregister_test_unit ************** // -// ************************************************************************** // - -void -deregister_test_unit( test_unit* tu ) -{ - impl::s_frk_state().m_test_units.erase( tu->p_id ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** clear ************** // -// ************************************************************************** // - -void -clear() -{ - impl::s_frk_state().clear(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** register_observer ************** // -// ************************************************************************** // - -void -register_observer( test_observer& to ) -{ - impl::s_frk_state().m_observers.insert( &to ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** deregister_observer ************** // -// ************************************************************************** // - -void -deregister_observer( test_observer& to ) -{ - impl::s_frk_state().m_observers.erase( &to ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** register_global_fixture ************** // -// ************************************************************************** // - -void -register_global_fixture( global_fixture& tuf ) -{ - impl::s_frk_state().m_global_fixtures.insert( &tuf ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** deregister_global_fixture ************** // -// ************************************************************************** // - -void -deregister_global_fixture( global_fixture &tuf ) -{ - impl::s_frk_state().m_global_fixtures.erase( &tuf ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** add_context ************** // -// ************************************************************************** // - -int -add_context( ::boost::unit_test::lazy_ostream const& context_descr, bool sticky ) -{ - std::stringstream buffer; - context_descr( buffer ); - int res_idx = impl::s_frk_state().m_context_idx++; - - impl::s_frk_state().m_context.push_back( state::context_frame( buffer.str(), res_idx, sticky ) ); - - return res_idx; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** clear_context ************** // -// ************************************************************************** // - -struct frame_with_id { - explicit frame_with_id( int id ) : m_id( id ) {} - - bool operator()( state::context_frame const& f ) - { - return f.frame_id == m_id; - } - int m_id; -}; - -//____________________________________________________________________________// - -void -clear_context( int frame_id ) -{ - if( frame_id == -1 ) { // clear all non sticky frames - for( int i=static_cast<int>(impl::s_frk_state().m_context.size())-1; i>=0; i-- ) - if( !impl::s_frk_state().m_context[i].is_sticky ) - impl::s_frk_state().m_context.erase( impl::s_frk_state().m_context.begin()+i ); - } - - else { // clear specific frame - state::context_data::iterator it = - std::find_if( impl::s_frk_state().m_context.begin(), impl::s_frk_state().m_context.end(), frame_with_id( frame_id ) ); - - if( it != impl::s_frk_state().m_context.end() ) // really an internal error if this is not true - impl::s_frk_state().m_context.erase( it ); - } -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** get_context ************** // -// ************************************************************************** // - -context_generator -get_context() -{ - return context_generator(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** context_generator ************** // -// ************************************************************************** // - -bool -context_generator::is_empty() const -{ - return impl::s_frk_state().m_context.empty(); -} - -//____________________________________________________________________________// - -const_string -context_generator::next() const -{ - return m_curr_frame < impl::s_frk_state().m_context.size() ? impl::s_frk_state().m_context[m_curr_frame++].descr : const_string(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** master_test_suite ************** // -// ************************************************************************** // - -master_test_suite_t& -master_test_suite() -{ - if( !impl::s_frk_state().m_master_test_suite ) - impl::s_frk_state().m_master_test_suite = new master_test_suite_t; - - return *impl::s_frk_state().m_master_test_suite; -} - -namespace impl { - -master_test_suite_name_setter::master_test_suite_name_setter(const_string name) { - assign_op( master_test_suite().p_name.value, name.trim( "\"" ), 0 ); -} - -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** current_auto_test_suite ************** // -// ************************************************************************** // - -test_suite& -current_auto_test_suite( test_suite* ts, bool push_or_pop ) -{ - if( impl::s_frk_state().m_auto_test_suites.empty() ) - impl::s_frk_state().m_auto_test_suites.push_back( &framework::master_test_suite() ); - - if( !push_or_pop ) - impl::s_frk_state().m_auto_test_suites.pop_back(); - else if( ts ) - impl::s_frk_state().m_auto_test_suites.push_back( ts ); - - return *impl::s_frk_state().m_auto_test_suites.back(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** current_test_case ************** // -// ************************************************************************** // - -test_case const& -current_test_case() -{ - return get<test_case>( impl::s_frk_state().m_curr_test_unit ); -} - - -test_unit const& -current_test_unit() -{ - return *impl::s_frk_state().m_test_units[impl::s_frk_state().m_curr_test_unit]; -} - -//____________________________________________________________________________// - -test_unit_id -current_test_case_id() -{ - return impl::s_frk_state().m_curr_test_unit; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** framework::get ************** // -// ************************************************************************** // - -test_unit& -get( test_unit_id id, test_unit_type t ) -{ - test_unit* res = impl::s_frk_state().m_test_units[id]; - - BOOST_TEST_I_ASSRT( (res->p_type & t) != 0, internal_error( "Invalid test unit type" ) ); - - return *res; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** framework::run ************** // -// ************************************************************************** // - -template <class Cont> -struct swap_on_delete { - swap_on_delete(Cont& c1, Cont& c2) : m_c1(c1), m_c2(c2){} - ~swap_on_delete() { - m_c1.swap(m_c2); - } - - Cont& m_c1; - Cont& m_c2; -}; - -struct register_observer_helper { - register_observer_helper(test_observer& observer) - : m_observer(observer) - { - register_obs(); - } - - ~register_observer_helper() { - if(m_registered) - deregister_observer( m_observer ); - } - - void deregister_obs() { - m_registered = false; - deregister_observer( m_observer ); - } - - void register_obs() { - m_registered = true; - register_observer( m_observer ); - } - - - test_observer& m_observer; - bool m_registered; -}; - -void -run( test_unit_id id, bool continue_test ) -{ - if( id == INV_TEST_UNIT_ID ) - id = master_test_suite().p_id; - - // Figure out run status for execution phase - impl::s_frk_state().deduce_run_status( id ); - - test_case_counter tcc; - traverse_test_tree( id, tcc ); - - BOOST_TEST_SETUP_ASSERT( tcc.p_count != 0 , runtime_config::get<std::vector<std::string> >( runtime_config::btrt_run_filters ).empty() - ? BOOST_TEST_L( "test tree is empty" ) - : BOOST_TEST_L( "no test cases matching filter or all test cases were disabled" ) ); - - bool was_in_progress = framework::test_in_progress(); - bool call_start_finish = !continue_test || !was_in_progress; - bool init_ok = true; - const_string setup_error; - - framework_init_observer_t local_init_observer; - register_observer_helper init_observer_helper( local_init_observer ); - - if( call_start_finish ) { - // indicates the framework that no test is in progress now if observers need to be notified - impl::s_frk_state().m_test_in_progress = false; - // unit_test::framework_init_observer will get cleared first - BOOST_TEST_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) { - BOOST_TEST_I_TRY { - ut_detail::test_unit_id_restore restore_current_test_unit(impl::s_frk_state().m_curr_test_unit, id); - unit_test_monitor_t::error_level result = unit_test_monitor.execute_and_translate( boost::bind( &test_observer::test_start, to, tcc.p_count, id ) ); - if( init_ok ) { - if( result != unit_test_monitor_t::test_ok ) { - init_ok = false; - } - else { - if( local_init_observer.has_failed() ) { - init_ok = false; - } - } - } - } - BOOST_TEST_I_CATCH( execution_exception, ex ) { - if( init_ok ) { - // log only the first error - init_ok = false; - setup_error = ex.what(); - } - // break; // we should continue otherwise loggers may have improper structure (XML start missing for instance) - } - } - } - - // removing this observer as it should not be of any use for the tests - init_observer_helper.deregister_obs(); - - if( init_ok ) { - - // attaching the global fixtures to the main entry point - test_unit& entry_test_unit = framework::get( id, TUT_ANY ); - std::vector<test_unit_fixture_ptr> v_saved_fixture(entry_test_unit.p_fixtures.value.begin(), - entry_test_unit.p_fixtures.value.end()); - - BOOST_TEST_FOREACH( test_unit_fixture*, tuf, impl::s_frk_state().m_global_fixtures ) { - entry_test_unit.p_fixtures.value.insert( entry_test_unit.p_fixtures.value.begin(), - test_unit_fixture_ptr(new impl::global_fixture_handle(tuf)) ); - } - - swap_on_delete< std::vector<test_unit_fixture_ptr> > raii_fixture(v_saved_fixture, entry_test_unit.p_fixtures.value); - - // now work in progress - impl::s_frk_state().m_test_in_progress = true; - unsigned seed = runtime_config::get<unsigned>( runtime_config::btrt_random_seed ); - switch( seed ) { - case 0: - break; - case 1: - seed = static_cast<unsigned>( std::rand() ^ std::time( 0 ) ); // better init using std::rand() ^ ... - BOOST_FALLTHROUGH; - default: - BOOST_TEST_FRAMEWORK_MESSAGE( "Test cases order is shuffled using seed: " << seed ); - std::srand( seed ); - } - - // executing the test tree - impl::s_frk_state().execute_test_tree( id ); - - // removing previously added global fixtures: dtor raii_fixture - } - - impl::s_frk_state().m_test_in_progress = false; - - results_reporter::make_report( INV_REPORT_LEVEL, id ); - - // reinstalling this observer - init_observer_helper.register_obs(); - - local_init_observer.clear(); - if( call_start_finish ) { - // indicates the framework that no test is in progress anymore if observers need to be notified - // and this is a teardown, so assertions should not raise any exception otherwise an exception - // might be raised in a dtor of a global fixture - impl::s_frk_state().m_test_in_progress = false; - BOOST_TEST_REVERSE_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) { - ut_detail::test_unit_id_restore restore_current_test_unit(impl::s_frk_state().m_curr_test_unit, id); - to->test_finish(); - } - } - - impl::s_frk_state().m_test_in_progress = was_in_progress; - - // propagates the init/teardown error if any - BOOST_TEST_SETUP_ASSERT( init_ok && !local_init_observer.has_failed(), setup_error ); -} - -//____________________________________________________________________________// - -void -run( test_unit const* tu, bool continue_test ) -{ - run( tu->p_id, continue_test ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** assertion_result ************** // -// ************************************************************************** // - -void -assertion_result( unit_test::assertion_result ar ) -{ - BOOST_TEST_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) - to->assertion_result( ar ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** exception_caught ************** // -// ************************************************************************** // - -void -exception_caught( execution_exception const& ex ) -{ - BOOST_TEST_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) - to->exception_caught( ex ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** test_unit_aborted ************** // -// ************************************************************************** // - -void -test_unit_aborted( test_unit const& tu ) -{ - BOOST_TEST_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) - to->test_unit_aborted( tu ); -} - -// ************************************************************************** // -// ************** test_aborted ************** // -// ************************************************************************** // - -void -test_aborted( ) -{ - BOOST_TEST_FOREACH( test_observer*, to, impl::s_frk_state().m_observers ) - to->test_aborted( ); -} - - -//____________________________________________________________________________// - -} // namespace framework -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_FRAMEWORK_IPP_021005GER diff --git a/ThirdParty/boost/test/impl/junit_log_formatter.ipp b/ThirdParty/boost/test/impl/junit_log_formatter.ipp deleted file mode 100644 index 10d83527c0bb09860637ad8925c52f3b0abf690e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/junit_log_formatter.ipp +++ /dev/null @@ -1,878 +0,0 @@ -// (C) Copyright 2016 Raffi Enficiaud. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -///@file -///@brief Contains the implementatoin of the Junit log formatter (OF_JUNIT) -// *************************************************************************** - -#ifndef BOOST_TEST_JUNIT_LOG_FORMATTER_IPP__ -#define BOOST_TEST_JUNIT_LOG_FORMATTER_IPP__ - -// Boost.Test -#include <boost/test/output/junit_log_formatter.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> -#include <boost/test/utils/xml_printer.hpp> -#include <boost/test/utils/string_cast.hpp> -#include <boost/test/framework.hpp> - -#include <boost/test/tree/visitor.hpp> -#include <boost/test/tree/traverse.hpp> -#include <boost/test/results_collector.hpp> - -#include <boost/test/utils/algorithm.hpp> -#include <boost/test/utils/string_cast.hpp> - -//#include <boost/test/results_reporter.hpp> - - -// Boost -#include <boost/version.hpp> -#include <boost/core/ignore_unused.hpp> - -// STL -#include <iostream> -#include <fstream> -#include <set> - -#include <boost/test/detail/suppress_warnings.hpp> - - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace output { - - -struct s_replace_chars { - template <class T> - void operator()(T& to_replace) - { - if(to_replace == '/') - to_replace = '.'; - else if(to_replace == ' ') - to_replace = '_'; - } -}; - -inline std::string tu_name_normalize(std::string full_name) -{ - // maybe directly using normalize_test_case_name instead? - std::for_each(full_name.begin(), full_name.end(), s_replace_chars()); - return full_name; -} - -inline std::string tu_name_remove_newlines(std::string full_name) -{ - full_name.erase(std::remove(full_name.begin(), full_name.end(), '\n'), full_name.end()); - return full_name; -} - -const_string file_basename(const_string filename) { - - const_string path_sep( "\\/" ); - const_string::iterator it = unit_test::utils::find_last_of( filename.begin(), filename.end(), - path_sep.begin(), path_sep.end() ); - if( it != filename.end() ) - filename.trim_left( it + 1 ); - - return filename; - -} - -// ************************************************************************** // -// ************** junit_log_formatter ************** // -// ************************************************************************** // - -void -junit_log_formatter::log_start( std::ostream& /*ostr*/, counter_t /*test_cases_amount*/) -{ - map_tests.clear(); - list_path_to_root.clear(); - runner_log_entry.clear(); -} - -//____________________________________________________________________________// - -class junit_result_helper : public test_tree_visitor { -private: - typedef junit_impl::junit_log_helper::assertion_entry assertion_entry; - typedef std::vector< assertion_entry >::const_iterator vect_assertion_entry_citerator; - typedef std::list<std::string>::const_iterator list_str_citerator; - -public: - explicit junit_result_helper( - std::ostream& stream, - test_unit const& ts, - junit_log_formatter::map_trace_t const& mt, - junit_impl::junit_log_helper const& runner_log_, - bool display_build_info ) - : m_stream(stream) - , m_ts( ts ) - , m_map_test( mt ) - , runner_log( runner_log_ ) - , m_id( 0 ) - , m_display_build_info(display_build_info) - { } - - void add_log_entry(assertion_entry const& log) const - { - std::string entry_type; - if( log.log_entry == assertion_entry::log_entry_failure ) { - entry_type = "failure"; - } - else if( log.log_entry == assertion_entry::log_entry_error ) { - entry_type = "error"; - } - else { - return; - } - - m_stream - << "<" << entry_type - << " message" << utils::attr_value() << log.logentry_message - << " type" << utils::attr_value() << log.logentry_type - << ">"; - - if(!log.output.empty()) { - m_stream << utils::cdata() << "\n" + log.output; - } - - m_stream << "</" << entry_type << ">"; - } - - struct conditional_cdata_helper { - std::ostream &ostr; - std::string const field; - bool empty; - - conditional_cdata_helper(std::ostream &ostr_, std::string field_) - : ostr(ostr_) - , field(field_) - , empty(true) - {} - - ~conditional_cdata_helper() { - if(!empty) { - ostr << BOOST_TEST_L( "]]>" ) << "</" << field << '>' << std::endl; - } - } - - void operator()(const std::string& s) { - bool current_empty = s.empty(); - if(empty) { - if(!current_empty) { - empty = false; - ostr << '<' << field << '>' << BOOST_TEST_L( "<![CDATA[" ); - } - } - if(!current_empty) { - ostr << s; - } - } - }; - - std::list<std::string> build_skipping_chain(test_unit const & tu) const - { - // we enter here because we know that the tu has been skipped. - // either junit has not seen this tu, or it is indicated as disabled - assert(m_map_test.count(tu.p_id) == 0 || results_collector.results( tu.p_id ).p_skipped); - - std::list<std::string> out; - - test_unit_id id(tu.p_id); - while( id != m_ts.p_id && id != INV_TEST_UNIT_ID) { - test_unit const& tu_hierarchy = boost::unit_test::framework::get( id, TUT_ANY ); - out.push_back("- disabled test unit: '" + tu_name_remove_newlines(tu_hierarchy.full_name()) + "'\n"); - if(m_map_test.count(id) > 0) - { - // junit has seen the reason: this is enough for constructing the chain - break; - } - id = tu_hierarchy.p_parent_id; - } - junit_log_formatter::map_trace_t::const_iterator it_element_stack(m_map_test.find(id)); - if( it_element_stack != m_map_test.end() ) - { - out.push_back("- reason: '" + it_element_stack->second.skipping_reason + "'"); - out.push_front("Test case disabled because of the following chain of decision:\n"); - } - - return out; - } - - std::string get_class_name(test_unit const & tu_class) const { - std::string classname; - test_unit_id id(tu_class.p_parent_id); - while( id != m_ts.p_id && id != INV_TEST_UNIT_ID ) { - test_unit const& tu = boost::unit_test::framework::get( id, TUT_ANY ); - classname = tu_name_normalize(tu.p_name) + "." + classname; - id = tu.p_parent_id; - } - - // removes the trailing dot - if(!classname.empty() && *classname.rbegin() == '.') { - classname.erase(classname.size()-1); - } - - return classname; - } - - void write_testcase_header(test_unit const & tu, - test_results const *tr, - int nb_assertions) const - { - std::string name; - std::string classname; - - if(tu.p_id == m_ts.p_id ) { - name = "boost_test"; - } - else { - classname = get_class_name(tu); - name = tu_name_normalize(tu.p_name); - } - - if( tu.p_type == TUT_SUITE ) { - if(tr->p_timed_out) - name += "-timed-execution"; - else - name += "-setup-teardown"; - } - - m_stream << "<testcase assertions" << utils::attr_value() << nb_assertions; - if(!classname.empty()) - m_stream << " classname" << utils::attr_value() << classname; - - // test case name and time taken - m_stream - << " name" << utils::attr_value() << name - << " time" << utils::attr_value() << double(tr->p_duration_microseconds) * 1E-6 - << ">" << std::endl; - } - - void write_testcase_system_out(junit_impl::junit_log_helper const &detailed_log, - test_unit const * tu, - bool skipped) const - { - // system-out + all info/messages, the object skips the empty entries - conditional_cdata_helper system_out_helper(m_stream, "system-out"); - - // indicate why the test has been skipped first - if( skipped ) { - std::list<std::string> skipping_decision_chain = build_skipping_chain(*tu); - for(list_str_citerator it(skipping_decision_chain.begin()), ite(skipping_decision_chain.end()); - it != ite; - ++it) - { - system_out_helper(*it); - } - } - - // stdout - for(list_str_citerator it(detailed_log.system_out.begin()), ite(detailed_log.system_out.end()); - it != ite; - ++it) - { - system_out_helper(*it); - } - - // warning/info message last - for(vect_assertion_entry_citerator it(detailed_log.assertion_entries.begin()); - it != detailed_log.assertion_entries.end(); - ++it) - { - if(it->log_entry != assertion_entry::log_entry_info) - continue; - system_out_helper(it->output); - } - } - - void write_testcase_system_err(junit_impl::junit_log_helper const &detailed_log, - test_unit const * tu, - test_results const *tr) const - { - // system-err output + test case informations - bool has_failed = (tr != 0) ? !tr->p_skipped && !tr->passed() : false; - if(!detailed_log.system_err.empty() || has_failed) - { - std::ostringstream o; - if(has_failed) { - o << "Failures detected in:" << std::endl; - } - else { - o << "ERROR STREAM:" << std::endl; - } - - if(tu->p_type == TUT_SUITE) { - if( tu->p_id == m_ts.p_id ) { - o << " boost.test global setup/teardown" << std::endl; - } else { - o << "- test suite: " << tu_name_remove_newlines(tu->full_name()) << std::endl; - } - } - else { - o << "- test case: " << tu_name_remove_newlines(tu->full_name()); - if(!tu->p_description.value.empty()) - o << " '" << tu->p_description << "'"; - - o << std::endl - << "- file: " << file_basename(tu->p_file_name) << std::endl - << "- line: " << tu->p_line_num << std::endl - ; - } - - if(!detailed_log.system_err.empty()) - o << std::endl << "STDERR BEGIN: ------------" << std::endl; - - for(list_str_citerator it(detailed_log.system_err.begin()), ite(detailed_log.system_err.end()); - it != ite; - ++it) - { - o << *it; - } - - if(!detailed_log.system_err.empty()) - o << std::endl << "STDERR END ------------" << std::endl; - - conditional_cdata_helper system_err_helper(m_stream, "system-err"); - system_err_helper(o.str()); - } - } - - int get_nb_assertions(junit_impl::junit_log_helper const &detailed_log, - test_unit const & tu, - test_results const *tr) const { - int nb_assertions(-1); - if( tu.p_type == TUT_SUITE ) { - nb_assertions = 0; - for(vect_assertion_entry_citerator it(detailed_log.assertion_entries.begin()); - it != detailed_log.assertion_entries.end(); - ++it) - { - if(it->log_entry != assertion_entry::log_entry_info) - nb_assertions++; - } - } - else { - nb_assertions = static_cast<int>(tr->p_assertions_passed + tr->p_assertions_failed); - } - - return nb_assertions; - } - - void output_detailed_logs(junit_impl::junit_log_helper const &detailed_log, - test_unit const & tu, - bool skipped, - test_results const *tr) const - { - int nb_assertions = get_nb_assertions(detailed_log, tu, tr); - if(!nb_assertions && tu.p_type == TUT_SUITE) - return; - - write_testcase_header(tu, tr, nb_assertions); - - if( skipped ) { - m_stream << "<skipped/>" << std::endl; - } - else { - - for(vect_assertion_entry_citerator it(detailed_log.assertion_entries.begin()); - it != detailed_log.assertion_entries.end(); - ++it) - { - add_log_entry(*it); - } - } - - write_testcase_system_out(detailed_log, &tu, skipped); - write_testcase_system_err(detailed_log, &tu, tr); - m_stream << "</testcase>" << std::endl; - } - - void visit( test_case const& tc ) - { - - test_results const& tr = results_collector.results( tc.p_id ); - junit_log_formatter::map_trace_t::const_iterator it_find = m_map_test.find(tc.p_id); - if(it_find == m_map_test.end()) - { - // test has been skipped and not seen by the logger - output_detailed_logs(junit_impl::junit_log_helper(), tc, true, &tr); - } - else { - output_detailed_logs(it_find->second, tc, tr.p_skipped, &tr); - } - } - - bool test_suite_start( test_suite const& ts ) - { - test_results const& tr = results_collector.results( ts.p_id ); - - // unique test suite, without s, nesting not supported in CI - if( m_ts.p_id == ts.p_id ) { - m_stream << "<testsuite"; - - // think about: maybe we should add the number of fixtures of a test_suite as - // independant tests (field p_fixtures). - // same goes for the timed-execution: we can think of that as a separate test-unit - // in the suite. - // see https://llg.cubic.org/docs/junit/ and - // http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLJUnitResultFormatter.java?view=markup - m_stream - // << "disabled=\"" << tr.p_test_cases_skipped << "\" " - << " tests" << utils::attr_value() - << tr.p_test_cases_passed - + tr.p_test_cases_failed - // + tr.p_test_cases_aborted // aborted is also failed, we avoid counting it twice - << " skipped" << utils::attr_value() << tr.p_test_cases_skipped - << " errors" << utils::attr_value() << tr.p_test_cases_aborted - << " failures" << utils::attr_value() - << tr.p_test_cases_failed - + tr.p_test_suites_timed_out - + tr.p_test_cases_timed_out - - tr.p_test_cases_aborted // failed is not aborted in the Junit sense - << " id" << utils::attr_value() << m_id++ - << " name" << utils::attr_value() << tu_name_normalize(ts.p_name) - << " time" << utils::attr_value() << (tr.p_duration_microseconds * 1E-6) - << ">" << std::endl; - - if(m_display_build_info) - { - m_stream << "<properties>" << std::endl; - m_stream << "<property name=\"platform\" value" << utils::attr_value() << BOOST_PLATFORM << " />" << std::endl; - m_stream << "<property name=\"compiler\" value" << utils::attr_value() << BOOST_COMPILER << " />" << std::endl; - m_stream << "<property name=\"stl\" value" << utils::attr_value() << BOOST_STDLIB << " />" << std::endl; - - std::ostringstream o; - o << BOOST_VERSION/100000 << "." << BOOST_VERSION/100 % 1000 << "." << BOOST_VERSION % 100; - m_stream << "<property name=\"boost\" value" << utils::attr_value() << o.str() << " />" << std::endl; - m_stream << "</properties>" << std::endl; - } - } - - if( !tr.p_skipped ) { - // if we land here, then this is a chance that we are logging the fixture setup/teardown of a test-suite. - // the setup/teardown logging of a test-case is part of the test case. - // we do not care about the test-suite that were skipped (really??) - junit_log_formatter::map_trace_t::const_iterator it_find = m_map_test.find(ts.p_id); - if(it_find != m_map_test.end()) { - output_detailed_logs(it_find->second, ts, false, &tr); - } - } - - return true; // indicates that the children should also be parsed - } - - virtual void test_suite_finish( test_suite const& ts ) - { - if( m_ts.p_id == ts.p_id ) { - write_testcase_system_out(runner_log, 0, false); - write_testcase_system_err(runner_log, 0, 0); - - m_stream << "</testsuite>"; - return; - } - } - -private: - // Data members - std::ostream& m_stream; - test_unit const& m_ts; - junit_log_formatter::map_trace_t const& m_map_test; - junit_impl::junit_log_helper const& runner_log; - size_t m_id; - bool m_display_build_info; -}; - - - -void -junit_log_formatter::log_finish( std::ostream& ostr ) -{ - ostr << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" << std::endl; - - // getting the root test suite - if(!map_tests.empty()) { - test_unit* root = &boost::unit_test::framework::get( map_tests.begin()->first, TUT_ANY ); - - // looking for the root of the SUBtree (we stay in the subtree) - while(root->p_parent_id != INV_TEST_UNIT_ID && map_tests.count(root->p_parent_id) > 0) { - root = &boost::unit_test::framework::get( root->p_parent_id, TUT_ANY ); - } - junit_result_helper ch( ostr, *root, map_tests, this->runner_log_entry, m_display_build_info ); - traverse_test_tree( root->p_id, ch, true ); // last is to ignore disabled suite special handling - } - else { - ostr << "<testsuites errors=\"1\">"; - ostr << "<testsuite errors=\"1\" name=\"boost-test-framework\">"; - ostr << "<testcase assertions=\"1\" name=\"test-setup\">"; - ostr << "<system-out>Incorrect setup: no test case executed</system-out>"; - ostr << "</testcase></testsuite></testsuites>"; - } - return; -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_build_info( std::ostream& /*ostr*/, bool log_build_info ) -{ - m_display_build_info = log_build_info; -} - -//____________________________________________________________________________// - -void -junit_log_formatter::test_unit_start( std::ostream& /*ostr*/, test_unit const& tu ) -{ - list_path_to_root.push_back( tu.p_id ); - map_tests.insert(std::make_pair(tu.p_id, junit_impl::junit_log_helper())); // current_test_case_id not working here -} - - - -//____________________________________________________________________________// - - -void -junit_log_formatter::test_unit_finish( std::ostream& /*ostr*/, test_unit const& tu, unsigned long /*elapsed*/ ) -{ - // the time is already stored in the result_reporter - boost::ignore_unused( tu ); - assert( tu.p_id == list_path_to_root.back() ); - list_path_to_root.pop_back(); -} - -void -junit_log_formatter::test_unit_aborted( std::ostream& /*ostr*/, test_unit const& tu ) -{ - boost::ignore_unused( tu ); - assert( tu.p_id == list_path_to_root.back() ); - //list_path_to_root.pop_back(); -} - -//____________________________________________________________________________// - -void -junit_log_formatter::test_unit_timed_out( std::ostream& /*os*/, test_unit const& tu) -{ - if(tu.p_type == TUT_SUITE) - { - // if we reach this call, it means that the test has already started and - // test_unit_start has already been called on the tu. - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - junit_impl::junit_log_helper::assertion_entry entry; - entry.logentry_message = "test-suite time out"; - entry.logentry_type = "execution timeout"; - entry.log_entry = junit_impl::junit_log_helper::assertion_entry::log_entry_error; - entry.output = "the current suite exceeded the allocated execution time"; - last_entry.assertion_entries.push_back(entry); - } -} - -//____________________________________________________________________________// - -void -junit_log_formatter::test_unit_skipped( std::ostream& /*ostr*/, test_unit const& tu, const_string reason ) -{ - // if a test unit is skipped, then the start of this TU has not been called yet. - // we cannot use get_current_log_entry here, but the TU id should appear in the map. - // The "skip" boolean is given by the boost.test framework - junit_impl::junit_log_helper& v = map_tests[tu.p_id]; // not sure if we can use get_current_log_entry() - v.skipping_reason.assign(reason.begin(), reason.end()); -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_exception_start( std::ostream& /*ostr*/, log_checkpoint_data const& checkpoint_data, execution_exception const& ex ) -{ - std::ostringstream o; - execution_exception::location const& loc = ex.where(); - - m_is_last_assertion_or_error = false; - - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - - junit_impl::junit_log_helper::assertion_entry entry; - - entry.logentry_message = "unexpected exception"; - entry.log_entry = junit_impl::junit_log_helper::assertion_entry::log_entry_error; - - switch(ex.code()) - { - case execution_exception::cpp_exception_error: - entry.logentry_type = "uncaught exception"; - break; - case execution_exception::timeout_error: - entry.logentry_type = "execution timeout"; - break; - case execution_exception::user_error: - entry.logentry_type = "user, assert() or CRT error"; - break; - case execution_exception::user_fatal_error: - // Looks like never used - entry.logentry_type = "user fatal error"; - break; - case execution_exception::system_error: - entry.logentry_type = "system error"; - break; - case execution_exception::system_fatal_error: - entry.logentry_type = "system fatal error"; - break; - default: - entry.logentry_type = "no error"; // not sure how to handle this one - break; - } - - o << "UNCAUGHT EXCEPTION:" << std::endl; - if( !loc.m_function.is_empty() ) - o << "- function: \"" << loc.m_function << "\"" << std::endl; - - o << "- file: " << file_basename(loc.m_file_name) << std::endl - << "- line: " << loc.m_line_num << std::endl - << std::endl; - - o << "\nEXCEPTION STACK TRACE: --------------\n" << ex.what() - << "\n-------------------------------------"; - - if( !checkpoint_data.m_file_name.is_empty() ) { - o << std::endl << std::endl - << "Last checkpoint:" << std::endl - << "- message: \"" << checkpoint_data.m_message << "\"" << std::endl - << "- file: " << file_basename(checkpoint_data.m_file_name) << std::endl - << "- line: " << checkpoint_data.m_line_num << std::endl - ; - } - - entry.output = o.str(); - - last_entry.assertion_entries.push_back(entry); -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_exception_finish( std::ostream& /*ostr*/ ) -{ - // sealing the last entry - assert(!get_current_log_entry().assertion_entries.back().sealed); - get_current_log_entry().assertion_entries.back().sealed = true; -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_entry_start( std::ostream& /*ostr*/, log_entry_data const& entry_data, log_entry_types let ) -{ - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - last_entry.skipping = false; - m_is_last_assertion_or_error = true; - switch(let) - { - case unit_test_log_formatter::BOOST_UTL_ET_INFO: - { - if(m_log_level_internal > log_successful_tests) { - last_entry.skipping = true; - break; - } - BOOST_FALLTHROUGH; - } - case unit_test_log_formatter::BOOST_UTL_ET_MESSAGE: - { - if(m_log_level_internal > log_messages) { - last_entry.skipping = true; - break; - } - BOOST_FALLTHROUGH; - } - case unit_test_log_formatter::BOOST_UTL_ET_WARNING: - { - if(m_log_level_internal > log_warnings) { - last_entry.skipping = true; - break; - } - std::ostringstream o; - junit_impl::junit_log_helper::assertion_entry entry; - - entry.log_entry = junit_impl::junit_log_helper::assertion_entry::log_entry_info; - entry.logentry_message = "info"; - entry.logentry_type = "message"; - - o << (let == unit_test_log_formatter::BOOST_UTL_ET_WARNING ? - "WARNING:" : (let == unit_test_log_formatter::BOOST_UTL_ET_MESSAGE ? - "MESSAGE:" : "INFO:")) - << std::endl - << "- file : " << file_basename(entry_data.m_file_name) << std::endl - << "- line : " << entry_data.m_line_num << std::endl - << "- message: "; // no CR - - entry.output += o.str(); - last_entry.assertion_entries.push_back(entry); - break; - } - default: - case unit_test_log_formatter::BOOST_UTL_ET_ERROR: - case unit_test_log_formatter::BOOST_UTL_ET_FATAL_ERROR: - { - std::ostringstream o; - junit_impl::junit_log_helper::assertion_entry entry; - entry.log_entry = junit_impl::junit_log_helper::assertion_entry::log_entry_failure; - entry.logentry_message = "failure"; - entry.logentry_type = (let == unit_test_log_formatter::BOOST_UTL_ET_ERROR ? "assertion error" : "fatal error"); - - o << "ASSERTION FAILURE:" << std::endl - << "- file : " << file_basename(entry_data.m_file_name) << std::endl - << "- line : " << entry_data.m_line_num << std::endl - << "- message: " ; // no CR - - entry.output += o.str(); - last_entry.assertion_entries.push_back(entry); - break; - } - } -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_entry_value( std::ostream& /*ostr*/, const_string value ) -{ - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - if(last_entry.skipping) - return; - - assert(last_entry.assertion_entries.empty() || !last_entry.assertion_entries.back().sealed); - - if(!last_entry.assertion_entries.empty()) - { - junit_impl::junit_log_helper::assertion_entry& log_entry = last_entry.assertion_entries.back(); - log_entry.output += value; - } - else - { - // this may be a message coming from another observer - // the prefix is set in the log_entry_start - last_entry.system_out.push_back(std::string(value.begin(), value.end())); - } -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_entry_finish( std::ostream& /*ostr*/ ) -{ - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - if(!last_entry.skipping) - { - assert(last_entry.assertion_entries.empty() || !last_entry.assertion_entries.back().sealed); - - if(!last_entry.assertion_entries.empty()) { - junit_impl::junit_log_helper::assertion_entry& log_entry = last_entry.assertion_entries.back(); - log_entry.output += "\n\n"; // quote end, CR - log_entry.sealed = true; - } - else { - last_entry.system_out.push_back("\n\n"); // quote end, CR - } - } - - last_entry.skipping = false; -} - -//____________________________________________________________________________// - -void -junit_log_formatter::entry_context_start( std::ostream& /*ostr*/, log_level ) -{ - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - if(last_entry.skipping) - return; - - std::vector< junit_impl::junit_log_helper::assertion_entry > &v_failure_or_error = last_entry.assertion_entries; - assert(!v_failure_or_error.back().sealed); - - junit_impl::junit_log_helper::assertion_entry& last_log_entry = v_failure_or_error.back(); - if(m_is_last_assertion_or_error) - { - last_log_entry.output += "\n- context:\n"; - } - else - { - last_log_entry.output += "\n\nCONTEXT:\n"; - } -} - -//____________________________________________________________________________// - -void -junit_log_formatter::entry_context_finish( std::ostream& /*ostr*/, log_level ) -{ - // no op, may be removed - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - if(last_entry.skipping) - return; - assert(!get_current_log_entry().assertion_entries.back().sealed); -} - -//____________________________________________________________________________// - -void -junit_log_formatter::log_entry_context( std::ostream& /*ostr*/, log_level , const_string context_descr ) -{ - junit_impl::junit_log_helper& last_entry = get_current_log_entry(); - if(last_entry.skipping) - return; - - assert(!last_entry.assertion_entries.back().sealed); - junit_impl::junit_log_helper::assertion_entry& last_log_entry = get_current_log_entry().assertion_entries.back(); - - last_log_entry.output += - (m_is_last_assertion_or_error ? " - '": "- '") + std::string(context_descr.begin(), context_descr.end()) + "'\n"; // quote end -} - -//____________________________________________________________________________// - - -std::string -junit_log_formatter::get_default_stream_description() const { - std::string name = framework::master_test_suite().p_name.value; - - static const std::string to_replace[] = { " ", "\"", "/", "\\", ":"}; - static const std::string replacement[] = { "_", "_" , "_", "_" , "_"}; - - name = unit_test::utils::replace_all_occurrences_of( - name, - to_replace, to_replace + sizeof(to_replace)/sizeof(to_replace[0]), - replacement, replacement + sizeof(replacement)/sizeof(replacement[0])); - - std::ifstream check_init((name + ".xml").c_str()); - if(!check_init) - return name + ".xml"; - - int index = 0; - for(; index < 100; index++) { - std::string candidate = name + "_" + utils::string_cast(index) + ".xml"; - std::ifstream file(candidate.c_str()); - if(!file) - return candidate; - } - - return name + ".xml"; -} - -} // namespace output -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_junit_log_formatter_IPP_020105GER diff --git a/ThirdParty/boost/test/impl/progress_monitor.ipp b/ThirdParty/boost/test/impl/progress_monitor.ipp deleted file mode 100644 index 4aacb357a448de45b6be70d09f85fe12c4c2c341..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/progress_monitor.ipp +++ /dev/null @@ -1,189 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : implements simple text based progress monitor -// *************************************************************************** - -#ifndef BOOST_TEST_PROGRESS_MONITOR_IPP_020105GER -#define BOOST_TEST_PROGRESS_MONITOR_IPP_020105GER - -// Boost.Test -#include <boost/test/progress_monitor.hpp> -#include <boost/test/unit_test_parameters.hpp> - -#include <boost/test/utils/setcolor.hpp> - -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/test_case_counter.hpp> -#include <boost/test/tree/traverse.hpp> - -// Boost -#include <boost/scoped_ptr.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** progress_monitor ************** // -// ************************************************************************** // - -struct progress_display { - progress_display( counter_t expected_count, std::ostream& os ) - : m_os(os) - , m_count( 0 ) - , m_expected_count( expected_count ) - , m_next_tic_count( 0 ) - , m_tic( 0 ) - { - - m_os << "\n0% 10 20 30 40 50 60 70 80 90 100%" - << "\n|----|----|----|----|----|----|----|----|----|----|" - << std::endl; - - if( !m_expected_count ) - m_expected_count = 1; // prevent divide by zero - } - - unsigned long operator+=( unsigned long increment ) - { - if( (m_count += increment) < m_next_tic_count ) - return m_count; - - // use of floating point ensures that both large and small counts - // work correctly. static_cast<>() is also used several places - // to suppress spurious compiler warnings. - unsigned int tics_needed = static_cast<unsigned int>( - (static_cast<double>(m_count)/m_expected_count)*50.0 ); - - do { - m_os << '*' << std::flush; - } while( ++m_tic < tics_needed ); - - m_next_tic_count = static_cast<unsigned long>((m_tic/50.0) * m_expected_count); - - if( m_count == m_expected_count ) { - if( m_tic < 51 ) - m_os << '*'; - - m_os << std::endl; - } - - return m_count; - } - unsigned long operator++() { return operator+=( 1 ); } - unsigned long count() const { return m_count; } - -private: - BOOST_DELETED_FUNCTION(progress_display(progress_display const&)) - BOOST_DELETED_FUNCTION(progress_display& operator=(progress_display const&)) - - std::ostream& m_os; // may not be present in all imps - - unsigned long m_count; - unsigned long m_expected_count; - unsigned long m_next_tic_count; - unsigned int m_tic; -}; - -namespace { - -struct progress_monitor_impl { - // Constructor - progress_monitor_impl() - : m_stream( &std::cout ) - , m_color_output( false ) - { - } - - std::ostream* m_stream; - scoped_ptr<progress_display> m_progress_display; - bool m_color_output; -}; - -progress_monitor_impl& s_pm_impl() { static progress_monitor_impl the_inst; return the_inst; } - -#define PM_SCOPED_COLOR() \ - BOOST_TEST_SCOPE_SETCOLOR( s_pm_impl().m_color_output, *s_pm_impl().m_stream, term_attr::BRIGHT, term_color::MAGENTA ) - -} // local namespace - -//____________________________________________________________________________// - -BOOST_TEST_SINGLETON_CONS_IMPL(progress_monitor_t) - -//____________________________________________________________________________// - -void -progress_monitor_t::test_start( counter_t test_cases_amount, test_unit_id ) -{ - s_pm_impl().m_color_output = runtime_config::get<bool>( runtime_config::btrt_color_output ); - - PM_SCOPED_COLOR(); - - s_pm_impl().m_progress_display.reset( new progress_display( test_cases_amount, *s_pm_impl().m_stream ) ); -} - -//____________________________________________________________________________// - -void -progress_monitor_t::test_aborted() -{ - PM_SCOPED_COLOR(); - - (*s_pm_impl().m_progress_display) += s_pm_impl().m_progress_display->count(); -} - -//____________________________________________________________________________// - -void -progress_monitor_t::test_unit_finish( test_unit const& tu, unsigned long ) -{ - PM_SCOPED_COLOR(); - - if( tu.p_type == TUT_CASE ) - ++(*s_pm_impl().m_progress_display); -} - -//____________________________________________________________________________// - -void -progress_monitor_t::test_unit_skipped( test_unit const& tu, const_string /*reason*/ ) -{ - PM_SCOPED_COLOR(); - - test_case_counter tcc; - traverse_test_tree( tu, tcc ); - - (*s_pm_impl().m_progress_display) += tcc.p_count; -} - -//____________________________________________________________________________// - -void -progress_monitor_t::set_stream( std::ostream& ostr ) -{ - s_pm_impl().m_stream = &ostr; -} - -//____________________________________________________________________________// - -#undef PM_SCOPED_COLOR - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_PROGRESS_MONITOR_IPP_020105GER diff --git a/ThirdParty/boost/test/impl/results_collector.ipp b/ThirdParty/boost/test/impl/results_collector.ipp deleted file mode 100644 index 40d5e55c8f48ce75c80a8c5d60528f5852010d45..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/results_collector.ipp +++ /dev/null @@ -1,349 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Test results collecting facility. -/// -// *************************************************************************** - -#ifndef BOOST_TEST_RESULTS_COLLECTOR_IPP_021105GER -#define BOOST_TEST_RESULTS_COLLECTOR_IPP_021105GER - -// Boost.Test -#include <boost/test/unit_test_log.hpp> -#include <boost/test/results_collector.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/execution_monitor.hpp> - -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/visitor.hpp> -#include <boost/test/tree/test_case_counter.hpp> -#include <boost/test/tree/traverse.hpp> - -// Boost -#include <boost/cstdlib.hpp> - -// STL -#include <map> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** test_results ************** // -// ************************************************************************** // - -test_results::test_results() -{ - clear(); -} - -//____________________________________________________________________________// - -bool -test_results::passed() const -{ - // if it is skipped, it is not passed. However, if any children is not failed/aborted - // then their skipped status is not taken into account. - return !p_skipped && - p_test_cases_failed == 0 && - p_assertions_failed <= p_expected_failures && - // p_test_cases_skipped == 0 && - !p_timed_out && - p_test_cases_timed_out == 0 && - !aborted(); -} - -//____________________________________________________________________________// - -bool -test_results::aborted() const -{ - return p_aborted; -} - -//____________________________________________________________________________// - -bool -test_results::skipped() const -{ - return p_skipped; -} - -//____________________________________________________________________________// - -int -test_results::result_code() const -{ - return passed() ? exit_success - : ( (p_assertions_failed > p_expected_failures || p_skipped || p_timed_out || p_test_cases_timed_out ) - ? exit_test_failure - : exit_exception_failure ); -} - -//____________________________________________________________________________// - -void -test_results::operator+=( test_results const& tr ) -{ - p_test_suites.value += tr.p_test_suites; - p_assertions_passed.value += tr.p_assertions_passed; - p_assertions_failed.value += tr.p_assertions_failed; - p_warnings_failed.value += tr.p_warnings_failed; - p_test_cases_passed.value += tr.p_test_cases_passed; - p_test_cases_warned.value += tr.p_test_cases_warned; - p_test_cases_failed.value += tr.p_test_cases_failed; - p_test_cases_skipped.value += tr.p_test_cases_skipped; - p_test_cases_aborted.value += tr.p_test_cases_aborted; - p_test_cases_timed_out.value += tr.p_test_cases_timed_out; - p_test_suites_timed_out.value += tr.p_test_suites_timed_out; - p_duration_microseconds.value += tr.p_duration_microseconds; -} - -//____________________________________________________________________________// - -void -test_results::clear() -{ - p_test_suites.value = 0; - p_assertions_passed.value = 0; - p_assertions_failed.value = 0; - p_warnings_failed.value = 0; - p_expected_failures.value = 0; - p_test_cases_passed.value = 0; - p_test_cases_warned.value = 0; - p_test_cases_failed.value = 0; - p_test_cases_skipped.value = 0; - p_test_cases_aborted.value = 0; - p_test_cases_timed_out.value = 0; - p_test_suites_timed_out.value = 0; - p_duration_microseconds.value= 0; - p_aborted.value = false; - p_skipped.value = false; - p_timed_out.value = false; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** results_collector ************** // -// ************************************************************************** // - -namespace { - -struct results_collector_impl { - std::map<test_unit_id,test_results> m_results_store; -}; - -results_collector_impl& s_rc_impl() { static results_collector_impl the_inst; return the_inst; } - -// deletes the entries of results_collector_impl -class clear_subtree_result : public test_tree_visitor { -public: - clear_subtree_result(results_collector_impl& store) - : m_store( store ) - {} - -private: - virtual bool visit( test_unit const& tu) - { - typedef std::map<test_unit_id,test_results>::iterator iterator; - iterator found = m_store.m_results_store.find(tu.p_id); - if(found != m_store.m_results_store.end()) { - m_store.m_results_store.erase( found ); - } - return true; - } - - results_collector_impl& m_store; -}; - -} // local namespace - -//____________________________________________________________________________// - -BOOST_TEST_SINGLETON_CONS_IMPL( results_collector_t ) - -//____________________________________________________________________________// - -void -results_collector_t::test_start( counter_t, test_unit_id id ) -{ - // deletes the results under id only - clear_subtree_result tree_clear(s_rc_impl()); - traverse_test_tree( id, tree_clear ); -} - -//____________________________________________________________________________// - -void -results_collector_t::test_unit_start( test_unit const& tu ) -{ - // init test_results entry - test_results& tr = s_rc_impl().m_results_store[tu.p_id]; - - tr.clear(); - - tr.p_expected_failures.value = tu.p_expected_failures; -} - -//____________________________________________________________________________// - -class results_collect_helper : public test_tree_visitor { -public: - explicit results_collect_helper( test_results& tr, test_unit const& ts ) : m_tr( tr ), m_ts( ts ) {} - - void visit( test_case const& tc ) - { - test_results const& tr = results_collector.results( tc.p_id ); - m_tr += tr; - - if( tr.passed() ) { - if( tr.p_warnings_failed ) - m_tr.p_test_cases_warned.value++; - else - m_tr.p_test_cases_passed.value++; - } - else if( tr.p_timed_out ) { - m_tr.p_test_cases_timed_out.value++; - } - else if( tr.p_skipped || !tc.is_enabled() ) { - m_tr.p_test_cases_skipped.value++; - } - else { - if( tr.p_aborted ) - m_tr.p_test_cases_aborted.value++; - - m_tr.p_test_cases_failed.value++; - } - } - bool test_suite_start( test_suite const& ts ) - { - if( m_ts.p_id == ts.p_id ) - return true; - - m_tr += results_collector.results( ts.p_id ); - m_tr.p_test_suites.value++; - - if( results_collector.results( ts.p_id ).p_timed_out ) - m_tr.p_test_suites_timed_out.value++; - return false; - } - -private: - // Data members - test_results& m_tr; - test_unit const& m_ts; -}; - -//____________________________________________________________________________// - -void -results_collector_t::test_unit_finish( test_unit const& tu, unsigned long elapsed_in_microseconds ) -{ - test_results & tr = s_rc_impl().m_results_store[tu.p_id]; - if( tu.p_type == TUT_SUITE ) { - results_collect_helper ch( tr, tu ); - traverse_test_tree( tu, ch, true ); // true to ignore the status: we need to count the skipped/disabled tests - } - else { - bool num_failures_match = tr.p_aborted || tr.p_assertions_failed >= tr.p_expected_failures; - if( !num_failures_match ) - BOOST_TEST_FRAMEWORK_MESSAGE( "Test case " << tu.full_name() << " has fewer failures than expected" ); - - bool check_any_assertions = tr.p_aborted || (tr.p_assertions_failed != 0) || (tr.p_assertions_passed != 0); - if( !check_any_assertions ) - BOOST_TEST_FRAMEWORK_MESSAGE( "Test case " << tu.full_name() << " did not check any assertions" ); - } - tr.p_duration_microseconds.value = elapsed_in_microseconds; -} - -//____________________________________________________________________________// - -void -results_collector_t::test_unit_skipped( test_unit const& tu, const_string /*reason*/ ) -{ - test_results& tr = s_rc_impl().m_results_store[tu.p_id]; - tr.clear(); - - tr.p_skipped.value = true; - - if( tu.p_type == TUT_SUITE ) { - test_case_counter tcc(true); - traverse_test_tree( tu, tcc, true ); // true because need to count the disabled tests/units - - tr.p_test_cases_skipped.value = tcc.p_count; - } -} - -//____________________________________________________________________________// - -void -results_collector_t::test_unit_timed_out(test_unit const& tu) -{ - test_results& tr = s_rc_impl().m_results_store[tu.p_id]; - tr.p_timed_out.value = true; -} - -//____________________________________________________________________________// - -void -results_collector_t::assertion_result( unit_test::assertion_result ar ) -{ - test_results& tr = s_rc_impl().m_results_store[framework::current_test_case_id()]; - - switch( ar ) { - case AR_PASSED: tr.p_assertions_passed.value++; break; - case AR_FAILED: tr.p_assertions_failed.value++; break; - case AR_TRIGGERED: tr.p_warnings_failed.value++; break; - } - - if( tr.p_assertions_failed == 1 ) - first_failed_assertion(); -} - -//____________________________________________________________________________// - -void -results_collector_t::exception_caught( execution_exception const& ex) -{ - test_results& tr = s_rc_impl().m_results_store[framework::current_test_case_id()]; - - tr.p_assertions_failed.value++; - if( ex.code() == execution_exception::timeout_error ) { - tr.p_timed_out.value = true; - } -} - -//____________________________________________________________________________// - -void -results_collector_t::test_unit_aborted( test_unit const& tu ) -{ - s_rc_impl().m_results_store[tu.p_id].p_aborted.value = true; -} - -//____________________________________________________________________________// - -test_results const& -results_collector_t::results( test_unit_id id ) const -{ - return s_rc_impl().m_results_store[id]; -} - -//____________________________________________________________________________// - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_RESULTS_COLLECTOR_IPP_021105GER diff --git a/ThirdParty/boost/test/impl/test_framework_init_observer.ipp b/ThirdParty/boost/test/impl/test_framework_init_observer.ipp deleted file mode 100644 index 4e9f49f70009ed4a669970cb4fa5a1effab959dc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/test_framework_init_observer.ipp +++ /dev/null @@ -1,88 +0,0 @@ -// (c) Copyright Raffi Enficiaud 2017. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! An observer for monitoring the success/failure of the other observers -// *************************************************************************** - -#ifndef BOOST_TEST_FRAMEWORK_INIT_OBSERVER_IPP_021105GER -#define BOOST_TEST_FRAMEWORK_INIT_OBSERVER_IPP_021105GER - -// Boost.Test -#include <boost/test/test_framework_init_observer.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** framework_init_observer_t ************** // -// ************************************************************************** // - -void -framework_init_observer_t::clear() -{ - m_has_failure = false; -} - -//____________________________________________________________________________// - -void -framework_init_observer_t::test_start( counter_t, test_unit_id ) -{ - clear(); -} - -//____________________________________________________________________________// - -void -framework_init_observer_t::assertion_result( unit_test::assertion_result ar ) -{ - switch( ar ) { - case AR_FAILED: m_has_failure = true; break; - default: - break; - } -} - -//____________________________________________________________________________// - -void -framework_init_observer_t::exception_caught( execution_exception const& ) -{ - m_has_failure = true; -} - -void -framework_init_observer_t::test_aborted() -{ - m_has_failure = true; -} - - -//____________________________________________________________________________// - -bool -framework_init_observer_t::has_failed() const -{ - return m_has_failure; -} - -//____________________________________________________________________________// - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_FRAMEWORK_INIT_OBSERVER_IPP_021105GER diff --git a/ThirdParty/boost/test/impl/test_tools.ipp b/ThirdParty/boost/test/impl/test_tools.ipp deleted file mode 100644 index 025cd1a92af36a6fe1f643b1a3fccd896348596c..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/test_tools.ipp +++ /dev/null @@ -1,833 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : supplies offline implementation for the Test Tools -// *************************************************************************** - -#ifndef BOOST_TEST_TEST_TOOLS_IPP_012205GER -#define BOOST_TEST_TEST_TOOLS_IPP_012205GER - -// Boost.Test -#include <boost/test/test_tools.hpp> -#include <boost/test/unit_test_log.hpp> -#include <boost/test/tools/context.hpp> -#include <boost/test/tools/output_test_stream.hpp> - -#include <boost/test/tools/detail/fwd.hpp> -#include <boost/test/tools/detail/print_helper.hpp> - -#include <boost/test/framework.hpp> -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/execution_monitor.hpp> // execution_aborted - -#include <boost/test/detail/throw_exception.hpp> - -#include <boost/test/utils/algorithm.hpp> - -// Boost -#include <boost/config.hpp> - -// STL -#include <fstream> -#include <string> -#include <cstring> -#include <cctype> -#include <cwchar> -#include <stdexcept> -#include <vector> -#include <utility> -#include <ios> - -// !! should we use #include <cstdarg> -#include <stdarg.h> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -# ifdef BOOST_NO_STDC_NAMESPACE -namespace std { using ::strcmp; using ::strlen; using ::isprint; } -#if !defined( BOOST_NO_CWCHAR ) -namespace std { using ::wcscmp; } -#endif -# endif - - -namespace boost { -namespace unit_test { - // local static variable, needed here for visibility reasons - lazy_ostream lazy_ostream::inst = lazy_ostream(); -}} - -namespace boost { -namespace test_tools { -namespace tt_detail { - -// ************************************************************************** // -// ************** print_log_value ************** // -// ************************************************************************** // - -void -print_log_value<bool>::operator()( std::ostream& ostr, bool t ) -{ - ostr << std::boolalpha << t; -} - -void -print_log_value<char>::operator()( std::ostream& ostr, char t ) -{ - if( (std::isprint)( static_cast<unsigned char>(t) ) ) - ostr << '\'' << t << '\''; - else - ostr << std::hex -#if BOOST_TEST_USE_STD_LOCALE - << std::showbase -#else - << "0x" -#endif - << static_cast<int>(t); -} - -//____________________________________________________________________________// - -void -print_log_value<unsigned char>::operator()( std::ostream& ostr, unsigned char t ) -{ - ostr << std::hex - // showbase is only available for new style streams: -#if BOOST_TEST_USE_STD_LOCALE - << std::showbase -#else - << "0x" -#endif - << static_cast<int>(t); -} - -//____________________________________________________________________________// - -void -print_log_value<char const*>::operator()( std::ostream& ostr, char const* t ) -{ - ostr << ( t ? t : "null string" ); -} - -//____________________________________________________________________________// - -void -print_log_value<wchar_t const*>::operator()( std::ostream& ostr, wchar_t const* t ) -{ - ostr << ( t ? reinterpret_cast<const void*>(t) : "null string" ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** TOOL BOX Implementation ************** // -// ************************************************************************** // - -using ::boost::unit_test::lazy_ostream; - -static char const* check_str [] = { " == ", " != ", " < " , " <= ", " > " , " >= " }; -static char const* rever_str [] = { " != ", " == ", " >= ", " > " , " <= ", " < " }; - -template<typename OutStream> -void -format_report( OutStream& os, assertion_result const& pr, unit_test::lazy_ostream const& assertion_descr, - tool_level tl, check_type ct, - std::size_t num_args, va_list args, - char const* prefix, char const* suffix ) -{ - using namespace unit_test; - - switch( ct ) { - case CHECK_PRED: - os << prefix << assertion_descr << suffix; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - - case CHECK_BUILT_ASSERTION: { - os << prefix << assertion_descr << suffix; - - if( tl != PASS ) { - const_string details_message = pr.message(); - - if( !details_message.is_empty() ) { - os << details_message; - } - } - break; - } - - case CHECK_MSG: - if( tl == PASS ) - os << prefix << "'" << assertion_descr << "'" << suffix; - else - os << assertion_descr; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - - case CHECK_EQUAL: - case CHECK_NE: - case CHECK_LT: - case CHECK_LE: - case CHECK_GT: - case CHECK_GE: { - char const* arg1_descr = va_arg( args, char const* ); - lazy_ostream const* arg1_val = va_arg( args, lazy_ostream const* ); - char const* arg2_descr = va_arg( args, char const* ); - lazy_ostream const* arg2_val = va_arg( args, lazy_ostream const* ); - - os << prefix << arg1_descr << check_str[ct-CHECK_EQUAL] << arg2_descr << suffix; - - if( tl != PASS ) - os << " [" << *arg1_val << rever_str[ct-CHECK_EQUAL] << *arg2_val << "]" ; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - } - - case CHECK_CLOSE: - case CHECK_CLOSE_FRACTION: { - char const* arg1_descr = va_arg( args, char const* ); - lazy_ostream const* arg1_val = va_arg( args, lazy_ostream const* ); - char const* arg2_descr = va_arg( args, char const* ); - lazy_ostream const* arg2_val = va_arg( args, lazy_ostream const* ); - /* toler_descr = */ va_arg( args, char const* ); - lazy_ostream const* toler_val = va_arg( args, lazy_ostream const* ); - - os << "difference{" << pr.message() - << "} between " << arg1_descr << "{" << *arg1_val - << "} and " << arg2_descr << "{" << *arg2_val - << ( tl == PASS ? "} doesn't exceed " : "} exceeds " ) - << *toler_val; - if( ct == CHECK_CLOSE ) - os << "%"; - break; - } - case CHECK_SMALL: { - char const* arg1_descr = va_arg( args, char const* ); - lazy_ostream const* arg1_val = va_arg( args, lazy_ostream const* ); - /* toler_descr = */ va_arg( args, char const* ); - lazy_ostream const* toler_val = va_arg( args, lazy_ostream const* ); - - os << "absolute value of " << arg1_descr << "{" << *arg1_val << "}" - << ( tl == PASS ? " doesn't exceed " : " exceeds " ) - << *toler_val; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - } - - case CHECK_PRED_WITH_ARGS: { - std::vector< std::pair<char const*, lazy_ostream const*> > args_copy; - args_copy.reserve( num_args ); - for( std::size_t i = 0; i < num_args; ++i ) { - char const* desc = va_arg( args, char const* ); - lazy_ostream const* value = va_arg( args, lazy_ostream const* ); - args_copy.push_back( std::make_pair( desc, value ) ); - } - - os << prefix << assertion_descr; - - // print predicate call description - os << "( "; - for( std::size_t i = 0; i < num_args; ++i ) { - os << args_copy[i].first; - - if( i != num_args-1 ) - os << ", "; - } - os << " )" << suffix; - - if( tl != PASS ) { - os << " for ( "; - for( std::size_t i = 0; i < num_args; ++i ) { - os << *args_copy[i].second; - - if( i != num_args-1 ) - os << ", "; - } - os << " )"; - } - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - } - - case CHECK_EQUAL_COLL: { - char const* left_begin_descr = va_arg( args, char const* ); - char const* left_end_descr = va_arg( args, char const* ); - char const* right_begin_descr = va_arg( args, char const* ); - char const* right_end_descr = va_arg( args, char const* ); - - os << prefix << "{ " << left_begin_descr << ", " << left_end_descr << " } == { " - << right_begin_descr << ", " << right_end_descr << " }" - << suffix; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - } - - case CHECK_BITWISE_EQUAL: { - char const* left_descr = va_arg( args, char const* ); - char const* right_descr = va_arg( args, char const* ); - - os << prefix << left_descr << " =.= " << right_descr << suffix; - - if( !pr.has_empty_message() ) - os << ". " << pr.message(); - break; - } - } -} - -//____________________________________________________________________________// - -bool -report_assertion( assertion_result const& ar, - lazy_ostream const& assertion_descr, - const_string file_name, - std::size_t line_num, - tool_level tl, - check_type ct, - std::size_t num_args, ... ) -{ - using namespace unit_test; - - if( !framework::test_in_progress() ) { - // in case no test is in progress, we do not throw anything: - // raising an exception here may result in raising an exception in a destructor of a global fixture - // which will abort the process - // We flag this as aborted instead - - //BOOST_TEST_I_ASSRT( framework::current_test_case_id() != INV_TEST_UNIT_ID, - // std::runtime_error( "Can't use testing tools outside of test case implementation." ) ); - - framework::test_aborted(); - return false; - } - - - if( !!ar ) - tl = PASS; - - log_level ll; - char const* prefix; - char const* suffix; - - switch( tl ) { - case PASS: - ll = log_successful_tests; - prefix = "check "; - suffix = " has passed"; - break; - case WARN: - ll = log_warnings; - prefix = "condition "; - suffix = " is not satisfied"; - break; - case CHECK: - ll = log_all_errors; - prefix = "check "; - suffix = " has failed"; - break; - case REQUIRE: - ll = log_fatal_errors; - prefix = "critical check "; - suffix = " has failed"; - break; - default: - return true; - } - - unit_test_log << unit_test::log::begin( file_name, line_num ) << ll; - va_list args; - va_start( args, num_args ); - - format_report( unit_test_log, ar, assertion_descr, tl, ct, num_args, args, prefix, suffix ); - - va_end( args ); - unit_test_log << unit_test::log::end(); - - switch( tl ) { - case PASS: - framework::assertion_result( AR_PASSED ); - return true; - - case WARN: - framework::assertion_result( AR_TRIGGERED ); - return false; - - case CHECK: - framework::assertion_result( AR_FAILED ); - return false; - - case REQUIRE: - framework::assertion_result( AR_FAILED ); - framework::test_unit_aborted( framework::current_test_unit() ); - BOOST_TEST_I_THROW( execution_aborted() ); - // the previous line either throws or aborts and the return below is not reached - // return false; - BOOST_TEST_UNREACHABLE_RETURN(false); - } - - return true; -} - -//____________________________________________________________________________// - -assertion_result -format_assertion_result( const_string expr_val, const_string details ) -{ - assertion_result res(false); - - bool starts_new_line = first_char( expr_val ) == '\n'; - - if( !starts_new_line && !expr_val.is_empty() ) - res.message().stream() << " [" << expr_val << "]"; - - if( !details.is_empty() ) { - if( first_char(details) != '[' ) - res.message().stream() << ": "; - else - res.message().stream() << " "; - - res.message().stream() << details; - } - - if( starts_new_line ) - res.message().stream() << "." << expr_val; - - return res; -} - -//____________________________________________________________________________// - -BOOST_TEST_DECL std::string -prod_report_format( assertion_result const& ar, unit_test::lazy_ostream const& assertion_descr, check_type ct, std::size_t num_args, ... ) -{ - std::ostringstream msg_buff; - - va_list args; - va_start( args, num_args ); - - format_report( msg_buff, ar, assertion_descr, CHECK, ct, num_args, args, "assertion ", " failed" ); - - va_end( args ); - - return msg_buff.str(); -} - -//____________________________________________________________________________// - -assertion_result -equal_impl( char const* left, char const* right ) -{ - return (left && right) ? std::strcmp( left, right ) == 0 : (left == right); -} - -//____________________________________________________________________________// - -#if !defined( BOOST_NO_CWCHAR ) - -assertion_result -equal_impl( wchar_t const* left, wchar_t const* right ) -{ - return (left && right) ? std::wcscmp( left, right ) == 0 : (left == right); -} - -#endif // !defined( BOOST_NO_CWCHAR ) - -//____________________________________________________________________________// - -bool -is_defined_impl( const_string symbol_name, const_string symbol_value ) -{ - symbol_value.trim_left( 2 ); - return symbol_name != symbol_value; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** context_frame ************** // -// ************************************************************************** // - -context_frame::context_frame( ::boost::unit_test::lazy_ostream const& context_descr ) -: m_frame_id( unit_test::framework::add_context( context_descr, true ) ) -{ -} - -//____________________________________________________________________________// - -context_frame::~context_frame() -{ - unit_test::framework::clear_context( m_frame_id ); -} - -//____________________________________________________________________________// - -context_frame::operator bool() -{ - return true; -} - -//____________________________________________________________________________// - -} // namespace tt_detail - -// ************************************************************************** // -// ************** output_test_stream ************** // -// ************************************************************************** // - -struct output_test_stream::Impl -{ - std::fstream m_pattern; - bool m_match_or_save; - bool m_text_or_binary; - std::string m_synced_string; - - char get_char() - { - char res = 0; - do { - m_pattern.get( res ); - } while( m_text_or_binary && res == '\r' && !m_pattern.fail() && !m_pattern.eof() ); - - return res; - } - - void check_and_fill( assertion_result& res ) - { - if( !res.p_predicate_value ) - res.message() << "Output content: \"" << m_synced_string << '\"'; - } -}; - -//____________________________________________________________________________// - -output_test_stream::output_test_stream( const_string pattern_file_name, bool match_or_save, bool text_or_binary ) -: m_pimpl( new Impl ) -{ - if( !pattern_file_name.is_empty() ) { - std::ios::openmode m = match_or_save ? std::ios::in : std::ios::out; - if( !text_or_binary ) - m |= std::ios::binary; - - m_pimpl->m_pattern.open( pattern_file_name.begin(), m ); - - if( !m_pimpl->m_pattern.is_open() ) - BOOST_TEST_FRAMEWORK_MESSAGE( "Can't open pattern file " << pattern_file_name << " for " << (match_or_save ? "reading" : "writing") ); - } - - m_pimpl->m_match_or_save = match_or_save; - m_pimpl->m_text_or_binary = text_or_binary; -} - -//____________________________________________________________________________// - -output_test_stream::~output_test_stream() -{ - delete m_pimpl; -} - -//____________________________________________________________________________// - -assertion_result -output_test_stream::is_empty( bool flush_stream ) -{ - sync(); - - assertion_result res( m_pimpl->m_synced_string.empty() ); - - m_pimpl->check_and_fill( res ); - - if( flush_stream ) - flush(); - - return res; -} - -//____________________________________________________________________________// - -assertion_result -output_test_stream::check_length( std::size_t length_, bool flush_stream ) -{ - sync(); - - assertion_result res( m_pimpl->m_synced_string.length() == length_ ); - - m_pimpl->check_and_fill( res ); - - if( flush_stream ) - flush(); - - return res; -} - -//____________________________________________________________________________// - -assertion_result -output_test_stream::is_equal( const_string arg, bool flush_stream ) -{ - sync(); - - assertion_result res( const_string( m_pimpl->m_synced_string ) == arg ); - - m_pimpl->check_and_fill( res ); - - if( flush_stream ) - flush(); - - return res; -} - -//____________________________________________________________________________// - -std::string pretty_print_log(std::string str) { - - static const std::string to_replace[] = { "\r", "\n" }; - static const std::string replacement[] = { "\\r", "\\n" }; - - return unit_test::utils::replace_all_occurrences_of( - str, - to_replace, to_replace + sizeof(to_replace)/sizeof(to_replace[0]), - replacement, replacement + sizeof(replacement)/sizeof(replacement[0])); -} - -assertion_result -output_test_stream::match_pattern( bool flush_stream ) -{ - const std::string::size_type n_chars_presuffix = 10; - sync(); - - assertion_result result( true ); - - const std::string stream_string_repr = get_stream_string_representation(); - - if( !m_pimpl->m_pattern.is_open() ) { - result = false; - result.message() << "Pattern file can't be opened!"; - } - else { - if( m_pimpl->m_match_or_save ) { - - int offset = 0; - std::vector<char> last_elements; - for ( std::string::size_type i = 0; static_cast<int>(i + offset) < static_cast<int>(stream_string_repr.length()); ++i ) { - - char c = m_pimpl->get_char(); - - if( last_elements.size() <= n_chars_presuffix ) { - last_elements.push_back( c ); - } - else { - last_elements[ i % last_elements.size() ] = c; - } - - bool is_same = !m_pimpl->m_pattern.fail() && - !m_pimpl->m_pattern.eof() && - (stream_string_repr[i+offset] == c); - - if( !is_same ) { - - result = false; - - std::string::size_type prefix_size = (std::min)( i + offset, n_chars_presuffix ); - - std::string::size_type suffix_size = (std::min)( stream_string_repr.length() - i - offset, - n_chars_presuffix ); - - // try to log area around the mismatch - std::string substr = stream_string_repr.substr(0, i+offset); - std::size_t line = std::count(substr.begin(), substr.end(), '\n'); - std::size_t column = i + offset - substr.rfind('\n'); - - result.message() - << "Mismatch at position " << i - << " (line " << line - << ", column " << column - << "): '" << pretty_print_log(std::string(1, stream_string_repr[i+offset])) << "' != '" << pretty_print_log(std::string(1, c)) << "' :\n"; - - // we already escape this substring because we need its actual size for the pretty print - // of the difference location. - std::string sub_str_prefix(pretty_print_log(stream_string_repr.substr( i + offset - prefix_size, prefix_size ))); - - // we need this substring as is because we compute the best matching substrings on it. - std::string sub_str_suffix(stream_string_repr.substr( i + offset, suffix_size)); - result.message() << "... " << sub_str_prefix + pretty_print_log(sub_str_suffix) << " ..." << '\n'; - - result.message() << "... "; - for( std::size_t j = 0; j < last_elements.size() ; j++ ) - result.message() << pretty_print_log(std::string(1, last_elements[(i + j + 1) % last_elements.size()])); - - std::vector<char> last_elements_ordered; - last_elements_ordered.push_back(c); - for( std::string::size_type counter = 0; counter < suffix_size - 1 ; counter++ ) { - char c2 = m_pimpl->get_char(); - - if( m_pimpl->m_pattern.fail() || m_pimpl->m_pattern.eof() ) - break; - - result.message() << pretty_print_log(std::string(1, c2)); - - last_elements_ordered.push_back(c2); - } - - // tries to find the best substring matching in the remainder of the - // two strings - std::size_t max_nb_char_in_common = 0; - std::size_t best_pattern_start_index = 0; - std::size_t best_stream_start_index = 0; - for( std::size_t pattern_start_index = best_pattern_start_index; - pattern_start_index < last_elements_ordered.size(); - pattern_start_index++ ) { - for( std::size_t stream_start_index = best_stream_start_index; - stream_start_index < sub_str_suffix.size(); - stream_start_index++ ) { - - std::size_t max_size = (std::min)( last_elements_ordered.size() - pattern_start_index, sub_str_suffix.size() - stream_start_index ); - if( max_nb_char_in_common > max_size ) - break; // safely break to go to the outer loop - - std::size_t nb_char_in_common = 0; - for( std::size_t k = 0; k < max_size; k++) { - if( last_elements_ordered[pattern_start_index + k] == sub_str_suffix[stream_start_index + k] ) - nb_char_in_common ++; - else - break; // we take fully matching substring only - } - - if( nb_char_in_common > max_nb_char_in_common ) { - max_nb_char_in_common = nb_char_in_common; - best_pattern_start_index = pattern_start_index; - best_stream_start_index = stream_start_index; - } - } - } - - // indicates with more precision the location of the mismatchs in "ascii arts" ... - result.message() << " ...\n... "; - for( std::string::size_type j = 0; j < sub_str_prefix.size(); j++) { - result.message() << ' '; - } - - result.message() << '~'; // places the first tilde at the current char that mismatches - - for( std::size_t k = 1; k < (std::max)(best_pattern_start_index, best_stream_start_index); k++ ) { // 1 is for the current char c - std::string s1(pretty_print_log(std::string(1, last_elements_ordered[(std::min)(k, best_pattern_start_index)]))); - std::string s2(pretty_print_log(std::string(1, sub_str_suffix[(std::min)(k, best_stream_start_index)]))); - for( int h = static_cast<int>((std::max)(s1.size(), s2.size())); h > 0; h--) - result.message() << "~"; - } - - if( m_pimpl->m_pattern.eof() ) { - result.message() << " (reference string shorter than current stream)"; - } - - result.message() << "\n"; - - // no need to continue if the EOF is reached - if( m_pimpl->m_pattern.eof() ) { - break; - } - - // first char is a replicat of c, so we do not copy it. - for(std::string::size_type counter = 0; counter < last_elements_ordered.size() - 1 ; counter++) - last_elements[ (i + 1 + counter) % last_elements.size() ] = last_elements_ordered[counter + 1]; - - i += last_elements_ordered.size()-1; - offset += best_stream_start_index - best_pattern_start_index; - - } - - } - - // not needed anymore - /* - if(offset > 0 && false) { - m_pimpl->m_pattern.ignore( - static_cast<std::streamsize>( offset )); - } - */ - } - else { - m_pimpl->m_pattern.write( stream_string_repr.c_str(), - static_cast<std::streamsize>( stream_string_repr.length() ) ); - m_pimpl->m_pattern.flush(); - } - } - - if( flush_stream ) - flush(); - - return result; -} - -//____________________________________________________________________________// - -void -output_test_stream::flush() -{ - m_pimpl->m_synced_string.erase(); - -#ifndef BOOST_NO_STRINGSTREAM - str( std::string() ); -#else - seekp( 0, std::ios::beg ); -#endif -} - - -std::string -output_test_stream::get_stream_string_representation() const { - return m_pimpl->m_synced_string; -} - -//____________________________________________________________________________// - -std::size_t -output_test_stream::length() -{ - sync(); - - return m_pimpl->m_synced_string.length(); -} - -//____________________________________________________________________________// - -void -output_test_stream::sync() -{ -#ifdef BOOST_NO_STRINGSTREAM - m_pimpl->m_synced_string.assign( str(), pcount() ); - freeze( false ); -#else - m_pimpl->m_synced_string = str(); -#endif -} - -//____________________________________________________________________________// - -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TEST_TOOLS_IPP_012205GER diff --git a/ThirdParty/boost/test/impl/test_tree.ipp b/ThirdParty/boost/test/impl/test_tree.ipp deleted file mode 100644 index 0872682ea67acd0e887e6f0712acc188b866e4f6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/test_tree.ipp +++ /dev/null @@ -1,584 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Provides core implementation for Unit Test Framework. -/// Extensions can be provided in separate files -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER -#define BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER - -// Boost.Test -#include <boost/detail/workaround.hpp> - -#include <boost/test/framework.hpp> -#include <boost/test/results_collector.hpp> - -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/visitor.hpp> -#include <boost/test/tree/traverse.hpp> -#include <boost/test/tree/auto_registration.hpp> -#include <boost/test/tree/global_fixture.hpp> - -#include <boost/test/utils/foreach.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> - -#include <boost/test/unit_test_parameters.hpp> - -// STL -#include <algorithm> -#include <vector> -#include <set> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** test_unit ************** // -// ************************************************************************** // - -test_unit::test_unit( const_string name, const_string file_name, std::size_t line_num, test_unit_type t ) -: p_type( t ) -, p_type_name( t == TUT_CASE ? "case" : "suite" ) -, p_file_name( file_name ) -, p_line_num( line_num ) -, p_id( INV_TEST_UNIT_ID ) -, p_parent_id( INV_TEST_UNIT_ID ) -, p_name( std::string( name.begin(), name.size() ) ) -, p_timeout( 0 ) -, p_expected_failures( 0 ) -, p_default_status( RS_INHERIT ) -, p_run_status( RS_INVALID ) -, p_sibling_rank(0) -{ -} - -//____________________________________________________________________________// - -test_unit::test_unit( const_string module_name ) -: p_type( TUT_SUITE ) -, p_type_name( "module" ) -, p_line_num( 0 ) -, p_id( INV_TEST_UNIT_ID ) -, p_parent_id( INV_TEST_UNIT_ID ) -, p_name( std::string( module_name.begin(), module_name.size() ) ) -, p_timeout( 0 ) -, p_expected_failures( 0 ) -, p_default_status( RS_INHERIT ) -, p_run_status( RS_INVALID ) -, p_sibling_rank(0) -{ -} - -//____________________________________________________________________________// - -test_unit::~test_unit() -{ - framework::deregister_test_unit( this ); -} - -//____________________________________________________________________________// - -void -test_unit::depends_on( test_unit* tu ) -{ - BOOST_TEST_SETUP_ASSERT( p_id != framework::master_test_suite().p_id, - "Can't add dependency to the master test suite" ); - - p_dependencies.value.push_back( tu->p_id ); -} - -//____________________________________________________________________________// - -void -test_unit::add_precondition( precondition_t const& pc ) -{ - p_preconditions.value.push_back( pc ); -} - -//____________________________________________________________________________// - -test_tools::assertion_result -test_unit::check_preconditions() const -{ - BOOST_TEST_FOREACH( test_unit_id, dep_id, p_dependencies.get() ) { - test_unit const& dep = framework::get( dep_id, TUT_ANY ); - - if( !dep.is_enabled() ) { - test_tools::assertion_result res(false); - res.message() << "dependency test " << dep.p_type_name << " \"" << dep.full_name() << "\" is disabled"; - return res; - } - - test_results const& test_rslt = unit_test::results_collector.results( dep_id ); - if( !test_rslt.passed() ) { - test_tools::assertion_result res(false); - res.message() << "dependency test " << dep.p_type_name << " \"" << dep.full_name() << (test_rslt.skipped() ? "\" was skipped":"\" has failed"); - return res; - } - - if( test_rslt.p_test_cases_skipped > 0 ) { - test_tools::assertion_result res(false); - res.message() << "dependency test " << dep.p_type_name << " \"" << dep.full_name() << "\" has skipped test cases"; - return res; - } - } - - BOOST_TEST_FOREACH( precondition_t, precondition, p_preconditions.get() ) { - test_tools::assertion_result res = precondition( p_id ); - if( !res ) { - test_tools::assertion_result res_out(false); - res_out.message() << "precondition failed"; - if( !res.has_empty_message() ) - res_out.message() << ": " << res.message(); - return res_out; - } - } - - return true; -} - -//____________________________________________________________________________// - -void -test_unit::increase_exp_fail( counter_t num ) -{ - p_expected_failures.value += num; - - if( p_parent_id != INV_TEST_UNIT_ID ) - framework::get<test_suite>( p_parent_id ).increase_exp_fail( num ); -} - -//____________________________________________________________________________// - -std::string -test_unit::full_name() const -{ - if( p_parent_id == INV_TEST_UNIT_ID || p_parent_id == framework::master_test_suite().p_id ) - return p_name; - - std::string res = framework::get<test_suite>( p_parent_id ).full_name(); - res.append("/"); - - res.append( p_name ); - - return res; -} - -//____________________________________________________________________________// - -void -test_unit::add_label( const_string l ) -{ - p_labels.value.push_back( std::string() + l ); -} - -//____________________________________________________________________________// - -bool -test_unit::has_label( const_string l ) const -{ - return std::find( p_labels->begin(), p_labels->end(), l ) != p_labels->end(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** test_case ************** // -// ************************************************************************** // - -test_case::test_case( const_string name, boost::function<void ()> const& test_func ) -: test_unit( name, "", 0, static_cast<test_unit_type>(type) ) -, p_test_func( test_func ) -{ - framework::register_test_unit( this ); -} - -//____________________________________________________________________________// - -test_case::test_case( const_string name, const_string file_name, std::size_t line_num, boost::function<void ()> const& test_func ) -: test_unit( name, file_name, line_num, static_cast<test_unit_type>(type) ) -, p_test_func( test_func ) -{ - framework::register_test_unit( this ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** test_suite ************** // -// ************************************************************************** // - -//____________________________________________________________________________// - -test_suite::test_suite( const_string name, const_string file_name, std::size_t line_num ) -: test_unit( ut_detail::normalize_test_case_name( name ), file_name, line_num, static_cast<test_unit_type>(type) ) -{ - framework::register_test_unit( this ); -} - -//____________________________________________________________________________// - -test_suite::test_suite( const_string module_name ) -: test_unit( module_name ) -{ - framework::register_test_unit( this ); -} - -//____________________________________________________________________________// - -void -test_suite::add( test_unit* tu, counter_t expected_failures, unsigned timeout ) -{ - tu->p_timeout.value = timeout; - - m_children.push_back( tu->p_id ); - tu->p_parent_id.value = p_id; - - if( tu->p_expected_failures != 0 ) - increase_exp_fail( tu->p_expected_failures ); - - if( expected_failures ) - tu->increase_exp_fail( expected_failures ); -} - -//____________________________________________________________________________// - -void -test_suite::add( test_unit_generator const& gen, unsigned timeout ) -{ - test_unit* tu; - while((tu = gen.next()) != 0) - add( tu, 0, timeout ); -} - -//____________________________________________________________________________// - -void -test_suite::add( test_unit_generator const& gen, decorator::collector_t& decorators ) -{ - test_unit* tu; - while((tu = gen.next()) != 0) { - decorators.store_in( *tu ); - add( tu, 0 ); - } - decorators.reset(); -} - -//____________________________________________________________________________// - -void -test_suite::add( boost::shared_ptr<test_unit_generator> gen_ptr, decorator::collector_t& decorators ) -{ - std::pair<boost::shared_ptr<test_unit_generator>, std::vector<decorator::base_ptr> > tmp_p(gen_ptr, decorators.get_lazy_decorators() ); - m_generators.push_back(tmp_p); - decorators.reset(); -} - -//____________________________________________________________________________// - -void -test_suite::generate( ) -{ - typedef std::pair<boost::shared_ptr<test_unit_generator>, std::vector<decorator::base_ptr> > element_t; - - for(std::vector<element_t>::iterator it(m_generators.begin()), ite(m_generators.end()); - it < ite; - ++it) - { - test_unit* tu; - while((tu = it->first->next()) != 0) { - tu->p_decorators.value.insert( tu->p_decorators.value.end(), it->second.begin(), it->second.end() ); - //it->second.store_in( *tu ); - add( tu, 0 ); - } - - } - m_generators.clear(); - - #if 0 - test_unit* tu; - while((tu = gen.next()) != 0) { - decorators.store_in( *tu ); - add( tu, 0 ); - } - #endif -} - -//____________________________________________________________________________// - -void -test_suite::check_for_duplicate_test_cases() { - // check for clashing names #12597 - std::set<std::string> names; - for( test_unit_id_list::const_iterator it(m_children.begin()), ite(m_children.end()); - it < ite; - ++it) { - std::string name = framework::get(*it, TUT_ANY).p_name; - std::pair<std::set<std::string>::iterator, bool> ret = names.insert(name); - BOOST_TEST_SETUP_ASSERT(ret.second, - "test unit with name '" - + name - + std::string("' registered multiple times in the test suite '") - + this->p_name.value - + "'"); - } - - return; -} - -//____________________________________________________________________________// - -void -test_suite::remove( test_unit_id id ) -{ - test_unit_id_list::iterator it = std::find( m_children.begin(), m_children.end(), id ); - - if( it != m_children.end() ) - m_children.erase( it ); -} - -//____________________________________________________________________________// - -test_unit_id -test_suite::get( const_string tu_name ) const -{ - BOOST_TEST_FOREACH( test_unit_id, id, m_children ) { - if( tu_name == framework::get( id, ut_detail::test_id_2_unit_type( id ) ).p_name.get() ) - return id; - } - - return INV_TEST_UNIT_ID; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** master_test_suite ************** // -// ************************************************************************** // - -master_test_suite_t::master_test_suite_t() -: test_suite( "Master Test Suite" ) -, argc( 0 ) -, argv( 0 ) -{ - p_default_status.value = RS_ENABLED; -} - -// ************************************************************************** // -// ************** traverse_test_tree ************** // -// ************************************************************************** // - -void -traverse_test_tree( test_case const& tc, test_tree_visitor& V, bool ignore_status ) -{ - if( tc.is_enabled() || ignore_status ) - V.visit( tc ); -} - -//____________________________________________________________________________// - -void -traverse_test_tree( test_suite const& suite, test_tree_visitor& V, bool ignore_status ) -{ - // skip disabled test suite unless we asked to ignore this condition - if( !ignore_status && !suite.is_enabled() ) - return; - - // Invoke test_suite_start callback - if( !V.test_suite_start( suite ) ) - return; - - // Recurse into children - std::size_t total_children = suite.m_children.size(); - for( std::size_t i=0; i < total_children; ) { - // this statement can remove the test unit from this list - traverse_test_tree( suite.m_children[i], V, ignore_status ); - if( total_children > suite.m_children.size() ) - total_children = suite.m_children.size(); - else - ++i; - } - - // Invoke test_suite_finish callback - V.test_suite_finish( suite ); -} - -//____________________________________________________________________________// - -void -traverse_test_tree( test_unit_id id, test_tree_visitor& V, bool ignore_status ) -{ - if( ut_detail::test_id_2_unit_type( id ) == TUT_CASE ) - traverse_test_tree( framework::get<test_case>( id ), V, ignore_status ); - else - traverse_test_tree( framework::get<test_suite>( id ), V, ignore_status ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** object generators ************** // -// ************************************************************************** // - -namespace ut_detail { - -std::string -normalize_test_case_name( const_string name ) -{ - std::string norm_name( name.begin(), name.size() ); - - if( name[0] == '&' ) - norm_name = norm_name.substr( 1 ); - - // trim spaces - std::size_t first_not_space = norm_name.find_first_not_of(' '); - if( first_not_space ) { - norm_name.erase(0, first_not_space); - } - - std::size_t last_not_space = norm_name.find_last_not_of(' '); - if( last_not_space !=std::string::npos ) { - norm_name.erase(last_not_space + 1); - } - - // sanitize all chars that might be used in runtime filters - static const char to_replace[] = { ':', '*', '@', '+', '!', '/', ',' }; - for(std::size_t index = 0; - index < sizeof(to_replace)/sizeof(to_replace[0]); - index++) { - std::replace(norm_name.begin(), norm_name.end(), to_replace[index], '_'); - } - - return norm_name; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** auto_test_unit_registrar ************** // -// ************************************************************************** // - -auto_test_unit_registrar::auto_test_unit_registrar( test_case* tc, decorator::collector_t& decorators, counter_t exp_fail ) -{ - framework::current_auto_test_suite().add( tc, exp_fail ); - - decorators.store_in( *tc ); - decorators.reset(); -} - -//____________________________________________________________________________// - -auto_test_unit_registrar::auto_test_unit_registrar( const_string ts_name, const_string ts_file, std::size_t ts_line, decorator::collector_t& decorators ) -{ - test_unit_id id = framework::current_auto_test_suite().get( ts_name ); - - test_suite* ts; - - if( id != INV_TEST_UNIT_ID ) { - ts = &framework::get<test_suite>( id ); - BOOST_ASSERT( ts->p_parent_id == framework::current_auto_test_suite().p_id ); - } - else { - ts = new test_suite( ts_name, ts_file, ts_line ); - framework::current_auto_test_suite().add( ts ); - } - - decorators.store_in( *ts ); - decorators.reset(); - - framework::current_auto_test_suite( ts ); -} - -//____________________________________________________________________________// - -auto_test_unit_registrar::auto_test_unit_registrar( test_unit_generator const& tc_gen, decorator::collector_t& decorators ) -{ - framework::current_auto_test_suite().add( tc_gen, decorators ); -} - -//____________________________________________________________________________// - -auto_test_unit_registrar::auto_test_unit_registrar( boost::shared_ptr<test_unit_generator> tc_gen, decorator::collector_t& decorators ) -{ - framework::current_auto_test_suite().add( tc_gen, decorators ); -} - - -//____________________________________________________________________________// - -auto_test_unit_registrar::auto_test_unit_registrar( int ) -{ - framework::current_auto_test_suite( 0, false ); -} - -//____________________________________________________________________________// - -} // namespace ut_detail - -// ************************************************************************** // -// ************** global_fixture ************** // -// ************************************************************************** // - -global_fixture::global_fixture(): registered(false) -{ - framework::register_global_fixture( *this ); - registered = true; -} - -void global_fixture::unregister_from_framework() { - // not accessing the framework singleton after deregistering -> release - // of the observer from the framework - if(registered) { - framework::deregister_global_fixture( *this ); - } - registered = false; -} - -global_fixture::~global_fixture() -{ - this->unregister_from_framework(); -} - -// ************************************************************************** // -// ************** global_configuration ************** // -// ************************************************************************** // - -global_configuration::global_configuration(): registered(false) -{ - framework::register_observer( *this ); - registered = true; -} - -void global_configuration::unregister_from_framework() -{ - // not accessing the framework singleton after deregistering -> release - // of the observer from the framework - if(registered) { - framework::deregister_observer( *this ); - } - registered = false; -} - -global_configuration::~global_configuration() -{ - this->unregister_from_framework(); -} - -//____________________________________________________________________________// - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER diff --git a/ThirdParty/boost/test/impl/unit_test_log.ipp b/ThirdParty/boost/test/impl/unit_test_log.ipp deleted file mode 100644 index 1b1e4eea9ae9f2e472294af8977faaa1d52dff67..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/unit_test_log.ipp +++ /dev/null @@ -1,787 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : implemets Unit Test Log -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_LOG_IPP_012205GER -#define BOOST_TEST_UNIT_TEST_LOG_IPP_012205GER - -// Boost.Test -#include <boost/test/unit_test_log.hpp> -#include <boost/test/unit_test_log_formatter.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/unit_test_parameters.hpp> - -#include <boost/test/utils/basic_cstring/compare.hpp> -#include <boost/test/utils/foreach.hpp> - -#include <boost/test/output/compiler_log_formatter.hpp> -#include <boost/test/output/xml_log_formatter.hpp> -#include <boost/test/output/junit_log_formatter.hpp> - -// Boost -#include <boost/shared_ptr.hpp> -#include <boost/io/ios_state.hpp> -typedef ::boost::io::ios_base_all_saver io_saver_type; - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** entry_value_collector ************** // -// ************************************************************************** // - -namespace ut_detail { - -entry_value_collector const& -entry_value_collector::operator<<( lazy_ostream const& v ) const -{ - unit_test_log << v; - - return *this; -} - -//____________________________________________________________________________// - -entry_value_collector const& -entry_value_collector::operator<<( const_string v ) const -{ - unit_test_log << v; - - return *this; -} - -//____________________________________________________________________________// - -entry_value_collector::~entry_value_collector() -{ - if( m_last ) - unit_test_log << log::end(); -} - -//____________________________________________________________________________// - -} // namespace ut_detail - -// ************************************************************************** // -// ************** unit_test_log ************** // -// ************************************************************************** // - -namespace { - -// log data -struct unit_test_log_data_helper_impl { - typedef boost::shared_ptr<unit_test_log_formatter> formatter_ptr; - typedef boost::shared_ptr<io_saver_type> saver_ptr; - - bool m_enabled; - output_format m_format; - std::ostream* m_stream; - saver_ptr m_stream_state_saver; - formatter_ptr m_log_formatter; - bool m_entry_in_progress; - - unit_test_log_data_helper_impl(unit_test_log_formatter* p_log_formatter, output_format format, bool enabled = false) - : m_enabled( enabled ) - , m_format( format ) - , m_stream( &std::cout ) - , m_stream_state_saver( new io_saver_type( std::cout ) ) - , m_log_formatter() - , m_entry_in_progress( false ) - { - m_log_formatter.reset(p_log_formatter); - m_log_formatter->set_log_level(log_all_errors); - } - - // helper functions - std::ostream& stream() - { - return *m_stream; - } - - log_level get_log_level() const - { - return m_log_formatter->get_log_level(); - } -}; - -struct unit_test_log_impl { - // Constructor - unit_test_log_impl() - { - m_log_formatter_data.push_back( unit_test_log_data_helper_impl(new output::compiler_log_formatter, OF_CLF, true) ); // only this one is active by default, - m_log_formatter_data.push_back( unit_test_log_data_helper_impl(new output::xml_log_formatter, OF_XML, false) ); - m_log_formatter_data.push_back( unit_test_log_data_helper_impl(new output::junit_log_formatter, OF_JUNIT, false) ); - } - - typedef std::vector<unit_test_log_data_helper_impl> v_formatter_data_t; - v_formatter_data_t m_log_formatter_data; - - typedef std::vector<unit_test_log_data_helper_impl*> vp_formatter_data_t; - vp_formatter_data_t m_active_log_formatter_data; - - // entry data - log_entry_data m_entry_data; - - bool has_entry_in_progress() const { - for( vp_formatter_data_t::const_iterator it(m_active_log_formatter_data.begin()), ite(m_active_log_formatter_data.end()); - it < ite; - ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.m_entry_in_progress ) - return true; - } - return false; - } - - // check point data - log_checkpoint_data m_checkpoint_data; - - void set_checkpoint( const_string file, std::size_t line_num, const_string msg ) - { - assign_op( m_checkpoint_data.m_message, msg, 0 ); - m_checkpoint_data.m_file_name = file; - m_checkpoint_data.m_line_num = line_num; - } -}; - -unit_test_log_impl& s_log_impl() { static unit_test_log_impl the_inst; return the_inst; } - - -//____________________________________________________________________________// - -void -log_entry_context( log_level l, unit_test_log_data_helper_impl& current_logger_data) -{ - framework::context_generator const& context = framework::get_context(); - if( context.is_empty() ) - return; - - const_string frame; - current_logger_data.m_log_formatter->entry_context_start( current_logger_data.stream(), l ); - while( !(frame=context.next()).is_empty() ) - { - current_logger_data.m_log_formatter->log_entry_context( current_logger_data.stream(), l, frame ); - } - current_logger_data.m_log_formatter->entry_context_finish( current_logger_data.stream(), l ); -} - -//____________________________________________________________________________// - -void -clear_entry_context() -{ - framework::clear_context(); -} - -// convenience -typedef unit_test_log_impl::vp_formatter_data_t vp_logger_t; -typedef unit_test_log_impl::v_formatter_data_t v_logger_t; - -} // local namespace - -//____________________________________________________________________________// - -BOOST_TEST_SINGLETON_CONS_IMPL( unit_test_log_t ) - -void -unit_test_log_t::configure( ) -{ - // configure is not test_start: - // test_start pushes the necessary log information when the test module is starting, and implies configure. - // configure: should be called each time the set of loggers, stream or configuration is changed. - s_log_impl().m_active_log_formatter_data.clear(); - for( unit_test_log_impl::v_formatter_data_t::iterator it(s_log_impl().m_log_formatter_data.begin()), - ite(s_log_impl().m_log_formatter_data.end()); - it < ite; - ++it) - { - if( !it->m_enabled || it->get_log_level() == log_nothing ) - continue; - - s_log_impl().m_active_log_formatter_data.push_back(&*it); - it->m_entry_in_progress = false; - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_start( counter_t test_cases_amount, test_unit_id ) -{ - configure(); - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - - current_logger_data.m_log_formatter->log_start( current_logger_data.stream(), test_cases_amount ); - current_logger_data.m_log_formatter->log_build_info( - current_logger_data.stream(), - runtime_config::get<bool>( runtime_config::btrt_build_info )); - - //current_logger_data.stream().flush(); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_finish() -{ - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - current_logger_data.m_log_formatter->log_finish( current_logger_data.stream() ); - current_logger_data.stream().flush(); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_aborted() -{ - BOOST_TEST_LOG_ENTRY( log_messages ) << "Test is aborted"; -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_unit_start( test_unit const& tu ) -{ - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.get_log_level() > log_test_units ) - continue; - current_logger_data.m_log_formatter->test_unit_start( current_logger_data.stream(), tu ); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_unit_finish( test_unit const& tu, unsigned long elapsed ) -{ - s_log_impl().m_checkpoint_data.clear(); - - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.get_log_level() > log_test_units ) - continue; - - current_logger_data.m_log_formatter->test_unit_finish( current_logger_data.stream(), tu, elapsed ); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::test_unit_skipped( test_unit const& tu, const_string reason ) -{ - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.get_log_level() > log_test_units ) - continue; - - current_logger_data.m_log_formatter->test_unit_skipped( current_logger_data.stream(), tu, reason ); - } -} - -void -unit_test_log_t::test_unit_aborted( test_unit const& tu ) -{ - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.get_log_level() > log_test_units ) - continue; - - current_logger_data.m_log_formatter->test_unit_aborted(current_logger_data.stream(), tu ); - } -} - -void -unit_test_log_t::test_unit_timed_out( test_unit const& tu ) -{ - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.get_log_level() > log_test_units ) - continue; - - current_logger_data.m_log_formatter->test_unit_timed_out(current_logger_data.stream(), tu ); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::exception_caught( execution_exception const& ex ) -{ - log_level l = - ex.code() <= execution_exception::cpp_exception_error ? log_cpp_exception_errors : - (ex.code() <= execution_exception::timeout_error ? log_system_errors - : log_fatal_errors ); - - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - - if( l >= current_logger_data.get_log_level() ) { - - current_logger_data.m_log_formatter->log_exception_start( current_logger_data.stream(), s_log_impl().m_checkpoint_data, ex ); - - log_entry_context( l, current_logger_data ); - - current_logger_data.m_log_formatter->log_exception_finish( current_logger_data.stream() ); - } - } - clear_entry_context(); -} - -//____________________________________________________________________________// - -void -unit_test_log_t::set_checkpoint( const_string file, std::size_t line_num, const_string msg ) -{ - s_log_impl().set_checkpoint( file, line_num, msg ); -} - -//____________________________________________________________________________// - -char -set_unix_slash( char in ) -{ - return in == '\\' ? '/' : in; -} - -unit_test_log_t& -unit_test_log_t::operator<<( log::begin const& b ) -{ - if( s_log_impl().has_entry_in_progress() ) - *this << log::end(); - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - current_logger_data.m_stream_state_saver->restore(); - } - - s_log_impl().m_entry_data.clear(); - - assign_op( s_log_impl().m_entry_data.m_file_name, b.m_file_name, 0 ); - - // normalize file name - std::transform( s_log_impl().m_entry_data.m_file_name.begin(), s_log_impl().m_entry_data.m_file_name.end(), - s_log_impl().m_entry_data.m_file_name.begin(), - &set_unix_slash ); - - s_log_impl().m_entry_data.m_line_num = b.m_line_num; - - return *this; -} - -//____________________________________________________________________________// - -unit_test_log_t& -unit_test_log_t::operator<<( log::end const& ) -{ - if( s_log_impl().has_entry_in_progress() ) { - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - log_level l = s_log_impl().m_entry_data.m_level; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( current_logger_data.m_entry_in_progress ) { - if( l >= current_logger_data.get_log_level() ) { - log_entry_context( l, current_logger_data ); - } - current_logger_data.m_log_formatter->log_entry_finish( current_logger_data.stream() ); - } - current_logger_data.m_entry_in_progress = false; - } - } - - clear_entry_context(); - - return *this; -} - -//____________________________________________________________________________// - -unit_test_log_t& -unit_test_log_t::operator<<( log_level l ) -{ - s_log_impl().m_entry_data.m_level = l; - - return *this; -} - -//____________________________________________________________________________// - -ut_detail::entry_value_collector -unit_test_log_t::operator()( log_level l ) -{ - *this << l; - - return ut_detail::entry_value_collector(); -} - -//____________________________________________________________________________// - -bool -log_entry_start(unit_test_log_data_helper_impl ¤t_logger_data) -{ - if( current_logger_data.m_entry_in_progress ) - return true; - - switch( s_log_impl().m_entry_data.m_level ) { - case log_successful_tests: - current_logger_data.m_log_formatter->log_entry_start( current_logger_data.stream(), s_log_impl().m_entry_data, - unit_test_log_formatter::BOOST_UTL_ET_INFO ); - break; - case log_messages: - current_logger_data.m_log_formatter->log_entry_start( current_logger_data.stream(), s_log_impl().m_entry_data, - unit_test_log_formatter::BOOST_UTL_ET_MESSAGE ); - break; - case log_warnings: - current_logger_data.m_log_formatter->log_entry_start( current_logger_data.stream(), s_log_impl().m_entry_data, - unit_test_log_formatter::BOOST_UTL_ET_WARNING ); - break; - case log_all_errors: - case log_cpp_exception_errors: - case log_system_errors: - current_logger_data.m_log_formatter->log_entry_start( current_logger_data.stream(), s_log_impl().m_entry_data, - unit_test_log_formatter::BOOST_UTL_ET_ERROR ); - break; - case log_fatal_errors: - current_logger_data.m_log_formatter->log_entry_start( current_logger_data.stream(), s_log_impl().m_entry_data, - unit_test_log_formatter::BOOST_UTL_ET_FATAL_ERROR ); - break; - case log_nothing: - case log_test_units: - case invalid_log_level: - return false; - } - - current_logger_data.m_entry_in_progress = true; - return true; -} - -//____________________________________________________________________________// - -unit_test_log_t& -unit_test_log_t::operator<<( const_string value ) -{ - if(value.empty()) { - return *this; - } - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( s_log_impl().m_entry_data.m_level >= current_logger_data.get_log_level() ) - if( log_entry_start(current_logger_data) ) { - current_logger_data.m_log_formatter->log_entry_value( current_logger_data.stream(), value ); - } - } - return *this; -} - -//____________________________________________________________________________// - -unit_test_log_t& -unit_test_log_t::operator<<( lazy_ostream const& value ) -{ - if(value.empty()) { - return *this; - } - - vp_logger_t& vloggers = s_log_impl().m_active_log_formatter_data; - for( vp_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = **it; - if( s_log_impl().m_entry_data.m_level >= current_logger_data.get_log_level() ) { - if( log_entry_start(current_logger_data) ) { - current_logger_data.m_log_formatter->log_entry_value( current_logger_data.stream(), value ); - } - } - } - return *this; -} - -//____________________________________________________________________________// - -void -unit_test_log_t::set_stream( std::ostream& str ) -{ - if( s_log_impl().has_entry_in_progress() ) - return; - - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - - current_logger_data.m_stream = &str; - current_logger_data.m_stream_state_saver.reset( new io_saver_type( str ) ); - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::set_stream( output_format log_format, std::ostream& str ) -{ - if( s_log_impl().has_entry_in_progress() ) - return; - - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - if( current_logger_data.m_format == log_format) { - current_logger_data.m_stream = &str; - current_logger_data.m_stream_state_saver.reset( new io_saver_type( str ) ); - break; - } - } -} - -std::ostream* -unit_test_log_t::get_stream( output_format log_format ) const -{ - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - if( current_logger_data.m_format == log_format) { - return current_logger_data.m_stream; - } - } - return 0; -} - -//____________________________________________________________________________// - -log_level -unit_test_log_t::set_threshold_level( log_level lev ) -{ - if( s_log_impl().has_entry_in_progress() || lev == invalid_log_level ) - return invalid_log_level; - - log_level ret = log_nothing; - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - ret = (std::min)(ret, current_logger_data.m_log_formatter->get_log_level()); - current_logger_data.m_log_formatter->set_log_level( lev ); - } - return ret; -} - -//____________________________________________________________________________// - -log_level -unit_test_log_t::set_threshold_level( output_format log_format, log_level lev ) -{ - if( s_log_impl().has_entry_in_progress() || lev == invalid_log_level ) - return invalid_log_level; - - log_level ret = log_nothing; - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - if( current_logger_data.m_format == log_format) { - ret = current_logger_data.m_log_formatter->get_log_level(); - current_logger_data.m_log_formatter->set_log_level( lev ); - break; - } - } - return ret; -} - -//____________________________________________________________________________// - -void -unit_test_log_t::set_format( output_format log_format ) -{ - if( s_log_impl().has_entry_in_progress() ) - return; - - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - current_logger_data.m_enabled = current_logger_data.m_format == log_format; - } -} - -//____________________________________________________________________________// - -void -unit_test_log_t::add_format( output_format log_format ) -{ - if( s_log_impl().has_entry_in_progress() ) - return; - - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - if( current_logger_data.m_format == log_format) { - current_logger_data.m_enabled = true; - break; - } - } -} - -//____________________________________________________________________________// - -unit_test_log_formatter* -unit_test_log_t::get_formatter( output_format log_format ) { - - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for( v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - unit_test_log_data_helper_impl& current_logger_data = *it; - if( current_logger_data.m_format == log_format) { - return current_logger_data.m_log_formatter.get(); - } - } - return 0; -} - - -void -unit_test_log_t::add_formatter( unit_test_log_formatter* the_formatter ) -{ - // remove only user defined logger - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for(v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - if( it->m_format == OF_CUSTOM_LOGGER) { - s_log_impl().m_log_formatter_data.erase(it); - break; - } - } - - if( the_formatter ) { - s_log_impl().m_active_log_formatter_data.clear(); // otherwise dandling references - vloggers.push_back( unit_test_log_data_helper_impl(the_formatter, OF_CUSTOM_LOGGER, true) ); - } -} - -void -unit_test_log_t::set_formatter( unit_test_log_formatter* the_formatter ) -{ - if( s_log_impl().has_entry_in_progress() ) - return; - - // remove only user defined logger - log_level current_level = invalid_log_level; - std::ostream *current_stream = 0; - output_format previous_format = OF_INVALID; - v_logger_t& vloggers = s_log_impl().m_log_formatter_data; - for(v_logger_t::iterator it(vloggers.begin()), ite(vloggers.end()); it < ite; ++it) - { - if( it->m_enabled ) { - if( current_level == invalid_log_level || it->m_format < previous_format || it->m_format == OF_CUSTOM_LOGGER) { - current_level = it->get_log_level(); - current_stream = &(it->stream()); - previous_format = it->m_format; - } - } - } - - if( the_formatter ) { - add_formatter(the_formatter); - set_format(OF_CUSTOM_LOGGER); - set_threshold_level(OF_CUSTOM_LOGGER, current_level); - set_stream(OF_CUSTOM_LOGGER, *current_stream); - } - - configure(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** unit_test_log_formatter ************** // -// ************************************************************************** // - -void -unit_test_log_formatter::log_entry_value( std::ostream& ostr, lazy_ostream const& value ) -{ - log_entry_value( ostr, (wrap_stringstream().ref() << value).str() ); -} - -void -unit_test_log_formatter::set_log_level(log_level new_log_level) -{ - m_log_level = new_log_level; -} - -log_level -unit_test_log_formatter::get_log_level() const -{ - return m_log_level; -} - -//____________________________________________________________________________// - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UNIT_TEST_LOG_IPP_012205GER - diff --git a/ThirdParty/boost/test/impl/unit_test_main.ipp b/ThirdParty/boost/test/impl/unit_test_main.ipp deleted file mode 100644 index 4e473fba630a435498f767241a4b563af6c69e91..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/unit_test_main.ipp +++ /dev/null @@ -1,315 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : main function implementation for Unit Test Framework -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_MAIN_IPP_012205GER -#define BOOST_TEST_UNIT_TEST_MAIN_IPP_012205GER - -// Boost.Test -#include <boost/test/framework.hpp> -#include <boost/test/results_collector.hpp> -#include <boost/test/results_reporter.hpp> - -#include <boost/test/tree/visitor.hpp> -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/traverse.hpp> - -#include <boost/test/unit_test_parameters.hpp> - -#include <boost/test/utils/foreach.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> - -// Boost -#include <boost/core/ignore_unused.hpp> -#include <boost/cstdlib.hpp> - -// STL -#include <cstdio> -#include <stdexcept> -#include <iostream> -#include <iomanip> -#include <iterator> -#include <set> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -namespace ut_detail { - -// ************************************************************************** // -// ************** hrf_content_reporter ************** // -// ************************************************************************** // - -struct hrf_content_reporter : test_tree_visitor { - explicit hrf_content_reporter( std::ostream& os ) : m_os( os ), m_indent( -4 ) {} // skip master test suite - -private: - void report_test_unit( test_unit const& tu ) - { - m_os << std::setw( m_indent ) << "" << tu.p_name; - m_os << (tu.p_default_status == test_unit::RS_ENABLED ? "*" : " "); - //m_os << '[' << tu.p_sibling_rank << ']'; - if( !tu.p_description->empty() ) - m_os << ": " << tu.p_description; - - m_os << "\n"; - } - virtual void visit( test_case const& tc ) { report_test_unit( tc ); } - virtual bool test_suite_start( test_suite const& ts ) - { - if( m_indent >= 0 ) - report_test_unit( ts ); - m_indent += 4; - return true; - } - virtual void test_suite_finish( test_suite const& ) - { - m_indent -= 4; - } - - // Data members - std::ostream& m_os; - int m_indent; -}; - -// ************************************************************************** // -// ************** dot_content_reporter ************** // -// ************************************************************************** // - -struct dot_content_reporter : test_tree_visitor { - explicit dot_content_reporter( std::ostream& os ) : m_os( os ) {} - -private: - void report_test_unit( test_unit const& tu ) - { - bool master_ts = tu.p_parent_id == INV_TEST_UNIT_ID; - - m_os << "tu" << tu.p_id; - - m_os << (master_ts ? "[shape=ellipse,peripheries=2" : "[shape=Mrecord" ); - - m_os << ",fontname=Helvetica"; - - m_os << (tu.p_default_status == test_unit::RS_ENABLED ? ",color=green" : ",color=yellow"); - - if( master_ts ) - m_os << ",label=\"" << tu.p_name << "\"];\n"; - else { - m_os << ",label=\"" << tu.p_name << "|" << tu.p_file_name << "(" << tu.p_line_num << ")"; - if( tu.p_timeout > 0 ) - m_os << "|timeout=" << tu.p_timeout; - if( tu.p_expected_failures != 0 ) - m_os << "|expected failures=" << tu.p_expected_failures; - if( !tu.p_labels->empty() ) { - m_os << "|labels:"; - - BOOST_TEST_FOREACH( std::string const&, l, tu.p_labels.get() ) - m_os << " @" << l; - } - m_os << "\"];\n"; - } - - if( !master_ts ) - m_os << "tu" << tu.p_parent_id << " -> " << "tu" << tu.p_id << ";\n"; - - BOOST_TEST_FOREACH( test_unit_id, dep_id, tu.p_dependencies.get() ) { - test_unit const& dep = framework::get( dep_id, TUT_ANY ); - - m_os << "tu" << tu.p_id << " -> " << "tu" << dep.p_id << "[color=red,style=dotted,constraint=false];\n"; - } - - } - virtual void visit( test_case const& tc ) - { - report_test_unit( tc ); - } - virtual bool test_suite_start( test_suite const& ts ) - { - if( ts.p_parent_id == INV_TEST_UNIT_ID ) - m_os << "digraph G {rankdir=LR;\n"; - - report_test_unit( ts ); - - m_os << "{\n"; - - return true; - } - virtual void test_suite_finish( test_suite const& ts ) - { - m_os << "}\n"; - if( ts.p_parent_id == INV_TEST_UNIT_ID ) - m_os << "}\n"; - } - - std::ostream& m_os; -}; - -// ************************************************************************** // -// ************** labels_collector ************** // -// ************************************************************************** // - -struct labels_collector : test_tree_visitor { - std::set<std::string> const& labels() const { return m_labels; } - -private: - virtual bool visit( test_unit const& tu ) - { - m_labels.insert( tu.p_labels->begin(), tu.p_labels->end() ); - return true; - } - - // Data members - std::set<std::string> m_labels; -}; - -struct framework_shutdown_helper { - ~framework_shutdown_helper() { - try { - framework::shutdown(); - } - catch(...) { - std::cerr << "Boost.Test shutdown exception caught" << std::endl; - } - } -}; - -} // namespace ut_detail - -// ************************************************************************** // -// ************** unit_test_main ************** // -// ************************************************************************** // - - - -int BOOST_TEST_DECL -unit_test_main( init_unit_test_func init_func, int argc, char* argv[] ) -{ - int result_code = 0; - - ut_detail::framework_shutdown_helper shutdown_helper; - boost::ignore_unused(shutdown_helper); - - BOOST_TEST_I_TRY { - - framework::init( init_func, argc, argv ); - - if( runtime_config::get<bool>( runtime_config::btrt_wait_for_debugger ) ) { - results_reporter::get_stream() << "Press any key to continue..." << std::endl; - - // getchar is defined as a macro in uClibc. Use parenthesis to fix - // gcc bug 58952 for gcc <= 4.8.2. - (std::getchar)(); - results_reporter::get_stream() << "Continuing..." << std::endl; - } - - framework::finalize_setup_phase(); - - output_format list_cont = runtime_config::get<output_format>( runtime_config::btrt_list_content ); - if( list_cont != unit_test::OF_INVALID ) { - if( list_cont == unit_test::OF_DOT ) { - ut_detail::dot_content_reporter reporter( results_reporter::get_stream() ); - - traverse_test_tree( framework::master_test_suite().p_id, reporter, true ); - } - else { - ut_detail::hrf_content_reporter reporter( results_reporter::get_stream() ); - - traverse_test_tree( framework::master_test_suite().p_id, reporter, true ); - } - - return boost::exit_success; - } - - if( runtime_config::get<bool>( runtime_config::btrt_list_labels ) ) { - ut_detail::labels_collector collector; - - traverse_test_tree( framework::master_test_suite().p_id, collector, true ); - - results_reporter::get_stream() << "Available labels:\n "; - std::copy( collector.labels().begin(), collector.labels().end(), - std::ostream_iterator<std::string>( results_reporter::get_stream(), "\n " ) ); - results_reporter::get_stream() << "\n"; - - return boost::exit_success; - } - - framework::run(); - - result_code = !runtime_config::get<bool>( runtime_config::btrt_result_code ) - ? boost::exit_success - : results_collector.results( framework::master_test_suite().p_id ).result_code(); - } - BOOST_TEST_I_CATCH( framework::nothing_to_test, ex ) { - result_code = ex.m_result_code; - } - BOOST_TEST_I_CATCH( framework::internal_error, ex ) { - results_reporter::get_stream() << "Boost.Test framework internal error: " << ex.what() << std::endl; - - result_code = boost::exit_exception_failure; - } - BOOST_TEST_I_CATCH( framework::setup_error, ex ) { - results_reporter::get_stream() << "Test setup error: " << ex.what() << std::endl; - - result_code = boost::exit_exception_failure; - } - BOOST_TEST_I_CATCH( std::logic_error, ex ) { - results_reporter::get_stream() << "Test setup error: " << ex.what() << std::endl; - - result_code = boost::exit_exception_failure; - } - BOOST_TEST_I_CATCHALL() { - results_reporter::get_stream() << "Boost.Test framework internal error: unknown reason" << std::endl; - - result_code = boost::exit_exception_failure; - } - - return result_code; -} - -} // namespace unit_test -} // namespace boost - -#if !defined(BOOST_TEST_DYN_LINK) && !defined(BOOST_TEST_NO_MAIN) - -// ************************************************************************** // -// ************** main function for tests using lib ************** // -// ************************************************************************** // - -int BOOST_TEST_CALL_DECL -main( int argc, char* argv[] ) -{ - // prototype for user's unit test init function -#ifdef BOOST_TEST_ALTERNATIVE_INIT_API - extern bool init_unit_test(); - - boost::unit_test::init_unit_test_func init_func = &init_unit_test; -#else - extern ::boost::unit_test::test_suite* init_unit_test_suite( int argc, char* argv[] ); - - boost::unit_test::init_unit_test_func init_func = &init_unit_test_suite; -#endif - - return ::boost::unit_test::unit_test_main( init_func, argc, argv ); -} - -#endif // !BOOST_TEST_DYN_LINK && !BOOST_TEST_NO_MAIN - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UNIT_TEST_MAIN_IPP_012205GER diff --git a/ThirdParty/boost/test/impl/xml_log_formatter.ipp b/ThirdParty/boost/test/impl/xml_log_formatter.ipp deleted file mode 100644 index e244d4d5f04358a21ed3e48fded02d1b7a1738d6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/impl/xml_log_formatter.ipp +++ /dev/null @@ -1,225 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : implements OF_XML Log formatter -// *************************************************************************** - -#ifndef BOOST_TEST_XML_LOG_FORMATTER_IPP_020105GER -#define BOOST_TEST_XML_LOG_FORMATTER_IPP_020105GER - -// Boost.Test -#include <boost/test/output/xml_log_formatter.hpp> -#include <boost/test/execution_monitor.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> -#include <boost/test/utils/xml_printer.hpp> - -// Boost -#include <boost/version.hpp> - -// STL -#include <iostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace output { - -static const_string tu_type_name( test_unit const& tu ) -{ - return tu.p_type == TUT_CASE ? "TestCase" : "TestSuite"; -} - -// ************************************************************************** // -// ************** xml_log_formatter ************** // -// ************************************************************************** // - -void -xml_log_formatter::log_start( std::ostream& ostr, counter_t ) -{ - ostr << "<TestLog>"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_finish( std::ostream& ostr ) -{ - ostr << "</TestLog>"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_build_info( std::ostream& ostr, bool log_build_info ) -{ - if( log_build_info ) { - ostr << "<BuildInfo" - << " platform" << utils::attr_value() << BOOST_PLATFORM - << " compiler" << utils::attr_value() << BOOST_COMPILER - << " stl" << utils::attr_value() << BOOST_STDLIB - << " boost=\"" << BOOST_VERSION/100000 << "." - << BOOST_VERSION/100 % 1000 << "." - << BOOST_VERSION % 100 << '\"' - << "/>"; - } -} - -//____________________________________________________________________________// - -void -xml_log_formatter::test_unit_start( std::ostream& ostr, test_unit const& tu ) -{ - ostr << "<" << tu_type_name( tu ) << " name" << utils::attr_value() << tu.p_name.get(); - - if( !tu.p_file_name.empty() ) - ostr << BOOST_TEST_L( " file" ) << utils::attr_value() << tu.p_file_name - << BOOST_TEST_L( " line" ) << utils::attr_value() << tu.p_line_num; - - ostr << ">"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::test_unit_finish( std::ostream& ostr, test_unit const& tu, unsigned long elapsed ) -{ - if( tu.p_type == TUT_CASE ) - ostr << "<TestingTime>" << elapsed << "</TestingTime>"; - - ostr << "</" << tu_type_name( tu ) << ">"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::test_unit_skipped( std::ostream& ostr, test_unit const& tu, const_string reason ) -{ - ostr << "<" << tu_type_name( tu ) - << " name" << utils::attr_value() << tu.p_name.get() - << " skipped" << utils::attr_value() << "yes" - << " reason" << utils::attr_value() << reason - << "/>"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_exception_start( std::ostream& ostr, log_checkpoint_data const& checkpoint_data, execution_exception const& ex ) -{ - execution_exception::location const& loc = ex.where(); - - ostr << "<Exception file" << utils::attr_value() << loc.m_file_name - << " line" << utils::attr_value() << loc.m_line_num; - - if( !loc.m_function.is_empty() ) - ostr << " function" << utils::attr_value() << loc.m_function; - - ostr << ">" << utils::cdata() << ex.what(); - - if( !checkpoint_data.m_file_name.is_empty() ) { - ostr << "<LastCheckpoint file" << utils::attr_value() << checkpoint_data.m_file_name - << " line" << utils::attr_value() << checkpoint_data.m_line_num - << ">" - << utils::cdata() << checkpoint_data.m_message - << "</LastCheckpoint>"; - } -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_exception_finish( std::ostream& ostr ) -{ - ostr << "</Exception>"; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_entry_start( std::ostream& ostr, log_entry_data const& entry_data, log_entry_types let ) -{ - static literal_string xml_tags[] = { "Info", "Message", "Warning", "Error", "FatalError" }; - - m_curr_tag = xml_tags[let]; - ostr << '<' << m_curr_tag - << BOOST_TEST_L( " file" ) << utils::attr_value() << entry_data.m_file_name - << BOOST_TEST_L( " line" ) << utils::attr_value() << entry_data.m_line_num - << BOOST_TEST_L( "><![CDATA[" ); - - m_value_closed = false; -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_entry_value( std::ostream& ostr, const_string value ) -{ - utils::print_escaped_cdata( ostr, value ); -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_entry_finish( std::ostream& ostr ) -{ - if( !m_value_closed ) { - ostr << BOOST_TEST_L( "]]>" ); - m_value_closed = true; - } - - ostr << BOOST_TEST_L( "</" ) << m_curr_tag << BOOST_TEST_L( ">" ); - - m_curr_tag.clear(); -} - -//____________________________________________________________________________// - -void -xml_log_formatter::entry_context_start( std::ostream& ostr, log_level ) -{ - if( !m_value_closed ) { - ostr << BOOST_TEST_L( "]]>" ); - m_value_closed = true; - } - - ostr << BOOST_TEST_L( "<Context>" ); -} - -//____________________________________________________________________________// - -void -xml_log_formatter::entry_context_finish( std::ostream& ostr, log_level ) -{ - ostr << BOOST_TEST_L( "</Context>" ); -} - -//____________________________________________________________________________// - -void -xml_log_formatter::log_entry_context( std::ostream& ostr, log_level, const_string context_descr ) -{ - ostr << BOOST_TEST_L( "<Frame>" ) << utils::cdata() << context_descr << BOOST_TEST_L( "</Frame>" ); -} - -//____________________________________________________________________________// - -} // namespace output -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_XML_LOG_FORMATTER_IPP_020105GER diff --git a/ThirdParty/boost/test/minimal.hpp b/ThirdParty/boost/test/minimal.hpp deleted file mode 100644 index 7210878bb6deec20b5b4cb663303b073aee21ab6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/minimal.hpp +++ /dev/null @@ -1,162 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Deprecated implementation of simple minimal testing -/// @deprecated -/// To convert to Unit Test Framework simply rewrite: -/// @code -/// #include <boost/test/minimal.hpp> -/// -/// int test_main( int, char *[] ) -/// { -/// ... -/// } -/// @endcode -/// as -/// @code -/// #include <boost/test/included/unit_test.hpp> -/// -/// BOOST_AUTO_TEST_CASE(test_main) -/// { -/// ... -/// } -/// @endcode -// *************************************************************************** - -#ifndef BOOST_TEST_MINIMAL_HPP_071894GER -#define BOOST_TEST_MINIMAL_HPP_071894GER - -#include <boost/config/header_deprecated.hpp> -BOOST_HEADER_DEPRECATED( "<boost/test/included/unit_test.hpp>" ) -#if defined(BOOST_ALLOW_DEPRECATED_HEADERS) -BOOST_PRAGMA_MESSAGE( "Boost.Test minimal is deprecated. Please convert to the header only variant of Boost.Test." ) -#endif - -#define BOOST_CHECK(exp) \ - ( (exp) \ - ? static_cast<void>(0) \ - : boost::minimal_test::report_error(#exp,__FILE__,__LINE__, BOOST_CURRENT_FUNCTION) ) - -#define BOOST_REQUIRE(exp) \ - ( (exp) \ - ? static_cast<void>(0) \ - : boost::minimal_test::report_critical_error(#exp,__FILE__,__LINE__,BOOST_CURRENT_FUNCTION)) - -#define BOOST_ERROR( msg_ ) \ - boost::minimal_test::report_error( (msg_),__FILE__,__LINE__, BOOST_CURRENT_FUNCTION, true ) -#define BOOST_FAIL( msg_ ) \ - boost::minimal_test::report_critical_error( (msg_),__FILE__,__LINE__, BOOST_CURRENT_FUNCTION, true ) - -//____________________________________________________________________________// - -// Boost.Test -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/impl/execution_monitor.ipp> -#include <boost/test/impl/debug.ipp> -#include <boost/test/utils/class_properties.hpp> -#include <boost/test/utils/basic_cstring/io.hpp> - -// Boost -#include <boost/cstdlib.hpp> // for exit codes -#include <boost/current_function.hpp> // for BOOST_CURRENT_FUNCTION - -// STL -#include <iostream> // std::cerr, std::endl -#include <string> // std::string - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -int test_main( int argc, char* argv[] ); // prototype for users test_main() - -namespace boost { -namespace minimal_test { - -typedef boost::unit_test::const_string const_string; - -inline unit_test::counter_t& errors_counter() { static unit_test::counter_t ec = 0; return ec; } - -inline void -report_error( const char* msg, const char* file, int line, const_string func_name, bool is_msg = false ) -{ - ++errors_counter(); - std::cerr << file << "(" << line << "): "; - - if( is_msg ) - std::cerr << msg; - else - std::cerr << "test " << msg << " failed"; - - if( func_name != "(unknown)" ) - std::cerr << " in function: '" << func_name << "'"; - - std::cerr << std::endl; -} - -inline void -report_critical_error( const char* msg, const char* file, int line, const_string func_name, bool is_msg = false ) -{ - report_error( msg, file, line, func_name, is_msg ); - - throw boost::execution_aborted(); -} - -class caller { -public: - // constructor - caller( int argc, char** argv ) - : m_argc( argc ), m_argv( argv ) {} - - // execution monitor hook implementation - int operator()() { return test_main( m_argc, m_argv ); } - -private: - // Data members - int m_argc; - char** m_argv; -}; // monitor - -} // namespace minimal_test -} // namespace boost - -//____________________________________________________________________________// - -int BOOST_TEST_CALL_DECL main( int argc, char* argv[] ) -{ - using namespace boost::minimal_test; - - try { - ::boost::execution_monitor ex_mon; - int run_result = ex_mon.execute( caller( argc, argv ) ); - - BOOST_CHECK( run_result == 0 || run_result == boost::exit_success ); - } - catch( boost::execution_exception const& exex ) { - if( exex.code() != boost::execution_exception::no_error ) - BOOST_ERROR( (std::string( "exception \"" ) + exex.what() + "\" caught").c_str() ); - std::cerr << "\n**** Testing aborted."; - } - - if( boost::minimal_test::errors_counter() != 0 ) { - std::cerr << "\n**** " << errors_counter() - << " error" << (errors_counter() > 1 ? "s" : "" ) << " detected\n"; - - return boost::exit_test_failure; - } - - std::cout << "\n**** no errors detected\n"; - - return boost::exit_success; -} - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_MINIMAL_HPP_071894GER diff --git a/ThirdParty/boost/test/output/compiler_log_formatter.hpp b/ThirdParty/boost/test/output/compiler_log_formatter.hpp deleted file mode 100644 index cccf6151d889d3e47dfce29c53a64bdb7c43bf16..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/output/compiler_log_formatter.hpp +++ /dev/null @@ -1,73 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Contains the formatter for the Human Readable Format (HRF) -// *************************************************************************** - -#ifndef BOOST_TEST_COMPILER_LOG_FORMATTER_HPP_020105GER -#define BOOST_TEST_COMPILER_LOG_FORMATTER_HPP_020105GER - -// Boost.Test -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/unit_test_log_formatter.hpp> - -#include <boost/test/utils/setcolor.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace output { - -// ************************************************************************** // -// ************** compiler_log_formatter ************** // -// ************************************************************************** // - -//!@brief Log formatter for the Human Readable Format (HRF) log format -class BOOST_TEST_DECL compiler_log_formatter : public unit_test_log_formatter { -public: - compiler_log_formatter() : m_color_output( false ), m_color_state() {} - - // Formatter interface - void log_start( std::ostream&, counter_t test_cases_amount ); - void log_finish( std::ostream& ); - void log_build_info( std::ostream&, bool ); - - void test_unit_start( std::ostream&, test_unit const& tu ); - void test_unit_finish( std::ostream&, test_unit const& tu, unsigned long elapsed ); - void test_unit_skipped( std::ostream&, test_unit const& tu, const_string reason ); - - void log_exception_start( std::ostream&, log_checkpoint_data const&, execution_exception const& ex ); - void log_exception_finish( std::ostream& ); - - void log_entry_start( std::ostream&, log_entry_data const&, log_entry_types let ); - void log_entry_value( std::ostream&, const_string value ); - void log_entry_value( std::ostream&, lazy_ostream const& value ); - void log_entry_finish( std::ostream& ); - - void entry_context_start( std::ostream&, log_level ); - void log_entry_context( std::ostream&, log_level l, const_string ); - void entry_context_finish( std::ostream&, log_level l ); - -protected: - virtual void print_prefix( std::ostream&, const_string file, std::size_t line ); - - // Data members - bool m_color_output; - utils::setcolor::state m_color_state; -}; - -} // namespace output -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_COMPILER_LOG_FORMATTER_HPP_020105GER diff --git a/ThirdParty/boost/test/progress_monitor.hpp b/ThirdParty/boost/test/progress_monitor.hpp deleted file mode 100644 index 195956abe8824fd5ff20e81eb5ff876c89d83fcf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/progress_monitor.hpp +++ /dev/null @@ -1,65 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief defines simple text based progress monitor -// *************************************************************************** - -#ifndef BOOST_TEST_PROGRESS_MONITOR_HPP_020105GER -#define BOOST_TEST_PROGRESS_MONITOR_HPP_020105GER - -// Boost.Test -#include <boost/test/tree/observer.hpp> - -// STL -#include <iosfwd> // for std::ostream& - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** progress_monitor ************** // -// ************************************************************************** // - -/// This class implements test observer interface and updates test progress as test units finish or get aborted -class BOOST_TEST_DECL progress_monitor_t : public test_observer { -public: - /// @name Test observer interface - /// @{ - virtual void test_start( counter_t test_cases_amount, test_unit_id ); - virtual void test_aborted(); - - virtual void test_unit_finish( test_unit const&, unsigned long ); - virtual void test_unit_skipped( test_unit const&, const_string ); - - virtual int priority() { return 4; } - /// @} - - /// @name Configuration - /// @{ - void set_stream( std::ostream& ); - /// @} - - /// Singleton pattern - BOOST_TEST_SINGLETON_CONS( progress_monitor_t ) -}; // progress_monitor_t - -BOOST_TEST_SINGLETON_INST( progress_monitor ) - -} // namespace unit_test -} // namespace boost - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_PROGRESS_MONITOR_HPP_020105GER - diff --git a/ThirdParty/boost/test/results_collector.hpp b/ThirdParty/boost/test/results_collector.hpp deleted file mode 100644 index d12a8a9bf2801c962b16e388a19a78736cba921d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/results_collector.hpp +++ /dev/null @@ -1,153 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Defines testing result collector components -/// -/// Defines classes for keeping track (@ref test_results) and collecting -/// (@ref results_collector_t) the states of the test units. -// *************************************************************************** - -#ifndef BOOST_TEST_RESULTS_COLLECTOR_HPP_071894GER -#define BOOST_TEST_RESULTS_COLLECTOR_HPP_071894GER - -// Boost.Test -#include <boost/test/tree/observer.hpp> - -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/fwd_decl.hpp> - -#include <boost/test/utils/class_properties.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -namespace { - -// ************************************************************************** // -/// First failed assertion debugger hook -/// -/// This function is a placeholder where user can set a breakpoint in debugger to catch the -/// very first assertion failure in each test case -// ************************************************************************** // -inline void first_failed_assertion() {} -} - -// ************************************************************************** // -/// @brief Collection of attributes constituting test unit results -/// -/// This class is a collection of attributes describing a test result. -/// -/// The attributes presented as public properties on -/// an instance of the class. In addition summary conclusion methods are presented to generate simple answer to pass/fail question - -class BOOST_TEST_DECL test_results { -public: - test_results(); - - /// Type representing counter like public property - typedef BOOST_READONLY_PROPERTY( counter_t, (results_collector_t) - (test_results) - (results_collect_helper) ) counter_prop; - /// Type representing boolean like public property - typedef BOOST_READONLY_PROPERTY( bool, (results_collector_t) - (test_results) - (results_collect_helper) ) bool_prop; - - counter_prop p_test_suites; //!< Number of test suites - counter_prop p_assertions_passed; //!< Number of successful assertions - counter_prop p_assertions_failed; //!< Number of failing assertions - counter_prop p_warnings_failed; //!< Number of warnings - counter_prop p_expected_failures; - counter_prop p_test_cases_passed; //!< Number of successfull test cases - counter_prop p_test_cases_warned; //!< Number of warnings in test cases - counter_prop p_test_cases_failed; //!< Number of failing test cases - counter_prop p_test_cases_skipped; //!< Number of skipped test cases - counter_prop p_test_cases_aborted; //!< Number of aborted test cases - counter_prop p_test_cases_timed_out; //!< Number of timed out test cases - counter_prop p_test_suites_timed_out; //!< Number of timed out test suites - counter_prop p_duration_microseconds; //!< Duration of the test in microseconds - bool_prop p_aborted; //!< Indicates that the test unit execution has been aborted - bool_prop p_skipped; //!< Indicates that the test unit execution has been skipped - bool_prop p_timed_out; //!< Indicates that the test unit has timed out - - /// Returns true if test unit passed - bool passed() const; - - /// Returns true if test unit skipped - /// - /// For test suites, this indicates if the test suite itself has been marked as - /// skipped, and not if the test suite contains any skipped test. - bool skipped() const; - - /// Returns true if the test unit was aborted (hard failure) - bool aborted() const; - - /// Produces result code for the test unit execution - /// - /// This methhod return one of the result codes defined in @c boost/cstdlib.hpp - /// @returns - /// - @c boost::exit_success on success, - /// - @c boost::exit_exception_failure in case test unit - /// was aborted for any reason (incuding uncaught exception) - /// - and @c boost::exit_test_failure otherwise - int result_code() const; - - //! Combines the results of the current instance with another - //! - //! Only the counters are updated and the @c p_aborted and @c p_skipped are left unchanged. - void operator+=( test_results const& ); - - //! Resets the current state of the result - void clear(); -}; - -// ************************************************************************** // -/// @brief Collects and combines the test results -/// -/// This class collects and combines the results of the test unit during the execution of the -/// test tree. The results_collector_t::results() function combines the test results on a subtree -/// of the test tree. -/// -/// @see boost::unit_test::test_observer -class BOOST_TEST_DECL results_collector_t : public test_observer { -public: - - virtual void test_start( counter_t, test_unit_id ); - - virtual void test_unit_start( test_unit const& ); - virtual void test_unit_finish( test_unit const&, unsigned long ); - virtual void test_unit_skipped( test_unit const&, const_string ); - virtual void test_unit_aborted( test_unit const& ); - virtual void test_unit_timed_out( test_unit const& ); - - virtual void assertion_result( unit_test::assertion_result ); - virtual void exception_caught( execution_exception const& ); - - virtual int priority() { return 3; } - - /// Results access per test unit - /// - /// @param[in] tu_id id of a test unit - test_results const& results( test_unit_id tu_id ) const; - - /// Singleton pattern - BOOST_TEST_SINGLETON_CONS( results_collector_t ) -}; - -BOOST_TEST_SINGLETON_INST( results_collector ) - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_RESULTS_COLLECTOR_HPP_071894GER diff --git a/ThirdParty/boost/test/test_framework_init_observer.hpp b/ThirdParty/boost/test/test_framework_init_observer.hpp deleted file mode 100644 index 230fb62f914fe18c4e0ae1a919efc061f7c7f709..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/test_framework_init_observer.hpp +++ /dev/null @@ -1,59 +0,0 @@ -// (c) Copyright Raffi Enficiaud 2017. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Defines an observer that monitors the init of the unit test framework -// *************************************************************************** - -#ifndef BOOST_TEST_FRAMEWORK_INIT_OBSERVER_HPP_071894GER -#define BOOST_TEST_FRAMEWORK_INIT_OBSERVER_HPP_071894GER - -// Boost.Test -#include <boost/test/tree/observer.hpp> - -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/fwd_decl.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -/// @brief Monitors the init of the framework -/// -/// This class collects the state of the init/termination of the unit test framework. -/// -/// @see boost::unit_test::test_observer -class BOOST_TEST_DECL framework_init_observer_t : public test_observer { -public: - - virtual void test_start( counter_t, test_unit_id ); - - virtual void assertion_result( unit_test::assertion_result ); - virtual void exception_caught( execution_exception const& ); - virtual void test_aborted(); - - virtual int priority() { return 0; } - - void clear(); - - /// Indicates if a failure has been recorded so far - bool has_failed( ) const; - -private: - bool m_has_failure; -}; - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_FRAMEWORK_INIT_OBSERVER_HPP_071894GER diff --git a/ThirdParty/boost/test/tools/assertion.hpp b/ThirdParty/boost/test/tools/assertion.hpp deleted file mode 100644 index 39eab3b03b9805b5bfb322c1746941df22eea494..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/assertion.hpp +++ /dev/null @@ -1,424 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief Defines framework for automated assertion construction -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_ASSERTION_HPP_100911GER -#define BOOST_TEST_TOOLS_ASSERTION_HPP_100911GER - -// Boost.Test -#include <boost/test/tools/assertion_result.hpp> -#include <boost/test/tools/detail/print_helper.hpp> -#include <boost/test/tools/detail/fwd.hpp> - -// Boost -#include <boost/type.hpp> -#include <boost/type_traits/decay.hpp> -#include <boost/mpl/assert.hpp> -#include <boost/utility/declval.hpp> -#include <boost/type_traits/remove_reference.hpp> -#include <boost/type_traits/remove_const.hpp> - -// STL -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES -#include <utility> -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace assertion { - -// ************************************************************************** // -// ************** assertion::operators ************** // -// ************************************************************************** // -// precedence 4: ->*, .* -// precedence 5: *, /, % -// precedence 6: +, - -// precedence 7: << , >> -// precedence 8: <, <=, > and >= -// precedence 9: == and != -// precedence 10: bitwise AND -// precedence 11: bitwise XOR -// precedence 12: bitwise OR -// precedence 13: logical AND -// disabled -// precedence 14: logical OR -// disabled -// precedence 15: ternary conditional -// disabled -// precedence 16: = and OP= operators -// precedence 17: throw operator -// not supported -// precedence 18: comma -// not supported - -namespace op { - -#define BOOST_TEST_FOR_EACH_COMP_OP(action) \ - action( < , LT, >=, GE ) \ - action( <=, LE, > , GT ) \ - action( > , GT, <=, LE ) \ - action( >=, GE, < , LT ) \ - action( ==, EQ, !=, NE ) \ - action( !=, NE, ==, EQ ) \ -/**/ - -//____________________________________________________________________________// - -#ifndef BOOST_NO_CXX11_DECLTYPE - -#define BOOST_TEST_FOR_EACH_CONST_OP(action)\ - action(->*, MEMP, ->*, MEMP ) \ - \ - action( * , MUL , * , MUL ) \ - action( / , DIV , / , DIV ) \ - action( % , MOD , % , MOD ) \ - \ - action( + , ADD , + , ADD ) \ - action( - , SUB , - , SUB ) \ - \ - action( <<, LSH , << , LSH ) \ - action( >>, RSH , >> , RSH ) \ - \ - BOOST_TEST_FOR_EACH_COMP_OP(action) \ - \ - action( & , BAND, & , BAND ) \ - action( ^ , XOR , ^ , XOR ) \ - action( | , BOR , | , BOR ) \ -/**/ - -#else - -#define BOOST_TEST_FOR_EACH_CONST_OP(action)\ - BOOST_TEST_FOR_EACH_COMP_OP(action) \ -/**/ - -#endif - -//____________________________________________________________________________// - -#define BOOST_TEST_FOR_EACH_MUT_OP(action) \ - action( = , SET , = , SET ) \ - action( +=, IADD, += , IADD ) \ - action( -=, ISUB, -= , ISUB ) \ - action( *=, IMUL, *= , IMUL ) \ - action( /=, IDIV, /= , IDIV ) \ - action( %=, IMOD, %= , IMOD ) \ - action(<<=, ILSH, <<=, ILSH ) \ - action(>>=, IRSH, >>=, IRSH ) \ - action( &=, IAND, &= , IAND ) \ - action( ^=, IXOR, ^= , IXOR ) \ - action( |=, IOR , |= , IOR ) \ -/**/ - -//____________________________________________________________________________// - -#ifndef BOOST_NO_CXX11_DECLTYPE -# define DEDUCE_RESULT_TYPE( oper ) \ - decltype(boost::declval<Lhs>() oper boost::declval<Rhs>() ) optype; \ - typedef typename boost::remove_reference<optype>::type \ -/**/ -#else -# define DEDUCE_RESULT_TYPE( oper ) bool -#endif - -#define DEFINE_CONST_OPER_FWD_DECL( oper, name, rev, name_inverse ) \ -template<typename Lhs, typename Rhs, \ - typename Enabler=void> \ -struct name; \ -/**/ - -BOOST_TEST_FOR_EACH_CONST_OP( DEFINE_CONST_OPER_FWD_DECL ) - -#define DEFINE_CONST_OPER( oper, name, rev, name_inverse ) \ -template<typename Lhs, typename Rhs, \ - typename Enabler> \ -struct name { \ - typedef DEDUCE_RESULT_TYPE( oper ) result_type; \ - typedef name_inverse<Lhs, Rhs> inverse; \ - \ - static result_type \ - eval( Lhs const& lhs, Rhs const& rhs ) \ - { \ - return lhs oper rhs; \ - } \ - \ - template<typename PrevExprType> \ - static void \ - report( std::ostream& ostr, \ - PrevExprType const& lhs, \ - Rhs const& rhs) \ - { \ - lhs.report( ostr ); \ - ostr << revert() \ - << tt_detail::print_helper( rhs ); \ - } \ - \ - static char const* forward() \ - { return " " #oper " "; } \ - static char const* revert() \ - { return " " #rev " "; } \ -}; \ -/**/ - -BOOST_TEST_FOR_EACH_CONST_OP( DEFINE_CONST_OPER ) - -#undef DEDUCE_RESULT_TYPE -#undef DEFINE_CONST_OPER - -//____________________________________________________________________________// - -} // namespace op - -// ************************************************************************** // -// ************** assertion::expression_base ************** // -// ************************************************************************** // -// Defines expression operators - -template<typename Lhs, typename Rhs, typename OP> class binary_expr; - -template<typename ExprType,typename ValType> -class expression_base { -public: - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - template<typename T> - struct RhsT : remove_const<typename remove_reference<T>::type> {}; - -#define ADD_OP_SUPPORT( oper, name, _, _i ) \ - template<typename T> \ - binary_expr<ExprType,T, \ - op::name<ValType,typename RhsT<T>::type> > \ - operator oper( T&& rhs ) \ - { \ - return binary_expr<ExprType,T, \ - op::name<ValType,typename RhsT<T>::type> > \ - ( std::forward<ExprType>( \ - *static_cast<ExprType*>(this) ), \ - std::forward<T>(rhs) ); \ - } \ -/**/ -#else - -#define ADD_OP_SUPPORT( oper, name, _, _i ) \ - template<typename T> \ - binary_expr<ExprType,typename boost::decay<T const>::type, \ - op::name<ValType,typename boost::decay<T const>::type> >\ - operator oper( T const& rhs ) const \ - { \ - typedef typename boost::decay<T const>::type Rhs; \ - return binary_expr<ExprType,Rhs,op::name<ValType,Rhs> > \ - ( *static_cast<ExprType const*>(this), \ - rhs ); \ - } \ -/**/ -#endif - - BOOST_TEST_FOR_EACH_CONST_OP( ADD_OP_SUPPORT ) - #undef ADD_OP_SUPPORT - -#ifndef BOOST_NO_CXX11_AUTO_DECLARATIONS - // Disabled operators - template<typename T> - ExprType& - operator ||( T const& /*rhs*/ ) - { - BOOST_MPL_ASSERT_MSG(false, CANT_USE_LOGICAL_OPERATOR_OR_WITHIN_THIS_TESTING_TOOL, () ); - - return *static_cast<ExprType*>(this); - } - - template<typename T> - ExprType& - operator &&( T const& /*rhs*/ ) - { - BOOST_MPL_ASSERT_MSG(false, CANT_USE_LOGICAL_OPERATOR_AND_WITHIN_THIS_TESTING_TOOL, () ); - - return *static_cast<ExprType*>(this); - } - - operator bool() - { - BOOST_MPL_ASSERT_MSG(false, CANT_USE_TERNARY_OPERATOR_WITHIN_THIS_TESTING_TOOL, () ); - - return false; - } -#endif -}; - -// ************************************************************************** // -// ************** assertion::value_expr ************** // -// ************************************************************************** // -// simple value expression - -template<typename T> -class value_expr : public expression_base<value_expr<T>,typename remove_const<typename remove_reference<T>::type>::type> { -public: - // Public types - typedef T result_type; - - // Constructor -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - value_expr( value_expr&& ve ) - : m_value( std::forward<T>(ve.m_value) ) - {} - explicit value_expr( T&& val ) - : m_value( std::forward<T>(val) ) - {} -#else - explicit value_expr( T const& val ) - : m_value( val ) - {} -#endif - - // Specific expression interface - T const& value() const - { - return m_value; - } - void report( std::ostream& ostr ) const - { - ostr << tt_detail::print_helper( value() ); - } - - // Mutating operators -#define ADD_OP_SUPPORT( OPER, ID, _, _i)\ - template<typename U> \ - value_expr<T>& \ - operator OPER( U const& rhs ) \ - { \ - m_value OPER rhs; \ - \ - return *this; \ - } \ -/**/ - - BOOST_TEST_FOR_EACH_MUT_OP( ADD_OP_SUPPORT ) -#undef ADD_OP_SUPPORT - - // expression interface - assertion_result evaluate( bool no_message = false ) const - { - assertion_result res( value() ); - if( no_message || res ) - return res; - - format_message( res.message(), value() ); - - return tt_detail::format_assertion_result( "", res.message().str() ); - } - -private: - template<typename U> - static void format_message( wrap_stringstream& ostr, U const& v ) - { - ostr << "['" << tt_detail::print_helper(v) << "' evaluates to false]"; - } - static void format_message( wrap_stringstream& /*ostr*/, bool /*v*/ ) {} - static void format_message( wrap_stringstream& /*ostr*/, assertion_result const& /*v*/ ) {} - - // Data members - T m_value; -}; - -// ************************************************************************** // -// ************** assertion::binary_expr ************** // -// ************************************************************************** // -// binary expression - -template<typename LExpr, typename Rhs, typename OP> -class binary_expr : public expression_base<binary_expr<LExpr,Rhs,OP>,typename OP::result_type> { -public: - // Public types - typedef typename OP::result_type result_type; - - // Constructor -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - binary_expr( binary_expr&& be ) - : m_lhs( std::forward<LExpr>(be.m_lhs) ) - , m_rhs( std::forward<Rhs>(be.m_rhs) ) - {} - binary_expr( LExpr&& lhs, Rhs&& rhs ) - : m_lhs( std::forward<LExpr>(lhs) ) - , m_rhs( std::forward<Rhs>(rhs) ) - {} -#else - binary_expr( LExpr const& lhs, Rhs const& rhs ) - : m_lhs( lhs ) - , m_rhs( rhs ) - {} -#endif - - // Specific expression interface - result_type value() const - { - return OP::eval( m_lhs.value(), m_rhs ); - } - void report( std::ostream& ostr ) const - { - return OP::report( ostr, m_lhs, m_rhs ); - } - - assertion_result evaluate( bool no_message = false ) const - { - assertion_result const expr_res( value() ); - if( no_message || expr_res ) - return expr_res; - - wrap_stringstream buff; - report( buff.stream() ); - - return tt_detail::format_assertion_result( buff.stream().str(), expr_res.message() ); - } - - // To support custom manipulators - LExpr const& lhs() const { return m_lhs; } - Rhs const& rhs() const { return m_rhs; } -private: - // Data members - LExpr m_lhs; - Rhs m_rhs; -}; - -// ************************************************************************** // -// ************** assertion::seed ************** // -// ************************************************************************** // -// seed added ot the input expression to form an assertion expression - -class seed { -public: - // ->* is highest precedence left to right operator - template<typename T> - value_expr<T> -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - operator->*( T&& v ) const - { - return value_expr<T>( std::forward<T>( v ) ); - } -#else - operator->*( T const& v ) const - { - return value_expr<T>( v ); - } -#endif -}; - -#undef BOOST_TEST_FOR_EACH_CONST_OP - -} // namespace assertion -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_ASSERTION_HPP_100911GER diff --git a/ThirdParty/boost/test/tools/collection_comparison_op.hpp b/ThirdParty/boost/test/tools/collection_comparison_op.hpp deleted file mode 100644 index 55d63301b3d72c64d55b656fa111df4632ee7edf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/collection_comparison_op.hpp +++ /dev/null @@ -1,458 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief Collection comparison with enhanced reporting -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_COLLECTION_COMPARISON_OP_HPP_050815GER -#define BOOST_TEST_TOOLS_COLLECTION_COMPARISON_OP_HPP_050815GER - -// Boost.Test -#include <boost/test/tools/assertion.hpp> - -#include <boost/test/utils/is_forward_iterable.hpp> -#include <boost/test/utils/is_cstring.hpp> - -// Boost -#include <boost/mpl/bool.hpp> -#include <boost/mpl/if.hpp> -#include <boost/utility/enable_if.hpp> -#include <boost/type_traits/decay.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace assertion { - -// ************************************************************************** // -// ************* selectors for specialized comparizon routines ************** // -// ************************************************************************** // - -template<typename T> -struct specialized_compare : public mpl::false_ {}; - -template <typename T> -struct is_c_array : public mpl::false_ {}; - -template<typename T, std::size_t N> -struct is_c_array<T [N]> : public mpl::true_ {}; - -template<typename T, std::size_t N> -struct is_c_array<T (&)[N]> : public mpl::true_ {}; - -#define BOOST_TEST_SPECIALIZED_COLLECTION_COMPARE(Col) \ -namespace boost { namespace test_tools { namespace assertion { \ -template<> \ -struct specialized_compare<Col> : public mpl::true_ {}; \ -}}} \ -/**/ - -// ************************************************************************** // -// ************** lexicographic_compare ************** // -// ************************************************************************** // - -namespace op { - -template <typename OP, bool can_be_equal, bool prefer_shorter, - typename Lhs, typename Rhs> -inline -typename boost::enable_if_c< - unit_test::is_forward_iterable<Lhs>::value && !unit_test::is_cstring<Lhs>::value - && unit_test::is_forward_iterable<Rhs>::value && !unit_test::is_cstring<Rhs>::value, - assertion_result>::type -lexicographic_compare( Lhs const& lhs, Rhs const& rhs ) -{ - assertion_result ar( true ); - - typedef unit_test::bt_iterator_traits<Lhs> t_Lhs_iterator; - typedef unit_test::bt_iterator_traits<Rhs> t_Rhs_iterator; - - typename t_Lhs_iterator::const_iterator first1 = t_Lhs_iterator::begin(lhs); - typename t_Rhs_iterator::const_iterator first2 = t_Rhs_iterator::begin(rhs); - typename t_Lhs_iterator::const_iterator last1 = t_Lhs_iterator::end(lhs); - typename t_Rhs_iterator::const_iterator last2 = t_Rhs_iterator::end(rhs); - std::size_t pos = 0; - - for( ; (first1 != last1) && (first2 != last2); ++first1, ++first2, ++pos ) { - assertion_result const& element_ar = OP::eval(*first1, *first2); - if( !can_be_equal && element_ar ) - return ar; // a < b - - assertion_result const& reverse_ar = OP::eval(*first2, *first1); - if( element_ar && !reverse_ar ) - return ar; // a<=b and !(b<=a) => a < b => return true - - if( element_ar || !reverse_ar ) { - continue; // (a<=b and b<=a) or (!(a<b) and !(b<a)) => a == b => keep looking - } - - // !(a<=b) and b<=a => b < a => return false - ar = false; - ar.message() << "\nFailure at position " << pos << ":"; - ar.message() << "\n - condition [" << tt_detail::print_helper(*first1) << OP::forward() << tt_detail::print_helper(*first2) << "] is false"; - if(!element_ar.has_empty_message()) - ar.message() << ": " << element_ar.message(); - ar.message() << "\n - inverse condition [" << tt_detail::print_helper(*first2) << OP::forward() << tt_detail::print_helper(*first1) << "] is true"; - if(!reverse_ar.has_empty_message()) - ar.message() << ": " << reverse_ar.message(); - return ar; - } - - if( first1 != last1 ) { - if( prefer_shorter ) { - ar = false; - ar.message() << "\nFirst collection has extra trailing elements."; - } - } - else if( first2 != last2 ) { - if( !prefer_shorter ) { - ar = false; - ar.message() << "\nSecond collection has extra trailing elements."; - } - } - else if( !can_be_equal ) { - ar = false; - ar.message() << "\nCollections appear to be equal."; - } - - return ar; -} - -template <typename OP, bool can_be_equal, bool prefer_shorter, - typename Lhs, typename Rhs> -inline -typename boost::enable_if_c< - (unit_test::is_cstring<Lhs>::value || unit_test::is_cstring<Rhs>::value), - assertion_result>::type -lexicographic_compare( Lhs const& lhs, Rhs const& rhs ) -{ - typedef typename unit_test::deduce_cstring_transform<Lhs>::type lhs_char_type; - typedef typename unit_test::deduce_cstring_transform<Rhs>::type rhs_char_type; - - return lexicographic_compare<OP, can_be_equal, prefer_shorter>( - lhs_char_type(lhs), - rhs_char_type(rhs)); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** equality_compare ************** // -// ************************************************************************** // - -template <typename OP, typename Lhs, typename Rhs> -inline -typename boost::enable_if_c< - unit_test::is_forward_iterable<Lhs>::value && !unit_test::is_cstring<Lhs>::value - && unit_test::is_forward_iterable<Rhs>::value && !unit_test::is_cstring<Rhs>::value, - assertion_result>::type -element_compare( Lhs const& lhs, Rhs const& rhs ) -{ - typedef unit_test::bt_iterator_traits<Lhs> t_Lhs_iterator; - typedef unit_test::bt_iterator_traits<Rhs> t_Rhs_iterator; - - assertion_result ar( true ); - - if( t_Lhs_iterator::size(lhs) != t_Rhs_iterator::size(rhs) ) { - ar = false; - ar.message() << "\nCollections size mismatch: " << t_Lhs_iterator::size(lhs) << " != " << t_Rhs_iterator::size(rhs); - return ar; - } - - typename t_Lhs_iterator::const_iterator left = t_Lhs_iterator::begin(lhs); - typename t_Rhs_iterator::const_iterator right = t_Rhs_iterator::begin(rhs); - std::size_t pos = 0; - - for( ; pos < t_Lhs_iterator::size(lhs); ++left, ++right, ++pos ) { - assertion_result const element_ar = OP::eval( *left, *right ); - if( element_ar ) - continue; - - ar = false; - ar.message() << "\n - mismatch at position " << pos << ": [" - << tt_detail::print_helper(*left) - << OP::forward() - << tt_detail::print_helper(*right) - << "] is false"; - if(!element_ar.has_empty_message()) - ar.message() << ": " << element_ar.message(); - } - - return ar; -} - -// In case string comparison is branching here -template <typename OP, typename Lhs, typename Rhs> -inline -typename boost::enable_if_c< - (unit_test::is_cstring<Lhs>::value || unit_test::is_cstring<Rhs>::value), - assertion_result>::type -element_compare( Lhs const& lhs, Rhs const& rhs ) -{ - typedef typename unit_test::deduce_cstring_transform<Lhs>::type lhs_char_type; - typedef typename unit_test::deduce_cstring_transform<Rhs>::type rhs_char_type; - - return element_compare<OP>(lhs_char_type(lhs), - rhs_char_type(rhs)); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** non_equality_compare ************** // -// ************************************************************************** // - -template <typename OP, typename Lhs, typename Rhs> -inline assertion_result -non_equality_compare( Lhs const& lhs, Rhs const& rhs ) -{ - typedef unit_test::bt_iterator_traits<Lhs> t_Lhs_iterator; - typedef unit_test::bt_iterator_traits<Rhs> t_Rhs_iterator; - - assertion_result ar( true ); - - if( t_Lhs_iterator::size(lhs) != t_Rhs_iterator::size(rhs) ) - return ar; - - typename t_Lhs_iterator::const_iterator left = t_Lhs_iterator::begin(lhs); - typename t_Rhs_iterator::const_iterator right = t_Rhs_iterator::begin(rhs); - typename t_Lhs_iterator::const_iterator end = t_Lhs_iterator::end(lhs); - - for( ; left != end; ++left, ++right ) { - if( OP::eval( *left, *right ) ) - return ar; - } - - ar = false; - ar.message() << "\nCollections appear to be equal"; - - return ar; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** cctraits ************** // -// ************************************************************************** // -// set of collection comparison traits per comparison OP - -template<typename OP> -struct cctraits; - -template<typename Lhs, typename Rhs> -struct cctraits<op::EQ<Lhs, Rhs> > { - typedef specialized_compare<Lhs> is_specialized; -}; - -template<typename Lhs, typename Rhs> -struct cctraits<op::NE<Lhs, Rhs> > { - typedef specialized_compare<Lhs> is_specialized; -}; - -template<typename Lhs, typename Rhs> -struct cctraits<op::LT<Lhs, Rhs> > { - static const bool can_be_equal = false; - static const bool prefer_short = true; - - typedef specialized_compare<Lhs> is_specialized; -}; - -template<typename Lhs, typename Rhs> -struct cctraits<op::LE<Lhs, Rhs> > { - static const bool can_be_equal = true; - static const bool prefer_short = true; - - typedef specialized_compare<Lhs> is_specialized; -}; - -template<typename Lhs, typename Rhs> -struct cctraits<op::GT<Lhs, Rhs> > { - static const bool can_be_equal = false; - static const bool prefer_short = false; - - typedef specialized_compare<Lhs> is_specialized; -}; - -template<typename Lhs, typename Rhs> -struct cctraits<op::GE<Lhs, Rhs> > { - static const bool can_be_equal = true; - static const bool prefer_short = false; - - typedef specialized_compare<Lhs> is_specialized; -}; - -// ************************************************************************** // -// ************** compare_collections ************** // -// ************************************************************************** // -// Overloaded set of functions dispatching to specific implementation of comparison - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::EQ<L, R> >*, mpl::true_ ) -{ - return assertion::op::element_compare<op::EQ<L, R> >( lhs, rhs ); -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::EQ<L, R> >*, mpl::false_ ) -{ - return lhs == rhs; -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::NE<L, R> >*, mpl::true_ ) -{ - return assertion::op::non_equality_compare<op::NE<L, R> >( lhs, rhs ); -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::NE<L, R> >*, mpl::false_ ) -{ - return lhs != rhs; -} - -//____________________________________________________________________________// - -template <typename OP, typename Lhs, typename Rhs> -inline assertion_result -lexicographic_compare( Lhs const& lhs, Rhs const& rhs ) -{ - return assertion::op::lexicographic_compare<OP, cctraits<OP>::can_be_equal, cctraits<OP>::prefer_short>( lhs, rhs ); -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename OP> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<OP>*, mpl::true_ ) -{ - return lexicographic_compare<OP>( lhs, rhs ); -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::LT<L, R> >*, mpl::false_ ) -{ - return lhs < rhs; -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::LE<L, R> >*, mpl::false_ ) -{ - return lhs <= rhs; -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::GT<L, R> >*, mpl::false_ ) -{ - return lhs > rhs; -} - -//____________________________________________________________________________// - -template <typename Lhs, typename Rhs, typename L, typename R> -inline assertion_result -compare_collections( Lhs const& lhs, Rhs const& rhs, boost::type<op::GE<L, R> >*, mpl::false_ ) -{ - return lhs >= rhs; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ********* specialization of comparison operators for collections ********* // -// ************************************************************************** // - -#define DEFINE_COLLECTION_COMPARISON( oper, name, rev, name_inverse ) \ -template<typename Lhs,typename Rhs> \ -struct name<Lhs,Rhs,typename boost::enable_if_c< \ - unit_test::is_forward_iterable<Lhs>::value \ - && !unit_test::is_cstring_comparable<Lhs>::value \ - && unit_test::is_forward_iterable<Rhs>::value \ - && !unit_test::is_cstring_comparable<Rhs>::value>::type> { \ -public: \ - typedef assertion_result result_type; \ - typedef name_inverse<Lhs, Rhs> inverse; \ - typedef unit_test::bt_iterator_traits<Lhs> t_Lhs_iterator_helper; \ - typedef unit_test::bt_iterator_traits<Rhs> t_Rhs_iterator_helper; \ - \ - typedef name<Lhs, Rhs> OP; \ - \ - typedef typename \ - mpl::if_c< \ - mpl::or_< \ - typename is_c_array<Lhs>::type, \ - typename is_c_array<Rhs>::type \ - >::value, \ - mpl::true_, \ - typename \ - mpl::if_c<is_same<typename decay<Lhs>::type, \ - typename decay<Rhs>::type>::value, \ - typename cctraits<OP>::is_specialized, \ - mpl::false_>::type \ - >::type is_specialized; \ - \ - typedef name<typename t_Lhs_iterator_helper::value_type, \ - typename t_Rhs_iterator_helper::value_type \ - > elem_op; \ - \ - static assertion_result \ - eval( Lhs const& lhs, Rhs const& rhs) \ - { \ - return assertion::op::compare_collections( lhs, rhs, \ - (boost::type<elem_op>*)0, \ - is_specialized() ); \ - } \ - \ - template<typename PrevExprType> \ - static void \ - report( std::ostream&, \ - PrevExprType const&, \ - Rhs const& ) {} \ - \ - static char const* forward() \ - { return " " #oper " "; } \ - static char const* revert() \ - { return " " #rev " "; } \ - \ -}; \ -/**/ - -BOOST_TEST_FOR_EACH_COMP_OP( DEFINE_COLLECTION_COMPARISON ) -#undef DEFINE_COLLECTION_COMPARISON - -//____________________________________________________________________________// - -} // namespace op -} // namespace assertion -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_COLLECTION_COMPARISON_OP_HPP_050815GER diff --git a/ThirdParty/boost/test/tools/cstring_comparison_op.hpp b/ThirdParty/boost/test/tools/cstring_comparison_op.hpp deleted file mode 100644 index 04b38561ee6f91c89faa100c7c478b80a781f2f9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/cstring_comparison_op.hpp +++ /dev/null @@ -1,91 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief C string comparison with enhanced reporting -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_CSTRING_COMPARISON_OP_HPP_050815GER -#define BOOST_TEST_TOOLS_CSTRING_COMPARISON_OP_HPP_050815GER - -// Boost.Test -#include <boost/test/tools/assertion.hpp> - -#include <boost/test/utils/is_cstring.hpp> -#include <boost/test/utils/basic_cstring/compare.hpp> - -// Boost -#include <boost/utility/enable_if.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace assertion { -namespace op { - -// ************************************************************************** // -// ************** string_compare ************** // -// ************************************************************************** // - -#define DEFINE_CSTRING_COMPARISON( oper, name, rev, name_inverse ) \ -template<typename Lhs,typename Rhs> \ -struct name<Lhs,Rhs,typename boost::enable_if_c< \ - ( unit_test::is_cstring_comparable<Lhs>::value \ - && unit_test::is_cstring_comparable<Rhs>::value) \ - >::type > \ -{ \ - typedef typename unit_test::deduce_cstring_transform<Lhs>::type lhs_char_type; \ - typedef typename unit_test::deduce_cstring_transform<Rhs>::type rhs_char_type; \ -public: \ - typedef assertion_result result_type; \ - typedef name_inverse<Lhs, Rhs> inverse; \ - \ - typedef name< \ - typename lhs_char_type::value_type, \ - typename rhs_char_type::value_type> elem_op; \ - \ - static bool \ - eval( Lhs const& lhs, Rhs const& rhs) \ - { \ - return lhs_char_type(lhs) oper rhs_char_type(rhs); \ - } \ - \ - template<typename PrevExprType> \ - static void \ - report( std::ostream& ostr, \ - PrevExprType const& lhs, \ - Rhs const& rhs) \ - { \ - lhs.report( ostr ); \ - ostr << revert() \ - << tt_detail::print_helper( rhs ); \ - } \ - \ - static char const* forward() \ - { return " " #oper " "; } \ - static char const* revert() \ - { return " " #rev " "; } \ -}; \ -/**/ - -BOOST_TEST_FOR_EACH_COMP_OP( DEFINE_CSTRING_COMPARISON ) -#undef DEFINE_CSTRING_COMPARISON - -//____________________________________________________________________________// - -} // namespace op -} // namespace assertion -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_CSTRING_COMPARISON_OP_HPP_050815GER - diff --git a/ThirdParty/boost/test/tools/detail/bitwise_manip.hpp b/ThirdParty/boost/test/tools/detail/bitwise_manip.hpp deleted file mode 100644 index 329a893a9a7b781171bfb450cf7362cf8050867b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/detail/bitwise_manip.hpp +++ /dev/null @@ -1,129 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! Bitwise comparison manipulator implementation -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_DETAIL_BITWISE_MANIP_HPP_012705GER -#define BOOST_TEST_TOOLS_DETAIL_BITWISE_MANIP_HPP_012705GER - -// Boost Test -#include <boost/test/tools/detail/fwd.hpp> -#include <boost/test/tools/detail/indirections.hpp> - -#include <boost/test/tools/assertion_result.hpp> -#include <boost/test/tools/assertion.hpp> - -// STL -#include <climits> // for CHAR_BIT - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { - -// ************************************************************************** // -// ************** bitwise comparison manipulator ************** // -// ************************************************************************** // - -//! Bitwise comparison manipulator -//! This is a terminal for the expression -struct bitwise {}; - -//____________________________________________________________________________// - -inline unit_test::lazy_ostream & -operator<<( unit_test::lazy_ostream &o, bitwise ) { return o; } - -// needed for the lazy evaluation in lazy_ostream as bitwise is a terminal -inline std::ostream& -operator<<( std::ostream& o, bitwise ) { return o; } - - -//____________________________________________________________________________// - -namespace tt_detail { - -/*!@brief Bitwise comparison of two operands - * - * This class constructs an @ref assertion_result that contains precise bit comparison information. - * In particular the location of the mismatches (if any) are printed in the assertion result. - */ -template<typename Lhs, typename Rhs, typename E> -inline assertion_result -bitwise_compare(Lhs const& lhs, Rhs const& rhs, E const& expr ) -{ - assertion_result pr( true ); - - std::size_t left_bit_size = sizeof(Lhs)*CHAR_BIT; - std::size_t right_bit_size = sizeof(Rhs)*CHAR_BIT; - - static Lhs const leftOne( 1 ); - static Rhs const rightOne( 1 ); - - std::size_t total_bits = left_bit_size < right_bit_size ? left_bit_size : right_bit_size; - - for( std::size_t counter = 0; counter < total_bits; ++counter ) { - if( (lhs & ( leftOne << counter )) != (rhs & (rightOne << counter)) ) { - if( pr ) { - pr.message() << " ["; - expr.report( pr.message().stream() ); - pr.message() << "]. Bitwise comparison failed"; - pr = false; - } - pr.message() << "\nMismatch at position " << counter; - } - } - - if( left_bit_size != right_bit_size ) { - if( pr ) { - pr.message() << " ["; - expr.report( pr.message().stream() ); - pr.message() << "]. Bitwise comparison failed"; - pr = false; - } - pr.message() << "\nOperands bit sizes mismatch: " << left_bit_size << " != " << right_bit_size; - } - - return pr; -} - -//____________________________________________________________________________// - -//! Returns an assertion_result using the bitwise comparison out of an expression -//! -//! This is used as a modifer of the normal operator<< on expressions to use the -//! bitwise comparison. -//! -//! @note Available only for compilers supporting the @c auto declaration. -template<typename T1, typename T2, typename T3, typename T4> -inline assertion_result -operator<<(assertion_evaluate_t<assertion::binary_expr<T1,T2,assertion::op::EQ<T3,T4> > > const& ae, bitwise ) -{ - return bitwise_compare( ae.m_e.lhs().value(), ae.m_e.rhs(), ae.m_e ); -} - -//____________________________________________________________________________// - -inline assertion_type -operator<<( assertion_type const& , bitwise ) -{ - return assertion_type(CHECK_BUILT_ASSERTION); -} - -//____________________________________________________________________________// - -} // namespace tt_detail -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_DETAIL_BITWISE_MANIP_HPP_012705GER diff --git a/ThirdParty/boost/test/tools/detail/indirections.hpp b/ThirdParty/boost/test/tools/detail/indirections.hpp deleted file mode 100644 index 2622f2a6538da3804d043d8ee171a928be1ae569..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/detail/indirections.hpp +++ /dev/null @@ -1,125 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision: 74248 $ -// -// Description : inidiration interfaces to support manipulators and message output -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_DETAIL_INDIRECTIONS_HPP_112812GER -#define BOOST_TEST_TOOLS_DETAIL_INDIRECTIONS_HPP_112812GER - -// Boost.Test -#include <boost/test/tools/detail/fwd.hpp> - -#include <boost/test/tools/assertion_result.hpp> -#include <boost/test/utils/lazy_ostream.hpp> - -#include <boost/shared_ptr.hpp> -#include <list> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace tt_detail { - -struct assertion_evaluation_context -{ - assertion_evaluation_context(bool has_report = false) - : m_has_report(has_report) - {} - - bool m_has_report; -}; - -// ************************************************************************** // -// ************** assertion_evaluate indirection ************** // -// ************************************************************************** // - -template<typename E> -struct assertion_evaluate_t { - - typedef shared_ptr<assertion_evaluation_context> context_holder; - - assertion_evaluate_t( E const& e ) : m_e( e ), m_evaluate( true ) - {} - - operator assertion_result() { return m_e.evaluate( m_evaluate ); } - - assertion_evaluate_t<E> - stack_context(context_holder context) const { - assertion_evaluate_t<E> added_context(*this); - - added_context.m_context_holder.push_back(context); - added_context.m_evaluate = !context->m_has_report; - return added_context; - } - - E const& m_e; - std::list< context_holder > m_context_holder; - bool m_evaluate; -}; - -//____________________________________________________________________________// - -template<typename E> -inline assertion_evaluate_t<E> -assertion_evaluate( E const& e ) { return assertion_evaluate_t<E>( e ); } - -//____________________________________________________________________________// - -template<typename E, typename T> -inline assertion_evaluate_t<E> -operator<<( assertion_evaluate_t<E> const& ae, T const& ) { return ae; } - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** assertion_text indirection ************** // -// ************************************************************************** // - -inline unit_test::lazy_ostream const& -assertion_text( unit_test::lazy_ostream const& et, unit_test::lazy_ostream const& s) { - if(!s.empty()) - return s; - return et; -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** assertion_evaluate indirection ************** // -// ************************************************************************** // - -struct assertion_type { - assertion_type(check_type ct = CHECK_MSG) : m_check_type(ct) - {} - - operator check_type() { return m_check_type; } - check_type m_check_type; -}; - -//____________________________________________________________________________// - -template<typename T> -inline assertion_type -operator<<( assertion_type const& at, T const& ) { return at; } - -//____________________________________________________________________________// - -} // namespace tt_detail -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_DETAIL_INDIRECTIONS_HPP_112812GER diff --git a/ThirdParty/boost/test/tools/detail/lexicographic_manip.hpp b/ThirdParty/boost/test/tools/detail/lexicographic_manip.hpp deleted file mode 100644 index 30a49c09275fa9ec400ae45f2fea521ad9ff38c2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/detail/lexicographic_manip.hpp +++ /dev/null @@ -1,77 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! Lexicographic comparison manipulator implementation -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_DETAIL_LEXICOGRAPHIC_MANIP_HPP_050815GER -#define BOOST_TEST_TOOLS_DETAIL_LEXICOGRAPHIC_MANIP_HPP_050815GER - -// Boost Test -#include <boost/test/tools/detail/fwd.hpp> -#include <boost/test/tools/detail/indirections.hpp> - -#include <boost/test/tools/assertion.hpp> -#include <boost/test/utils/lazy_ostream.hpp> -#include <boost/test/tools/collection_comparison_op.hpp> - -#include <ostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { - -// ************************************************************************** // -// ************** per element comparison manipulator ************** // -// ************************************************************************** // - -//! Lexicographic comparison manipulator, for containers -//! This is a terminal that involves evaluation of the expression -struct lexicographic {}; - -//____________________________________________________________________________// - -inline unit_test::lazy_ostream& -operator<<( unit_test::lazy_ostream & o, lexicographic ) { return o; } - -// needed for the lazy evaluation in lazy_ostream as lexicographic is a terminal -inline std::ostream& -operator<<( std::ostream& o, lexicographic ) { return o; } - -//____________________________________________________________________________// - -namespace tt_detail { - -template<typename T1, typename T2, typename OP> -inline assertion_result -operator<<(assertion_evaluate_t<assertion::binary_expr<T1,T2,OP> > const& ae, lexicographic ) -{ - typedef typename OP::elem_op elem_op; - return assertion::op::lexicographic_compare<elem_op>( ae.m_e.lhs().value(), ae.m_e.rhs() ); -} - -//____________________________________________________________________________// - -inline assertion_type -operator<<( assertion_type const&, lexicographic ) -{ - return assertion_type(CHECK_BUILT_ASSERTION); -} - -//____________________________________________________________________________// - -} // namespace tt_detail -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_DETAIL_LEXICOGRAPHIC_MANIP_HPP_050815GER diff --git a/ThirdParty/boost/test/tools/detail/per_element_manip.hpp b/ThirdParty/boost/test/tools/detail/per_element_manip.hpp deleted file mode 100644 index 98b5703685279aad0b24a5a3c05d32f732d1dfc6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/detail/per_element_manip.hpp +++ /dev/null @@ -1,77 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! Per element comparison manipulator implementation -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_DETAIL_PER_ELEMENT_MANIP_HPP_050815GER -#define BOOST_TEST_TOOLS_DETAIL_PER_ELEMENT_MANIP_HPP_050815GER - -// Boost Test -#include <boost/test/tools/detail/fwd.hpp> -#include <boost/test/tools/detail/indirections.hpp> - -#include <boost/test/utils/lazy_ostream.hpp> -#include <boost/test/tools/assertion.hpp> -#include <boost/test/tools/collection_comparison_op.hpp> - -#include <ostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { - -// ************************************************************************** // -// ************** per element comparison manipulator ************** // -// ************************************************************************** // - -//! Per element comparison manipulator, for containers -//! This is a terminal that involves evaluation of the expression -struct per_element {}; - -//____________________________________________________________________________// - -inline unit_test::lazy_ostream& -operator<<( unit_test::lazy_ostream &o, per_element ) { return o; } - -// needed for the lazy evaluation in lazy_ostream as per_element is a terminal -inline std::ostream& -operator<<( std::ostream& o, per_element ) { return o; } - -//____________________________________________________________________________// - -namespace tt_detail { - -template<typename T1, typename T2, typename OP> -inline assertion_result -operator<<(assertion_evaluate_t<assertion::binary_expr<T1,T2,OP> > const& ae, per_element ) -{ - typedef typename OP::elem_op elem_op; - return assertion::op::element_compare<elem_op>( ae.m_e.lhs().value(), ae.m_e.rhs() ); -} - -//____________________________________________________________________________// - -inline assertion_type -operator<<( assertion_type const&, per_element ) -{ - return assertion_type(CHECK_BUILT_ASSERTION); -} - -//____________________________________________________________________________// - -} // namespace tt_detail -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_DETAIL_PER_ELEMENT_MANIP_HPP_050815GER diff --git a/ThirdParty/boost/test/tools/detail/tolerance_manip.hpp b/ThirdParty/boost/test/tools/detail/tolerance_manip.hpp deleted file mode 100644 index af945cf704ae81128952aa935c4954c452fa7077..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/detail/tolerance_manip.hpp +++ /dev/null @@ -1,154 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! @brief Floating point comparison tolerance manipulators -//! -//! This file defines several manipulators for floating point comparison. These -//! manipulators are intended to be used with BOOST_TEST. -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_DETAIL_TOLERANCE_MANIP_HPP_012705GER -#define BOOST_TEST_TOOLS_DETAIL_TOLERANCE_MANIP_HPP_012705GER - -// Boost Test -#include <boost/test/tools/detail/fwd.hpp> -#include <boost/test/tools/detail/indirections.hpp> - -#include <boost/test/utils/lazy_ostream.hpp> -#include <boost/test/tools/fpc_tolerance.hpp> -#include <boost/test/tools/floating_point_comparison.hpp> - -#include <ostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace tt_detail { - -// ************************************************************************** // -// ************** fpc tolerance manipulator ************** // -// ************************************************************************** // - -//! Tolerance manipulator, not to be used directly -//! This is not a terminal of the expression -template<typename FPT> -struct tolerance_manip { - explicit tolerance_manip( FPT const & tol ) : m_value( tol ) {} - - FPT m_value; -}; - -//____________________________________________________________________________// - -struct tolerance_manip_delay {}; - -template<typename FPT> -inline tolerance_manip<FPT> -operator%( FPT v, tolerance_manip_delay const& ) -{ - BOOST_STATIC_ASSERT_MSG( (fpc::tolerance_based<FPT>::value), - "tolerance should be specified using a floating points type" ); - - return tolerance_manip<FPT>( FPT(v / 100) ); -} - -template <typename FPT> -struct tolerance_evaluation_context: assertion_evaluation_context { - tolerance_evaluation_context(FPT tol) - : assertion_evaluation_context( true ) // has report - , m_tolerance_context(tol) - {} - - local_fpc_tolerance<FPT> m_tolerance_context; -}; - -//____________________________________________________________________________// - -template<typename E, typename FPT> -inline assertion_evaluate_t<E> -operator<<(assertion_evaluate_t<E> const& ae, tolerance_manip<FPT> const& tol) -{ - return ae.stack_context( - typename assertion_evaluate_t<E>::context_holder( - new tolerance_evaluation_context<FPT>( tol.m_value )) - ); -} - -//____________________________________________________________________________// - -template<typename FPT> -unit_test::lazy_ostream & -operator<<( unit_test::lazy_ostream &o, tolerance_manip<FPT> const& ) { return o; } - -// needed for the lazy evaluation in lazy_ostream as for commutativity with other arguments -template<typename FPT> -std::ostream& -operator<<( std::ostream& o, tolerance_manip<FPT> const& ) { return o; } - - -//____________________________________________________________________________// - -template<typename FPT> -inline assertion_type -operator<<( assertion_type const& /*at*/, tolerance_manip<FPT> const& ) { - return assertion_type(CHECK_BUILT_ASSERTION); -} - -//____________________________________________________________________________// - -} // namespace tt_detail - - -/*! Tolerance manipulator - * - * These functions return a manipulator that can be used in conjunction with BOOST_TEST - * in order to specify the tolerance with which floating point comparisons are made. - */ -template<typename FPT> -inline tt_detail::tolerance_manip<FPT> -tolerance( FPT v ) -{ - BOOST_STATIC_ASSERT_MSG( (fpc::tolerance_based<FPT>::value), - "tolerance only for floating points" ); - - return tt_detail::tolerance_manip<FPT>( v ); -} - -//____________________________________________________________________________// - -//! @overload tolerance( FPT v ) -template<typename FPT> -inline tt_detail::tolerance_manip<FPT> -tolerance( fpc::percent_tolerance_t<FPT> v ) -{ - BOOST_STATIC_ASSERT_MSG( (fpc::tolerance_based<FPT>::value), - "tolerance only for floating points" ); - - return tt_detail::tolerance_manip<FPT>( static_cast<FPT>(v.m_value / 100) ); -} - -//____________________________________________________________________________// - -//! @overload tolerance( FPT v ) -inline tt_detail::tolerance_manip_delay -tolerance() -{ - return tt_detail::tolerance_manip_delay(); -} - -//____________________________________________________________________________// - -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_DETAIL_TOLERANCE_MANIP_HPP_012705GER diff --git a/ThirdParty/boost/test/tools/floating_point_comparison.hpp b/ThirdParty/boost/test/tools/floating_point_comparison.hpp deleted file mode 100644 index 1364fde8b81761db3e4c32bd3c2d82f48082a6b9..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/floating_point_comparison.hpp +++ /dev/null @@ -1,336 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief algorithms for comparing floating point values -// *************************************************************************** - -#ifndef BOOST_TEST_FLOATING_POINT_COMPARISON_HPP_071894GER -#define BOOST_TEST_FLOATING_POINT_COMPARISON_HPP_071894GER - -// Boost.Test -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/tools/assertion_result.hpp> - -// Boost -#include <boost/limits.hpp> // for std::numeric_limits -#include <boost/static_assert.hpp> -#include <boost/assert.hpp> -#include <boost/mpl/bool.hpp> -#include <boost/type_traits/is_floating_point.hpp> -#include <boost/type_traits/is_array.hpp> -#include <boost/type_traits/is_reference.hpp> -#include <boost/type_traits/is_void.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/utility/enable_if.hpp> - -// STL -#include <iosfwd> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace math { -namespace fpc { - -// ************************************************************************** // -// ************** fpc::tolerance_based ************** // -// ************************************************************************** // - - -//! @internal -//! Protects the instanciation of std::numeric_limits from non-supported types (eg. T=array) -template <typename T, bool enabled> -struct tolerance_based_delegate; - -template <typename T> -struct tolerance_based_delegate<T, false> : mpl::false_ {}; - -// from https://stackoverflow.com/a/16509511/1617295 -template<typename T> -class is_abstract_class_or_function -{ - typedef char (&Two)[2]; - template<typename U> static char test(U(*)[1]); - template<typename U> static Two test(...); - -public: - static const bool value = - !is_reference<T>::value - && !is_void<T>::value - && (sizeof(test<T>(0)) == sizeof(Two)); -}; - -// warning: we cannot instanciate std::numeric_limits for incomplete types, we use is_abstract_class_or_function -// prior to the specialization below -template <typename T> -struct tolerance_based_delegate<T, true> -: mpl::bool_< - is_floating_point<T>::value || - (!std::numeric_limits<T>::is_integer && std::numeric_limits<T>::is_specialized && !std::numeric_limits<T>::is_exact)> -{}; - - -/*!@brief Indicates if a type can be compared using a tolerance scheme - * - * This is a metafunction that should evaluate to @c mpl::true_ if the type - * @c T can be compared using a tolerance based method, typically for floating point - * types. - * - * This metafunction can be specialized further to declare user types that are - * floating point (eg. boost.multiprecision). - */ -template <typename T> -struct tolerance_based : tolerance_based_delegate<T, !is_array<T>::value && !is_abstract_class_or_function<T>::value>::type {}; - -// ************************************************************************** // -// ************** fpc::strength ************** // -// ************************************************************************** // - -//! Method for comparing floating point numbers -enum strength { - FPC_STRONG, //!< "Very close" - equation 2' in docs, the default - FPC_WEAK //!< "Close enough" - equation 3' in docs. -}; - - -// ************************************************************************** // -// ************** tolerance presentation types ************** // -// ************************************************************************** // - -template<typename FPT> -struct percent_tolerance_t { - explicit percent_tolerance_t( FPT v ) : m_value( v ) {} - - FPT m_value; -}; - -//____________________________________________________________________________// - -template<typename FPT> -inline std::ostream& operator<<( std::ostream& out, percent_tolerance_t<FPT> t ) -{ - return out << t.m_value; -} - -//____________________________________________________________________________// - -template<typename FPT> -inline percent_tolerance_t<FPT> -percent_tolerance( FPT v ) -{ - return percent_tolerance_t<FPT>( v ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** details ************** // -// ************************************************************************** // - -namespace fpc_detail { - -// FPT is Floating-Point Type: float, double, long double or User-Defined. -template<typename FPT> -inline FPT -fpt_abs( FPT fpv ) -{ - return fpv < static_cast<FPT>(0) ? -fpv : fpv; -} - -//____________________________________________________________________________// - -template<typename FPT> -struct fpt_specialized_limits -{ - static FPT min_value() { return (std::numeric_limits<FPT>::min)(); } - static FPT max_value() { return (std::numeric_limits<FPT>::max)(); } -}; - -template<typename FPT> -struct fpt_non_specialized_limits -{ - static FPT min_value() { return static_cast<FPT>(0); } - static FPT max_value() { return static_cast<FPT>(1000000); } // for our purposes it doesn't really matter what value is returned here -}; - -template<typename FPT> -struct fpt_limits : boost::conditional<std::numeric_limits<FPT>::is_specialized, - fpt_specialized_limits<FPT>, - fpt_non_specialized_limits<FPT> - >::type -{}; - -//____________________________________________________________________________// - -// both f1 and f2 are unsigned here -template<typename FPT> -inline FPT -safe_fpt_division( FPT f1, FPT f2 ) -{ - // Avoid overflow. - if( (f2 < static_cast<FPT>(1)) && (f1 > f2*fpt_limits<FPT>::max_value()) ) - return fpt_limits<FPT>::max_value(); - - // Avoid underflow. - if( (fpt_abs(f1) <= fpt_limits<FPT>::min_value()) || - ((f2 > static_cast<FPT>(1)) && (f1 < f2*fpt_limits<FPT>::min_value())) ) - return static_cast<FPT>(0); - - return f1/f2; -} - -//____________________________________________________________________________// - -template<typename FPT, typename ToleranceType> -inline FPT -fraction_tolerance( ToleranceType tolerance ) -{ - return static_cast<FPT>(tolerance); -} - -//____________________________________________________________________________// - -template<typename FPT2, typename FPT> -inline FPT2 -fraction_tolerance( percent_tolerance_t<FPT> tolerance ) -{ - return FPT2(tolerance.m_value)*FPT2(0.01); -} - -//____________________________________________________________________________// - -} // namespace fpc_detail - -// ************************************************************************** // -// ************** close_at_tolerance ************** // -// ************************************************************************** // - - -/*!@brief Predicate for comparing floating point numbers - * - * This predicate is used to compare floating point numbers. In addition the comparison produces maximum - * related difference, which can be used to generate detailed error message - * The methods for comparing floating points are detailed in the documentation. The method is chosen - * by the @ref boost::math::fpc::strength given at construction. - * - * This predicate is not suitable for comparing to 0 or to infinity. - */ -template<typename FPT> -class close_at_tolerance { -public: - // Public typedefs - typedef bool result_type; - - // Constructor - template<typename ToleranceType> - explicit close_at_tolerance( ToleranceType tolerance, fpc::strength fpc_strength = FPC_STRONG ) - : m_fraction_tolerance( fpc_detail::fraction_tolerance<FPT>( tolerance ) ) - , m_strength( fpc_strength ) - , m_tested_rel_diff( 0 ) - { - BOOST_ASSERT_MSG( m_fraction_tolerance >= FPT(0), "tolerance must not be negative!" ); // no reason for tolerance to be negative - } - - // Access methods - //! Returns the tolerance - FPT fraction_tolerance() const { return m_fraction_tolerance; } - - //! Returns the comparison method - fpc::strength strength() const { return m_strength; } - - //! Returns the failing fraction - FPT tested_rel_diff() const { return m_tested_rel_diff; } - - /*! Compares two floating point numbers a and b such that their "left" relative difference |a-b|/a and/or - * "right" relative difference |a-b|/b does not exceed specified relative (fraction) tolerance. - * - * @param[in] left first floating point number to be compared - * @param[in] right second floating point number to be compared - * - * What is reported by @c tested_rel_diff in case of failure depends on the comparison method: - * - for @c FPC_STRONG: the max of the two fractions - * - for @c FPC_WEAK: the min of the two fractions - * The rationale behind is to report the tolerance to set in order to make a test pass. - */ - bool operator()( FPT left, FPT right ) const - { - FPT diff = fpc_detail::fpt_abs<FPT>( left - right ); - FPT fraction_of_right = fpc_detail::safe_fpt_division( diff, fpc_detail::fpt_abs( right ) ); - FPT fraction_of_left = fpc_detail::safe_fpt_division( diff, fpc_detail::fpt_abs( left ) ); - - FPT max_rel_diff = (std::max)( fraction_of_left, fraction_of_right ); - FPT min_rel_diff = (std::min)( fraction_of_left, fraction_of_right ); - - m_tested_rel_diff = m_strength == FPC_STRONG ? max_rel_diff : min_rel_diff; - - return m_tested_rel_diff <= m_fraction_tolerance; - } - -private: - // Data members - FPT m_fraction_tolerance; - fpc::strength m_strength; - mutable FPT m_tested_rel_diff; -}; - -// ************************************************************************** // -// ************** small_with_tolerance ************** // -// ************************************************************************** // - - -/*!@brief Predicate for comparing floating point numbers against 0 - * - * Serves the same purpose as boost::math::fpc::close_at_tolerance, but used when one - * of the operand is null. - */ -template<typename FPT> -class small_with_tolerance { -public: - // Public typedefs - typedef bool result_type; - - // Constructor - explicit small_with_tolerance( FPT tolerance ) // <= absolute tolerance - : m_tolerance( tolerance ) - { - BOOST_ASSERT( m_tolerance >= FPT(0) ); // no reason for the tolerance to be negative - } - - // Action method - bool operator()( FPT fpv ) const - { - return fpc::fpc_detail::fpt_abs( fpv ) <= m_tolerance; - } - -private: - // Data members - FPT m_tolerance; -}; - -// ************************************************************************** // -// ************** is_small ************** // -// ************************************************************************** // - -template<typename FPT> -inline bool -is_small( FPT fpv, FPT tolerance ) -{ - return small_with_tolerance<FPT>( tolerance )( fpv ); -} - -//____________________________________________________________________________// - -} // namespace fpc -} // namespace math -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_FLOATING_POINT_COMAPARISON_HPP_071894GER diff --git a/ThirdParty/boost/test/tools/fpc_op.hpp b/ThirdParty/boost/test/tools/fpc_op.hpp deleted file mode 100644 index 22bfeaa31d7d312b9f94e8f8ff43bb89c0faab28..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/fpc_op.hpp +++ /dev/null @@ -1,244 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief Floating point comparison with enhanced reporting -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_FPC_OP_HPP_050915GER -#define BOOST_TEST_TOOLS_FPC_OP_HPP_050915GER - -// Boost.Test -#include <boost/test/tools/assertion.hpp> - -#include <boost/test/tools/floating_point_comparison.hpp> -#include <boost/test/tools/fpc_tolerance.hpp> - -// Boost -#include <boost/type_traits/common_type.hpp> -#include <boost/type_traits/is_arithmetic.hpp> -#include <boost/utility/enable_if.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace test_tools { -namespace assertion { -namespace op { - -// ************************************************************************** // -// ************** fpctraits ************** // -// ************************************************************************** // -// set of floating point comparison traits per comparison OP - -template<typename OP> -struct fpctraits { - // indicate if we should perform the operation with a "logical OR" - // with the "equality under tolerance". - static const bool equality_logical_disjunction = true; -}; - -template <typename Lhs, typename Rhs> -struct fpctraits<op::LT<Lhs,Rhs> > { - static const bool equality_logical_disjunction = false; -}; - -template <typename Lhs, typename Rhs> -struct fpctraits<op::GT<Lhs,Rhs> > { - static const bool equality_logical_disjunction = false; -}; - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** set of overloads to select correct fpc algo ************** // -// ************************************************************************** // -// we really only care about EQ vs NE. All other comparisons use direct first -// and then need EQ. For example a <= b (tolerance t) IFF a <= b OR a == b (tolerance t) - -template <typename FPT, typename Lhs, typename Rhs, typename OP> -inline assertion_result -compare_fpv( Lhs const& lhs, Rhs const& rhs, OP* cmp_operator) -{ - assertion_result result_direct_compare = cmp_operator->eval_direct(lhs, rhs); - if(fpctraits<OP>::equality_logical_disjunction) { - // this look like this can be simplified, but combining result && compare_fpv - // looses the message in the return value of compare_fpv - if( result_direct_compare ) { - result_direct_compare.message() << "operation" << OP::forward() << "on arguments yields 'true'."; - return result_direct_compare; - } - // result || compare_fpv(EQ) - assertion_result result_eq = compare_fpv<FPT>(lhs, rhs, (op::EQ<Lhs, Rhs>*)0); - result_direct_compare = result_direct_compare || result_eq; - if( !result_eq ) { - result_direct_compare.message() << "operation" << op::EQ<Lhs, Rhs>::forward() << "on arguments yields 'false': " << result_eq.message() << "."; - } - return result_direct_compare; - } - if( !result_direct_compare ) { - result_direct_compare.message() << "operation" << OP::forward() << " on arguments yields 'false'."; - return result_direct_compare; - } - // result && compare_fpv(NE) - assertion_result result_neq = compare_fpv<FPT>(lhs, rhs, (op::NE<Lhs, Rhs>*)0); - result_direct_compare = result_direct_compare && result_neq; - if( !result_neq ) { - result_direct_compare.message() << "operation" << op::NE<Lhs, Rhs>::forward() << "on arguments yields 'false': " << result_neq.message() << "."; - } - return result_direct_compare; -} - -//____________________________________________________________________________// - -template <typename FPT, typename Lhs, typename Rhs> -inline assertion_result -compare_fpv_near_zero( FPT const& fpv, op::EQ<Lhs,Rhs>* ) -{ - fpc::small_with_tolerance<FPT> P( fpc_tolerance<FPT>() ); - - assertion_result ar( P( fpv ) ); - if( !ar ) - ar.message() << "absolute value exceeds tolerance [|" << fpv << "| > "<< fpc_tolerance<FPT>() << ']'; - - return ar; -} - -//____________________________________________________________________________// - -template <typename FPT, typename Lhs, typename Rhs> -inline assertion_result -compare_fpv_near_zero( FPT const& fpv, op::NE<Lhs,Rhs>* ) -{ - fpc::small_with_tolerance<FPT> P( fpc_tolerance<FPT>() ); - - assertion_result ar( !P( fpv ) ); - if( !ar ) - ar.message() << "absolute value is within tolerance [|" << fpv << "| < "<< fpc_tolerance<FPT>() << ']'; - return ar; -} - -//____________________________________________________________________________// - -template <typename FPT, typename Lhs, typename Rhs> -inline assertion_result -compare_fpv( Lhs const& lhs, Rhs const& rhs, op::EQ<Lhs,Rhs>* ) -{ - if( lhs == 0 ) { - return compare_fpv_near_zero<FPT>( rhs, (op::EQ<Lhs,Rhs>*)0 ); - } - else if( rhs == 0) { - return compare_fpv_near_zero<FPT>( lhs, (op::EQ<Lhs,Rhs>*)0 ); - } - else { - fpc::close_at_tolerance<FPT> P( fpc_tolerance<FPT>(), fpc::FPC_STRONG ); - - assertion_result ar( P( lhs, rhs ) ); - if( !ar ) - ar.message() << "relative difference exceeds tolerance [" - << P.tested_rel_diff() << " > " << P.fraction_tolerance() << ']'; - return ar; - } -} - -//____________________________________________________________________________// - -template <typename FPT, typename Lhs, typename Rhs> -inline assertion_result -compare_fpv( Lhs const& lhs, Rhs const& rhs, op::NE<Lhs,Rhs>* ) -{ - if( lhs == 0 ) { - return compare_fpv_near_zero<FPT>( rhs, (op::NE<Lhs,Rhs>*)0 ); - } - else if( rhs == 0 ) { - return compare_fpv_near_zero<FPT>( lhs, (op::NE<Lhs,Rhs>*)0 ); - } - else { - fpc::close_at_tolerance<FPT> P( fpc_tolerance<FPT>(), fpc::FPC_WEAK ); - - assertion_result ar( !P( lhs, rhs ) ); - if( !ar ) - ar.message() << "relative difference is within tolerance [" - << P.tested_rel_diff() << " < " << fpc_tolerance<FPT>() << ']'; - - return ar; - } -} - -//____________________________________________________________________________// - -#define DEFINE_FPV_COMPARISON( oper, name, rev, name_inverse ) \ -template<typename Lhs,typename Rhs> \ -struct name<Lhs,Rhs,typename boost::enable_if_c< \ - (fpc::tolerance_based<Lhs>::value && \ - fpc::tolerance_based<Rhs>::value) || \ - (fpc::tolerance_based<Lhs>::value && \ - boost::is_arithmetic<Rhs>::value) || \ - (boost::is_arithmetic<Lhs>::value && \ - fpc::tolerance_based<Rhs>::value) \ - >::type> { \ -public: \ - typedef typename common_type<Lhs,Rhs>::type FPT; \ - typedef name<Lhs,Rhs> OP; \ - typedef name_inverse<Lhs, Rhs> inverse; \ - \ - typedef assertion_result result_type; \ - \ - static bool \ - eval_direct( Lhs const& lhs, Rhs const& rhs ) \ - { \ - return lhs oper rhs; \ - } \ - \ - static assertion_result \ - eval( Lhs const& lhs, Rhs const& rhs ) \ - { \ - if( fpc_tolerance<FPT>() == FPT(0) \ - || (std::numeric_limits<Lhs>::has_infinity \ - && (lhs == std::numeric_limits<Lhs>::infinity())) \ - || (std::numeric_limits<Rhs>::has_infinity \ - && (rhs == std::numeric_limits<Rhs>::infinity()))) \ - { \ - return eval_direct( lhs, rhs ); \ - } \ - \ - return compare_fpv<FPT>( lhs, rhs, (OP*)0 ); \ - } \ - \ - template<typename PrevExprType> \ - static void \ - report( std::ostream& ostr, \ - PrevExprType const& lhs, \ - Rhs const& rhs ) \ - { \ - lhs.report( ostr ); \ - ostr << revert() \ - << tt_detail::print_helper( rhs ); \ - } \ - \ - static char const* forward() \ - { return " " #oper " "; } \ - static char const* revert() \ - { return " " #rev " "; } \ -}; \ -/**/ - -BOOST_TEST_FOR_EACH_COMP_OP( DEFINE_FPV_COMPARISON ) -#undef DEFINE_FPV_COMPARISON - -//____________________________________________________________________________// - -} // namespace op -} // namespace assertion -} // namespace test_tools -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_FPC_OP_HPP_050915GER diff --git a/ThirdParty/boost/test/tools/interface.hpp b/ThirdParty/boost/test/tools/interface.hpp deleted file mode 100644 index e62ae946c02846af0517a0e3502e18a2dd89c504..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tools/interface.hpp +++ /dev/null @@ -1,366 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision: 81247 $ -// -// Description : contains definition for all test tools in test toolbox -// *************************************************************************** - -#ifndef BOOST_TEST_TOOLS_INTERFACE_HPP_111712GER -#define BOOST_TEST_TOOLS_INTERFACE_HPP_111712GER - -// Boost.Test -#include <boost/test/unit_test_log.hpp> -#ifdef BOOST_TEST_TOOLS_DEBUGGABLE -#include <boost/test/debug.hpp> -#endif - -#include <boost/test/detail/pp_variadic.hpp> - -#ifdef BOOST_TEST_NO_OLD_TOOLS -#include <boost/preprocessor/seq/to_tuple.hpp> - -#include <iterator> -#endif // BOOST_TEST_NO_OLD_TOOLS - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** BOOST_TEST_<level> ************** // -// ************************************************************************** // - -#define BOOST_TEST_BUILD_ASSERTION( P ) \ - (::boost::test_tools::assertion::seed()->*P) \ -/**/ - -//____________________________________________________________________________// - -// Implementation based on direct predicate evaluation -#define BOOST_TEST_TOOL_DIRECT_IMPL( P, level, M ) \ -do { \ - ::boost::test_tools::assertion_result res = (P); \ - report_assertion( \ - res, \ - BOOST_TEST_LAZY_MSG( M ), \ - BOOST_TEST_L(__FILE__), \ - static_cast<std::size_t>(__LINE__), \ - ::boost::test_tools::tt_detail::level, \ - ::boost::test_tools::tt_detail::CHECK_MSG, \ - 0 ); \ -} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -//____________________________________________________________________________// - -// Implementation based on expression template construction -#define BOOST_TEST_TOOL_ET_IMPL( P, level ) \ -do { \ - BOOST_TEST_PASSPOINT(); \ - \ - ::boost::test_tools::tt_detail:: \ - report_assertion( \ - BOOST_TEST_BUILD_ASSERTION( P ).evaluate(), \ - BOOST_TEST_LAZY_MSG( BOOST_TEST_STRINGIZE( P ) ), \ - BOOST_TEST_L(__FILE__), \ - static_cast<std::size_t>(__LINE__), \ - ::boost::test_tools::tt_detail::level, \ - ::boost::test_tools::tt_detail::CHECK_BUILT_ASSERTION, \ - 0 ); \ -} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -//____________________________________________________________________________// - -// Implementation based on expression template construction with extra tool arguments -#define BOOST_TEST_TOOL_ET_IMPL_EX( P, level, arg ) \ -do { \ - BOOST_TEST_PASSPOINT(); \ - \ - ::boost::test_tools::tt_detail:: \ - report_assertion( \ - ::boost::test_tools::tt_detail::assertion_evaluate( \ - BOOST_TEST_BUILD_ASSERTION( P ) ) \ - << arg, \ - ::boost::test_tools::tt_detail::assertion_text( \ - BOOST_TEST_LAZY_MSG( BOOST_TEST_STRINGIZE(P) ), \ - BOOST_TEST_LAZY_MSG( arg ) ), \ - BOOST_TEST_L(__FILE__), \ - static_cast<std::size_t>(__LINE__), \ - ::boost::test_tools::tt_detail::level, \ - ::boost::test_tools::tt_detail::assertion_type() \ - << arg, \ - 0 ); \ -} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -//____________________________________________________________________________// - -#ifdef BOOST_TEST_TOOLS_UNDER_DEBUGGER - -#define BOOST_TEST_TOOL_UNIV( level, P ) \ - BOOST_TEST_TOOL_DIRECT_IMPL( P, level, BOOST_TEST_STRINGIZE( P ) ) \ -/**/ - -#define BOOST_TEST_TOOL_UNIV_EX( level, P, ... ) \ - BOOST_TEST_TOOL_UNIV( level, P ) \ -/**/ - -#elif defined(BOOST_TEST_TOOLS_DEBUGGABLE) - -#define BOOST_TEST_TOOL_UNIV( level, P ) \ -do { \ - if( ::boost::debug::under_debugger() ) \ - BOOST_TEST_TOOL_DIRECT_IMPL( P, level, BOOST_TEST_STRINGIZE( P ) ); \ - else \ - BOOST_TEST_TOOL_ET_IMPL( P, level ); \ -} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -#define BOOST_TEST_TOOL_UNIV_EX( level, P, ... ) \ - BOOST_TEST_TOOL_UNIV( level, P ) \ -/**/ - -#else - -#define BOOST_TEST_TOOL_UNIV( level, P ) \ - BOOST_TEST_TOOL_ET_IMPL( P, level ) \ -/**/ - -#define BOOST_TEST_TOOL_UNIV_EX( level, P, ... ) \ - BOOST_TEST_TOOL_ET_IMPL_EX( P, level, __VA_ARGS__ ) \ -/**/ - -#endif - -//____________________________________________________________________________// - -#define BOOST_TEST_WARN( ... ) BOOST_TEST_INVOKE_IF_N_ARGS( \ - 2, BOOST_TEST_TOOL_UNIV, BOOST_TEST_TOOL_UNIV_EX, WARN, __VA_ARGS__ ) \ -/**/ -#define BOOST_TEST_CHECK( ... ) BOOST_TEST_INVOKE_IF_N_ARGS( \ - 2, BOOST_TEST_TOOL_UNIV, BOOST_TEST_TOOL_UNIV_EX, CHECK, __VA_ARGS__ ) \ -/**/ -#define BOOST_TEST_REQUIRE( ... ) BOOST_TEST_INVOKE_IF_N_ARGS( \ - 2, BOOST_TEST_TOOL_UNIV, BOOST_TEST_TOOL_UNIV_EX, REQUIRE, __VA_ARGS__ )\ -/**/ - -#define BOOST_TEST( ... ) BOOST_TEST_INVOKE_IF_N_ARGS( \ - 2, BOOST_TEST_TOOL_UNIV, BOOST_TEST_TOOL_UNIV_EX, CHECK, __VA_ARGS__ ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_TEST_ERROR( M ) BOOST_CHECK_MESSAGE( false, M ) -#define BOOST_TEST_FAIL( M ) BOOST_REQUIRE_MESSAGE( false, M ) - -//____________________________________________________________________________// - -#define BOOST_TEST_IS_DEFINED( symb ) ::boost::test_tools::tt_detail::is_defined_impl( symb, BOOST_STRINGIZE(= symb) ) - -//____________________________________________________________________________// - -#ifdef BOOST_TEST_NO_OLD_TOOLS - -#ifdef BOOST_TEST_TOOLS_UNDER_DEBUGGER - -#define BOOST_CHECK_THROW_IMPL(S, E, TL, Ppassed, Mpassed, Pcaught, Mcaught)\ -do { try { \ - S; \ - BOOST_TEST_TOOL_DIRECT_IMPL( Ppassed, TL, Mpassed ); \ -} catch( E ) { \ - BOOST_TEST_TOOL_DIRECT_IMPL( Pcaught, TL, Mcaught ); \ -}} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -#elif defined(BOOST_TEST_TOOLS_DEBUGGABLE) - -#define BOOST_CHECK_THROW_IMPL(S, E, TL, Ppassed, Mpassed, Pcaught, Mcaught)\ -do { try { \ - if( ::boost::debug::under_debugger() ) \ - BOOST_TEST_PASSPOINT(); \ - S; \ - BOOST_TEST_TOOL_DIRECT_IMPL( Ppassed, TL, Mpassed ); \ -} catch( E ) { \ - BOOST_TEST_TOOL_DIRECT_IMPL( Pcaught, TL, Mcaught ); \ -}} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -#else - -#define BOOST_CHECK_THROW_IMPL(S, E, TL, Ppassed, Mpassed, Pcaught, Mcaught)\ -do { try { \ - BOOST_TEST_PASSPOINT(); \ - S; \ - BOOST_TEST_TOOL_DIRECT_IMPL( Ppassed, TL, Mpassed ); \ -} catch( E ) { \ - BOOST_TEST_TOOL_DIRECT_IMPL( Pcaught, TL, Mcaught ); \ -}} while( ::boost::test_tools::tt_detail::dummy_cond() ) \ -/**/ - -#endif - -//____________________________________________________________________________// - -#define BOOST_WARN_THROW( S, E ) \ - BOOST_CHECK_THROW_IMPL(S, E const&, WARN, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - true , "exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ -#define BOOST_CHECK_THROW( S, E ) \ - BOOST_CHECK_THROW_IMPL(S, E const&, CHECK, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - true , "exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ -#define BOOST_REQUIRE_THROW( S, E ) \ - BOOST_CHECK_THROW_IMPL(S, E const&, REQUIRE, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - true , "exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_WARN_EXCEPTION( S, E, P ) \ - BOOST_CHECK_THROW_IMPL(S, E const& ex, WARN, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - P(ex), "incorrect exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ -#define BOOST_CHECK_EXCEPTION( S, E, P ) \ - BOOST_CHECK_THROW_IMPL(S, E const& ex, CHECK, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - P(ex), "incorrect exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ -#define BOOST_REQUIRE_EXCEPTION( S, E, P ) \ - BOOST_CHECK_THROW_IMPL(S, E const& ex, REQUIRE, \ - false, "exception " BOOST_STRINGIZE(E) " is expected", \ - P(ex), "incorrect exception " BOOST_STRINGIZE(E) " is caught" ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_WARN_NO_THROW( S ) \ - BOOST_CHECK_THROW_IMPL(S, ..., WARN, \ - true , "no exceptions thrown by " BOOST_STRINGIZE( S ), \ - false, "exception thrown by " BOOST_STRINGIZE( S ) ) \ -/**/ -#define BOOST_CHECK_NO_THROW( S ) \ - BOOST_CHECK_THROW_IMPL(S, ..., CHECK, \ - true , "no exceptions thrown by " BOOST_STRINGIZE( S ), \ - false, "exception thrown by " BOOST_STRINGIZE( S ) ) \ -/**/ -#define BOOST_REQUIRE_NO_THROW( S ) \ - BOOST_CHECK_THROW_IMPL(S, ..., REQUIRE, \ - true , "no exceptions thrown by " BOOST_STRINGIZE( S ), \ - false, "exception thrown by " BOOST_STRINGIZE( S ) ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_WARN_MESSAGE( P, M ) BOOST_TEST_TOOL_DIRECT_IMPL( P, WARN, M ) -#define BOOST_CHECK_MESSAGE( P, M ) BOOST_TEST_TOOL_DIRECT_IMPL( P, CHECK, M ) -#define BOOST_REQUIRE_MESSAGE( P, M ) BOOST_TEST_TOOL_DIRECT_IMPL( P, REQUIRE, M ) - -//____________________________________________________________________________// - -//////////////////////////////////////////////////////////////////////////////// -///////////////////////////// DEPRECATED TOOLS ///////////////////////////// - -#define BOOST_WARN( P ) BOOST_TEST_WARN( P ) -#define BOOST_CHECK( P ) BOOST_TEST_CHECK( P ) -#define BOOST_REQUIRE( P ) BOOST_TEST_REQUIRE( P ) - -//____________________________________________________________________________// - -#define BOOST_ERROR( M ) BOOST_TEST_ERROR( M ) -#define BOOST_FAIL( M ) BOOST_TEST_FAIL( M ) - -//____________________________________________________________________________// - -#define BOOST_WARN_EQUAL( L, R ) BOOST_TEST_WARN( L == R ) -#define BOOST_CHECK_EQUAL( L, R ) BOOST_TEST_CHECK( L == R ) -#define BOOST_REQUIRE_EQUAL( L, R ) BOOST_TEST_REQUIRE( L == R ) - -#define BOOST_WARN_NE( L, R ) BOOST_TEST_WARN( L != R ) -#define BOOST_CHECK_NE( L, R ) BOOST_TEST_CHECK( L != R ) -#define BOOST_REQUIRE_NE( L, R ) BOOST_TEST_REQUIRE( L != R ) - -#define BOOST_WARN_LT( L, R ) BOOST_TEST_WARN( L < R ) -#define BOOST_CHECK_LT( L, R ) BOOST_TEST_CHECK( L < R ) -#define BOOST_REQUIRE_LT( L, R ) BOOST_TEST_REQUIRE( L < R ) - -#define BOOST_WARN_LE( L, R ) BOOST_TEST_WARN( L <= R ) -#define BOOST_CHECK_LE( L, R ) BOOST_TEST_CHECK( L <= R ) -#define BOOST_REQUIRE_LE( L, R ) BOOST_TEST_REQUIRE( L <= R ) - -#define BOOST_WARN_GT( L, R ) BOOST_TEST_WARN( L > R ) -#define BOOST_CHECK_GT( L, R ) BOOST_TEST_CHECK( L > R ) -#define BOOST_REQUIRE_GT( L, R ) BOOST_TEST_REQUIRE( L > R ) - -#define BOOST_WARN_GE( L, R ) BOOST_TEST_WARN( L >= R ) -#define BOOST_CHECK_GE( L, R ) BOOST_TEST_CHECK( L >= R ) -#define BOOST_REQUIRE_GE( L, R ) BOOST_TEST_REQUIRE( L >= R ) - -//____________________________________________________________________________// - -#define BOOST_WARN_CLOSE( L, R, T ) BOOST_TEST_WARN( L == R, T % ::boost::test_tools::tolerance() ) -#define BOOST_CHECK_CLOSE( L, R, T ) BOOST_TEST_CHECK( L == R, T % ::boost::test_tools::tolerance() ) -#define BOOST_REQUIRE_CLOSE( L, R, T ) BOOST_TEST_REQUIRE( L == R, T % ::boost::test_tools::tolerance() ) - -#define BOOST_WARN_CLOSE_FRACTION(L, R, T) BOOST_TEST_WARN( L == R, ::boost::test_tools::tolerance( T ) ) -#define BOOST_CHECK_CLOSE_FRACTION(L, R, T) BOOST_TEST_CHECK( L == R, ::boost::test_tools::tolerance( T ) ) -#define BOOST_REQUIRE_CLOSE_FRACTION(L,R,T) BOOST_TEST_REQUIRE( L == R, ::boost::test_tools::tolerance( T ) ) - -#define BOOST_WARN_SMALL( FPV, T ) BOOST_TEST_WARN( FPV == 0., ::boost::test_tools::tolerance( T ) ) -#define BOOST_CHECK_SMALL( FPV, T ) BOOST_TEST_CHECK( FPV == 0., ::boost::test_tools::tolerance( T ) ) -#define BOOST_REQUIRE_SMALL( FPV, T ) BOOST_TEST_REQUIRE( FPV == 0., ::boost::test_tools::tolerance( T ) ) - -//____________________________________________________________________________// - -#define BOOST_WARN_EQUAL_COLLECTIONS( L_begin, L_end, R_begin, R_end ) \ - BOOST_TEST_WARN( ::boost::test_tools::tt_detail::make_it_pair(L_begin, L_end) ==\ - ::boost::test_tools::tt_detail::make_it_pair(R_begin, R_end), \ - ::boost::test_tools::per_element() ) \ -/**/ - -#define BOOST_CHECK_EQUAL_COLLECTIONS( L_begin, L_end, R_begin, R_end ) \ - BOOST_TEST_CHECK( ::boost::test_tools::tt_detail::make_it_pair(L_begin, L_end) ==\ - ::boost::test_tools::tt_detail::make_it_pair(R_begin, R_end), \ - ::boost::test_tools::per_element() ) \ -/**/ - -#define BOOST_REQUIRE_EQUAL_COLLECTIONS( L_begin, L_end, R_begin, R_end ) \ - BOOST_TEST_REQUIRE( ::boost::test_tools::tt_detail::make_it_pair(L_begin, L_end) ==\ - ::boost::test_tools::tt_detail::make_it_pair(R_begin, R_end), \ - ::boost::test_tools::per_element() ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_WARN_BITWISE_EQUAL( L, R ) BOOST_TEST_WARN( L == R, ::boost::test_tools::bitwise() ) -#define BOOST_CHECK_BITWISE_EQUAL( L, R ) BOOST_TEST_CHECK( L == R, ::boost::test_tools::bitwise() ) -#define BOOST_REQUIRE_BITWISE_EQUAL( L, R ) BOOST_TEST_REQUIRE( L == R, ::boost::test_tools::bitwise() ) - -//____________________________________________________________________________// - -#define BOOST_WARN_PREDICATE( P, ARGS ) BOOST_TEST_WARN( P BOOST_PP_SEQ_TO_TUPLE(ARGS) ) -#define BOOST_CHECK_PREDICATE( P, ARGS ) BOOST_TEST_CHECK( P BOOST_PP_SEQ_TO_TUPLE(ARGS) ) -#define BOOST_REQUIRE_PREDICATE( P, ARGS ) BOOST_TEST_REQUIRE( P BOOST_PP_SEQ_TO_TUPLE(ARGS) ) - -//____________________________________________________________________________// - -#define BOOST_IS_DEFINED( symb ) ::boost::test_tools::tt_detail::is_defined_impl( #symb, BOOST_STRINGIZE(= symb) ) - -//____________________________________________________________________________// - -#endif // BOOST_TEST_NO_OLD_TOOLS - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TOOLS_INTERFACE_HPP_111712GER diff --git a/ThirdParty/boost/test/tree/global_fixture.hpp b/ThirdParty/boost/test/tree/global_fixture.hpp deleted file mode 100644 index edd86a48456450a5c523d796ea0e4c63e98a417b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tree/global_fixture.hpp +++ /dev/null @@ -1,139 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Defines global_fixture -// *************************************************************************** - -#ifndef BOOST_TEST_TREE_GLOBAL_FIXTURE_HPP_091911GER -#define BOOST_TEST_TREE_GLOBAL_FIXTURE_HPP_091911GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/detail/global_typedef.hpp> - -#include <boost/test/tree/observer.hpp> -#include <boost/test/tree/fixture.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** global_configuration ************** // -// ************************************************************************** // - -class BOOST_TEST_DECL global_configuration : public test_observer { - -public: - // Constructor - global_configuration(); - - /// Unregisters the global fixture from the framework - /// - /// This is called by the framework at shutdown time - void unregister_from_framework(); - - // Dtor - virtual ~global_configuration(); - - // Happens after the framework global observer init has been done - virtual int priority() { return 1; } - -private: - bool registered; -}; - - - -// ************************************************************************** // -// ************** global_fixture ************** // -// ************************************************************************** // - -class BOOST_TEST_DECL global_fixture : public test_unit_fixture { - -public: - // Constructor - global_fixture(); - - /// Unregisters the global fixture from the framework - /// - /// This is called by the framework at shutdown time - void unregister_from_framework(); - - // Dtor - virtual ~global_fixture(); - -private: - bool registered; -}; - -//____________________________________________________________________________// - -namespace ut_detail { - -template<typename F> -struct global_configuration_impl : public global_configuration { - // Constructor - global_configuration_impl() : m_configuration_observer( 0 ) { - } - - // test observer interface - virtual void test_start( counter_t, test_unit_id ) { - m_configuration_observer = new F; - } - - // test observer interface - virtual void test_finish() { - if(m_configuration_observer) { - delete m_configuration_observer; - m_configuration_observer = 0; - } - } -private: - // Data members - F* m_configuration_observer; -}; - -template<typename F> -struct global_fixture_impl : public global_fixture { - // Constructor - global_fixture_impl() : m_fixture( 0 ) { - } - - // test fixture interface - virtual void setup() { - m_fixture = new F; - setup_conditional(*m_fixture); - } - - // test fixture interface - virtual void teardown() { - if(m_fixture) { - teardown_conditional(*m_fixture); - } - delete m_fixture; - m_fixture = 0; - } - -private: - // Data members - F* m_fixture; -}; - -} // namespace ut_detail -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TREE_GLOBAL_FIXTURE_HPP_091911GER - diff --git a/ThirdParty/boost/test/tree/observer.hpp b/ThirdParty/boost/test/tree/observer.hpp deleted file mode 100644 index 0c0a4013af3b8df324a65695fd6f6d3cadbb2631..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tree/observer.hpp +++ /dev/null @@ -1,115 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//!@file -//!@brief defines abstract interface for test observer -// *************************************************************************** - -#ifndef BOOST_TEST_TEST_OBSERVER_HPP_021005GER -#define BOOST_TEST_TEST_OBSERVER_HPP_021005GER - -// Boost.Test -#include <boost/test/detail/fwd_decl.hpp> -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/config.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** test_observer ************** // -// ************************************************************************** // - -/// @brief Generic test observer interface -/// -/// This interface is used by observers in order to receive notifications from the -/// Boost.Test framework on the current execution state. -/// -/// Several observers can be running at the same time, and it is not unusual to -/// have interactions among them. The @ref test_observer::priority member function allows the specification -/// of a particular order among them (lowest priority executed first, except specified otherwise). -/// -class BOOST_TEST_DECL test_observer { -public: - - //! Called before the framework starts executing the test cases - //! - //! @param[in] number_of_test_cases indicates the number of test cases. Only active - //! test cases are taken into account. - //! @param[in] root_test_unit_id the ID root of the test tree currently being tested - virtual void test_start( counter_t /* number_of_test_cases */, test_unit_id /* root_test_unit_id */ ) {} - - //! Called after the framework ends executing the test cases - //! - //! @note The call is made with a reversed priority order. - virtual void test_finish() {} - - //! Called when a critical error is detected - //! - //! The critical errors are mainly the signals sent by the system and caught by the Boost.Test framework. - //! Since the running binary may be in incoherent/instable state, the test execution is aborted and all remaining - //! tests are discarded. - //! - //! @note may be called before test_observer::test_unit_finish() - virtual void test_aborted() {} - - //! Called before the framework starts executing a test unit - //! - //! @param[in] test_unit the test being executed - virtual void test_unit_start( test_unit const& /* test */) {} - - //! Called at each end of a test unit. - //! - //! @param elapsed duration of the test unit in microseconds. - virtual void test_unit_finish( test_unit const& /* test */, unsigned long /* elapsed */ ) {} - virtual void test_unit_skipped( test_unit const& tu, const_string ) { test_unit_skipped( tu ); } - virtual void test_unit_skipped( test_unit const& ) {} ///< backward compatibility - - //! Called when the test timed out - //! - //! This function is called to signal that a test unit (case or suite) timed out. - //! A valid test unit is available through boost::unit_test::framework::current_test_unit - virtual void test_unit_timed_out( test_unit const& ) {} - - //! Called when a test unit indicates a fatal error. - //! - //! A fatal error happens when - //! - a strong assertion (with @c REQUIRE) fails, which indicates that the test case cannot continue - //! - an unexpected exception is caught by the Boost.Test framework - virtual void test_unit_aborted( test_unit const& ) {} - - virtual void assertion_result( unit_test::assertion_result /* ar */ ) - { - } - - //! Called when an exception is intercepted - //! - //! In case an exception is intercepted, this call happens before the call - //! to @ref test_unit_aborted in order to log - //! additional data about the exception. - virtual void exception_caught( execution_exception const& ) {} - - //! The priority indicates the order at which this observer is initialized - //! and tore down in the UTF framework. The order is lowest to highest priority. - virtual int priority() { return 0; } - -protected: - - BOOST_TEST_PROTECTED_VIRTUAL ~test_observer() {} -}; - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TEST_OBSERVER_HPP_021005GER - diff --git a/ThirdParty/boost/test/tree/test_case_counter.hpp b/ThirdParty/boost/test/tree/test_case_counter.hpp deleted file mode 100644 index 2d9b3bdddc3598a79555c33226058eb765d8644e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tree/test_case_counter.hpp +++ /dev/null @@ -1,58 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Defines @ref test_case_counter -// *************************************************************************** - -#ifndef BOOST_TEST_TREE_TEST_CASE_COUNTER_HPP_100211GER -#define BOOST_TEST_TREE_TEST_CASE_COUNTER_HPP_100211GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/utils/class_properties.hpp> - -#include <boost/test/tree/test_unit.hpp> -#include <boost/test/tree/visitor.hpp> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** test_case_counter ************** // -// ************************************************************************** // - -///! Counts the number of enabled test cases -class test_case_counter : public test_tree_visitor { -public: - // Constructor - // @param ignore_disabled ignore the status when counting - test_case_counter(bool ignore_status = false) - : p_count( 0 ) - , m_ignore_status(ignore_status) - {} - - BOOST_READONLY_PROPERTY( counter_t, (test_case_counter)) p_count; -private: - // test tree visitor interface - virtual void visit( test_case const& tc ) { if( m_ignore_status || tc.is_enabled() ) ++p_count.value; } - virtual bool test_suite_start( test_suite const& ts ) { return m_ignore_status || ts.is_enabled(); } - - bool m_ignore_status; -}; - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TREE_TEST_CASE_COUNTER_HPP_100211GER - diff --git a/ThirdParty/boost/test/tree/test_case_template.hpp b/ThirdParty/boost/test/tree/test_case_template.hpp deleted file mode 100644 index e88c2ff0b9ea81d03e728a7bdbc4dbe2f6b915c6..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tree/test_case_template.hpp +++ /dev/null @@ -1,211 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -///@ file -/// Defines template_test_case_gen -// *************************************************************************** - -#ifndef BOOST_TEST_TREE_TEST_CASE_TEMPLATE_HPP_091911GER -#define BOOST_TEST_TREE_TEST_CASE_TEMPLATE_HPP_091911GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/fwd_decl.hpp> -#include <boost/test/tree/test_unit.hpp> - -#include <boost/test/utils/class_properties.hpp> -#include <boost/test/tree/observer.hpp> -#include <boost/test/utils/algorithm.hpp> - - -// Boost -#include <boost/shared_ptr.hpp> -#include <boost/mpl/for_each.hpp> -#include <boost/mpl/identity.hpp> -#include <boost/type.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/is_volatile.hpp> -#include <boost/type_traits/is_lvalue_reference.hpp> -#include <boost/type_traits/is_rvalue_reference.hpp> -#include <boost/type_traits/remove_reference.hpp> -#include <boost/function/function0.hpp> - -#if defined(BOOST_NO_TYPEID) || defined(BOOST_NO_RTTI) -# include <boost/current_function.hpp> -#else -# include <boost/core/demangle.hpp> -#endif - -// STL -#include <string> // for std::string -#include <list> // for std::list - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && \ - !defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) - #include <type_traits> - #include <boost/mpl/is_sequence.hpp> -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace ut_detail { - -// ************************************************************************** // -// ************** test_case_template_invoker ************** // -// ************************************************************************** // - -template<typename TestCaseTemplate,typename TestType> -class test_case_template_invoker { -public: - void operator()() { TestCaseTemplate::run( (boost::type<TestType>*)0 ); } -}; - -// ************************************************************************** // -// ************** generate_test_case_4_type ************** // -// ************************************************************************** // - -template<typename Generator, typename TestCaseTemplate> -struct generate_test_case_4_type { - explicit generate_test_case_4_type( const_string tc_name, const_string tc_file, std::size_t tc_line, Generator& G ) - : m_test_case_name( tc_name ) - , m_test_case_file( tc_file ) - , m_test_case_line( tc_line ) - , m_holder( G ) - {} - - template<typename TestType> - void operator()( mpl::identity<TestType> ) - { - std::string full_name; - assign_op( full_name, m_test_case_name, 0 ); - full_name += '<'; -#if !defined(BOOST_NO_TYPEID) && !defined(BOOST_NO_RTTI) - full_name += boost::core::demangle(typeid(TestType).name()); // same as execution_monitor.ipp -#else - full_name += BOOST_CURRENT_FUNCTION; -#endif - - // replacing ',' by ', ' first, and then removing any double space - static const std::string to_replace[] = { "class ", "struct ", ",", " ", " <", " >"}; - static const std::string replacement[] = { "", "" , ", ", " ", "<" , ">"}; - - full_name = unit_test::utils::replace_all_occurrences_of( - full_name, - to_replace, to_replace + sizeof(to_replace)/sizeof(to_replace[0]), - replacement, replacement + sizeof(replacement)/sizeof(replacement[0])); - - typedef typename boost::remove_reference<TestType>::type TestTypewoRef; - if( boost::is_const<TestTypewoRef>::value ) - full_name += "_const"; - if( boost::is_volatile<TestTypewoRef>::value ) - full_name += "_volatile"; - if( boost::is_rvalue_reference<TestType>::value ) - full_name += "_refref"; - else if( boost::is_lvalue_reference<TestType>::value ) - full_name += "_ref"; - - full_name += '>'; - - m_holder.m_test_cases.push_back( new test_case( ut_detail::normalize_test_case_name( full_name ), - m_test_case_file, - m_test_case_line, - test_case_template_invoker<TestCaseTemplate,TestType>() ) ); - } - -private: - // Data members - const_string m_test_case_name; - const_string m_test_case_file; - std::size_t m_test_case_line; - Generator& m_holder; -}; - -// ************************************************************************** // -// ************** test_case_template ************** // -// ************************************************************************** // - -class template_test_case_gen_base : public test_unit_generator { -public: - virtual test_unit* next() const - { - if( m_test_cases.empty() ) - return 0; - - test_unit* res = m_test_cases.front(); - m_test_cases.pop_front(); - - return res; - } - - // Data members - mutable std::list<test_unit*> m_test_cases; -}; - -template<typename TestCaseTemplate,typename TestTypesList, typename enabler = void> -class template_test_case_gen : public template_test_case_gen_base { -public: - // Constructor - template_test_case_gen( const_string tc_name, const_string tc_file, std::size_t tc_line ) - { - typedef generate_test_case_4_type<template_test_case_gen<TestCaseTemplate,TestTypesList>,TestCaseTemplate> single_test_gen; - - mpl::for_each<TestTypesList,mpl::make_identity<mpl::_> >( single_test_gen( tc_name, tc_file, tc_line, *this ) ); - } -}; - -// Describing template test cases with tuples -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && \ - !defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && \ - !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - -template<typename TestCaseTemplate, - template <class ...> class C, - typename... parameter_pack> -class template_test_case_gen< - TestCaseTemplate, - C<parameter_pack...>, - typename std::enable_if<!boost::mpl::is_sequence<C<parameter_pack...>>::value>::type > - : public template_test_case_gen_base { - - template<typename F> - void for_each(F &f) - { - auto l = { (f(mpl::identity<parameter_pack>()), 0)... }; - (void)l; // silence warning - } - -public: - // Constructor - template_test_case_gen( const_string tc_name, const_string tc_file, std::size_t tc_line ) - { - using this_type = template_test_case_gen< - TestCaseTemplate, - C<parameter_pack...>, - typename std::enable_if<!boost::mpl::is_sequence<C<parameter_pack...>>::value>::type>; - using single_test_gen = generate_test_case_4_type<this_type, TestCaseTemplate>; - - single_test_gen op( tc_name, tc_file, tc_line, *this ); - - this->for_each(op); - } -}; - -#endif /* C++11 variadic, type alias */ - -} // namespace ut_detail -} // unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TREE_TEST_CASE_TEMPLATE_HPP_091911GER diff --git a/ThirdParty/boost/test/tree/test_unit.hpp b/ThirdParty/boost/test/tree/test_unit.hpp deleted file mode 100644 index 0eab1d9941dd6ddd93b899457e85575c65f5700e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/tree/test_unit.hpp +++ /dev/null @@ -1,291 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// Defines @ref boost::unit_test::test_unit "test_unit", @ref boost::unit_test::test_case "test_case", -/// @ref boost::unit_test::test_suite "test_suite" and @ref boost::unit_test::master_test_suite_t "master_test_suite_t" -// *************************************************************************** - -#ifndef BOOST_TEST_TREE_TEST_UNIT_HPP_100211GER -#define BOOST_TEST_TREE_TEST_UNIT_HPP_100211GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/fwd_decl.hpp> - -#include <boost/test/tree/decorator.hpp> -#include <boost/test/tree/fixture.hpp> -#include <boost/test/framework.hpp> - -#include <boost/test/tools/assertion_result.hpp> - -#include <boost/test/utils/class_properties.hpp> - -// Boost -#include <boost/function/function0.hpp> -#include <boost/function/function1.hpp> - -// STL -#include <vector> -#include <string> -#include <map> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -namespace framework { - class state; -} - -// ************************************************************************** // -// ************** test_unit ************** // -// ************************************************************************** // - -typedef std::vector<test_unit_id> test_unit_id_list; - -class BOOST_TEST_DECL test_unit { -public: - enum { type = TUT_ANY }; - enum run_status { RS_DISABLED, RS_ENABLED, RS_INHERIT, RS_INVALID }; - - typedef std::vector<test_unit_id> id_list; - typedef std::vector<test_unit_fixture_ptr> fixture_list_t; - typedef BOOST_READONLY_PROPERTY(test_unit_id,(framework::state)) id_t; - typedef BOOST_READONLY_PROPERTY(test_unit_id,(test_suite)) parent_id_t; - typedef BOOST_READONLY_PROPERTY(id_list,(test_unit)) id_list_t; - typedef std::vector<decorator::base_ptr> decor_list_t; - typedef BOOST_READONLY_PROPERTY(std::vector<std::string>,(test_unit)) label_list_t; - - typedef boost::function<test_tools::assertion_result (test_unit_id)> precondition_t; - typedef BOOST_READONLY_PROPERTY(std::vector<precondition_t>,(test_unit)) precond_list_t; - - // preconditions management - void depends_on( test_unit* tu ); - void add_precondition( precondition_t const& ); - test_tools::assertion_result check_preconditions() const; - - // labels management - void add_label( const_string l ); - bool has_label( const_string l ) const; - - // helper access methods - void increase_exp_fail( counter_t num ); - bool is_enabled() const { return p_run_status == RS_ENABLED; } - std::string full_name() const; - - // Public r/o properties - test_unit_type const p_type; ///< type for this test unit - const_string const p_type_name; ///< "case"/"suite"/"module" - const_string const p_file_name; - std::size_t const p_line_num; - id_t p_id; ///< unique id for this test unit - parent_id_t p_parent_id; ///< parent test suite id - label_list_t p_labels; ///< list of labels associated with this test unit - - id_list_t p_dependencies; ///< list of test units this one depends on - precond_list_t p_preconditions; ///< user supplied preconditions for this test unit; - - // Public r/w properties - readwrite_property<std::string> p_name; ///< name for this test unit - readwrite_property<std::string> p_description; ///< description for this test unit - readwrite_property<unsigned> p_timeout; ///< timeout for the test unit execution in seconds - readwrite_property<counter_t> p_expected_failures; ///< number of expected failures in this test unit - - readwrite_property<run_status> p_default_status; ///< run status obtained by this unit during setup phase - readwrite_property<run_status> p_run_status; ///< run status assigned to this unit before execution phase after applying all filters - - readwrite_property<counter_t> p_sibling_rank; ///< rank of this test unit amoung siblings of the same parent - - readwrite_property<decor_list_t> p_decorators; ///< automatically assigned decorators; execution is delayed till framework::finalize_setup_phase function - readwrite_property<fixture_list_t> p_fixtures; ///< fixtures associated with this test unit - -protected: - ~test_unit(); - // Constructor - test_unit( const_string tu_name, const_string tc_file, std::size_t tc_line, test_unit_type t ); - // Master test suite constructor - explicit test_unit( const_string module_name ); -}; - -// ************************************************************************** // -// ************** test_unit_generator ************** // -// ************************************************************************** // - -class BOOST_TEST_DECL test_unit_generator { -public: - virtual test_unit* next() const = 0; - -protected: - BOOST_TEST_PROTECTED_VIRTUAL ~test_unit_generator() {} -}; - -// ************************************************************************** // -// ************** test_case ************** // -// ************************************************************************** // - -class BOOST_TEST_DECL test_case : public test_unit { -public: - enum { type = TUT_CASE }; - - // Constructor - test_case( const_string tc_name, boost::function<void ()> const& test_func ); - test_case( const_string tc_name, const_string tc_file, std::size_t tc_line, boost::function<void ()> const& test_func ); - - // Public property - typedef BOOST_READONLY_PROPERTY(boost::function<void ()>,(test_case)) test_func; - - test_func p_test_func; - -private: - friend class framework::state; - ~test_case() {} -}; - -// ************************************************************************** // -// ************** test_suite ************** // -// ************************************************************************** // - -//! Class representing test suites -class BOOST_TEST_DECL test_suite : public test_unit { -public: - enum { type = TUT_SUITE }; - - // Constructor - explicit test_suite( const_string ts_name, const_string ts_file, std::size_t ts_line ); - - // test unit list management - - /*!@brief Adds a test unit to a test suite. - * - * It is possible to specify the timeout and the expected failures. - */ - void add( test_unit* tu, counter_t expected_failures = 0, unsigned timeout = 0 ); - - /// @overload - void add( test_unit_generator const& gen, unsigned timeout = 0 ); - - /// @overload - void add( test_unit_generator const& gen, decorator::collector_t& decorators ); - - /// @overload - void add( boost::shared_ptr<test_unit_generator> gen_ptr, decorator::collector_t& decorators ); - - //! Removes a test from the test suite. - void remove( test_unit_id id ); - - //! Generates all the delayed test_units from the generators - void generate( ); - - //! Check for duplicates name in test cases - //! - //! Raises a setup_error if there are duplicates - void check_for_duplicate_test_cases(); - - // access methods - test_unit_id get( const_string tu_name ) const; - std::size_t size() const { return m_children.size(); } - -protected: - // Master test suite constructor - explicit test_suite( const_string module_name ); - - friend BOOST_TEST_DECL - void traverse_test_tree( test_suite const&, test_tree_visitor&, bool ); - friend class framework::state; - virtual ~test_suite() {} - - typedef std::multimap<counter_t,test_unit_id> children_per_rank; - // Data members - - test_unit_id_list m_children; - children_per_rank m_ranked_children; ///< maps child sibling rank to list of children with that rank - - std::vector< std::pair<boost::shared_ptr<test_unit_generator>, std::vector<decorator::base_ptr> > > m_generators; /// lazy evaluation -}; - -// ************************************************************************** // -// ************** master_test_suite ************** // -// ************************************************************************** // - -class BOOST_TEST_DECL master_test_suite_t : public test_suite { -private: - master_test_suite_t(); - master_test_suite_t(const master_test_suite_t&); // undefined - master_test_suite_t& operator=(master_test_suite_t const &); // undefined - -public: - // Data members - int argc; - char** argv; - - friend BOOST_TEST_DECL master_test_suite_t& boost::unit_test::framework::master_test_suite(); -}; - -// ************************************************************************** // -// ************** user_tc_method_invoker ************** // -// ************************************************************************** // - -namespace ut_detail { - -BOOST_TEST_DECL std::string normalize_test_case_name( const_string tu_name ); - -//____________________________________________________________________________// - -template<typename InstanceType,typename UserTestCase> -struct user_tc_method_invoker { - typedef void (UserTestCase::*TestMethod )(); - - user_tc_method_invoker( shared_ptr<InstanceType> inst, TestMethod test_method ) - : m_inst( inst ), m_test_method( test_method ) {} - - void operator()() { ((*m_inst).*m_test_method)(); } - - shared_ptr<InstanceType> m_inst; - TestMethod m_test_method; -}; - -} // namespace ut_detail - -// ************************************************************************** // -// ************** make_test_case ************** // -// ************************************************************************** // - -inline test_case* -make_test_case( boost::function<void ()> const& test_func, const_string tc_name, const_string tc_file, std::size_t tc_line ) -{ - return new test_case( ut_detail::normalize_test_case_name( tc_name ), tc_file, tc_line, test_func ); -} - -//____________________________________________________________________________// - -template<typename UserTestCase, typename InstanceType> -inline test_case* -make_test_case( void (UserTestCase::* test_method )(), - const_string tc_name, - const_string tc_file, - std::size_t tc_line, - boost::shared_ptr<InstanceType> user_test_case ) -{ - return new test_case( ut_detail::normalize_test_case_name( tc_name ), - tc_file, - tc_line, - ut_detail::user_tc_method_invoker<InstanceType,UserTestCase>( user_test_case, test_method ) ); -} - -//____________________________________________________________________________// - -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_TREE_TEST_UNIT_HPP_100211GER diff --git a/ThirdParty/boost/test/unit_test_log.hpp b/ThirdParty/boost/test/unit_test_log.hpp deleted file mode 100644 index e90c6813aa5490b340bc3a34b442cdd0340415b1..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/unit_test_log.hpp +++ /dev/null @@ -1,280 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief defines singleton class unit_test_log and all manipulators. -/// unit_test_log has output stream like interface. It's implementation is -/// completely hidden with pimple idiom -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_LOG_HPP_071894GER -#define BOOST_TEST_UNIT_TEST_LOG_HPP_071894GER - -// Boost.Test -#include <boost/test/tree/observer.hpp> - -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/log_level.hpp> -#include <boost/test/detail/fwd_decl.hpp> - -#include <boost/test/utils/wrap_stringstream.hpp> -#include <boost/test/utils/lazy_ostream.hpp> - -// Boost - -// STL -#include <iosfwd> // for std::ostream& - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** log manipulators ************** // -// ************************************************************************** // - -namespace log { - -struct BOOST_TEST_DECL begin { - begin( const_string fn, std::size_t ln ) - : m_file_name( fn ) - , m_line_num( ln ) - {} - - const_string m_file_name; - std::size_t m_line_num; -}; - -struct end {}; - -} // namespace log - -// ************************************************************************** // -// ************** entry_value_collector ************** // -// ************************************************************************** // - -namespace ut_detail { - -class BOOST_TEST_DECL entry_value_collector { -public: - // Constructors - entry_value_collector() : m_last( true ) {} - entry_value_collector( entry_value_collector const& rhs ) : m_last( true ) { rhs.m_last = false; } - ~entry_value_collector(); - - // collection interface - entry_value_collector const& operator<<( lazy_ostream const& ) const; - entry_value_collector const& operator<<( const_string ) const; - -private: - // Data members - mutable bool m_last; -}; - -} // namespace ut_detail - -// ************************************************************************** // -// ************** unit_test_log ************** // -// ************************************************************************** // - -/// @brief Manages the sets of loggers, their streams and log levels -/// -/// The Boost.Test framework allows for having several formatters/loggers at the same time, each of which -/// having their own log level and output stream. -/// -/// This class serves the purpose of -/// - exposing an interface to the test framework (as a boost::unit_test::test_observer) -/// - exposing an interface to the testing tools -/// - managing several loggers -/// -/// @note Accesses to the functions exposed by this class are made through the singleton -/// @c boost::unit_test::unit_test_log. -/// -/// Users/developers willing to implement their own formatter need to: -/// - implement a boost::unit_test::unit_test_log_formatter that will output the desired format -/// - register the formatter during a eg. global fixture using the method @c set_formatter (though the framework singleton). -/// -/// @warning this observer has a higher priority than the @ref boost::unit_test::results_collector_t. This means -/// that the various @ref boost::unit_test::test_results associated to each test unit may not be available at the time -/// the @c test_unit_start, @c test_unit_finish ... are called. -/// -/// @see -/// - boost::unit_test::test_observer -/// - boost::unit_test::unit_test_log_formatter -class BOOST_TEST_DECL unit_test_log_t : public test_observer { -public: - // test_observer interface implementation - virtual void test_start( counter_t test_cases_amount, test_unit_id ); - virtual void test_finish(); - virtual void test_aborted(); - - virtual void test_unit_start( test_unit const& ); - virtual void test_unit_finish( test_unit const&, unsigned long elapsed ); - virtual void test_unit_skipped( test_unit const&, const_string ); - virtual void test_unit_aborted( test_unit const& ); - virtual void test_unit_timed_out( test_unit const& ); - - virtual void exception_caught( execution_exception const& ex ); - - virtual int priority() { return 2; } - - // log configuration methods - //! Sets the stream for all loggers - //! - //! This will override the log sink/stream of all loggers, whether enabled or not. - void set_stream( std::ostream& ); - - //! Sets the stream for specific logger - //! - //! @note Has no effect if the specified format is not found - //! @par Since Boost 1.62 - void set_stream( output_format, std::ostream& ); - - //! Returns a pointer to the stream associated to specific logger - //! - //! @note Returns a null pointer if the format is not found - //! @par Since Boost 1.67 - std::ostream* get_stream( output_format ) const; - - - //! Sets the threshold level for all loggers/formatters. - //! - //! This will override the log level of all loggers, whether enabled or not. - //! @return the minimum of the previous log level of all formatters (new in Boost 1.73) - log_level set_threshold_level( log_level ); - - //! Sets the threshold/log level of a specific format - //! - //! @note Has no effect if the specified format is not found - //! @par Since Boost 1.62 - //! @return the previous log level of the corresponding formatter (new in Boost 1.73) - log_level set_threshold_level( output_format, log_level ); - - //! Add a format to the set of loggers - //! - //! Adding a logger means that the specified logger is enabled. The log level is managed by the formatter itself - //! and specifies what events are forwarded to the underlying formatter. - //! @par Since Boost 1.62 - void add_format( output_format ); - - //! Sets the format of the logger - //! - //! This will become the only active format of the logs. - void set_format( output_format ); - - //! Returns the logger instance for a specific format. - //! - //! @returns the logger/formatter instance, or @c (unit_test_log_formatter*)0 if the format is not found. - //! @par Since Boost 1.62 - unit_test_log_formatter* get_formatter( output_format ); - - //! Sets the logger instance - //! - //! The specified logger becomes the unique active one. The custom log formatter has the - //! format @c OF_CUSTOM_LOGGER. If such a format exists already, its formatter gets replaced by the one - //! given in argument. - //! - //! The log level and output stream of the new formatter are taken from the currently active logger. In case - //! several loggers are active, the order of priority is CUSTOM, HRF, XML, and JUNIT. - //! If (unit_test_log_formatter*)0 is given as argument, the custom logger (if any) is removed. - //! - //! @note The ownership of the pointer is transfered to the Boost.Test framework. This call is equivalent to - //! - a call to @c add_formatter - //! - a call to @c set_format(OF_CUSTOM_LOGGER) - //! - a configuration of the newly added logger with a previously configured stream and log level. - void set_formatter( unit_test_log_formatter* ); - - //! Adds a custom log formatter to the set of formatters - //! - //! The specified logger is added with the format @c OF_CUSTOM_LOGGER, such that it can - //! be futher selected or its stream/log level can be specified. - //! If there is already a custom logger (with @c OF_CUSTOM_LOGGER), then - //! the existing one gets replaced by the one given in argument. - //! The provided logger is added with an enabled state. - //! If (unit_test_log_formatter*)0 is given as argument, the custom logger (if any) is removed and - //! no other action is performed. - //! - //! @note The ownership of the pointer is transfered to the Boost.Test framework. - //! @par Since Boost 1.62 - void add_formatter( unit_test_log_formatter* the_formatter ); - - // test progress logging - void set_checkpoint( const_string file, std::size_t line_num, const_string msg = const_string() ); - - // entry logging - unit_test_log_t& operator<<( log::begin const& ); // begin entry - unit_test_log_t& operator<<( log::end const& ); // end entry - unit_test_log_t& operator<<( log_level ); // set entry level - unit_test_log_t& operator<<( const_string ); // log entry value - unit_test_log_t& operator<<( lazy_ostream const& ); // log entry value - - ut_detail::entry_value_collector operator()( log_level ); // initiate entry collection - - //! Prepares internal states after log levels, streams and format has been set up - void configure(); -private: - // Singleton - BOOST_TEST_SINGLETON_CONS( unit_test_log_t ) -}; // unit_test_log_t - -BOOST_TEST_SINGLETON_INST( unit_test_log ) - -// helper macros -#define BOOST_TEST_LOG_ENTRY( ll ) \ - (::boost::unit_test::unit_test_log \ - << ::boost::unit_test::log::begin( BOOST_TEST_L(__FILE__), __LINE__ ))(ll) \ -/**/ - -} // namespace unit_test -} // namespace boost - -// ************************************************************************** // -// ************** Unit test log interface helpers ************** // -// ************************************************************************** // - -// messages sent by the framework -#define BOOST_TEST_FRAMEWORK_MESSAGE( M ) \ - (::boost::unit_test::unit_test_log \ - << ::boost::unit_test::log::begin( \ - "boost.test framework", \ - 0 )) \ - ( ::boost::unit_test::log_messages ) \ - << BOOST_TEST_LAZY_MSG( M ) \ -/**/ - - -#define BOOST_TEST_MESSAGE( M ) \ - BOOST_TEST_LOG_ENTRY( ::boost::unit_test::log_messages ) \ - << BOOST_TEST_LAZY_MSG( M ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_TEST_PASSPOINT() \ - ::boost::unit_test::unit_test_log.set_checkpoint( \ - BOOST_TEST_L(__FILE__), \ - static_cast<std::size_t>(__LINE__) ) \ -/**/ - -//____________________________________________________________________________// - -#define BOOST_TEST_CHECKPOINT( M ) \ - ::boost::unit_test::unit_test_log.set_checkpoint( \ - BOOST_TEST_L(__FILE__), \ - static_cast<std::size_t>(__LINE__), \ - (::boost::wrap_stringstream().ref() << M).str() ) \ -/**/ - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UNIT_TEST_LOG_HPP_071894GER - diff --git a/ThirdParty/boost/test/unit_test_log_formatter.hpp b/ThirdParty/boost/test/unit_test_log_formatter.hpp deleted file mode 100644 index 6ec72cafa7ab8d3f375384224c631305354feff3..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/unit_test_log_formatter.hpp +++ /dev/null @@ -1,327 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Defines unit test log formatter interface -/// -/// You can define a class with implements this interface and use an instance of it -/// as a Unit Test Framework log formatter -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_LOG_FORMATTER_HPP_071894GER -#define BOOST_TEST_UNIT_TEST_LOG_FORMATTER_HPP_071894GER - -// Boost.Test -#include <boost/test/detail/global_typedef.hpp> -#include <boost/test/detail/log_level.hpp> -#include <boost/test/detail/fwd_decl.hpp> - -// STL -#include <iosfwd> -#include <string> // for std::string -#include <iostream> - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -/// Collection of log entry attributes -// ************************************************************************** // - -struct BOOST_TEST_DECL log_entry_data { - log_entry_data() - { - m_file_name.reserve( 200 ); - } - - std::string m_file_name; ///< log entry file name - std::size_t m_line_num; ///< log entry line number - log_level m_level; ///< log entry level - - void clear() - { - m_file_name.erase(); - m_line_num = 0; - m_level = log_nothing; - } -}; - -// ************************************************************************** // -/// Collection of log checkpoint attributes -// ************************************************************************** // - -struct BOOST_TEST_DECL log_checkpoint_data -{ - const_string m_file_name; ///< log checkpoint file name - std::size_t m_line_num; ///< log checkpoint file name - std::string m_message; ///< log checkpoint message - - void clear() - { - m_file_name.clear(); - m_line_num = 0; - m_message = std::string(); - } -}; - -// ************************************************************************** // -/// @brief Abstract Unit Test Framework log formatter interface -/// -/// During the test module execution Unit Test Framework can report messages about success -/// or failure of assertions, which test suites are being run and more (specifically which -/// messages are reported depends on log level threshold selected by the user). -/// -/// All these messages constitute Unit Test Framework log. There are many ways (formats) to present -/// these messages to the user. -/// -/// Boost.Test comes with three formats: -/// - Compiler-like log format: intended for human consumption/diagnostic -/// - XML based log format: intended for processing by automated regression test systems. -/// - JUNIT based log format: intended for processing by automated regression test systems. -/// -/// If you want to produce some other format you need to implement class with specific interface and use -/// method @c unit_test_log_t::set_formatter during a test module initialization to set an active formatter. -/// The class unit_test_log_formatter defines this interface. -/// -/// This interface requires you to format all possible messages being produced in the log. -/// These includes error messages about failed assertions, messages about caught exceptions and -/// information messages about test units being started/ended. All the methods in this interface takes -/// a reference to standard stream as a first argument. This is where final messages needs to be directed -/// to. Also you are given all the information necessary to produce a message. -/// -/// @par Since Boost 1.62: -/// - Each formatter may indicate the default output stream. This is convenient for instance for streams intended -/// for automated processing that indicate a file. See @c get_default_stream_description for more details. -/// - Each formatter may manage its own log level through the getter/setter @c get_log_level and @c set_log_level . -/// -/// @see -/// - boost::unit_test::test_observer for an indication of the calls of the test observer interface -class BOOST_TEST_DECL unit_test_log_formatter { -public: - /// Types of log entries (messages written into a log) - enum log_entry_types { BOOST_UTL_ET_INFO, ///< Information message from the framework - BOOST_UTL_ET_MESSAGE, ///< Information message from the user - BOOST_UTL_ET_WARNING, ///< Warning (non error) condition notification message - BOOST_UTL_ET_ERROR, ///< Non fatal error notification message - BOOST_UTL_ET_FATAL_ERROR ///< Fatal error notification message - }; - - //! Constructor - unit_test_log_formatter() - : m_log_level(log_all_errors) - {} - - // Destructor - virtual ~unit_test_log_formatter() {} - - // @name Test start/finish - - /// Invoked at the beginning of test module execution - /// - /// @param[in] os output stream to write a messages to - /// @param[in] test_cases_amount total test case amount to be run - /// @see log_finish - virtual void log_start( std::ostream& os, counter_t test_cases_amount ) = 0; - - /// Invoked at the end of test module execution - /// - /// @param[in] os output stream to write a messages into - /// @see log_start - virtual void log_finish( std::ostream& os ) = 0; - - /// Invoked when Unit Test Framework build information is requested - /// - /// @param[in] os output stream to write a messages into - /// @param[in] log_build_info indicates if build info should be logged or not - virtual void log_build_info( std::ostream& os, bool log_build_info = true ) = 0; - // @} - - // @name Test unit start/finish - - /// Invoked when test unit starts (either test suite or test case) - /// - /// @param[in] os output stream to write a messages into - /// @param[in] tu test unit being started - /// @see test_unit_finish - virtual void test_unit_start( std::ostream& os, test_unit const& tu ) = 0; - - /// Invoked when test unit finishes - /// - /// @param[in] os output stream to write a messages into - /// @param[in] tu test unit being finished - /// @param[in] elapsed time in microseconds spend executing this test unit - /// @see test_unit_start - virtual void test_unit_finish( std::ostream& os, test_unit const& tu, unsigned long elapsed ) = 0; - - /// Invoked if test unit skipped for any reason - /// - /// @param[in] os output stream to write a messages into - /// @param[in] tu skipped test unit - /// @param[in] reason explanation why was it skipped - virtual void test_unit_skipped( std::ostream& os, test_unit const& tu, const_string /* reason */) - { - test_unit_skipped( os, tu ); - } - - /// Deprecated version of this interface - /// @deprecated - virtual void test_unit_skipped( std::ostream& /* os */, test_unit const& /* tu */) {} - - /// Invoked when a test unit is aborted - virtual void test_unit_aborted( std::ostream& /* os */, test_unit const& /* tu */) {} - - /// Invoked when a test unit times-out - virtual void test_unit_timed_out( std::ostream& /* os */, test_unit const& /* tu */) {} - - - // @} - - // @name Uncaught exception report - - /// Invoked when Unit Test Framework detects uncaught exception - /// - /// The framwork calls this function when an uncaught exception it detected. - /// This call is followed by context information: - /// - one call to @c entry_context_start, - /// - as many calls to @c log_entry_context as there are context entries - /// - one call to @c entry_context_finish - /// - /// The logging of the exception information is finilized by a call to @c log_exception_finish. - /// - /// @param[in] os output stream to write a messages into - /// @param[in] lcd information about the last checkpoint before the exception was triggered - /// @param[in] ex information about the caught exception - /// @see log_exception_finish - virtual void log_exception_start( std::ostream& os, log_checkpoint_data const& lcd, execution_exception const& ex ) = 0; - - /// Invoked when Unit Test Framework detects uncaught exception - /// - /// Call to this function finishes uncaught exception report. - /// @param[in] os output stream to write a messages into - /// @see log_exception_start - virtual void log_exception_finish( std::ostream& os ) = 0; - // @} - - // @name Regular log entry - - /// Invoked by Unit Test Framework to start new log entry - - /// Call to this function starts new log entry. It is followed by series of log_entry_value calls and finally call to log_entry_finish. - /// A log entry may consist of one or more values being reported. Some of these values will be plain strings, while others can be complicated - /// expressions in a form of "lazy" expression template lazy_ostream. - /// @param[in] os output stream to write a messages into - /// @param[in] led log entry attributes - /// @param[in] let log entry type log_entry_finish - /// @see log_entry_value, log_entry_finish - /// - /// @note call to this function may happen before any call to test_unit_start or all calls to test_unit_finish as the - /// framework might log errors raised during global initialization/shutdown. - virtual void log_entry_start( std::ostream& os, log_entry_data const& led, log_entry_types let ) = 0; - - /// Invoked by Unit Test Framework to report a log entry content - /// - /// This is one of two overloaded methods to report log entry content. This one is used to report plain string value. - /// @param[in] os output stream to write a messages into. - /// @param[in] value log entry string value - /// @see log_entry_start, log_entry_finish - virtual void log_entry_value( std::ostream& os, const_string value ) = 0; - - /// Invoked by Unit Test Framework to report a log entry content - - /// This is one of two overloaded methods to report log entry content. This one is used to report some complicated expression passed as - /// an expression template lazy_ostream. In most cases default implementation provided by the framework should work as is (it just converts - /// the lazy expression into a string. - /// @param[in] os output stream to write a messages into - /// @param[in] value log entry "lazy" value - /// @see log_entry_start, log_entry_finish - virtual void log_entry_value( std::ostream& os, lazy_ostream const& value ); // there is a default impl - - /// Invoked by Unit Test Framework to finish a log entry report - - /// @param[in] os output stream to write a messages into - /// @see log_entry_start, log_entry_start - virtual void log_entry_finish( std::ostream& os ) = 0; - // @} - - // @name Log entry context report - - /// Invoked by Unit Test Framework to start log entry context report - // - /// Unit Test Framework logs for failed assertions and uncaught exceptions context if one was defined by a test module. - /// Context consists of multiple "scopes" identified by description messages assigned by the test module using - /// BOOST_TEST_INFO/BOOST_TEST_CONTEXT statements. - /// @param[in] os output stream to write a messages into - /// @param[in] l entry log_level, to be used to fine tune the message - /// @see log_entry_context, entry_context_finish - virtual void entry_context_start( std::ostream& os, log_level l ) = 0; - - /// Invoked by Unit Test Framework to report log entry context "scope" description - // - /// Each "scope" description is reported by separate call to log_entry_context. - /// @param[in] os output stream to write a messages into - /// @param[in] l entry log_level, to be used to fine tune the message - /// @param[in] value context "scope" description - /// @see log_entry_start, entry_context_finish - virtual void log_entry_context( std::ostream& os, log_level l, const_string value ) = 0; - - /// Invoked by Unit Test Framework to finish log entry context report - /// - /// @param[in] os output stream to write a messages into - /// @param[in] l entry log_level, to be used to fine tune the message - /// @see log_entry_start, entry_context_context - virtual void entry_context_finish( std::ostream& os, log_level l ) = 0; - // @} - - // @name Log level management - - /// Sets the log level of the logger/formatter - /// - /// Some loggers need to manage the log level by their own. This - /// member function let the implementation decide of that. - /// @par Since Boost 1.62 - virtual void set_log_level(log_level new_log_level); - - /// Returns the log level of the logger/formatter - /// @par Since Boost 1.62 - virtual log_level get_log_level() const; - // @} - - - // @name Stream management - - /// Returns a default stream for this logger. - /// - /// The returned string describes the stream as if it was passed from - /// the command line @c "--log_sink" parameter. With that regards, @b stdout and @b stderr - /// have special meaning indicating the standard output or error stream respectively. - /// - /// @par Since Boost 1.62 - virtual std::string get_default_stream_description() const - { - return "stdout"; - } - - // @} - - -protected: - log_level m_log_level; - -}; - -} // namespace unit_test -} // namespace boost - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UNIT_TEST_LOG_FORMATTER_HPP_071894GER diff --git a/ThirdParty/boost/test/unit_test_suite.hpp b/ThirdParty/boost/test/unit_test_suite.hpp deleted file mode 100644 index f74a4c47a55b7cc79778405ca2b34f5fa6aa51bf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/unit_test_suite.hpp +++ /dev/null @@ -1,409 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -/// @file -/// @brief Defines Unit Test Framework public API -// *************************************************************************** - -#ifndef BOOST_TEST_UNIT_TEST_SUITE_HPP_071894GER -#define BOOST_TEST_UNIT_TEST_SUITE_HPP_071894GER - -// Boost.Test -#include <boost/test/detail/config.hpp> -#include <boost/test/framework.hpp> -#include <boost/test/tree/auto_registration.hpp> -#include <boost/test/tree/test_case_template.hpp> -#include <boost/test/tree/global_fixture.hpp> - - -#include <boost/test/detail/suppress_warnings.hpp> - - -#include <boost/test/detail/pp_variadic.hpp> - - - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** Non-auto (explicit) test case interface ************** // -// ************************************************************************** // - -#define BOOST_TEST_CASE_NAME( test_function, test_name ) \ -boost::unit_test::make_test_case( boost::function<void ()>(test_function), \ - test_name , \ - __FILE__, __LINE__ ) -#define BOOST_TEST_CASE( test_function ) \ -BOOST_TEST_CASE_NAME(test_function, BOOST_TEST_STRINGIZE( test_function) ) -#define BOOST_CLASS_TEST_CASE( test_function, tc_instance ) \ -boost::unit_test::make_test_case( (test_function), \ - BOOST_TEST_STRINGIZE( test_function ), \ - __FILE__, __LINE__, tc_instance ) - -// ************************************************************************** // -// ************** BOOST_TEST_SUITE ************** // -// ************************************************************************** // - -#define BOOST_TEST_SUITE( testsuite_name ) \ -( new boost::unit_test::test_suite( testsuite_name, __FILE__, __LINE__ ) ) - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_SUITE ************** // -// ************************************************************************** // - -#define BOOST_AUTO_TEST_SUITE_WITH_DECOR( suite_name, decorators ) \ -namespace suite_name { \ -BOOST_AUTO_TU_REGISTRAR( suite_name )( \ - BOOST_STRINGIZE( suite_name ), \ - __FILE__, __LINE__, \ - decorators ); \ -/**/ - -#define BOOST_AUTO_TEST_SUITE_NO_DECOR( suite_name ) \ - BOOST_AUTO_TEST_SUITE_WITH_DECOR( \ - suite_name, \ - boost::unit_test::decorator::collector_t::instance() ) \ -/**/ - -#if BOOST_PP_VARIADICS -#define BOOST_AUTO_TEST_SUITE( ... ) \ - BOOST_TEST_INVOKE_IF_N_ARGS( 1, \ - BOOST_AUTO_TEST_SUITE_NO_DECOR, \ - BOOST_AUTO_TEST_SUITE_WITH_DECOR, \ - __VA_ARGS__) \ -/**/ - -#else /* BOOST_PP_VARIADICS */ - -#define BOOST_AUTO_TEST_SUITE( suite_name ) \ - BOOST_AUTO_TEST_SUITE_NO_DECOR( suite_name ) \ -/**/ - - -#endif /* BOOST_PP_VARIADICS */ - -// ************************************************************************** // -// ************** BOOST_FIXTURE_TEST_SUITE ************** // -// ************************************************************************** // - -#define BOOST_FIXTURE_TEST_SUITE_WITH_DECOR(suite_name, F, decorators) \ - BOOST_AUTO_TEST_SUITE_WITH_DECOR( suite_name, decorators ) \ -typedef F BOOST_AUTO_TEST_CASE_FIXTURE; \ -/**/ - -#define BOOST_FIXTURE_TEST_SUITE_NO_DECOR( suite_name, F ) \ - BOOST_AUTO_TEST_SUITE_NO_DECOR( suite_name ) \ -typedef F BOOST_AUTO_TEST_CASE_FIXTURE; \ -/**/ - -#if BOOST_PP_VARIADICS - -#define BOOST_FIXTURE_TEST_SUITE( ... ) \ - BOOST_TEST_INVOKE_IF_N_ARGS( 2, \ - BOOST_FIXTURE_TEST_SUITE_NO_DECOR, \ - BOOST_FIXTURE_TEST_SUITE_WITH_DECOR, \ - __VA_ARGS__) \ -/**/ - -#else /* BOOST_PP_VARIADICS */ - -#define BOOST_FIXTURE_TEST_SUITE( suite_name, F ) \ - BOOST_FIXTURE_TEST_SUITE_NO_DECOR( suite_name, F ) \ -/**/ - - -#endif /* BOOST_PP_VARIADICS */ - - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_SUITE_END ************** // -// ************************************************************************** // - -#define BOOST_AUTO_TEST_SUITE_END() \ -BOOST_AUTO_TU_REGISTRAR( end_suite )( 1 ); \ -} \ -/**/ - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_CASE_EXPECTED_FAILURES ************** // -// ************************************************************************** // - -/// @deprecated use decorator instead -#define BOOST_AUTO_TEST_CASE_EXPECTED_FAILURES( test_name, n ) \ -BOOST_TEST_DECORATOR( * boost::unit_test::expected_failures( n ) ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_FIXTURE_TEST_CASE ************** // -// ************************************************************************** // - -#define BOOST_FIXTURE_TEST_CASE_WITH_DECOR( test_name, F, decorators ) \ -struct test_name : public F { void test_method(); }; \ - \ -static void BOOST_AUTO_TC_INVOKER( test_name )() \ -{ \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture ctor"); \ - test_name t; \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture setup"); \ - boost::unit_test::setup_conditional(t); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" test entry"); \ - t.test_method(); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture teardown"); \ - boost::unit_test::teardown_conditional(t); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture dtor"); \ -} \ - \ -struct BOOST_AUTO_TC_UNIQUE_ID( test_name ) {}; \ - \ -BOOST_AUTO_TU_REGISTRAR( test_name )( \ - boost::unit_test::make_test_case( \ - &BOOST_AUTO_TC_INVOKER( test_name ), \ - #test_name, __FILE__, __LINE__ ), \ - decorators ); \ - \ -void test_name::test_method() \ -/**/ - -#define BOOST_FIXTURE_TEST_CASE_NO_DECOR( test_name, F ) \ -BOOST_FIXTURE_TEST_CASE_WITH_DECOR( test_name, F, \ - boost::unit_test::decorator::collector_t::instance() ) \ -/**/ - -#if BOOST_PP_VARIADICS - -#define BOOST_FIXTURE_TEST_CASE( ... ) \ - BOOST_TEST_INVOKE_IF_N_ARGS( 2, \ - BOOST_FIXTURE_TEST_CASE_NO_DECOR, \ - BOOST_FIXTURE_TEST_CASE_WITH_DECOR, \ - __VA_ARGS__) \ -/**/ - -#else /* BOOST_PP_VARIADICS */ - -#define BOOST_FIXTURE_TEST_CASE( test_name, F ) \ - BOOST_FIXTURE_TEST_CASE_NO_DECOR(test_name, F) \ -/**/ - - -#endif /* BOOST_PP_VARIADICS */ - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_CASE ************** // -// ************************************************************************** // - -#define BOOST_AUTO_TEST_CASE_NO_DECOR( test_name ) \ - BOOST_FIXTURE_TEST_CASE_NO_DECOR( test_name, \ - BOOST_AUTO_TEST_CASE_FIXTURE ) \ -/**/ - -#define BOOST_AUTO_TEST_CASE_WITH_DECOR( test_name, decorators ) \ - BOOST_FIXTURE_TEST_CASE_WITH_DECOR( test_name, \ - BOOST_AUTO_TEST_CASE_FIXTURE, decorators ) \ -/**/ - -#if BOOST_PP_VARIADICS - -#define BOOST_AUTO_TEST_CASE( ... ) \ - BOOST_TEST_INVOKE_IF_N_ARGS( 1, \ - BOOST_AUTO_TEST_CASE_NO_DECOR, \ - BOOST_AUTO_TEST_CASE_WITH_DECOR, \ - __VA_ARGS__) \ -/**/ - -#else /* BOOST_PP_VARIADICS */ - -#define BOOST_AUTO_TEST_CASE( test_name ) \ - BOOST_AUTO_TEST_CASE_NO_DECOR( test_name ) \ -/**/ - - -#endif /* BOOST_PP_VARIADICS */ - -// ************************************************************************** // -// ************** BOOST_FIXTURE_TEST_CASE_TEMPLATE ************** // -// ************************************************************************** // - -#define BOOST_FIXTURE_TEST_CASE_TEMPLATE( test_name, type_name, TL, F ) \ -template<typename type_name> \ -struct test_name : public F \ -{ void test_method(); }; \ - \ -struct BOOST_AUTO_TC_INVOKER( test_name ) { \ - template<typename TestType> \ - static void run( boost::type<TestType>* = 0 ) \ - { \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture ctor"); \ - test_name<TestType> t; \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture setup"); \ - boost::unit_test::setup_conditional(t); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" test entry"); \ - t.test_method(); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture teardown");\ - boost::unit_test::teardown_conditional(t); \ - BOOST_TEST_CHECKPOINT('"' << #test_name << "\" fixture dtor"); \ - } \ -}; \ - \ -BOOST_AUTO_TU_REGISTRAR( test_name )( \ - boost::unit_test::ut_detail::template_test_case_gen< \ - BOOST_AUTO_TC_INVOKER( test_name ),TL >( \ - BOOST_STRINGIZE( test_name ), __FILE__, __LINE__ ), \ - boost::unit_test::decorator::collector_t::instance() ); \ - \ -template<typename type_name> \ -void test_name<type_name>::test_method() \ -/**/ - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_CASE_TEMPLATE ************** // -// ************************************************************************** // - -#define BOOST_AUTO_TEST_CASE_TEMPLATE( test_name, type_name, TL ) \ -BOOST_FIXTURE_TEST_CASE_TEMPLATE( test_name, type_name, TL, \ - BOOST_AUTO_TEST_CASE_FIXTURE ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_TEST_CASE_TEMPLATE ************** // -// ************************************************************************** // - -#define BOOST_TEST_CASE_TEMPLATE( name, typelist ) \ - boost::unit_test::ut_detail::template_test_case_gen<name,typelist>( \ - BOOST_TEST_STRINGIZE( name ), __FILE__, __LINE__ ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_TEST_CASE_TEMPLATE_FUNCTION ************** // -// ************************************************************************** // - -#define BOOST_TEST_CASE_TEMPLATE_FUNCTION( name, type_name ) \ -template<typename type_name> \ -void BOOST_JOIN( name, _impl )( boost::type<type_name>* ); \ - \ -struct name { \ - template<typename TestType> \ - static void run( boost::type<TestType>* frwrd = 0 ) \ - { \ - BOOST_JOIN( name, _impl )( frwrd ); \ - } \ -}; \ - \ -template<typename type_name> \ -void BOOST_JOIN( name, _impl )( boost::type<type_name>* ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_GLOBAL_FIXTURE ************** // -// ************************************************************************** // - -#define BOOST_GLOBAL_FIXTURE( F ) \ -static boost::unit_test::ut_detail::global_configuration_impl<F> BOOST_JOIN( gf_, F ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_TEST_GLOBAL_CONFIGURATION ************** // -// ************************************************************************** // - -#define BOOST_TEST_GLOBAL_CONFIGURATION( F ) \ -static boost::unit_test::ut_detail::global_configuration_impl<F> BOOST_JOIN( gf_, F ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_TEST_GLOBAL_FIXTURE ************** // -// ************************************************************************** // - -#define BOOST_TEST_GLOBAL_FIXTURE( F ) \ -static boost::unit_test::ut_detail::global_fixture_impl<F> BOOST_JOIN( gf_, F ) \ -/**/ - -// ************************************************************************** // -// ************** BOOST_TEST_DECORATOR ************** // -// ************************************************************************** // - -#define BOOST_TEST_DECORATOR( D ) \ -static boost::unit_test::decorator::collector_t const& \ -BOOST_TEST_APPEND_UNIQUE_ID(decorator_collector) BOOST_ATTRIBUTE_UNUSED = D; \ -/**/ - -// ************************************************************************** // -// ************** BOOST_AUTO_TEST_CASE_FIXTURE ************** // -// ************************************************************************** // - -namespace boost { namespace unit_test { namespace ut_detail { - -struct nil_t {}; - -} // namespace ut_detail -} // unit_test -} // namespace boost - -// Intentionally is in global namespace, so that FIXTURE_TEST_SUITE can reset it in user code. -typedef ::boost::unit_test::ut_detail::nil_t BOOST_AUTO_TEST_CASE_FIXTURE; - -// ************************************************************************** // -// ************** Auto registration facility helper macros ************** // -// ************************************************************************** // - -// Facility for having a unique name based on __LINE__ and __COUNTER__ (later if available) -#if defined(__COUNTER__) - #define BOOST_TEST_INTERNAL_HAS_COUNTER -#endif - -#if defined(BOOST_TEST_INTERNAL_HAS_COUNTER) - #define BOOST_TEST_APPEND_UNIQUE_ID( name ) \ - BOOST_JOIN( BOOST_JOIN( name, __LINE__ ), __COUNTER__) - /**/ -#else - #define BOOST_TEST_APPEND_UNIQUE_ID( name ) \ - BOOST_JOIN( name, __LINE__ ) - /**/ -#endif -/**/ - -#define BOOST_AUTO_TU_REGISTRAR( test_name ) \ -static boost::unit_test::ut_detail::auto_test_unit_registrar \ -BOOST_TEST_APPEND_UNIQUE_ID( BOOST_JOIN( test_name, _registrar ) ) BOOST_ATTRIBUTE_UNUSED \ -/**/ -#define BOOST_AUTO_TC_INVOKER( test_name ) BOOST_JOIN( test_name, _invoker ) -#define BOOST_AUTO_TC_UNIQUE_ID( test_name ) BOOST_JOIN( test_name, _id ) - -// ************************************************************************** // -// ************** BOOST_TEST_MAIN ************** // -// ************************************************************************** // - -#if defined(BOOST_TEST_MAIN) - -// initializing the master test suite name from the user defined macros -// this function should be seen exactly once. -#ifdef BOOST_TEST_MODULE -static const boost::unit_test::framework::impl::master_test_suite_name_setter mtsetter(BOOST_TEST_STRINGIZE( BOOST_TEST_MODULE ).trim( "\"" )); -#endif - -#ifdef BOOST_TEST_ALTERNATIVE_INIT_API -bool init_unit_test() { -#else -::boost::unit_test::test_suite* -init_unit_test_suite( int, char* [] ) { -#endif - -#ifdef BOOST_TEST_ALTERNATIVE_INIT_API - return true; -} -#else - return 0; -} -#endif - -#endif - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - - -#endif // BOOST_TEST_UNIT_TEST_SUITE_HPP_071894GER - diff --git a/ThirdParty/boost/test/utils/basic_cstring/basic_cstring.hpp b/ThirdParty/boost/test/utils/basic_cstring/basic_cstring.hpp deleted file mode 100644 index d1953dbd36f73dbc67a73e28ff495d4f050eb1e4..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/basic_cstring/basic_cstring.hpp +++ /dev/null @@ -1,782 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : class basic_cstring wraps C string and provide std_string like -// interface -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_BASIC_CSTRING_HPP -#define BOOST_TEST_UTILS_BASIC_CSTRING_HPP - -// Boost.Test -#include <boost/test/utils/basic_cstring/basic_cstring_fwd.hpp> -#include <boost/test/utils/basic_cstring/bcs_char_traits.hpp> - -// Boost -#include <boost/type_traits/remove_cv.hpp> - -// STL -#include <string> - -#if defined(BOOST_TEST_STRING_VIEW) -#include <string_view> -#endif - -#include <boost/test/detail/suppress_warnings.hpp> - -//____________________________________________________________________________// - -namespace boost { - -namespace unit_test { - -// ************************************************************************** // -// ************** basic_cstring ************** // -// ************************************************************************** // - -template<typename CharT> -class BOOST_SYMBOL_VISIBLE basic_cstring { - typedef basic_cstring<CharT> self_type; -public: - // Subtypes - typedef ut_detail::bcs_char_traits<CharT> traits_type; - typedef typename traits_type::std_string std_string; - - typedef CharT value_type; - typedef typename remove_cv<value_type>::type value_ret_type; - typedef value_type* pointer; - typedef value_type const* const_pointer; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - typedef value_type const* const_iterator; - typedef value_type* iterator; - - // !! should also present reverse_iterator, const_reverse_iterator - -#if !BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) && !defined(__DCC__) - BOOST_STATIC_CONSTANT(size_type, npos = static_cast<size_type>(-1)); -#else - // IBM/VisualAge version 6 is not able to handle enums larger than 4 bytes. - // But size_type is 8 bytes in 64bit mode. - static const size_type npos = -1 ; -#endif - - static pointer null_str(); - - // Constructors; default copy constructor is generated by compiler - basic_cstring(); - basic_cstring( basic_cstring const & ); - basic_cstring( std_string const& s ); - basic_cstring( pointer s ); - template<typename LenType> - basic_cstring( pointer s, LenType len ) : m_begin( s ), m_end( m_begin + len ) {} - basic_cstring( pointer first, pointer last ); - - // data access methods - value_ret_type operator[]( size_type index ) const; - value_ret_type at( size_type index ) const; - - // size operators - size_type size() const; - bool is_empty() const; - void clear(); - void resize( size_type new_len ); - - // !! only for STL container conformance use is_empty instead - bool empty() const; - - // Trimming - self_type& trim_right( size_type trim_size ); - self_type& trim_left( size_type trim_size ); - self_type& trim_right( iterator it ); - self_type& trim_left( iterator it ); -#if !BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(800)) - self_type& trim_left( self_type exclusions = self_type() ) ; - self_type& trim_right( self_type exclusions = self_type() ) ; - self_type& trim( self_type exclusions = self_type() ) ; -#else - // VA C++/XL C++ v6 and v8 has in this case a problem with the default arguments. - self_type& trim_left( self_type exclusions ); - self_type& trim_right( self_type exclusions ); - self_type& trim( self_type exclusions ); - self_type& trim_left() { return trim_left( self_type() ); } - self_type& trim_right() { return trim_right( self_type() ); } - self_type& trim() { return trim( self_type() ); } -#endif - - // Assignment operators - basic_cstring& operator=( self_type const& s ); - basic_cstring& operator=( std_string const& s ); - basic_cstring& operator=( pointer s ); - - template<typename CharT2> - basic_cstring& assign( basic_cstring<CharT2> const& s ) - { - return *this = basic_cstring<CharT>( s.begin(), s.end() ); - } - template<typename PosType, typename LenType> - basic_cstring& assign( self_type const& s, PosType pos, LenType len ) - { - return *this = self_type( s.m_begin + pos, len ); - } - - basic_cstring& assign( std_string const& s ); - template<typename PosType, typename LenType> - basic_cstring& assign( std_string const& s, PosType pos, LenType len ) - { - return *this = self_type( s.c_str() + pos, len ); - } - basic_cstring& assign( pointer s ); - template<typename LenType> - basic_cstring& assign( pointer s, LenType len ) - { - return *this = self_type( s, len ); - } - basic_cstring& assign( pointer f, pointer l ); - - // swapping - void swap( self_type& s ); - - // Iterators - iterator begin(); - const_iterator begin() const; - iterator end(); - const_iterator end() const; - - // !! should have rbegin, rend - - // substring search operation - size_type find( basic_cstring ) const; - size_type rfind( basic_cstring ) const; - self_type substr( size_type beg_index, size_type end_index = npos ) const; - -private: - static self_type default_trim_ex(); - - // Data members - iterator m_begin; - iterator m_end; - static CharT null; -}; - -// ************************************************************************** // -// ************** cstring_string_view_helper ************** // -// ************************************************************************** // - - -#if defined(BOOST_TEST_STRING_VIEW) -// Helper for instanciating a subclass of cstring using a string_view. We do not -// change the API of cstring using BOOST_TEST_STRING_VIEW as the code should remain -// compatible between boost.test and test module using different compiler options. -//! @internal -template <class CharT, class string_view_t = std::basic_string_view<CharT>> -class BOOST_SYMBOL_VISIBLE stringview_cstring_helper : public basic_cstring<CharT> { -public: - stringview_cstring_helper(string_view_t const& sv) - : basic_cstring<CharT>(const_cast<CharT*>(sv.data()), sv.size()) - {} -}; -#endif - - -// ************************************************************************** // -// ************** basic_cstring::impl ************** // -// ************************************************************************** // - -//____________________________________________________________________________// - -template<typename CharT> -CharT basic_cstring<CharT>::null = 0; - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::pointer -basic_cstring<CharT>::null_str() -{ - return &null; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline -basic_cstring<CharT>::basic_cstring() -: m_begin( null_str() ) -, m_end( m_begin ) -{ -} - -//____________________________________________________________________________// - -template<typename CharT> -inline -basic_cstring<CharT>::basic_cstring(basic_cstring const & s) -: m_begin( s.m_begin ) -, m_end( s.m_end ) -{ -} - -//____________________________________________________________________________// - -template<typename CharT> -inline -basic_cstring<CharT>::basic_cstring( std_string const& s ) -: m_begin( s.c_str() ) -, m_end( m_begin + s.size() ) -{ -} - -//____________________________________________________________________________// - -template<typename CharT> -inline -basic_cstring<CharT>::basic_cstring( pointer s ) -: m_begin( s ? s : null_str() ) -, m_end ( m_begin + (s ? traits_type::length( s ) : 0 ) ) -{ -} - -//____________________________________________________________________________// - -template<typename CharT> -inline -basic_cstring<CharT>::basic_cstring( pointer first, pointer last ) -: m_begin( first ) -, m_end( last ) -{ -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::value_ret_type -basic_cstring<CharT>::operator[]( size_type index ) const -{ - return m_begin[index]; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::value_ret_type -basic_cstring<CharT>::at( size_type index ) const -{ - if( m_begin + index >= m_end ) - return static_cast<value_type>(0); - - return m_begin[index]; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::size_type -basic_cstring<CharT>::size() const -{ - return static_cast<size_type>(m_end - m_begin); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -basic_cstring<CharT>::is_empty() const -{ - return m_end == m_begin; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -basic_cstring<CharT>::empty() const -{ - return is_empty(); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline void -basic_cstring<CharT>::clear() -{ - m_begin = m_end; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline void -basic_cstring<CharT>::resize( size_type new_len ) -{ - if( m_begin + new_len < m_end ) - m_end = m_begin + new_len; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_left( size_type trim_size ) -{ - m_begin += trim_size; - if( m_end <= m_begin ) - clear(); - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_left( iterator it ) -{ - m_begin = it; - if( m_end <= m_begin ) - clear(); - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_left( basic_cstring exclusions ) -{ - if( exclusions.is_empty() ) - exclusions = default_trim_ex(); - - iterator it; - for( it = begin(); it != end(); ++it ) { - if( traits_type::find( exclusions.begin(), exclusions.size(), *it ) == reinterpret_cast<pointer>(0) ) - break; - } - - return trim_left( it ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_right( size_type trim_size ) -{ - m_end -= trim_size; - if( m_end <= m_begin ) - clear(); - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_right( iterator it ) -{ - m_end = it; - if( m_end <= m_begin ) - clear(); - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim_right( basic_cstring exclusions ) -{ - if( exclusions.is_empty() ) - exclusions = default_trim_ex(); - - iterator it; - - for( it = end()-1; it != begin()-1; --it ) { - if( self_type::traits_type::find( exclusions.begin(), exclusions.size(), *it ) == reinterpret_cast<pointer>(0) ) - break; - } - - return trim_right( it+1 ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::trim( basic_cstring exclusions ) -{ - trim_left( exclusions ); - trim_right( exclusions ); - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::operator=( basic_cstring<CharT> const& s ) -{ - m_begin = s.m_begin; - m_end = s.m_end; - - return *this; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::operator=( std_string const& s ) -{ - return *this = self_type( s ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::operator=( pointer s ) -{ - return *this = self_type( s ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::assign( std_string const& s ) -{ - return *this = self_type( s ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::assign( pointer s ) -{ - return *this = self_type( s ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT>& -basic_cstring<CharT>::assign( pointer f, pointer l ) -{ - return *this = self_type( f, l ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline void -basic_cstring<CharT>::swap( basic_cstring<CharT>& s ) -{ - // do not want to include alogrithm - pointer tmp1 = m_begin; - pointer tmp2 = m_end; - - m_begin = s.m_begin; - m_end = s.m_end; - - s.m_begin = tmp1; - s.m_end = tmp2; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::iterator -basic_cstring<CharT>::begin() -{ - return m_begin; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::const_iterator -basic_cstring<CharT>::begin() const -{ - return m_begin; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::iterator -basic_cstring<CharT>::end() -{ - return m_end; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::const_iterator -basic_cstring<CharT>::end() const -{ - return m_end; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::size_type -basic_cstring<CharT>::find( basic_cstring<CharT> str ) const -{ - if( str.is_empty() || str.size() > size() ) - return static_cast<size_type>(npos); - - const_iterator it = begin(); - const_iterator last = end() - str.size() + 1; - - while( it != last ) { - if( traits_type::compare( it, str.begin(), str.size() ) == 0 ) - break; - - ++it; - } - - return it == last ? npos : static_cast<size_type>(it - begin()); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline typename basic_cstring<CharT>::size_type -basic_cstring<CharT>::rfind( basic_cstring<CharT> str ) const -{ - if( str.is_empty() || str.size() > size() ) - return static_cast<size_type>(npos); - - const_iterator it = end() - str.size(); - const_iterator last = begin()-1; - - while( it != last ) { - if( traits_type::compare( it, str.begin(), str.size() ) == 0 ) - break; - - --it; - } - - return it == last ? static_cast<size_type>(npos) : static_cast<size_type>(it - begin()); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT> -basic_cstring<CharT>::substr( size_type beg_index, size_type end_index ) const -{ - return beg_index > size() - ? self_type() - : end_index > size() - ? self_type( m_begin + beg_index, m_end ) - : self_type( m_begin + beg_index, m_begin + end_index ); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline basic_cstring<CharT> -basic_cstring<CharT>::default_trim_ex() -{ - static CharT ws[3] = { CharT(' '), CharT('\t'), CharT('\n') }; // !! wide case - - return self_type( ws, 3 ); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** comparison operators ************** // -// ************************************************************************** // - -template<typename CharT1,typename CharT2> -inline bool -operator==( basic_cstring<CharT1> const& s1, basic_cstring<CharT2> const& s2 ) -{ - typedef typename basic_cstring<CharT1>::traits_type traits_type; - return s1.size() == s2.size() && - traits_type::compare( s1.begin(), s2.begin(), s1.size() ) == 0; -} - -//____________________________________________________________________________// - -template<typename CharT1,typename CharT2> -inline bool -operator==( basic_cstring<CharT1> const& s1, CharT2* s2 ) -{ -#if !defined(__DMC__) - return s1 == basic_cstring<CharT2>( s2 ); -#else - return s1 == basic_cstring<CharT2 const>( s2 ); -#endif -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator==( basic_cstring<CharT> const& s1, typename basic_cstring<CharT>::std_string const& s2 ) -{ - return s1 == basic_cstring<CharT>( s2 ); -} - -//____________________________________________________________________________// - -template<typename CharT1,typename CharT2> -inline bool -operator==( CharT1* s2, basic_cstring<CharT2> const& s1 ) -{ - return s1 == s2; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator==( typename basic_cstring<CharT>::std_string const& s2, basic_cstring<CharT> const& s1 ) -{ - return s1 == s2; -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator!=( basic_cstring<CharT> const& s1, CharT* s2 ) -{ - return !(s1 == s2); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator!=( CharT* s2, basic_cstring<CharT> const& s1 ) -{ - return !(s1 == s2); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator!=( basic_cstring<CharT> const& s1, basic_cstring<CharT> const& s2 ) -{ - return !(s1 == s2); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator!=( basic_cstring<CharT> const& s1, typename basic_cstring<CharT>::std_string const& s2 ) -{ - return !(s1 == s2); -} - -//____________________________________________________________________________// - -template<typename CharT> -inline bool -operator!=( typename basic_cstring<CharT>::std_string const& s2, basic_cstring<CharT> const& s1 ) -{ - return !(s1 == s2); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** first_char ************** // -// ************************************************************************** // - -template<typename CharT> -inline typename basic_cstring<CharT>::value_ret_type -first_char( basic_cstring<CharT> source ) -{ - typedef typename basic_cstring<CharT>::value_ret_type res_type; - - return source.is_empty() ? static_cast<res_type>(0) : *source.begin(); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** last_char ************** // -// ************************************************************************** // - -template<typename CharT> -inline typename basic_cstring<CharT>::value_ret_type -last_char( basic_cstring<CharT> source ) -{ - typedef typename basic_cstring<CharT>::value_ret_type res_type; - - return source.is_empty() ? static_cast<res_type>(0) : *(source.end()-1); -} - -//____________________________________________________________________________// - -// ************************************************************************** // -// ************** assign_op ************** // -// ************************************************************************** // - -template<typename CharT1, typename CharT2> -inline void -assign_op( std::basic_string<CharT1>& target, basic_cstring<CharT2> src, int ) -{ - target.assign( src.begin(), src.size() ); -} - -//____________________________________________________________________________// - -template<typename CharT1, typename CharT2> -inline std::basic_string<CharT1>& -operator+=( std::basic_string<CharT1>& target, basic_cstring<CharT2> const& str ) -{ - target.append( str.begin(), str.end() ); - return target; -} - -//____________________________________________________________________________// - -template<typename CharT1, typename CharT2> -inline std::basic_string<CharT1> -operator+( std::basic_string<CharT1> const& lhs, basic_cstring<CharT2> const& rhs ) -{ - std::basic_string<CharT1> res( lhs ); - - res.append( rhs.begin(), rhs.end() ); - return res; -} - -//____________________________________________________________________________// - -} // namespace unit_test - -} // namespace boost - -//____________________________________________________________________________// - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UTILS_BASIC_CSTRING_HPP diff --git a/ThirdParty/boost/test/utils/basic_cstring/basic_cstring_fwd.hpp b/ThirdParty/boost/test/utils/basic_cstring/basic_cstring_fwd.hpp deleted file mode 100644 index 0401e832156e2dcf9582e47ea43b8e6df6a56684..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/basic_cstring/basic_cstring_fwd.hpp +++ /dev/null @@ -1,46 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : basic_cstring class wrap C string and provide std_string like -// interface -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_BASIC_CSTRING_FWD_HPP -#define BOOST_TEST_UTILS_BASIC_CSTRING_FWD_HPP - -#include <boost/test/detail/config.hpp> - - -namespace boost { - -namespace unit_test { - -template<typename CharT> class BOOST_SYMBOL_VISIBLE basic_cstring; -typedef basic_cstring<char const> const_string; -#if BOOST_WORKAROUND(__DECCXX_VER, BOOST_TESTED_AT(60590041)) -typedef const_string literal_string; -#else -typedef const_string const literal_string; -#endif - -typedef char const* const c_literal_string; - -#if defined(BOOST_TEST_STRING_VIEW) -template <class CharT, class string_view_t> -class BOOST_SYMBOL_VISIBLE stringview_cstring_helper; -#endif - - -} // namespace unit_test - -} // namespace boost - -#endif // BOOST_TEST_UTILS_BASIC_CSTRING_FWD_HPP diff --git a/ThirdParty/boost/test/utils/is_cstring.hpp b/ThirdParty/boost/test/utils/is_cstring.hpp deleted file mode 100644 index ffec3657ac6ead948c74a2e9a5cc6dfecef22b49..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/is_cstring.hpp +++ /dev/null @@ -1,133 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -//! @file -//! Defines the is_cstring type trait -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_IS_CSTRING_HPP -#define BOOST_TEST_UTILS_IS_CSTRING_HPP - -// Boost -#include <boost/mpl/bool.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/decay.hpp> -#include <boost/type_traits/remove_pointer.hpp> -#include <boost/type_traits/remove_const.hpp> -#include <boost/type_traits/add_const.hpp> - -#include <boost/test/utils/basic_cstring/basic_cstring_fwd.hpp> -#include <string> - -#if defined(BOOST_TEST_STRING_VIEW) -#include <string_view> -#endif - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { - -// ************************************************************************** // -// ************** is_cstring ************** // -// ************************************************************************** // - -namespace ut_detail { - -template<typename T> -struct is_cstring_impl : public mpl::false_ {}; - -template<typename T> -struct is_cstring_impl<T const*> : public is_cstring_impl<T*> {}; - -template<typename T> -struct is_cstring_impl<T const* const> : public is_cstring_impl<T*> {}; - -template<> -struct is_cstring_impl<char*> : public mpl::true_ {}; - -template<> -struct is_cstring_impl<wchar_t*> : public mpl::true_ {}; - -template <typename T, bool is_cstring = is_cstring_impl<typename boost::decay<T>::type>::value > -struct deduce_cstring_transform_impl; - -template <typename T, bool is_cstring > -struct deduce_cstring_transform_impl<T&, is_cstring> : public deduce_cstring_transform_impl<T, is_cstring>{}; - -template <typename T, bool is_cstring > -struct deduce_cstring_transform_impl<T const, is_cstring> : public deduce_cstring_transform_impl<T, is_cstring>{}; - -template <typename T> -struct deduce_cstring_transform_impl<T, true> { - typedef typename boost::add_const< - typename boost::remove_pointer< - typename boost::decay<T>::type - >::type - >::type U; - typedef boost::unit_test::basic_cstring<U> type; -}; - -template <typename T> -struct deduce_cstring_transform_impl< T, false > { - typedef typename - boost::remove_const< - typename boost::remove_reference<T>::type - >::type type; -}; - -template <typename T> -struct deduce_cstring_transform_impl< std::basic_string<T, std::char_traits<T> >, false > { - typedef boost::unit_test::basic_cstring<typename boost::add_const<T>::type> type; -}; - -#if defined(BOOST_TEST_STRING_VIEW) -template <typename T> -struct deduce_cstring_transform_impl< std::basic_string_view<T, std::char_traits<T> >, false > { -private: - using sv_t = std::basic_string_view<T, std::char_traits<T> > ; - -public: - using type = stringview_cstring_helper<typename boost::add_const<T>::type, sv_t>; -}; -#endif - -} // namespace ut_detail - -template<typename T> -struct is_cstring : public ut_detail::is_cstring_impl<typename decay<T>::type> {}; - -template<typename T, bool is_cstring = is_cstring<typename boost::decay<T>::type>::value > -struct is_cstring_comparable: public mpl::false_ {}; - -template<typename T> -struct is_cstring_comparable< T, true > : public mpl::true_ {}; - -template<typename T> -struct is_cstring_comparable< std::basic_string<T, std::char_traits<T> >, false > : public mpl::true_ {}; - -#if defined(BOOST_TEST_STRING_VIEW) -template<typename T> -struct is_cstring_comparable< std::basic_string_view<T, std::char_traits<T> >, false > : public mpl::true_ {}; -#endif - -template<typename T> -struct is_cstring_comparable< boost::unit_test::basic_cstring<T>, false > : public mpl::true_ {}; - -template <class T> -struct deduce_cstring_transform { - typedef typename - boost::remove_const< - typename boost::remove_reference<T>::type - >::type U; - typedef typename ut_detail::deduce_cstring_transform_impl<typename boost::decay<U>::type>::type type; -}; - -} // namespace unit_test -} // namespace boost - -#endif // BOOST_TEST_UTILS_IS_CSTRING_HPP diff --git a/ThirdParty/boost/test/utils/runtime/cla/argv_traverser.hpp b/ThirdParty/boost/test/utils/runtime/cla/argv_traverser.hpp deleted file mode 100644 index 476eaae2a0c297edd4ef290665122d3dce6cb422..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/runtime/cla/argv_traverser.hpp +++ /dev/null @@ -1,106 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// Use, modification, and distribution are subject to 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : defines facility to hide input traversing details -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_RUNTIME_CLA_ARGV_TRAVERSER_HPP -#define BOOST_TEST_UTILS_RUNTIME_CLA_ARGV_TRAVERSER_HPP - -// Boost.Test Runtime parameters -#include <boost/test/utils/runtime/fwd.hpp> -#include <cstring> - -#include <boost/test/detail/suppress_warnings.hpp> - -namespace boost { -namespace runtime { -namespace cla { - -// ************************************************************************** // -// ************** runtime::cla::argv_traverser ************** // -// ************************************************************************** // - -class argv_traverser { - typedef char const** argv_type; -public: - /// Constructs traverser based on argc/argv pair - /// argv is taken "by reference" and later can be - /// updated in remainder method - argv_traverser( int argc, argv_type argv ) - : m_argc( argc ) - , m_curr_token( 0 ) - , m_token_size( 0 ) - , m_argv( argv ) - { - // save program name - save_token(); - } - - /// Returns new argc - int remainder() - { - return static_cast<int>(m_argc); - } - - /// Returns true, if we reached end on input - bool eoi() const - { - return m_curr_token == m_argc; - } - - /// Returns current token in the input - cstring current_token() - { - if( eoi() ) - return cstring(); - - return cstring( m_argv[m_curr_token], m_token_size ); - } - - /// Saves current token for remainder - void save_token() - { - ++m_curr_token; - - if( !eoi() ) - m_token_size = ::strlen( m_argv[m_curr_token] ); - } - - /// Commit current token and iterate to next one - void next_token() - { - if( !eoi() ) { - for( std::size_t i = m_curr_token; i < m_argc-1; ++i ) - m_argv[i] = m_argv[i + 1]; - - --m_argc; - - m_token_size = ::strlen( m_argv[m_curr_token] ); - } - } - -private: - - // Data members - std::size_t m_argc; // total number of arguments - std::size_t m_curr_token; // current token index in argv - std::size_t m_token_size; // current token size - argv_type m_argv; // all arguments -}; - -} // namespace cla -} // namespace runtime -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UTILS_RUNTIME_CLA_ARGV_TRAVERSER_HPP diff --git a/ThirdParty/boost/test/utils/setcolor.hpp b/ThirdParty/boost/test/utils/setcolor.hpp deleted file mode 100644 index c09e188f7c41a9cacad807b17a5610f04a86e3e0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/setcolor.hpp +++ /dev/null @@ -1,351 +0,0 @@ -// (C) Copyright Gennadiy Rozental 2001. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// File : $RCSfile$ -// -// Version : $Revision$ -// -// Description : contains definition for setcolor iostream manipulator -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_SETCOLOR_HPP -#define BOOST_TEST_UTILS_SETCOLOR_HPP - -// Boost.Test -#include <boost/test/detail/config.hpp> - -#include <boost/core/ignore_unused.hpp> - -// STL -#include <iostream> -#include <cstdio> -#include <cassert> - -#include <boost/test/detail/suppress_warnings.hpp> - -#ifdef _WIN32 - #include <windows.h> - - #if defined(__MINGW32__) && !defined(COMMON_LVB_UNDERSCORE) - // mingw badly mimicking windows.h - #define COMMON_LVB_UNDERSCORE 0x8000 - #endif -#endif - -//____________________________________________________________________________// - -namespace boost { -namespace unit_test { -namespace utils { - -// ************************************************************************** // -// ************** term_attr ************** // -// ************************************************************************** // - -struct term_attr { enum _ { - NORMAL = 0, - BRIGHT = 1, - DIM = 2, - UNDERLINE = 4, - BLINK = 5, - REVERSE = 7, - CROSSOUT = 9 -}; }; - -// ************************************************************************** // -// ************** term_color ************** // -// ************************************************************************** // - -struct term_color { enum _ { - BLACK = 0, - RED = 1, - GREEN = 2, - YELLOW = 3, - BLUE = 4, - MAGENTA = 5, - CYAN = 6, - WHITE = 7, - ORIGINAL = 9 -}; }; - -// ************************************************************************** // -// ************** setcolor ************** // -// ************************************************************************** // - -#ifndef _WIN32 -class setcolor { -public: - typedef int state; - - // Constructor - explicit setcolor( bool is_color_output = false, - term_attr::_ attr = term_attr::NORMAL, - term_color::_ fg = term_color::ORIGINAL, - term_color::_ bg = term_color::ORIGINAL, - state* /* unused */= NULL) - : m_is_color_output(is_color_output) - { - m_command_size = std::sprintf( m_control_command, "%c[%c;3%c;4%cm", - 0x1B, - static_cast<char>(attr + '0'), - static_cast<char>(fg + '0'), - static_cast<char>(bg + '0')); - } - - explicit setcolor(bool is_color_output, - state* /* unused */) - : m_is_color_output(is_color_output) - { - m_command_size = std::sprintf(m_control_command, "%c[%c;3%c;4%cm", - 0x1B, - static_cast<char>(term_attr::NORMAL + '0'), - static_cast<char>(term_color::ORIGINAL + '0'), - static_cast<char>(term_color::ORIGINAL + '0')); - } - - friend std::ostream& - operator<<( std::ostream& os, setcolor const& sc ) - { - if (sc.m_is_color_output && (&os == &std::cout || &os == &std::cerr)) { - return os.write( sc.m_control_command, sc.m_command_size ); - } - return os; - } - -private: - // Data members - bool m_is_color_output; - char m_control_command[13]; - int m_command_size; -}; - -#else - -class setcolor { - -protected: - void set_console_color(std::ostream& os, WORD *attributes = NULL) const { - if (!m_is_color_output || m_state_saved) { - return; - } - DWORD console_type; - if (&os == &std::cout) { - console_type = STD_OUTPUT_HANDLE; - } - else if (&os == &std::cerr) { - console_type = STD_ERROR_HANDLE; - } - else { - return; - } - HANDLE hConsole = GetStdHandle(console_type); - - if(hConsole == INVALID_HANDLE_VALUE || hConsole == NULL ) - return; - - state console_attributes; - if(attributes != NULL || (m_restore_state && m_s)) { - if (attributes != NULL) { - console_attributes = *attributes; - } - else { - console_attributes = *m_s; - *m_s = state(); - } - SetConsoleTextAttribute(hConsole, console_attributes); - return; - } - - CONSOLE_SCREEN_BUFFER_INFO consoleInfo; - GetConsoleScreenBufferInfo(hConsole, &consoleInfo); - console_attributes = consoleInfo.wAttributes; - - if (!m_state_saved && m_s) { - assert(!m_restore_state); - // we can save the state only the first time this object is used - // for modifying the console. - *m_s = console_attributes; - m_state_saved = true; - } - - WORD fg_attr = 0; - switch(m_fg) - { - case term_color::WHITE: - fg_attr = FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE; - break; - case term_color::BLACK: - fg_attr = 0; - break; - case term_color::RED: - fg_attr = FOREGROUND_RED; - break; - case term_color::GREEN: - fg_attr = FOREGROUND_GREEN; - break; - case term_color::CYAN: - fg_attr = FOREGROUND_GREEN | FOREGROUND_BLUE; - break; - case term_color::MAGENTA: - fg_attr = FOREGROUND_RED | FOREGROUND_BLUE; - break; - case term_color::BLUE: - fg_attr = FOREGROUND_BLUE; - break; - case term_color::YELLOW: - fg_attr = FOREGROUND_RED | FOREGROUND_GREEN; - break; - case term_color::ORIGINAL: - default: - fg_attr = console_attributes & (FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE); - break; - } - - WORD bg_attr = 0; - switch(m_bg) - { - case term_color::BLACK: - bg_attr = 0; - break; - case term_color::WHITE: - bg_attr = BACKGROUND_RED | BACKGROUND_GREEN | BACKGROUND_BLUE; - break; - case term_color::RED: - bg_attr = BACKGROUND_RED; - break; - case term_color::GREEN: - bg_attr = BACKGROUND_GREEN; - break; - case term_color::BLUE: - bg_attr = BACKGROUND_BLUE; - break; - case term_color::ORIGINAL: - default: - bg_attr = console_attributes & (BACKGROUND_RED | BACKGROUND_GREEN | BACKGROUND_BLUE); - break; - } - - WORD text_attr = 0; - switch(m_attr) - { - case term_attr::BRIGHT: - text_attr = FOREGROUND_INTENSITY; - break; - case term_attr::UNDERLINE: - text_attr = COMMON_LVB_UNDERSCORE; - break; - default: - break; - } - - SetConsoleTextAttribute(hConsole, fg_attr | bg_attr | text_attr); - return; - } - -public: - typedef WORD state; - - // Constructor - explicit setcolor( - bool is_color_output = false, - term_attr::_ attr = term_attr::NORMAL, - term_color::_ fg = term_color::ORIGINAL, - term_color::_ bg = term_color::ORIGINAL, - state* s = NULL) - : m_is_color_output(is_color_output) - , m_attr(attr) - , m_fg(fg) - , m_bg(bg) - , m_s(s) - , m_restore_state(false) - , m_state_saved(false) - {} - - explicit setcolor( - bool is_color_output, - state* s) - : m_is_color_output(is_color_output) - , m_attr(term_attr::NORMAL) - , m_fg(term_color::ORIGINAL) - , m_bg(term_color::ORIGINAL) - , m_s(s) - , m_restore_state(true) - , m_state_saved(false) - {} - - friend std::ostream& - operator<<( std::ostream& os, setcolor const& sc ) - { - sc.set_console_color(os); - return os; - } - -private: - bool m_is_color_output; - term_attr::_ m_attr; - term_color::_ m_fg; - term_color::_ m_bg; - state* m_s; - // indicates that the instance has been initialized to restore a previously - // stored state - bool m_restore_state; - // indicates the first time we pull and set the console information. - mutable bool m_state_saved; -}; - -#endif -// ************************************************************************** // -// ************** scope_setcolor ************** // -// ************************************************************************** // - -struct scope_setcolor { - scope_setcolor() - : m_os( 0 ) - , m_state() - , m_is_color_output(false) - {} - - explicit scope_setcolor( - bool is_color_output, - std::ostream& os, - term_attr::_ attr = term_attr::NORMAL, - term_color::_ fg = term_color::ORIGINAL, - term_color::_ bg = term_color::ORIGINAL ) - : m_os( &os ) - , m_is_color_output(is_color_output) - { - os << setcolor(is_color_output, attr, fg, bg, &m_state); - } - - ~scope_setcolor() - { - if (m_os) { - *m_os << setcolor(m_is_color_output, &m_state); - } - } -private: - scope_setcolor(const scope_setcolor& r); - scope_setcolor& operator=(const scope_setcolor& r); - // Data members - std::ostream* m_os; - setcolor::state m_state; - bool m_is_color_output; -}; - - -#define BOOST_TEST_SCOPE_SETCOLOR( is_color_output, os, attr, color ) \ - utils::scope_setcolor const sc(is_color_output, os, utils::attr, utils::color); \ - boost::ignore_unused( sc ) \ -/**/ - -} // namespace utils -} // namespace unit_test -} // namespace boost - -#include <boost/test/detail/enable_warnings.hpp> - -#endif // BOOST_TEST_UTILS_SETCOLOR_HPP diff --git a/ThirdParty/boost/test/utils/timer.hpp b/ThirdParty/boost/test/utils/timer.hpp deleted file mode 100644 index 1241692e4e30d73867651b5e2ffce3b4f0dcafb0..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/test/utils/timer.hpp +++ /dev/null @@ -1,165 +0,0 @@ -// (C) Copyright Raffi Enficiaud 2019. -// 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) - -// See http://www.boost.org/libs/test for the library home page. -// -// Description : timer and elapsed types -// *************************************************************************** - -#ifndef BOOST_TEST_UTILS_TIMER_HPP -#define BOOST_TEST_UTILS_TIMER_HPP - -#include <boost/config.hpp> -#include <boost/cstdint.hpp> -#include <utility> -#include <ctime> - -# if defined(_WIN32) || defined(__CYGWIN__) -# define BOOST_TEST_TIMER_WINDOWS_API -# elif defined(__MACH__)// && !defined(CLOCK_MONOTONIC) -# // we compile for all macs the same, CLOCK_MONOTONIC introduced in 10.12 -# define BOOST_TEST_TIMER_MACH_API -# else -# define BOOST_TEST_TIMER_POSIX_API -# if !defined(CLOCK_MONOTONIC) -# error "CLOCK_MONOTONIC not defined" -# endif -# endif - -# if defined(BOOST_TEST_TIMER_WINDOWS_API) -# include <windows.h> -# elif defined(BOOST_TEST_TIMER_MACH_API) -# include <mach/mach_time.h> -//# include <mach/mach.h> /* host_get_clock_service, mach_... */ -# else -# include <sys/time.h> -# endif - -# ifdef BOOST_NO_STDC_NAMESPACE - namespace std { using ::clock_t; using ::clock; } -# endif - -namespace boost { -namespace unit_test { -namespace timer { - - struct elapsed_time - { - typedef boost::int_least64_t nanosecond_type; - - nanosecond_type wall; - nanosecond_type system; - void clear() { - wall = 0; - system = 0; - } - }; - - inline double - microsecond_wall_time( elapsed_time const& elapsed ) - { - return elapsed.wall / 1E3; - } - - inline double - second_wall_time( elapsed_time const& elapsed ) - { - return elapsed.wall / 1E9; - } - - namespace details { - #if defined(BOOST_TEST_TIMER_WINDOWS_API) - elapsed_time::nanosecond_type get_tick_freq() { - LARGE_INTEGER freq; - ::QueryPerformanceFrequency( &freq ); - return static_cast<elapsed_time::nanosecond_type>(freq.QuadPart); - } - #elif defined(BOOST_TEST_TIMER_MACH_API) - std::pair<elapsed_time::nanosecond_type, elapsed_time::nanosecond_type> get_time_base() { - mach_timebase_info_data_t timebase; - if(mach_timebase_info(&timebase) == 0) - return std::pair<elapsed_time::nanosecond_type, elapsed_time::nanosecond_type>(timebase.numer, timebase.denom); - return std::pair<elapsed_time::nanosecond_type, elapsed_time::nanosecond_type>(0, 1); - } - #endif - } - - //! Simple timing class - //! - //! This class measures the wall clock time. - class timer - { - public: - timer() - { - restart(); - } - void restart() - { - _start_time_clock = std::clock(); - #if defined(BOOST_TEST_TIMER_WINDOWS_API) - ::QueryPerformanceCounter(&_start_time_wall); - #elif defined(BOOST_TEST_TIMER_MACH_API) - _start_time_wall = mach_absolute_time(); - #else - if( ::clock_gettime( CLOCK_MONOTONIC, &_start_time_wall ) != 0 ) - { - _start_time_wall.tv_nsec = -1; - _start_time_wall.tv_sec = -1; - } - #endif - } - - // return elapsed time in seconds - elapsed_time elapsed() const - { - typedef elapsed_time::nanosecond_type nanosecond_type; - static const double clock_to_nano_seconds = 1E9 / CLOCKS_PER_SEC; - elapsed_time return_value; - - // processor / system time - return_value.system = static_cast<nanosecond_type>(double(std::clock() - _start_time_clock) * clock_to_nano_seconds); - -#if defined(BOOST_TEST_TIMER_WINDOWS_API) - static const nanosecond_type tick_per_sec = details::get_tick_freq(); - LARGE_INTEGER end_time; - ::QueryPerformanceCounter(&end_time); - return_value.wall = static_cast<nanosecond_type>(((end_time.QuadPart - _start_time_wall.QuadPart) * 1E9) / tick_per_sec); -#elif defined(BOOST_TEST_TIMER_MACH_API) - static std::pair<nanosecond_type, nanosecond_type> timebase = details::get_time_base(); - nanosecond_type clock = mach_absolute_time() - _start_time_wall; - return_value.wall = static_cast<nanosecond_type>((clock * timebase.first) / timebase.second); -#else - struct timespec end_time; - return_value.wall = 0; - if( ::clock_gettime( CLOCK_MONOTONIC, &end_time ) == 0 ) - { - return_value.wall = static_cast<nanosecond_type>((end_time.tv_sec - _start_time_wall.tv_sec) * 1E9 + (end_time.tv_nsec - _start_time_wall.tv_nsec)); - } -#endif - - return return_value; - } - - private: - std::clock_t _start_time_clock; - #if defined(BOOST_TEST_TIMER_WINDOWS_API) - LARGE_INTEGER _start_time_wall; - #elif defined(BOOST_TEST_TIMER_MACH_API) - elapsed_time::nanosecond_type _start_time_wall; - #else - struct timespec _start_time_wall; - #endif - }; - - -//____________________________________________________________________________// - -} // namespace timer -} // namespace unit_test -} // namespace boost - -#endif // BOOST_TEST_UTILS_TIMER_HPP - diff --git a/ThirdParty/boost/throw_exception.hpp b/ThirdParty/boost/throw_exception.hpp deleted file mode 100644 index 17aff51c09b580fc2f74a82a2237bc2468ddcf7f..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/throw_exception.hpp +++ /dev/null @@ -1,182 +0,0 @@ -#ifndef BOOST_THROW_EXCEPTION_HPP_INCLUDED -#define BOOST_THROW_EXCEPTION_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/throw_exception.hpp -// -// Copyright (c) 2002, 2018, 2019 Peter Dimov -// Copyright (c) 2008-2009 Emil Dotchevski and Reverge Studios, Inc. -// -// 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) -// -// http://www.boost.org/libs/throw_exception -// - -#include <boost/assert/source_location.hpp> -#include <boost/config.hpp> -#include <boost/config/workaround.hpp> -#include <exception> - -#if !defined( BOOST_EXCEPTION_DISABLE ) && defined( __BORLANDC__ ) && BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x593) ) -# define BOOST_EXCEPTION_DISABLE -#endif - -namespace boost -{ - -// All boost exceptions are required to derive from std::exception, -// to ensure compatibility with BOOST_NO_EXCEPTIONS. - -inline void throw_exception_assert_compatibility( std::exception const & ) {} - -} // namespace boost - -#if defined( BOOST_NO_EXCEPTIONS ) - -namespace boost -{ - -BOOST_NORETURN void throw_exception( std::exception const & e ); // user defined -BOOST_NORETURN void throw_exception( std::exception const & e, boost::source_location const & loc ); // user defined - -} // namespace boost - -#elif defined( BOOST_EXCEPTION_DISABLE ) - -namespace boost -{ - -template<class E> BOOST_NORETURN void throw_exception( E const & e ) -{ - throw_exception_assert_compatibility( e ); - throw e; -} - -template<class E> BOOST_NORETURN void throw_exception( E const & e, boost::source_location const & ) -{ - throw_exception_assert_compatibility( e ); - throw e; -} - -} // namespace boost - -#else // !defined( BOOST_NO_EXCEPTIONS ) && !defined( BOOST_EXCEPTION_DISABLE ) - -#include <boost/exception/exception.hpp> - -namespace boost -{ - -// boost::wrapexcept<E> - -namespace detail -{ - -typedef char (&wrapexcept_s1)[ 1 ]; -typedef char (&wrapexcept_s2)[ 2 ]; - -template<class T> wrapexcept_s1 wrapexcept_is_convertible( T* ); -template<class T> wrapexcept_s2 wrapexcept_is_convertible( void* ); - -template<class E, class B, int I = sizeof( wrapexcept_is_convertible<B>( static_cast< E* >( 0 ) ) ) > struct wrapexcept_add_base; - -template<class E, class B> struct wrapexcept_add_base<E, B, 1> -{ - struct type {}; -}; - -template<class E, class B> struct wrapexcept_add_base<E, B, 2> -{ - typedef B type; -}; - -} // namespace detail - -template<class E> struct BOOST_SYMBOL_VISIBLE wrapexcept: - public detail::wrapexcept_add_base<E, boost::exception_detail::clone_base>::type, - public E, - public detail::wrapexcept_add_base<E, boost::exception>::type -{ -private: - - struct deleter - { - wrapexcept * p_; - ~deleter() { delete p_; } - }; - -private: - - void copy_from( void const* ) - { - } - - void copy_from( boost::exception const* p ) - { - static_cast<boost::exception&>( *this ) = *p; - } - -public: - - explicit wrapexcept( E const & e ): E( e ) - { - copy_from( &e ); - } - - explicit wrapexcept( E const & e, boost::source_location const & loc ): E( e ) - { - copy_from( &e ); - - set_info( *this, throw_file( loc.file_name() ) ); - set_info( *this, throw_line( loc.line() ) ); - set_info( *this, throw_function( loc.function_name() ) ); - } - - virtual boost::exception_detail::clone_base const * clone() const - { - wrapexcept * p = new wrapexcept( *this ); - deleter del = { p }; - - boost::exception_detail::copy_boost_exception( p, this ); - - del.p_ = 0; - return p; - } - - virtual void rethrow() const - { - throw *this; - } -}; - -// boost::throw_exception - -template<class E> BOOST_NORETURN void throw_exception( E const & e ) -{ - throw_exception_assert_compatibility( e ); - throw wrapexcept<E>( e ); -} - -template<class E> BOOST_NORETURN void throw_exception( E const & e, boost::source_location const & loc ) -{ - throw_exception_assert_compatibility( e ); - throw wrapexcept<E>( e, loc ); -} - -} // namespace boost - -#endif - -// BOOST_THROW_EXCEPTION - -#define BOOST_THROW_EXCEPTION(x) ::boost::throw_exception(x, BOOST_CURRENT_LOCATION) - -#endif // #ifndef BOOST_THROW_EXCEPTION_HPP_INCLUDED diff --git a/ThirdParty/boost/type_index.hpp b/ThirdParty/boost/type_index.hpp deleted file mode 100644 index 8b866202961263dcdbeebf365b86650a9ffe6d86..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index.hpp +++ /dev/null @@ -1,265 +0,0 @@ -// -// Copyright 2012-2020 Antony Polukhin. -// -// 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_HPP -#define BOOST_TYPE_INDEX_HPP - -/// \file boost/type_index.hpp -/// \brief Includes minimal set of headers required to use the Boost.TypeIndex library. -/// -/// By inclusion of this file most optimal type index classes will be included and used -/// as a boost::typeindex::type_index and boost::typeindex::type_info. - -#include <boost/config.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -#if defined(BOOST_TYPE_INDEX_USER_TYPEINDEX) -# include BOOST_TYPE_INDEX_USER_TYPEINDEX -# ifdef BOOST_HAS_PRAGMA_DETECT_MISMATCH -# pragma detect_mismatch( "boost__type_index__abi", "user defined type_index class is used: " BOOST_STRINGIZE(BOOST_TYPE_INDEX_USER_TYPEINDEX)) -# endif -#elif (!defined(BOOST_NO_RTTI) && !defined(BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY)) || defined(BOOST_MSVC) -# include <boost/type_index/stl_type_index.hpp> -# if defined(BOOST_NO_RTTI) || defined(BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY) -# include <boost/type_index/detail/stl_register_class.hpp> -# ifdef BOOST_HAS_PRAGMA_DETECT_MISMATCH -# pragma detect_mismatch( "boost__type_index__abi", "RTTI is off - typeid() is used only for templates") -# endif -# else -# ifdef BOOST_HAS_PRAGMA_DETECT_MISMATCH -# pragma detect_mismatch( "boost__type_index__abi", "RTTI is used") -# endif -# endif -#else -# include <boost/type_index/ctti_type_index.hpp> -# include <boost/type_index/detail/ctti_register_class.hpp> -# ifdef BOOST_HAS_PRAGMA_DETECT_MISMATCH -# pragma detect_mismatch( "boost__type_index__abi", "RTTI is off - using CTTI") -# endif -#endif - -#ifndef BOOST_TYPE_INDEX_REGISTER_CLASS -#define BOOST_TYPE_INDEX_REGISTER_CLASS -#endif - -namespace boost { namespace typeindex { - -#if defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) - -/// \def BOOST_TYPE_INDEX_FUNCTION_SIGNATURE -/// BOOST_TYPE_INDEX_FUNCTION_SIGNATURE is used by boost::typeindex::ctti_type_index class to -/// deduce the name of a type. If your compiler is not recognized -/// by the TypeIndex library and you wish to work with boost::typeindex::ctti_type_index, you may -/// define this macro by yourself. -/// -/// BOOST_TYPE_INDEX_FUNCTION_SIGNATURE must be defined to a compiler specific macro -/// that outputs the \b whole function signature \b including \b template \b parameters. -/// -/// If your compiler is not recognised and BOOST_TYPE_INDEX_FUNCTION_SIGNATURE is not defined, -/// then a compile-time error will arise at any attempt to use boost::typeindex::ctti_type_index classes. -/// -/// See BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS and BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING -/// for an information of how to tune the implementation to make a nice pretty_name() output. -#define BOOST_TYPE_INDEX_FUNCTION_SIGNATURE BOOST_CURRENT_FUNCTION - -/// \def BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING -/// This is a helper macro for making correct pretty_names() with RTTI off. -/// -/// BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING macro may be defined to -/// '(begin_skip, end_skip, runtime_skip, runtime_skip_until)' with parameters for adding a -/// support for compilers, that by default are not recognized by TypeIndex library. -/// -/// \b Example: -/// -/// Imagine the situation when -/// \code boost::typeindex::ctti_type_index::type_id<int>().pretty_name() \endcode -/// returns the following string: -/// \code "static const char *boost::detail::ctti<int>::n() [T = int]" \endcode -/// and \code boost::typeindex::ctti_type_index::type_id<short>().pretty_name() \endcode returns the following: -/// \code "static const char *boost::detail::ctti<short>::n() [T = short]" \endcode -/// -/// As we may see first 39 characters are "static const char *boost::detail::ctti<" and they do not depend on -/// the type T. After first 39 characters we have a human readable type name which is duplicated at the end -/// of a string. String always ends on ']', which consumes 1 character. -/// -/// Now if we define `BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING` to -/// `(39, 1, false, "")` we'll be getting \code "int>::n() [T = int" \endcode -/// for `boost::typeindex::ctti_type_index::type_id<int>().pretty_name()` and \code "short>::n() [T = short" \endcode -/// for `boost::typeindex::ctti_type_index::type_id<short>().pretty_name()`. -/// -/// Now we need to take additional care of the characters that go before the last mention of our type. We'll -/// do that by telling the macro that we need to cut off everything that goes before the "T = " including the "T = " -/// itself: -/// -/// \code (39, 1, true, "T = ") \endcode -/// -/// In case of GCC or Clang command line we need to add the following line while compiling all the sources: -/// -/// \code -/// -DBOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING='(39, 1, true, "T = ")' -/// \endcode -/// \param begin_skip How many characters must be skipped at the beginning of the type holding string. -/// Must be a compile time constant. -/// \param end_skip How many characters must be skipped at the end of the type holding string. -/// Must be a compile time constant. -/// \param runtime_skip Do we need additional checks at runtime to cut off the more characters. -/// Must be `true` or `false`. -/// \param runtime_skip_until Skip all the characters before the following string (including the string itself). -/// Must be a compile time array of characters. -/// -/// See [RTTI emulation limitations](boost_typeindex/rtti_emulation_limitations.html) for more info. -#define BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING (0, 0, false, "") - - - /// Depending on a compiler flags, optimal implementation of type_index will be used - /// as a default boost::typeindex::type_index. - /// - /// Could be a boost::typeindex::stl_type_index, boost::typeindex::ctti_type_index or - /// user defined type_index class. - /// - /// \b See boost::typeindex::type_index_facade for a full description of type_index functions. - typedef platform_specific type_index; -#elif defined(BOOST_TYPE_INDEX_USER_TYPEINDEX) - // Nothing to do -#elif (!defined(BOOST_NO_RTTI) && !defined(BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY)) || defined(BOOST_MSVC) - typedef boost::typeindex::stl_type_index type_index; -#else - typedef boost::typeindex::ctti_type_index type_index; -#endif - -/// Depending on a compiler flags, optimal implementation of type_info will be used -/// as a default boost::typeindex::type_info. -/// -/// Could be a std::type_info, boost::typeindex::detail::ctti_data or -/// some user defined class. -/// -/// type_info \b is \b not copyable or default constructible. It is \b not assignable too! -typedef type_index::type_info_t type_info; - -#if defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) - -/// \def BOOST_TYPE_INDEX_USER_TYPEINDEX -/// BOOST_TYPE_INDEX_USER_TYPEINDEX can be defined to the path to header file -/// with user provided implementation of type_index. -/// -/// See [Making a custom type_index](boost_typeindex/making_a_custom_type_index.html) section -/// of documentation for usage example. -#define BOOST_TYPE_INDEX_USER_TYPEINDEX <full/absolute/path/to/header/with/type_index.hpp> - - -/// \def BOOST_TYPE_INDEX_REGISTER_CLASS -/// BOOST_TYPE_INDEX_REGISTER_CLASS is used to help to emulate RTTI. -/// Put this macro into the public section of polymorphic class to allow runtime type detection. -/// -/// Depending on the typeid() availability this macro will expand to nothing or to virtual helper function -/// `virtual const type_info& boost_type_info_type_id_runtime_() const noexcept`. -/// -/// \b Example: -/// \code -/// class A { -/// public: -/// BOOST_TYPE_INDEX_REGISTER_CLASS -/// virtual ~A(){} -/// }; -/// -/// struct B: public A { -/// BOOST_TYPE_INDEX_REGISTER_CLASS -/// }; -/// -/// struct C: public B { -/// BOOST_TYPE_INDEX_REGISTER_CLASS -/// }; -/// -/// ... -/// -/// C c1; -/// A* pc1 = &c1; -/// assert(boost::typeindex::type_id<C>() == boost::typeindex::type_id_runtime(*pc1)); -/// \endcode -#define BOOST_TYPE_INDEX_REGISTER_CLASS nothing-or-some-virtual-functions - -/// \def BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY -/// BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY is a helper macro that must be defined if mixing -/// RTTI on/off modules. See -/// [Mixing sources with RTTI on and RTTI off](boost_typeindex/mixing_sources_with_rtti_on_and_.html) -/// section of documentation for more info. -#define BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY - -#endif // defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) - - -/// Function to get boost::typeindex::type_index for a type T. -/// Removes const, volatile && and & modifiers from T. -/// -/// \b Example: -/// \code -/// type_index ti = type_id<int&>(); -/// std::cout << ti.pretty_name(); // Outputs 'int' -/// \endcode -/// -/// \tparam T Type for which type_index must be created. -/// \throw Nothing. -/// \return boost::typeindex::type_index with information about the specified type T. -template <class T> -inline type_index type_id() BOOST_NOEXCEPT { - return type_index::type_id<T>(); -} - -/// Function for constructing boost::typeindex::type_index instance for type T. -/// Does not remove const, volatile, & and && modifiers from T. -/// -/// If T has no const, volatile, & and && modifiers, then returns exactly -/// the same result as in case of calling `type_id<T>()`. -/// -/// \b Example: -/// \code -/// type_index ti = type_id_with_cvr<int&>(); -/// std::cout << ti.pretty_name(); // Outputs 'int&' -/// \endcode -/// -/// \tparam T Type for which type_index must be created. -/// \throw Nothing. -/// \return boost::typeindex::type_index with information about the specified type T. -template <class T> -inline type_index type_id_with_cvr() BOOST_NOEXCEPT { - return type_index::type_id_with_cvr<T>(); -} - -/// Function that works exactly like C++ typeid(rtti_val) call, but returns boost::type_index. -/// -/// Returns runtime information about specified type. -/// -/// \b Requirements: RTTI available or Base and Derived classes must be marked with BOOST_TYPE_INDEX_REGISTER_CLASS. -/// -/// \b Example: -/// \code -/// struct Base { virtual ~Base(){} }; -/// struct Derived: public Base {}; -/// ... -/// Derived d; -/// Base& b = d; -/// type_index ti = type_id_runtime(b); -/// std::cout << ti.pretty_name(); // Outputs 'Derived' -/// \endcode -/// -/// \param runtime_val Variable which runtime type must be returned. -/// \throw Nothing. -/// \return boost::typeindex::type_index with information about the specified variable. -template <class T> -inline type_index type_id_runtime(const T& runtime_val) BOOST_NOEXCEPT { - return type_index::type_id_runtime(runtime_val); -} - -}} // namespace boost::typeindex - - - -#endif // BOOST_TYPE_INDEX_HPP - diff --git a/ThirdParty/boost/type_index/ctti_type_index.hpp b/ThirdParty/boost/type_index/ctti_type_index.hpp deleted file mode 100644 index edb57149f004b4bcddfdaf9a8aa8220785384df2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/ctti_type_index.hpp +++ /dev/null @@ -1,213 +0,0 @@ -// -// Copyright 2013-2020 Antony Polukhin. -// -// -// 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_CTTI_TYPE_INDEX_HPP -#define BOOST_TYPE_INDEX_CTTI_TYPE_INDEX_HPP - -/// \file ctti_type_index.hpp -/// \brief Contains boost::typeindex::ctti_type_index class that is constexpr if C++14 constexpr is supported by compiler. -/// -/// boost::typeindex::ctti_type_index class can be used as a drop-in replacement -/// for std::type_index. -/// -/// It is used in situations when typeid() method is not available or -/// BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY macro is defined. - -#include <boost/type_index/type_index_facade.hpp> -#include <boost/type_index/detail/compile_time_type_info.hpp> - -#include <cstring> -#include <boost/container_hash/hash.hpp> -#include <boost/static_assert.hpp> -#include <boost/type_traits/remove_cv.hpp> -#include <boost/type_traits/remove_reference.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost { namespace typeindex { - -namespace detail { - -// That's the most trickiest part of the TypeIndex library: -// 1) we do not want to give user ability to manually construct and compare `struct-that-represents-type` -// 2) we need to distinguish between `struct-that-represents-type` and `const char*` -// 3) we need a thread-safe way to have references to instances `struct-that-represents-type` -// 4) we need a compile-time control to make sure that user does not copy or -// default construct `struct-that-represents-type` -// -// Solution would be the following: - -/// \class ctti_data -/// Standard-layout class with private constructors and assignment operators. -/// -/// You can not work with this class directly. The purpose of this class is to hold type info -/// \b when \b RTTI \b is \b off and allow ctti_type_index construction from itself. -/// -/// \b Example: -/// \code -/// const detail::ctti_data& foo(); -/// ... -/// type_index ti = type_index(foo()); -/// std::cout << ti.pretty_name(); -/// \endcode -class ctti_data { -#ifndef BOOST_NO_CXX11_DELETED_FUNCTIONS -public: - ctti_data() = delete; - ctti_data(const ctti_data&) = delete; - ctti_data& operator=(const ctti_data&) = delete; -#else -private: - ctti_data(); - ctti_data(const ctti_data&); - ctti_data& operator=(const ctti_data&); -#endif -}; - -} // namespace detail - -/// Helper method for getting detail::ctti_data of a template parameter T. -template <class T> -inline const detail::ctti_data& ctti_construct() BOOST_NOEXCEPT { - // Standard C++11, 5.2.10 Reinterpret cast: - // An object pointer can be explicitly converted to an object pointer of a different type. When a prvalue - // v of type "pointer to T1" is converted to the type "pointer to cv T2", the result is static_cast<cv - // T2*>(static_cast<cv void*>(v)) if both T1 and T2 are standard-layout types (3.9) and the alignment - // requirements of T2 are no stricter than those of T1, or if either type is void. Converting a prvalue of type - // "pointer to T1" to the type "pointer to T2" (where T1 and T2 are object types and where the alignment - // requirements of T2 are no stricter than those of T1) and back to its original type yields the original pointer - // value. - // - // Alignments are checked in `type_index_test_ctti_alignment.cpp` test. - return *reinterpret_cast<const detail::ctti_data*>(boost::detail::ctti<T>::n()); -} - -/// \class ctti_type_index -/// This class is a wrapper that pretends to work exactly like stl_type_index, but does -/// not require RTTI support. \b For \b description \b of \b functions \b see type_index_facade. -/// -/// This class on C++14 compatible compilers has following functions marked as constexpr: -/// * default constructor -/// * copy constructors and assignemnt operations -/// * class methods: name(), before(const ctti_type_index& rhs), equal(const ctti_type_index& rhs) -/// * static methods type_id<T>(), type_id_with_cvr<T>() -/// * comparison operators -/// -/// This class produces slightly longer type names, so consider using stl_type_index -/// in situations when typeid() is working. -class ctti_type_index: public type_index_facade<ctti_type_index, detail::ctti_data> { - const char* data_; - - inline std::size_t get_raw_name_length() const BOOST_NOEXCEPT; - - BOOST_CXX14_CONSTEXPR inline explicit ctti_type_index(const char* data) BOOST_NOEXCEPT - : data_(data) - {} - -public: - typedef detail::ctti_data type_info_t; - - BOOST_CXX14_CONSTEXPR inline ctti_type_index() BOOST_NOEXCEPT - : data_(boost::detail::ctti<void>::n()) - {} - - inline ctti_type_index(const type_info_t& data) BOOST_NOEXCEPT - : data_(reinterpret_cast<const char*>(&data)) - {} - - inline const type_info_t& type_info() const BOOST_NOEXCEPT; - BOOST_CXX14_CONSTEXPR inline const char* raw_name() const BOOST_NOEXCEPT; - BOOST_CXX14_CONSTEXPR inline const char* name() const BOOST_NOEXCEPT; - inline std::string pretty_name() const; - inline std::size_t hash_code() const BOOST_NOEXCEPT; - - BOOST_CXX14_CONSTEXPR inline bool equal(const ctti_type_index& rhs) const BOOST_NOEXCEPT; - BOOST_CXX14_CONSTEXPR inline bool before(const ctti_type_index& rhs) const BOOST_NOEXCEPT; - - template <class T> - BOOST_CXX14_CONSTEXPR inline static ctti_type_index type_id() BOOST_NOEXCEPT; - - template <class T> - BOOST_CXX14_CONSTEXPR inline static ctti_type_index type_id_with_cvr() BOOST_NOEXCEPT; - - template <class T> - inline static ctti_type_index type_id_runtime(const T& variable) BOOST_NOEXCEPT; -}; - - -inline const ctti_type_index::type_info_t& ctti_type_index::type_info() const BOOST_NOEXCEPT { - return *reinterpret_cast<const detail::ctti_data*>(data_); -} - - -BOOST_CXX14_CONSTEXPR inline bool ctti_type_index::equal(const ctti_type_index& rhs) const BOOST_NOEXCEPT { - const char* const left = raw_name(); - const char* const right = rhs.raw_name(); - return /*left == right ||*/ !boost::typeindex::detail::constexpr_strcmp(left, right); -} - -BOOST_CXX14_CONSTEXPR inline bool ctti_type_index::before(const ctti_type_index& rhs) const BOOST_NOEXCEPT { - const char* const left = raw_name(); - const char* const right = rhs.raw_name(); - return /*left != right &&*/ boost::typeindex::detail::constexpr_strcmp(left, right) < 0; -} - - -template <class T> -BOOST_CXX14_CONSTEXPR inline ctti_type_index ctti_type_index::type_id() BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::remove_reference<T>::type no_ref_t; - typedef BOOST_DEDUCED_TYPENAME boost::remove_cv<no_ref_t>::type no_cvr_t; - return ctti_type_index(boost::detail::ctti<no_cvr_t>::n()); -} - - - -template <class T> -BOOST_CXX14_CONSTEXPR inline ctti_type_index ctti_type_index::type_id_with_cvr() BOOST_NOEXCEPT { - return ctti_type_index(boost::detail::ctti<T>::n()); -} - - -template <class T> -inline ctti_type_index ctti_type_index::type_id_runtime(const T& variable) BOOST_NOEXCEPT { - return variable.boost_type_index_type_id_runtime_(); -} - - -BOOST_CXX14_CONSTEXPR inline const char* ctti_type_index::raw_name() const BOOST_NOEXCEPT { - return data_; -} - - -BOOST_CXX14_CONSTEXPR inline const char* ctti_type_index::name() const BOOST_NOEXCEPT { - return data_; -} - -inline std::size_t ctti_type_index::get_raw_name_length() const BOOST_NOEXCEPT { - return std::strlen(raw_name() + detail::ctti_skip_size_at_end); -} - - -inline std::string ctti_type_index::pretty_name() const { - std::size_t len = get_raw_name_length(); - while (raw_name()[len - 1] == ' ') --len; // MSVC sometimes adds whitespaces - return std::string(raw_name(), len); -} - - -inline std::size_t ctti_type_index::hash_code() const BOOST_NOEXCEPT { - return boost::hash_range(raw_name(), raw_name() + get_raw_name_length()); -} - - -}} // namespace boost::typeindex - -#endif // BOOST_TYPE_INDEX_CTTI_TYPE_INDEX_HPP - diff --git a/ThirdParty/boost/type_index/detail/compile_time_type_info.hpp b/ThirdParty/boost/type_index/detail/compile_time_type_info.hpp deleted file mode 100644 index dcc9aa99b0de887528f771846fa11a71ed50690a..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/detail/compile_time_type_info.hpp +++ /dev/null @@ -1,339 +0,0 @@ -// -// Copyright 2012-2020 Antony Polukhin. -// -// -// 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_DETAIL_COMPILE_TIME_TYPE_INFO_HPP -#define BOOST_TYPE_INDEX_DETAIL_COMPILE_TIME_TYPE_INFO_HPP - -/// \file compile_time_type_info.hpp -/// \brief Contains helper macros and implementation details of boost::typeindex::ctti_type_index. -/// Not intended for inclusion from user's code. - -#include <cstring> -#include <boost/config.hpp> -#include <boost/static_assert.hpp> -#include <boost/type_traits/integral_constant.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -/// @cond -#if defined(__has_builtin) -#if __has_builtin(__builtin_constant_p) -#define BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT(x) __builtin_constant_p(x) -#endif -#if __has_builtin(__builtin_strcmp) -#define BOOST_TYPE_INDEX_DETAIL_BUILTIN_STRCMP(str1, str2) __builtin_strcmp(str1, str2) -#endif -#elif defined(__GNUC__) -#define BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT(x) __builtin_constant_p(x) -#define BOOST_TYPE_INDEX_DETAIL_BUILTIN_STRCMP(str1, str2) __builtin_strcmp(str1, str2) -#endif - -#define BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(begin_skip, end_skip, runtime_skip, runtime_skip_until) \ - namespace boost { namespace typeindex { namespace detail { \ - BOOST_STATIC_CONSTEXPR std::size_t ctti_skip_size_at_begin = begin_skip; \ - BOOST_STATIC_CONSTEXPR std::size_t ctti_skip_size_at_end = end_skip; \ - BOOST_STATIC_CONSTEXPR bool ctti_skip_more_at_runtime = runtime_skip; \ - BOOST_STATIC_CONSTEXPR char ctti_skip_until_runtime[] = runtime_skip_until; \ - }}} /* namespace boost::typeindex::detail */ \ - /**/ -/// @endcond - - -#if defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) - /* Nothing to document. All the macro docs are moved to <boost/type_index.hpp> */ -#elif defined(BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING) -# include <boost/preprocessor/facilities/expand.hpp> - BOOST_PP_EXPAND( BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING ) -#elif defined(_MSC_VER) && !defined(__clang__) && defined (BOOST_NO_CXX11_NOEXCEPT) - // sizeof("const char *__cdecl boost::detail::ctti<") - 1, sizeof(">::n(void)") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(40, 10, false, "") -#elif defined(_MSC_VER) && !defined(__clang__) && !defined (BOOST_NO_CXX11_NOEXCEPT) - // sizeof("const char *__cdecl boost::detail::ctti<") - 1, sizeof(">::n(void) noexcept") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(40, 19, false, "") -#elif defined(__clang__) && defined(__APPLE__) - // Someone made __clang_major__ equal to LLVM version rather than compiler version - // on APPLE platform. - // - // Using less efficient solution because there is no good way to detect real version of Clang. - // sizeof("static const char *boost::detail::ctti<") - 1, sizeof("]") - 1, true, "???????????>::n() [T = int" - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(39, 1, true, "T = ") -#elif defined(__clang__) && (__clang_major__ < 3 || (__clang_major__ == 3 && __clang_minor__ == 0)) - // sizeof("static const char *boost::detail::ctti<") - 1, sizeof(">::n()") - 1 - // note: checked on 3.0 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(39, 6, false, "") -#elif defined(__clang__) && (__clang_major__ >= 4 || (__clang_major__ == 3 && __clang_minor__ > 0)) - // sizeof("static const char *boost::detail::ctti<") - 1, sizeof("]") - 1, true, "int>::n() [T = int" - // note: checked on 3.1, 3.4 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(39, 1, true, "T = ") -#elif defined(__EDG__) && !defined(BOOST_NO_CXX14_CONSTEXPR) - // sizeof("static cha boost::detail::ctti<T>::s() [with I = 40U, T = ") - 1, sizeof("]") - 1 - // note: checked on 4.14 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(58, 1, false, "") -#elif defined(__EDG__) && defined(BOOST_NO_CXX14_CONSTEXPR) - // sizeof("static const char *boost::detail::ctti<T>::n() [with T = ") - 1, sizeof("]") - 1 - // note: checked on 4.14 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(57, 1, false, "") -#elif defined(__GNUC__) && (__GNUC__ < 7) && !defined(BOOST_NO_CXX14_CONSTEXPR) - // sizeof("static constexpr char boost::detail::ctti<T>::s() [with unsigned int I = 0u; T = ") - 1, sizeof("]") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(81, 1, false, "") -#elif defined(__GNUC__) && (__GNUC__ >= 7) && !defined(BOOST_NO_CXX14_CONSTEXPR) - // sizeof("static constexpr char boost::detail::ctti<T>::s() [with unsigned int I = 0; T = ") - 1, sizeof("]") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(80, 1, false, "") -#elif defined(__GNUC__) && defined(BOOST_NO_CXX14_CONSTEXPR) - // sizeof("static const char* boost::detail::ctti<T>::n() [with T = ") - 1, sizeof("]") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(57, 1, false, "") -#elif defined(__ghs__) - // sizeof("static const char *boost::detail::ctti<T>::n() [with T = ") - 1, sizeof("]") - 1 - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(57, 1, false, "") -#else - // Deafult code for other platforms... Just skip nothing! - BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS(0, 0, false, "") -#endif - -#undef BOOST_TYPE_INDEX_REGISTER_CTTI_PARSING_PARAMS - -namespace boost { namespace typeindex { namespace detail { - template <bool Condition> - BOOST_CXX14_CONSTEXPR inline void assert_compile_time_legths() BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG( - Condition, - "TypeIndex library is misconfigured for your compiler. " - "Please define BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING to correct values. See section " - "'RTTI emulation limitations' of the documentation for more information." - ); - } - - template <class T> - BOOST_CXX14_CONSTEXPR inline void failed_to_get_function_name() BOOST_NOEXCEPT { - BOOST_STATIC_ASSERT_MSG( - sizeof(T) && false, - "TypeIndex library could not detect your compiler. " - "Please make the BOOST_TYPE_INDEX_FUNCTION_SIGNATURE macro use " - "correct compiler macro for getting the whole function name. " - "Define BOOST_TYPE_INDEX_CTTI_USER_DEFINED_PARSING to correct value after that." - ); - } - -#if defined(BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT) - BOOST_CXX14_CONSTEXPR BOOST_FORCEINLINE bool is_constant_string(const char* str) BOOST_NOEXCEPT { - while (BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT(*str)) { - if (*str == '\0') - return true; - ++str; - } - return false; - } -#endif // defined(BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT) - - template <unsigned int ArrayLength> - BOOST_CXX14_CONSTEXPR inline const char* skip_begining_runtime(const char* begin, boost::false_type) BOOST_NOEXCEPT { - return begin; - } - - template<class ForwardIterator1, class ForwardIterator2> - BOOST_CXX14_CONSTEXPR inline ForwardIterator1 constexpr_search( - ForwardIterator1 first1, - ForwardIterator1 last1, - ForwardIterator2 first2, - ForwardIterator2 last2) BOOST_NOEXCEPT - { - if (first2 == last2) { - return first1; // specified in C++11 - } - - while (first1 != last1) { - ForwardIterator1 it1 = first1; - ForwardIterator2 it2 = first2; - - while (*it1 == *it2) { - ++it1; - ++it2; - if (it2 == last2) return first1; - if (it1 == last1) return last1; - } - - ++first1; - } - - return last1; - } - - BOOST_CXX14_CONSTEXPR inline int constexpr_strcmp_loop(const char *v1, const char *v2) BOOST_NOEXCEPT { - while (*v1 != '\0' && *v1 == *v2) { - ++v1; - ++v2; - } - - return static_cast<int>(*v1) - *v2; - } - - BOOST_CXX14_CONSTEXPR inline int constexpr_strcmp(const char *v1, const char *v2) BOOST_NOEXCEPT { -#if !defined(BOOST_NO_CXX14_CONSTEXPR) && defined(BOOST_TYPE_INDEX_DETAIL_IS_CONSTANT) && defined(BOOST_TYPE_INDEX_DETAIL_BUILTIN_STRCMP) - if (boost::typeindex::detail::is_constant_string(v1) && boost::typeindex::detail::is_constant_string(v2)) - return boost::typeindex::detail::constexpr_strcmp_loop(v1, v2); - return BOOST_TYPE_INDEX_DETAIL_BUILTIN_STRCMP(v1, v2); -#elif !defined(BOOST_NO_CXX14_CONSTEXPR) - return boost::typeindex::detail::constexpr_strcmp_loop(v1, v2); -#else - return std::strcmp(v1, v2); -#endif - } - - template <unsigned int ArrayLength> - BOOST_CXX14_CONSTEXPR inline const char* skip_begining_runtime(const char* begin, boost::true_type) BOOST_NOEXCEPT { - const char* const it = constexpr_search( - begin, begin + ArrayLength, - ctti_skip_until_runtime, ctti_skip_until_runtime + sizeof(ctti_skip_until_runtime) - 1 - ); - return (it == begin + ArrayLength ? begin : it + sizeof(ctti_skip_until_runtime) - 1); - } - - template <unsigned int ArrayLength> - BOOST_CXX14_CONSTEXPR inline const char* skip_begining(const char* begin) BOOST_NOEXCEPT { - assert_compile_time_legths<(ArrayLength > ctti_skip_size_at_begin + ctti_skip_size_at_end)>(); - return skip_begining_runtime<ArrayLength - ctti_skip_size_at_begin>( - begin + ctti_skip_size_at_begin, - boost::integral_constant<bool, ctti_skip_more_at_runtime>() - ); - } - -#if !defined(__clang__) && defined(__GNUC__) && !defined(BOOST_NO_CXX14_CONSTEXPR) - template <unsigned int... I> - struct index_seq {}; - - template <typename Left, typename Right> - struct make_index_sequence_join; - - template <unsigned int... Left, unsigned int... Right> - struct make_index_sequence_join<index_seq<Left...>, index_seq<Right...> > { - typedef index_seq<Left..., Right...> type; - }; - - template <unsigned int C, unsigned int D> - struct make_index_seq_impl { - typedef typename make_index_sequence_join< - typename make_index_seq_impl<C, D / 2>::type, - typename make_index_seq_impl<C + D / 2, (D + 1) / 2>::type - >::type type; - }; - - template <unsigned int C> - struct make_index_seq_impl<C, 0> { - typedef index_seq<> type; - }; - - template <unsigned int C> - struct make_index_seq_impl<C, 1> { - typedef index_seq<C> type; - }; - - template <char... C> - struct cstring { - static constexpr unsigned int size_ = sizeof...(C); - static constexpr char data_[size_] = { C... }; - }; - - template <char... C> - constexpr char cstring<C...>::data_[]; -#endif - -}}} // namespace boost::typeindex::detail - -namespace boost { namespace detail { - -/// Noncopyable type_info that does not require RTTI. -/// CTTI == Compile Time Type Info. -/// This name must be as short as possible, to avoid code bloat -template <class T> -struct ctti { - -#if !defined(__clang__) && defined(__GNUC__) && !defined(BOOST_NO_CXX14_CONSTEXPR) - //helper functions - template <unsigned int I> - constexpr static char s() BOOST_NOEXCEPT { // step - constexpr unsigned int offset = - (I >= 10u ? 1u : 0u) - + (I >= 100u ? 1u : 0u) - + (I >= 1000u ? 1u : 0u) - + (I >= 10000u ? 1u : 0u) - + (I >= 100000u ? 1u : 0u) - + (I >= 1000000u ? 1u : 0u) - ; - - #if defined(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE) - return BOOST_TYPE_INDEX_FUNCTION_SIGNATURE[I + offset]; - #elif defined(__FUNCSIG__) - return __FUNCSIG__[I + offset]; - #else - return __PRETTY_FUNCTION__[I + offset]; - #endif - } - - template <unsigned int ...Indexes> - constexpr static const char* impl(::boost::typeindex::detail::index_seq<Indexes...> ) BOOST_NOEXCEPT { - return ::boost::typeindex::detail::cstring<s<Indexes>()...>::data_; - } - - template <unsigned int D = 0> // `D` means `Dummy` - constexpr static const char* n() BOOST_NOEXCEPT { - #if defined(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE) - constexpr unsigned int size = sizeof(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE); - #elif defined(__FUNCSIG__) - constexpr unsigned int size = sizeof(__FUNCSIG__); - #elif defined(__PRETTY_FUNCTION__) \ - || defined(__GNUC__) \ - || (defined(__SUNPRO_CC) && (__SUNPRO_CC >= 0x5130)) \ - || (defined(__MWERKS__) && (__MWERKS__ >= 0x3000)) \ - || (defined(__ICC) && (__ICC >= 600)) \ - || defined(__ghs__) \ - || defined(__DMC__) - constexpr unsigned int size = sizeof(__PRETTY_FUNCTION__); - #else - boost::typeindex::detail::failed_to_get_function_name<T>(); - #endif - - boost::typeindex::detail::assert_compile_time_legths< - (size > boost::typeindex::detail::ctti_skip_size_at_begin + boost::typeindex::detail::ctti_skip_size_at_end + sizeof("const *") - 1) - >(); - static_assert(!boost::typeindex::detail::ctti_skip_more_at_runtime, "Skipping for GCC in C++14 mode is unsupported"); - - typedef typename boost::typeindex::detail::make_index_seq_impl< - boost::typeindex::detail::ctti_skip_size_at_begin, - size - sizeof("const *") + 1 - boost::typeindex::detail::ctti_skip_size_at_begin - >::type idx_seq; - return impl(idx_seq()); - } -#else - /// Returns raw name. Must be as short, as possible, to avoid code bloat - BOOST_CXX14_CONSTEXPR static const char* n() BOOST_NOEXCEPT { - #if defined(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE) - return boost::typeindex::detail::skip_begining< sizeof(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE) >(BOOST_TYPE_INDEX_FUNCTION_SIGNATURE); - #elif defined(__FUNCSIG__) - return boost::typeindex::detail::skip_begining< sizeof(__FUNCSIG__) >(__FUNCSIG__); - #elif defined(__PRETTY_FUNCTION__) \ - || defined(__GNUC__) \ - || (defined(__SUNPRO_CC) && (__SUNPRO_CC >= 0x5130)) \ - || (defined(__MWERKS__) && (__MWERKS__ >= 0x3000)) \ - || (defined(__ICC) && (__ICC >= 600)) \ - || defined(__ghs__) \ - || defined(__DMC__) \ - || defined(__clang__) - return boost::typeindex::detail::skip_begining< sizeof(__PRETTY_FUNCTION__) >(__PRETTY_FUNCTION__); - #else - boost::typeindex::detail::failed_to_get_function_name<T>(); - return ""; - #endif - } -#endif -}; - -}} // namespace boost::detail - -#endif // BOOST_TYPE_INDEX_DETAIL_COMPILE_TIME_TYPE_INFO_HPP diff --git a/ThirdParty/boost/type_index/detail/ctti_register_class.hpp b/ThirdParty/boost/type_index/detail/ctti_register_class.hpp deleted file mode 100644 index c15ec82f30274be562eab99307b898a08f0f47ae..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/detail/ctti_register_class.hpp +++ /dev/null @@ -1,40 +0,0 @@ -// -// Copyright 2013-2020 Antony Polukhin. -// -// -// 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_CTTI_REGISTER_CLASS_HPP -#define BOOST_TYPE_INDEX_CTTI_REGISTER_CLASS_HPP - -/// \file ctti_register_class.hpp -/// \brief Contains BOOST_TYPE_INDEX_REGISTER_CLASS macro implementation that uses boost::typeindex::ctti_type_index. -/// Not intended for inclusion from user's code. - -#include <boost/type_index/ctti_type_index.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost { namespace typeindex { namespace detail { - -template <class T> -inline const ctti_data& ctti_construct_typeid_ref(const T*) BOOST_NOEXCEPT { - return ctti_construct<T>(); -} - -}}} // namespace boost::typeindex::detail - -/// @cond -#define BOOST_TYPE_INDEX_REGISTER_CLASS \ - virtual const boost::typeindex::detail::ctti_data& boost_type_index_type_id_runtime_() const BOOST_NOEXCEPT { \ - return boost::typeindex::detail::ctti_construct_typeid_ref(this); \ - } \ -/**/ -/// @endcond - -#endif // BOOST_TYPE_INDEX_CTTI_REGISTER_CLASS_HPP - diff --git a/ThirdParty/boost/type_index/detail/stl_register_class.hpp b/ThirdParty/boost/type_index/detail/stl_register_class.hpp deleted file mode 100644 index b8df8c75fc22c3d2ca8842aa2567777a306f20c2..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/detail/stl_register_class.hpp +++ /dev/null @@ -1,40 +0,0 @@ -// -// Copyright 2013-2020 Antony Polukhin. -// -// -// 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_STL_REGISTER_CLASS_HPP -#define BOOST_TYPE_INDEX_STL_REGISTER_CLASS_HPP - -/// \file stl_register_class.hpp -/// \brief Contains BOOST_TYPE_INDEX_REGISTER_CLASS macro implementation that uses boost::typeindex::stl_type_index. -/// Not intended for inclusion from user's code. - -#include <boost/type_index/stl_type_index.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost { namespace typeindex { namespace detail { - -template <class T> -inline const stl_type_index::type_info_t& stl_construct_typeid_ref(const T*) BOOST_NOEXCEPT { - return typeid(T); -} - -}}} // namespace boost::typeindex::detail - -/// @cond -#define BOOST_TYPE_INDEX_REGISTER_CLASS \ - virtual const boost::typeindex::stl_type_index::type_info_t& boost_type_index_type_id_runtime_() const BOOST_NOEXCEPT { \ - return boost::typeindex::detail::stl_construct_typeid_ref(this); \ - } \ -/**/ -/// @endcond - -#endif // BOOST_TYPE_INDEX_STL_REGISTER_CLASS_HPP - diff --git a/ThirdParty/boost/type_index/runtime_cast.hpp b/ThirdParty/boost/type_index/runtime_cast.hpp deleted file mode 100644 index c72b11916b1bdbc9a4d5b9a72ac269ffc934b927..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp b/ThirdParty/boost/type_index/runtime_cast/boost_shared_ptr_cast.hpp deleted file mode 100644 index e31f19d72868e74dd94d03537bfdd1bc8ea449f0..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp b/ThirdParty/boost/type_index/runtime_cast/detail/runtime_cast_impl.hpp deleted file mode 100644 index 6181df60f5857af43a32cf0e8b1f6014074bcc9c..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/pointer_cast.hpp b/ThirdParty/boost/type_index/runtime_cast/pointer_cast.hpp deleted file mode 100644 index 49a761390ca2fa1821c34c592977d54eeb183e91..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/reference_cast.hpp b/ThirdParty/boost/type_index/runtime_cast/reference_cast.hpp deleted file mode 100644 index 1511f7d03138f63bbb50fa1f13283f5095c5bf3b..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/register_runtime_class.hpp b/ThirdParty/boost/type_index/runtime_cast/register_runtime_class.hpp deleted file mode 100644 index ab758a5f171ebfeaef9ec7cd8d6413dedc7f54da..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp b/ThirdParty/boost/type_index/runtime_cast/std_shared_ptr_cast.hpp deleted file mode 100644 index 277a52426001ef1fe8698af690e34c3abc9c27f6..0000000000000000000000000000000000000000 --- a/ThirdParty/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/ThirdParty/boost/type_index/stl_type_index.hpp b/ThirdParty/boost/type_index/stl_type_index.hpp deleted file mode 100644 index 3f3177229fb38191cbdfd483073a18e42bd8a388..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/stl_type_index.hpp +++ /dev/null @@ -1,278 +0,0 @@ -// -// Copyright 2013-2020 Antony Polukhin. -// -// -// 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_STL_TYPE_INDEX_HPP -#define BOOST_TYPE_INDEX_STL_TYPE_INDEX_HPP - -/// \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 -/// for std::type_index. -/// -/// It is used in situations when RTTI is enabled or typeid() method is available. -/// When typeid() is disabled or BOOST_TYPE_INDEX_FORCE_NO_RTTI_COMPATIBILITY macro -/// is defined boost::typeindex::ctti is usually used instead of boost::typeindex::stl_type_index. - -#include <boost/type_index/type_index_facade.hpp> - -// MSVC is capable of calling typeid(T) even when RTTI is off -#if defined(BOOST_NO_RTTI) && !defined(BOOST_MSVC) -#error "File boost/type_index/stl_type_index.ipp is not usable when typeid() is not available." -#endif - -#include <typeinfo> -#include <cstring> // std::strcmp, std::strlen, std::strstr -#include <stdexcept> -#include <boost/static_assert.hpp> -#include <boost/throw_exception.hpp> -#include <boost/core/demangle.hpp> -#include <boost/type_traits/conditional.hpp> -#include <boost/type_traits/is_const.hpp> -#include <boost/type_traits/is_reference.hpp> -#include <boost/type_traits/is_volatile.hpp> -#include <boost/type_traits/remove_cv.hpp> -#include <boost/type_traits/remove_reference.hpp> - -#if (defined(_MSC_VER) && _MSC_VER > 1600) \ - || (defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ > 5 && defined(__GXX_EXPERIMENTAL_CXX0X__)) \ - || (defined(__GNUC__) && __GNUC__ > 4 && __cplusplus >= 201103) -# define BOOST_TYPE_INDEX_STD_TYPE_INDEX_HAS_HASH_CODE -#else -# include <boost/container_hash/hash.hpp> -#endif - -#if (defined(__EDG_VERSION__) && __EDG_VERSION__ < 245) \ - || (defined(__sgi) && defined(_COMPILER_VERSION) && _COMPILER_VERSION <= 744) -# include <boost/type_traits/is_signed.hpp> -# include <boost/type_traits/make_signed.hpp> -# include <boost/type_traits/type_identity.hpp> -#endif - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost { namespace typeindex { - -/// \class stl_type_index -/// This class is a wrapper around std::type_info, that workarounds issues and provides -/// much more rich interface. \b For \b description \b of \b functions \b see type_index_facade. -/// -/// 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, - #ifdef BOOST_NO_STD_TYPEINFO - type_info - #else - std::type_info - #endif - > -{ -public: -#ifdef BOOST_NO_STD_TYPEINFO - typedef type_info type_info_t; -#else - typedef std::type_info type_info_t; -#endif - -private: - const type_info_t* data_; - -public: - inline stl_type_index() BOOST_NOEXCEPT - : data_(&typeid(void)) - {} - - inline stl_type_index(const type_info_t& data) BOOST_NOEXCEPT - : data_(&data) - {} - - inline const type_info_t& type_info() const BOOST_NOEXCEPT; - - inline const char* raw_name() const BOOST_NOEXCEPT; - inline const char* name() const BOOST_NOEXCEPT; - inline std::string pretty_name() const; - - inline std::size_t hash_code() const BOOST_NOEXCEPT; - inline bool equal(const stl_type_index& rhs) const BOOST_NOEXCEPT; - inline bool before(const stl_type_index& rhs) const BOOST_NOEXCEPT; - - template <class T> - inline static stl_type_index type_id() BOOST_NOEXCEPT; - - template <class T> - inline static stl_type_index type_id_with_cvr() BOOST_NOEXCEPT; - - template <class T> - inline static stl_type_index type_id_runtime(const T& value) BOOST_NOEXCEPT; -}; - -inline const stl_type_index::type_info_t& stl_type_index::type_info() const BOOST_NOEXCEPT { - return *data_; -} - - -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 { - return data_->name(); -} - -inline std::string stl_type_index::pretty_name() const { - static const char cvr_saver_name[] = "boost::typeindex::detail::cvr_saver<"; - static BOOST_CONSTEXPR_OR_CONST std::string::size_type cvr_saver_name_len = sizeof(cvr_saver_name) - 1; - - // In case of MSVC demangle() is a no-op, and name() already returns demangled name. - // In case of GCC and Clang (on non-Windows systems) name() returns mangled name and demangle() undecorates it. - const boost::core::scoped_demangled_name demangled_name(data_->name()); - - const char* begin = demangled_name.get(); - if (!begin) { - boost::throw_exception(std::runtime_error("Type name demangling failed")); - } - - const std::string::size_type len = std::strlen(begin); - const char* end = begin + len; - - if (len > cvr_saver_name_len) { - const char* b = std::strstr(begin, cvr_saver_name); - if (b) { - b += cvr_saver_name_len; - - // Trim leading spaces - while (*b == ' ') { // the string is zero terminated, we won't exceed the buffer size - ++ b; - } - - // Skip the closing angle bracket - const char* e = end - 1; - while (e > b && *e != '>') { - -- e; - } - - // Trim trailing spaces - while (e > b && *(e - 1) == ' ') { - -- e; - } - - if (b < e) { - // Parsing seems to have succeeded, the type name is not empty - begin = b; - end = e; - } - } - } - - return std::string(begin, end); -} - - -inline std::size_t stl_type_index::hash_code() const BOOST_NOEXCEPT { -#ifdef BOOST_TYPE_INDEX_STD_TYPE_INDEX_HAS_HASH_CODE - return data_->hash_code(); -#else - return boost::hash_range(raw_name(), raw_name() + std::strlen(raw_name())); -#endif -} - - -/// @cond - -// for this compiler at least, cross-shared-library type_info -// comparisons don't work, so we are using typeid(x).name() instead. -# if (defined(__GNUC__) && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5))) \ - || defined(_AIX) \ - || (defined(__sgi) && defined(__host_mips)) \ - || (defined(__hpux) && defined(__HP_aCC)) \ - || (defined(linux) && defined(__INTEL_COMPILER) && defined(__ICC)) -# define BOOST_TYPE_INDEX_CLASSINFO_COMPARE_BY_NAMES -# endif - -/// @endcond - -inline bool stl_type_index::equal(const stl_type_index& rhs) const BOOST_NOEXCEPT { -#ifdef BOOST_TYPE_INDEX_CLASSINFO_COMPARE_BY_NAMES - return raw_name() == rhs.raw_name() || !std::strcmp(raw_name(), rhs.raw_name()); -#else - return !!(*data_ == *rhs.data_); -#endif -} - -inline bool stl_type_index::before(const stl_type_index& rhs) const BOOST_NOEXCEPT { -#ifdef BOOST_TYPE_INDEX_CLASSINFO_COMPARE_BY_NAMES - return raw_name() != rhs.raw_name() && std::strcmp(raw_name(), rhs.raw_name()) < 0; -#else - return !!data_->before(*rhs.data_); -#endif -} - -#undef BOOST_TYPE_INDEX_CLASSINFO_COMPARE_BY_NAMES - - -template <class T> -inline stl_type_index stl_type_index::type_id() BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::remove_reference<T>::type no_ref_t; - typedef BOOST_DEDUCED_TYPENAME boost::remove_cv<no_ref_t>::type no_cvr_prefinal_t; - - # if (defined(__EDG_VERSION__) && __EDG_VERSION__ < 245) \ - || (defined(__sgi) && defined(_COMPILER_VERSION) && _COMPILER_VERSION <= 744) - - // Old EDG-based compilers seem to mistakenly distinguish 'integral' from 'signed integral' - // in typeid() expressions. Full template specialization for 'integral' fixes that issue: - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_signed<no_cvr_prefinal_t>::value, - boost::make_signed<no_cvr_prefinal_t>, - boost::type_identity<no_cvr_prefinal_t> - >::type no_cvr_prefinal_lazy_t; - - typedef BOOST_DEDUCED_TYPENAME no_cvr_prefinal_t::type no_cvr_t; - #else - typedef no_cvr_prefinal_t no_cvr_t; - #endif - - return typeid(no_cvr_t); -} - -namespace detail { - template <class T> class cvr_saver{}; -} - -template <class T> -inline stl_type_index stl_type_index::type_id_with_cvr() BOOST_NOEXCEPT { - typedef BOOST_DEDUCED_TYPENAME boost::conditional< - boost::is_reference<T>::value || boost::is_const<T>::value || boost::is_volatile<T>::value, - detail::cvr_saver<T>, - T - >::type type; - - return typeid(type); -} - - -template <class T> -inline stl_type_index stl_type_index::type_id_runtime(const T& value) BOOST_NOEXCEPT { -#ifdef BOOST_NO_RTTI - return value.boost_type_index_type_id_runtime_(); -#else - return typeid(value); -#endif -} - -}} // namespace boost::typeindex - -#undef BOOST_TYPE_INDEX_STD_TYPE_INDEX_HAS_HASH_CODE - -#endif // BOOST_TYPE_INDEX_STL_TYPE_INDEX_HPP diff --git a/ThirdParty/boost/type_index/type_index_facade.hpp b/ThirdParty/boost/type_index/type_index_facade.hpp deleted file mode 100644 index cf5ef1e9aec9d34ffa556ef6fa19844b4bc3d7bc..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_index/type_index_facade.hpp +++ /dev/null @@ -1,297 +0,0 @@ -// -// Copyright 2013-2020 Antony Polukhin. -// -// -// 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_TYPE_INDEX_FACADE_HPP -#define BOOST_TYPE_INDEX_TYPE_INDEX_FACADE_HPP - -#include <boost/config.hpp> -#include <boost/container_hash/hash_fwd.hpp> -#include <string> -#include <cstring> - -#if !defined(BOOST_NO_IOSTREAM) -#if !defined(BOOST_NO_IOSFWD) -#include <iosfwd> // for std::basic_ostream -#else -#include <ostream> -#endif -#endif - -#ifdef BOOST_HAS_PRAGMA_ONCE -# pragma once -#endif - -namespace boost { namespace typeindex { - -/// \class type_index_facade -/// -/// This class takes care about the comparison operators, hash functions and -/// ostream operators. Use this class as a public base class for defining new -/// type_info-conforming classes. -/// -/// \b Example: -/// \code -/// class stl_type_index: public type_index_facade<stl_type_index, std::type_info> -/// { -/// public: -/// typedef std::type_info type_info_t; -/// private: -/// const type_info_t* data_; -/// -/// public: -/// stl_type_index(const type_info_t& data) noexcept -/// : data_(&data) -/// {} -/// // ... -/// }; -/// \endcode -/// -/// \tparam Derived Class derived from type_index_facade. -/// \tparam TypeInfo Class that will be used as a base type_info class. -/// \note Take a look at the protected methods. They are \b not \b defined in type_index_facade. -/// Protected member functions raw_name() \b must be defined in Derived class. All the other -/// methods are mandatory. -/// \see 'Making a custom type_index' section for more information about -/// creating your own type_index using type_index_facade. -template <class Derived, class TypeInfo> -class type_index_facade { -private: - /// @cond - BOOST_CXX14_CONSTEXPR const Derived & derived() const BOOST_NOEXCEPT { - return *static_cast<Derived const*>(this); - } - /// @endcond -public: - typedef TypeInfo type_info_t; - - /// \b Override: This function \b may be redefined in Derived class. Overrides \b must not throw. - /// \return Name of a type. By default returns Derived::raw_name(). - inline const char* name() const BOOST_NOEXCEPT { - return derived().raw_name(); - } - - /// \b Override: This function \b may be redefined in Derived class. Overrides may throw. - /// \return Human readable type name. By default returns Derived::name(). - inline std::string pretty_name() const { - return derived().name(); - } - - /// \b Override: This function \b may be redefined in Derived class. Overrides \b must not throw. - /// \return True if two types are equal. By default compares types by raw_name(). - inline bool equal(const Derived& rhs) const BOOST_NOEXCEPT { - const char* const left = derived().raw_name(); - const char* const right = rhs.raw_name(); - return left == right || !std::strcmp(left, right); - } - - /// \b Override: This function \b may be redefined in Derived class. Overrides \b must not throw. - /// \return True if rhs is greater than this. By default compares types by raw_name(). - inline bool before(const Derived& rhs) const BOOST_NOEXCEPT { - const char* const left = derived().raw_name(); - const char* const right = rhs.raw_name(); - return left != right && std::strcmp(left, right) < 0; - } - - /// \b Override: This function \b may be redefined in Derived class. Overrides \b must not throw. - /// \return Hash code of a type. By default hashes types by raw_name(). - /// \note Derived class header \b must include <boost/container_hash/hash.hpp>, \b unless this function is redefined in - /// Derived class to not use boost::hash_range(). - inline std::size_t hash_code() const BOOST_NOEXCEPT { - const char* const name_raw = derived().raw_name(); - return boost::hash_range(name_raw, name_raw + std::strlen(name_raw)); - } - -#if defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) -protected: - /// \b Override: This function \b must be redefined in Derived class. Overrides \b must not throw. - /// \return Pointer to unredable/raw type name. - inline const char* raw_name() const BOOST_NOEXCEPT; - - /// \b Override: This function \b may be redefined in Derived class. Overrides \b must not throw. - /// \return Const reference to underlying low level type_info_t. - inline const type_info_t& type_info() const BOOST_NOEXCEPT; - - /// This is a factory method that is used to create instances of Derived classes. - /// boost::typeindex::type_id() will call this method, if Derived has same type as boost::typeindex::type_index. - /// - /// \b Override: This function \b may be redefined and made public in Derived class. Overrides \b must not throw. - /// Overrides \b must remove const, volatile && and & modifiers from T. - /// \tparam T Type for which type_index must be created. - /// \return type_index for type T. - template <class T> - static Derived type_id() BOOST_NOEXCEPT; - - /// This is a factory method that is used to create instances of Derived classes. - /// boost::typeindex::type_id_with_cvr() will call this method, if Derived has same type as boost::typeindex::type_index. - /// - /// \b Override: This function \b may be redefined and made public in Derived class. Overrides \b must not throw. - /// Overrides \b must \b not remove const, volatile && and & modifiers from T. - /// \tparam T Type for which type_index must be created. - /// \return type_index for type T. - template <class T> - static Derived type_id_with_cvr() BOOST_NOEXCEPT; - - /// This is a factory method that is used to create instances of Derived classes. - /// boost::typeindex::type_id_runtime(const T&) will call this method, if Derived has same type as boost::typeindex::type_index. - /// - /// \b Override: This function \b may be redefined and made public in Derived class. - /// \param variable Variable which runtime type will be stored in type_index. - /// \return type_index with runtime type of variable. - template <class T> - static Derived type_id_runtime(const T& variable) BOOST_NOEXCEPT; - -#endif - -}; - -/// @cond -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator == (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return static_cast<Derived const&>(lhs).equal(static_cast<Derived const&>(rhs)); -} - -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator < (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return static_cast<Derived const&>(lhs).before(static_cast<Derived const&>(rhs)); -} - - - -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator > (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return rhs < lhs; -} - -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator <= (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(lhs > rhs); -} - -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator >= (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(lhs < rhs); -} - -template <class Derived, class TypeInfo> -BOOST_CXX14_CONSTEXPR inline bool operator != (const type_index_facade<Derived, TypeInfo>& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(lhs == rhs); -} - -// ######################### COMPARISONS with Derived ############################ // -template <class Derived, class TypeInfo> -inline bool operator == (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return Derived(lhs) == rhs; -} - -template <class Derived, class TypeInfo> -inline bool operator < (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return Derived(lhs) < rhs; -} - -template <class Derived, class TypeInfo> -inline bool operator > (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return rhs < Derived(lhs); -} - -template <class Derived, class TypeInfo> -inline bool operator <= (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(Derived(lhs) > rhs); -} - -template <class Derived, class TypeInfo> -inline bool operator >= (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(Derived(lhs) < rhs); -} - -template <class Derived, class TypeInfo> -inline bool operator != (const TypeInfo& lhs, const type_index_facade<Derived, TypeInfo>& rhs) BOOST_NOEXCEPT { - return !(Derived(lhs) == rhs); -} - - -template <class Derived, class TypeInfo> -inline bool operator == (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return lhs == Derived(rhs); -} - -template <class Derived, class TypeInfo> -inline bool operator < (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return lhs < Derived(rhs); -} - -template <class Derived, class TypeInfo> -inline bool operator > (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return Derived(rhs) < lhs; -} - -template <class Derived, class TypeInfo> -inline bool operator <= (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return !(lhs > Derived(rhs)); -} - -template <class Derived, class TypeInfo> -inline bool operator >= (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return !(lhs < Derived(rhs)); -} - -template <class Derived, class TypeInfo> -inline bool operator != (const type_index_facade<Derived, TypeInfo>& lhs, const TypeInfo& rhs) BOOST_NOEXCEPT { - return !(lhs == Derived(rhs)); -} - -// ######################### COMPARISONS with Derived END ############################ // - -/// @endcond - -#if defined(BOOST_TYPE_INDEX_DOXYGEN_INVOKED) - -/// noexcept comparison operators for type_index_facade classes. -bool operator ==, !=, <, ... (const type_index_facade& lhs, const type_index_facade& rhs) noexcept; - -/// noexcept comparison operators for type_index_facade and it's TypeInfo classes. -bool operator ==, !=, <, ... (const type_index_facade& lhs, const TypeInfo& rhs) noexcept; - -/// noexcept comparison operators for type_index_facade's TypeInfo and type_index_facade classes. -bool operator ==, !=, <, ... (const TypeInfo& lhs, const type_index_facade& rhs) noexcept; - -#endif - -#ifndef BOOST_NO_IOSTREAM -#ifdef BOOST_NO_TEMPLATED_IOSTREAMS -/// @cond -/// Ostream operator that will output demangled name -template <class Derived, class TypeInfo> -inline std::ostream& operator<<(std::ostream& ostr, const type_index_facade<Derived, TypeInfo>& ind) { - ostr << static_cast<Derived const&>(ind).pretty_name(); - return ostr; -} -/// @endcond -#else -/// Ostream operator that will output demangled name. -template <class CharT, class TriatT, class Derived, class TypeInfo> -inline std::basic_ostream<CharT, TriatT>& operator<<( - std::basic_ostream<CharT, TriatT>& ostr, - const type_index_facade<Derived, TypeInfo>& ind) -{ - ostr << static_cast<Derived const&>(ind).pretty_name(); - return ostr; -} -#endif // BOOST_NO_TEMPLATED_IOSTREAMS -#endif // BOOST_NO_IOSTREAM - -/// This free function is used by Boost's unordered containers. -/// \note <boost/container_hash/hash.hpp> has to be included if this function is used. -template <class Derived, class TypeInfo> -inline std::size_t hash_value(const type_index_facade<Derived, TypeInfo>& lhs) BOOST_NOEXCEPT { - return static_cast<Derived const&>(lhs).hash_code(); -} - -}} // namespace boost::typeindex - -#endif // BOOST_TYPE_INDEX_TYPE_INDEX_FACADE_HPP - diff --git a/ThirdParty/boost/type_traits/detail/config.hpp b/ThirdParty/boost/type_traits/detail/config.hpp deleted file mode 100644 index 7c4b4f2162deff88195d6027513adfb577e24e7d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_traits/detail/config.hpp +++ /dev/null @@ -1,113 +0,0 @@ - -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to 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). -// -// See http://www.boost.org/libs/type_traits for most recent version including documentation. - -#ifndef BOOST_TT_CONFIG_HPP_INCLUDED -#define BOOST_TT_CONFIG_HPP_INCLUDED - -#ifndef BOOST_CONFIG_HPP -#include <boost/config.hpp> -#endif -#include <boost/version.hpp> -#include <boost/config/workaround.hpp> - -// -// whenever we have a conversion function with ellipses -// it needs to be declared __cdecl to suppress compiler -// warnings from MS and Borland compilers (this *must* -// appear before we include is_same.hpp below): -#if defined(BOOST_MSVC) || (defined(__BORLANDC__) && !defined(BOOST_DISABLE_WIN32)) -# define BOOST_TT_DECL __cdecl -#else -# define BOOST_TT_DECL /**/ -#endif - -# if (BOOST_WORKAROUND(__MWERKS__, < 0x3000) \ - || BOOST_WORKAROUND(__IBMCPP__, < 600 ) \ - || BOOST_WORKAROUND(__BORLANDC__, < 0x5A0) \ - || defined(__ghs) \ - || BOOST_WORKAROUND(__HP_aCC, < 60700) \ - || BOOST_WORKAROUND(MPW_CPLUS, BOOST_TESTED_AT(0x890)) \ - || BOOST_WORKAROUND(__SUNPRO_CC, BOOST_TESTED_AT(0x580))) \ - && defined(BOOST_NO_IS_ABSTRACT) - -# define BOOST_TT_NO_CONFORMING_IS_CLASS_IMPLEMENTATION 1 - -#endif - -#ifndef BOOST_TT_NO_CONFORMING_IS_CLASS_IMPLEMENTATION -# define BOOST_TT_HAS_CONFORMING_IS_CLASS_IMPLEMENTATION 1 -#endif - -// -// define BOOST_TT_TEST_MS_FUNC_SIGS -// when we want to test __stdcall etc function types with is_function etc -// (Note, does not work with Borland, even though it does support __stdcall etc): -// -#if defined(_MSC_EXTENSIONS) && !defined(__BORLANDC__) -# define BOOST_TT_TEST_MS_FUNC_SIGS -#endif - -// -// define BOOST_TT_NO_CV_FUNC_TEST -// if tests for cv-qualified member functions don't -// work in is_member_function_pointer -// -#if BOOST_WORKAROUND(__MWERKS__, < 0x3000) || BOOST_WORKAROUND(__IBMCPP__, <= 600) -# define BOOST_TT_NO_CV_FUNC_TEST -#endif - -// -// Macros that have been deprecated, defined here for backwards compatibility: -// -#define BOOST_BROKEN_COMPILER_TYPE_TRAITS_SPECIALIZATION(x) -#define BOOST_TT_BROKEN_COMPILER_SPEC(x) - -// -// Can we implement "accurate" binary operator detection: -// -#if !defined(BOOST_NO_SFINAE_EXPR) && !defined(BOOST_NO_CXX11_DECLTYPE) && !BOOST_WORKAROUND(BOOST_MSVC, < 1900) && !BOOST_WORKAROUND(BOOST_GCC, < 40900) -# define BOOST_TT_HAS_ACCURATE_BINARY_OPERATOR_DETECTION -#endif - -#if defined(__clang__) && (__clang_major__ == 3) && (__clang_minor__ < 2) && defined(BOOST_TT_HAS_ACCURATE_BINARY_OPERATOR_DETECTION) -#undef BOOST_TT_HAS_ACCURATE_BINARY_OPERATOR_DETECTION -#endif - -// -// Can we implement accurate is_function/is_member_function_pointer (post C++03)? -// -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !BOOST_WORKAROUND(BOOST_GCC, < 40805)\ - && !BOOST_WORKAROUND(BOOST_MSVC, < 1900) && !BOOST_WORKAROUND(__clang_major__, <= 4) -# define BOOST_TT_HAS_ASCCURATE_IS_FUNCTION -#endif - -#if defined(_MSVC_LANG) && (_MSVC_LANG >= 201703) -# define BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM -#endif -#if defined(__APPLE_CC__) && defined(__clang_major__) && (__clang_major__ == 9) && (__clang_minor__ == 0) -# define BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM -# define BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE -#endif -// -// If we have the SD6 macros (check for C++11's __cpp_rvalue_references), and we don't have __cpp_noexcept_function_type -// set, then don't treat noexcept functions as seperate types. This is a fix for msvc with the /Zc:noexceptTypes- flag set. -// -#if defined(__cpp_rvalue_references) && !defined(__cpp_noexcept_function_type) && !defined(BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE) -# define BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE -#endif -// -// Check MSVC specific macro on older msvc compilers that don't support the SD6 macros, we don't rely on this -// if the SD6 macros *are* available as it appears to be undocumented. -// -#if defined(BOOST_MSVC) && !defined(__cpp_rvalue_references) && !defined(BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE) && !defined(_NOEXCEPT_TYPES_SUPPORTED) -# define BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE -#endif - -#endif // BOOST_TT_CONFIG_HPP_INCLUDED - - diff --git a/ThirdParty/boost/type_traits/detail/is_function_cxx_11.hpp b/ThirdParty/boost/type_traits/detail/is_function_cxx_11.hpp deleted file mode 100644 index 4de74a7373027befb6261cc17664824c4a8b1491..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_traits/detail/is_function_cxx_11.hpp +++ /dev/null @@ -1,597 +0,0 @@ - -// Copyright 2000 John Maddock (john@johnmaddock.co.uk) -// Copyright 2002 Aleksey Gurtovoy (agurtovoy@meta-comm.com) -// -// Use, modification and distribution are subject to 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). -// -// See http://www.boost.org/libs/type_traits for most recent version including documentation. - -#ifndef BOOST_TT_IS_FUNCTION_CXX_11_HPP_INCLUDED -#define BOOST_TT_IS_FUNCTION_CXX_11_HPP_INCLUDED - -#include <boost/type_traits/integral_constant.hpp> - -namespace boost { - - template <class T> - struct is_function : public false_type {}; - -#if defined(__cpp_noexcept_function_type) && !defined(BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM) -#define BOOST_TT_NOEXCEPT_PARAM , bool NE -#define BOOST_TT_NOEXCEPT_DECL noexcept(NE) -#else -#define BOOST_TT_NOEXCEPT_PARAM -#define BOOST_TT_NOEXCEPT_DECL -#endif - -#ifdef _MSC_VER -#define BOOST_TT_DEF_CALL __cdecl -#else -#define BOOST_TT_DEF_CALL -#endif - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // Reference qualified: - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // rvalue reference qualified: - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)&& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)&& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - -#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // reference qualified: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // rvalue reference qualified: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)&&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)&&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)&&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - -#endif // _MSC_VER - - // All over again for msvc with noexcept: - -#if defined(BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM) && !defined(BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE) - -#undef BOOST_TT_NOEXCEPT_DECL -#define BOOST_TT_NOEXCEPT_DECL noexcept - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // Reference qualified: - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // rvalue reference qualified: - - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret BOOST_TT_DEF_CALL(Args...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret(Args..., ...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - -#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // reference qualified: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // rvalue reference qualified: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - // const volatile: -#ifdef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __clrcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __stdcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __fastcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_function<Ret __vectorcall(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - -#endif // defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) - -#endif - -} - -#undef BOOST_TT_NOEXCEPT_DECL -#undef BOOST_TT_NOEXCEPT_PARAM -#undef BOOST_TT_DEF_CALL - -#endif // BOOST_TT_IS_FUNCTION_CXX_11_HPP_INCLUDED - diff --git a/ThirdParty/boost/type_traits/detail/is_member_function_pointer_cxx_11.hpp b/ThirdParty/boost/type_traits/detail/is_member_function_pointer_cxx_11.hpp deleted file mode 100644 index b0502cbe8b3053abc29073cd8918b164bbcda98d..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/type_traits/detail/is_member_function_pointer_cxx_11.hpp +++ /dev/null @@ -1,672 +0,0 @@ - -// (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, Howard -// Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to 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). -// -// See http://www.boost.org/libs/type_traits for most recent version including documentation. - - -#ifndef BOOST_TT_IS_MEMBER_FUNCTION_POINTER_CXX_11_HPP_INCLUDED -#define BOOST_TT_IS_MEMBER_FUNCTION_POINTER_CXX_11_HPP_INCLUDED - -#include <boost/type_traits/integral_constant.hpp> - -namespace boost { - -#ifdef _MSC_VER -#define BOOST_TT_DEF_CALL __thiscall -#else -#define BOOST_TT_DEF_CALL -#endif - - - template <class T> - struct is_member_function_pointer : public false_type {}; - template <class T> - struct is_member_function_pointer<T const> : public is_member_function_pointer<T> {}; - template <class T> - struct is_member_function_pointer<T volatile> : public is_member_function_pointer<T> {}; - template <class T> - struct is_member_function_pointer<T const volatile> : public is_member_function_pointer<T> {}; - -#if defined(BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM) - // MSVC can't handle noexcept(b) as a deduced template parameter - // so we will have to write everything out :( -#define BOOST_TT_NOEXCEPT_PARAM -#define BOOST_TT_NOEXCEPT_DECL -#elif defined(__cpp_noexcept_function_type) -#define BOOST_TT_NOEXCEPT_PARAM , bool NE -#define BOOST_TT_NOEXCEPT_DECL noexcept(NE) -#else -#define BOOST_TT_NOEXCEPT_PARAM -#define BOOST_TT_NOEXCEPT_DECL -#endif - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (C::*)(Args..., ...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // Reference qualified: - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // rvalue reference qualified: - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (BOOST_TT_DEF_CALL C::*)(Args...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - -#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__clrcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // reference qualified: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // rvalue reference qualified: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__stdcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__fastcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret (__vectorcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif - - -#if defined(BOOST_TT_NO_DEDUCED_NOEXCEPT_PARAM) && !defined(BOOST_TT_NO_NOEXCEPT_SEPARATE_TYPE) - -#undef BOOST_TT_NOEXCEPT_DECL -#define BOOST_TT_NOEXCEPT_DECL noexcept - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // Reference qualified: - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)& BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile & BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - - // rvalue reference qualified: - - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const qualified: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // volatile: - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - // const volatile - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(BOOST_TT_DEF_CALL C::*)(Args...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - template <class Ret, class C, class ...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(C::*)(Args..., ...)const volatile && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - -#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const volatile BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // reference qualified: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const volatile &BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // rvalue reference qualified: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...) && BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - - // const volatile: -#ifdef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__clrcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; - -#endif -#ifndef _M_AMD64 - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__stdcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#ifndef __CLR_VER - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__fastcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__cdecl C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#if !defined(__CLR_VER) && (defined(_M_IX86_FP) && (_M_IX86_FP >= 2) || defined(_M_X64)) - template <class Ret, class C, class...Args BOOST_TT_NOEXCEPT_PARAM> - struct is_member_function_pointer<Ret(__vectorcall C::*)(Args...)const volatile &&BOOST_TT_NOEXCEPT_DECL> : public true_type {}; -#endif -#endif - - -#endif - -#undef BOOST_TT_NOEXCEPT_DECL -#undef BOOST_TT_NOEXCEPT_PARAM -#undef BOOST_TT_DEF_CALL -} - -#endif // BOOST_TT_IS_MEMBER_FUNCTION_POINTER_CXX_11_HPP_INCLUDED diff --git a/ThirdParty/boost/typeof/int_encoding.hpp b/ThirdParty/boost/typeof/int_encoding.hpp deleted file mode 100644 index 1f00d4f1e7dd62acc24c49eb9ee83b082f5d038e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/typeof/int_encoding.hpp +++ /dev/null @@ -1,118 +0,0 @@ -// Copyright (C) 2004 Arkadiy Vertleyb -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_TYPEOF_INT_ENCODING_HPP_INCLUDED -#define BOOST_TYPEOF_INT_ENCODING_HPP_INCLUDED - -#include <boost/config.hpp> -#include <boost/typeof/constant.hpp> -#include <cstddef> // for std::size_t - -namespace boost { namespace type_of { - - template<class T> struct get_unsigned - { - typedef T type; - }; - template<> struct get_unsigned<signed char> - { - typedef unsigned char type; - }; - template<> struct get_unsigned<char> - { - typedef unsigned char type; - }; - template<> struct get_unsigned<short> - { - typedef unsigned short type; - }; - template<> struct get_unsigned<int> - { - typedef unsigned int type; - }; - template<> struct get_unsigned<long> - { - typedef unsigned long type; - }; - - ////////////////////////// - - template<std::size_t n, bool Overflow> - struct pack - { - BOOST_STATIC_CONSTANT(std::size_t , value=((n + 1) * 2 + (Overflow ? 1 : 0))); - }; - - template<std::size_t m> - struct unpack - { - BOOST_STATIC_CONSTANT(std::size_t, value = (m / 2) - 1); - BOOST_STATIC_CONSTANT(std::size_t, overflow = (m % 2 == 1)); - }; - - //////////////////////////////// - - template<class V, std::size_t n, bool overflow = (n >= 0x3fffffff)> - struct encode_size_t : push_back< - V, - boost::type_of::constant<std::size_t,pack<n, false>::value> - > - {}; - - template<class V, std::size_t n> - struct encode_size_t<V, n, true> : push_back<typename push_back< - V, - boost::type_of::constant<std::size_t,pack<n % 0x3ffffffe, true>::value> >::type, - boost::type_of::constant<std::size_t,n / 0x3ffffffe> - > - {}; - - template<class V, class T, T n> - struct encode_integral : encode_size_t< V, (typename get_unsigned<T>::type)n,(((typename get_unsigned<T>::type)n)>=0x3fffffff) > - {}; - - template<class V, bool b> - struct encode_integral<V, bool, b> : encode_size_t< V, b?1:0, false> - {}; - /////////////////////////// - - template<std::size_t n, class Iter, bool overflow> - struct decode_size_t; - - template<std::size_t n, class Iter> - struct decode_size_t<n, Iter, false> - { - BOOST_STATIC_CONSTANT(std::size_t,value = n); - typedef Iter iter; - }; - - template<std::size_t n, class Iter> - struct decode_size_t<n, Iter, true> - { - BOOST_STATIC_CONSTANT(std::size_t,m = Iter::type::value); - - BOOST_STATIC_CONSTANT(std::size_t,value = (std::size_t)m * 0x3ffffffe + n); - typedef typename Iter::next iter; - }; - - template<class T, class Iter> - struct decode_integral - { - typedef decode_integral<T,Iter> self_t; - BOOST_STATIC_CONSTANT(std::size_t,m = Iter::type::value); - - BOOST_STATIC_CONSTANT(std::size_t,n = unpack<m>::value); - - BOOST_STATIC_CONSTANT(std::size_t,overflow = unpack<m>::overflow); - - typedef typename Iter::next nextpos; - - static const T value = (T)(std::size_t)decode_size_t<n, nextpos, overflow>::value; - - typedef typename decode_size_t<self_t::n, nextpos, self_t::overflow>::iter iter; - }; - -}}//namespace - -#endif//BOOST_TYPEOF_INT_ENCODING_HPP_INCLUDED diff --git a/ThirdParty/boost/typeof/typeof_impl.hpp b/ThirdParty/boost/typeof/typeof_impl.hpp deleted file mode 100644 index 73a25dfeef9cf3542a8ec258ca5a739b7af7eb62..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/typeof/typeof_impl.hpp +++ /dev/null @@ -1,187 +0,0 @@ -// Copyright (C) 2004, 2005 Arkadiy Vertleyb -// Copyright (C) 2005 Peder Holt -// 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_TYPEOF_TYPEOF_IMPL_HPP_INCLUDED -#define BOOST_TYPEOF_TYPEOF_IMPL_HPP_INCLUDED - -#include <boost/preprocessor/repetition/enum.hpp> -#include <boost/typeof/constant.hpp> -#include <boost/typeof/encode_decode.hpp> -#include <boost/typeof/vector.hpp> -#include <boost/type_traits/enable_if.hpp> -#include <boost/type_traits/is_function.hpp> -#include <cstddef> // for std::size_t - -#define BOOST_TYPEOF_VECTOR(n) BOOST_PP_CAT(boost::type_of::vector, n) - -#define BOOST_TYPEOF_sizer_item(z, n, _)\ - char item ## n[V::item ## n ::value]; - -namespace boost { namespace type_of { - template<class V> - struct sizer - { - // char item0[V::item0::value]; - // char item1[V::item1::value]; - // ... - - BOOST_PP_REPEAT(BOOST_TYPEOF_LIMIT_SIZE, BOOST_TYPEOF_sizer_item, ~) - }; -}} - -#undef BOOST_TYPEOF_sizer_item - -// -namespace boost { namespace type_of { -# ifdef BOOST_NO_SFINAE - template<class V, class T> - sizer<typename encode_type<V, T>::type> encode(const T&); -# else - template<class V, class T> - typename enable_if_< - is_function<T>::value, - sizer<typename encode_type<V, T>::type> >::type encode(T&); - - template<class V, class T> - typename enable_if_< - !is_function<T>::value, - sizer<typename encode_type<V, T>::type> >::type encode(const T&); -# endif -}} -// -namespace boost { namespace type_of { - - template<class V> - struct decode_begin - { - typedef typename decode_type<typename V::begin>::type type; - }; -}} - -#define BOOST_TYPEOF_TYPEITEM(z, n, expr)\ - boost::type_of::constant<std::size_t,sizeof(boost::type_of::encode<BOOST_TYPEOF_VECTOR(0)<> >(expr).item ## n)> - -#define BOOST_TYPEOF_ENCODED_VECTOR(Expr) \ - BOOST_TYPEOF_VECTOR(BOOST_TYPEOF_LIMIT_SIZE)< \ - BOOST_PP_ENUM(BOOST_TYPEOF_LIMIT_SIZE, BOOST_TYPEOF_TYPEITEM, Expr) \ - > - -#define BOOST_TYPEOF(Expr)\ - boost::type_of::decode_begin<BOOST_TYPEOF_ENCODED_VECTOR(Expr) >::type - -#define BOOST_TYPEOF_TPL typename BOOST_TYPEOF - -//offset_vector is used to delay the insertion of data into the vector in order to allow -//encoding to be done in many steps -namespace boost { namespace type_of { - template<typename V,typename Offset> - struct offset_vector { - }; - - template<class V,class Offset,class T> - struct push_back<boost::type_of::offset_vector<V,Offset>,T> { - typedef offset_vector<V,typename Offset::prior> type; - }; - - template<class V,class T> - struct push_back<boost::type_of::offset_vector<V,constant<std::size_t,0> >,T> { - typedef typename push_back<V,T>::type type; - }; -}} - -#define BOOST_TYPEOF_NESTED_TYPEITEM(z, n, expr)\ - BOOST_STATIC_CONSTANT(int,BOOST_PP_CAT(value,n) = sizeof(boost::type_of::encode<_typeof_start_vector>(expr).item ## n));\ - typedef boost::type_of::constant<std::size_t,BOOST_PP_CAT(self_t::value,n)> BOOST_PP_CAT(item,n); - -#ifdef __DMC__ -#define BOOST_TYPEOF_NESTED_TYPEITEM_2(z,n,expr)\ - typedef typename _typeof_encode_fraction<iteration>::BOOST_PP_CAT(item,n) BOOST_PP_CAT(item,n); - -#define BOOST_TYPEOF_FRACTIONTYPE()\ - BOOST_PP_REPEAT(BOOST_TYPEOF_LIMIT_SIZE,BOOST_TYPEOF_NESTED_TYPEITEM_2,_)\ - typedef _typeof_fraction_iter<Pos> fraction_type; -#else -#define BOOST_TYPEOF_FRACTIONTYPE()\ - typedef _typeof_encode_fraction<self_t::iteration> fraction_type; -#endif - -#ifdef __BORLANDC__ -namespace boost { namespace type_of { - template<typename Pos,typename Iter> - struct generic_typeof_fraction_iter { - typedef generic_typeof_fraction_iter<Pos,Iter> self_t; - static const int pos=(Pos::value); - static const int iteration=(pos/5); - static const int where=pos%5; - typedef typename Iter::template _apply_next<self_t::iteration>::type fraction_type; - typedef generic_typeof_fraction_iter<typename Pos::next,Iter> next; - typedef typename v_iter<fraction_type,constant<int, self_t::where> >::type type; - }; -}} -#define BOOST_TYPEOF_NESTED_TYPEDEF_IMPL(expr) \ - template<int _Typeof_Iteration>\ - struct _typeof_encode_fraction {\ - typedef _typeof_encode_fraction<_Typeof_Iteration> self_t;\ - BOOST_STATIC_CONSTANT(int,_typeof_encode_offset = (_Typeof_Iteration*BOOST_TYPEOF_LIMIT_SIZE));\ - typedef boost::type_of::offset_vector<BOOST_TYPEOF_VECTOR(0)<>,boost::type_of::constant<std::size_t,self_t::_typeof_encode_offset> > _typeof_start_vector;\ - BOOST_PP_REPEAT(BOOST_TYPEOF_LIMIT_SIZE,BOOST_TYPEOF_NESTED_TYPEITEM,expr)\ - template<int Next>\ - struct _apply_next {\ - typedef _typeof_encode_fraction<Next> type;\ - };\ - };\ - template<typename Pos>\ - struct _typeof_fraction_iter {\ - typedef boost::type_of::generic_typeof_fraction_iter<Pos,_typeof_encode_fraction<0> > self_t;\ - typedef typename self_t::next next;\ - typedef typename self_t::type type;\ - }; -#else -#define BOOST_TYPEOF_NESTED_TYPEDEF_IMPL(expr) \ - template<int _Typeof_Iteration>\ - struct _typeof_encode_fraction {\ - typedef _typeof_encode_fraction<_Typeof_Iteration> self_t;\ - BOOST_STATIC_CONSTANT(int,_typeof_encode_offset = (_Typeof_Iteration*BOOST_TYPEOF_LIMIT_SIZE));\ - typedef boost::type_of::offset_vector<BOOST_TYPEOF_VECTOR(0)<>,boost::type_of::constant<std::size_t,self_t::_typeof_encode_offset> > _typeof_start_vector;\ - BOOST_PP_REPEAT(BOOST_TYPEOF_LIMIT_SIZE,BOOST_TYPEOF_NESTED_TYPEITEM,expr)\ - };\ - template<typename Pos>\ - struct _typeof_fraction_iter {\ - typedef _typeof_fraction_iter<Pos> self_t;\ - BOOST_STATIC_CONSTANT(int,pos=(Pos::value));\ - BOOST_STATIC_CONSTANT(int,iteration=(pos/BOOST_TYPEOF_LIMIT_SIZE));\ - BOOST_STATIC_CONSTANT(int,where=pos%BOOST_TYPEOF_LIMIT_SIZE);\ - BOOST_TYPEOF_FRACTIONTYPE()\ - typedef typename boost::type_of::v_iter<fraction_type,boost::type_of::constant<int,self_t::where> >::type type;\ - typedef _typeof_fraction_iter<typename Pos::next> next;\ - }; -#endif -#ifdef __MWERKS__ - -# define BOOST_TYPEOF_NESTED_TYPEDEF(name,expr) \ -template<typename T>\ -struct BOOST_PP_CAT(_typeof_template_,name) {\ - BOOST_TYPEOF_NESTED_TYPEDEF_IMPL(expr)\ - typedef typename boost::type_of::decode_type<_typeof_fraction_iter<boost::type_of::constant<std::size_t,0> > >::type type;\ -};\ -typedef BOOST_PP_CAT(_typeof_template_,name)<int> name; - -# define BOOST_TYPEOF_NESTED_TYPEDEF_TPL(name,expr) BOOST_TYPEOF_NESTED_TYPEDEF(name,expr) - -#else -# define BOOST_TYPEOF_NESTED_TYPEDEF_TPL(name,expr) \ - struct name {\ - BOOST_TYPEOF_NESTED_TYPEDEF_IMPL(expr)\ - typedef typename boost::type_of::decode_type<_typeof_fraction_iter<boost::type_of::constant<std::size_t,0> > >::type type;\ - }; - -# define BOOST_TYPEOF_NESTED_TYPEDEF(name,expr) \ - struct name {\ - BOOST_TYPEOF_NESTED_TYPEDEF_IMPL(expr)\ - typedef boost::type_of::decode_type<_typeof_fraction_iter<boost::type_of::constant<std::size_t,0> > >::type type;\ - }; -#endif - -#endif//BOOST_TYPEOF_COMPLIANT_TYPEOF_IMPL_HPP_INCLUDED diff --git a/ThirdParty/boost/unordered/detail/fwd.hpp b/ThirdParty/boost/unordered/detail/fwd.hpp deleted file mode 100644 index e749ce67bb6eb7117be467587971c0453c3eb2bf..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/unordered/detail/fwd.hpp +++ /dev/null @@ -1,63 +0,0 @@ - -// Copyright (C) 2008-2016 Daniel James. -// 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_UNORDERED_FWD_HPP_INCLUDED -#define BOOST_UNORDERED_FWD_HPP_INCLUDED - -#include <boost/config.hpp> -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -#include <boost/predef.h> - -#if defined(BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT) -// Already defined. -#elif defined(BOOST_LIBSTDCXX11) -// https://github.com/gcc-mirror/gcc/blob/gcc-4_6-branch/libstdc++-v3/include/bits/stl_pair.h#L70 -#if BOOST_LIBSTDCXX_VERSION > 40600 -#define BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT 1 -#endif -#elif BOOST_LIB_STD_CXX -// https://github.com/llvm-mirror/libcxx/blob/release_30/include/utility#L206 -#if BOOST_LIB_STD_CXX >= BOOST_VERSION_NUMBER(3, 0, 0) -#define BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT 1 -#endif -#elif defined(BOOST_LIB_STD_DINKUMWARE) -// Apparently C++11 standard supported in Visual Studio 2012 -// https://msdn.microsoft.com/en-us/library/hh567368.aspx#stl -// 2012 = VC+11 = BOOST_MSVC 1700 Hopefully! -// I have no idea when Dinkumware added it, probably a lot -// earlier than this check. -#if BOOST_LIB_STD_DINKUMWARE >= BOOST_VERSION_NUMBER(6, 50, 0) || \ - BOOST_COMP_MSVC >= BOOST_VERSION_NUMBER(17, 0, 0) -#define BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT 1 -#endif -#endif - -// Assume that an unknown library does not support piecewise construction. -#if !defined(BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT) -#define BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT 0 -#endif - -#if BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT -#include <utility> -#endif - -namespace boost { - namespace unordered { -#if BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT - using std::piecewise_construct_t; - using std::piecewise_construct; -#else - struct piecewise_construct_t - { - }; - const piecewise_construct_t piecewise_construct = piecewise_construct_t(); -#endif - } -} - -#endif diff --git a/ThirdParty/boost/unordered/detail/implementation.hpp b/ThirdParty/boost/unordered/detail/implementation.hpp deleted file mode 100644 index 9dffde159df377ddef2e266b12e726e705646f3e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/unordered/detail/implementation.hpp +++ /dev/null @@ -1,4952 +0,0 @@ -// Copyright (C) 2003-2004 Jeremy B. Maitin-Shepard. -// Copyright (C) 2005-2016 Daniel James -// -// 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_UNORDERED_DETAIL_IMPLEMENTATION_HPP -#define BOOST_UNORDERED_DETAIL_IMPLEMENTATION_HPP - -#include <boost/config.hpp> -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -#include <boost/assert.hpp> -#include <boost/core/no_exceptions_support.hpp> -#include <boost/core/pointer_traits.hpp> -#include <boost/detail/select_type.hpp> -#include <boost/limits.hpp> -#include <boost/move/move.hpp> -#include <boost/preprocessor/arithmetic/inc.hpp> -#include <boost/preprocessor/cat.hpp> -#include <boost/preprocessor/repetition/enum.hpp> -#include <boost/preprocessor/repetition/enum_binary_params.hpp> -#include <boost/preprocessor/repetition/enum_params.hpp> -#include <boost/preprocessor/repetition/repeat_from_to.hpp> -#include <boost/preprocessor/seq/enum.hpp> -#include <boost/preprocessor/seq/size.hpp> -#include <boost/swap.hpp> -#include <boost/throw_exception.hpp> -#include <boost/tuple/tuple.hpp> -#include <boost/type_traits/add_lvalue_reference.hpp> -#include <boost/type_traits/aligned_storage.hpp> -#include <boost/type_traits/alignment_of.hpp> -#include <boost/type_traits/integral_constant.hpp> -#include <boost/type_traits/is_base_of.hpp> -#include <boost/type_traits/is_class.hpp> -#include <boost/type_traits/is_empty.hpp> -#include <boost/type_traits/is_nothrow_move_assignable.hpp> -#include <boost/type_traits/is_nothrow_move_constructible.hpp> -#include <boost/type_traits/is_nothrow_swappable.hpp> -#include <boost/type_traits/is_same.hpp> -#include <boost/type_traits/remove_const.hpp> -#include <boost/unordered/detail/fwd.hpp> -#include <boost/utility/addressof.hpp> -#include <boost/utility/enable_if.hpp> -#include <cmath> -#include <iterator> -#include <stdexcept> -#include <utility> - -#if !defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS) -#include <type_traits> -#endif - -//////////////////////////////////////////////////////////////////////////////// -// Configuration -// -// Unless documented elsewhere these configuration macros should be considered -// an implementation detail, I'll try not to break them, but you never know. - -// Use Sun C++ workarounds -// I'm not sure which versions of the compiler require these workarounds, so -// I'm just using them of everything older than the current test compilers -// (as of May 2017). - -#if !defined(BOOST_UNORDERED_SUN_WORKAROUNDS1) -#if BOOST_COMP_SUNPRO && BOOST_COMP_SUNPRO < BOOST_VERSION_NUMBER(5, 20, 0) -#define BOOST_UNORDERED_SUN_WORKAROUNDS1 1 -#else -#define BOOST_UNORDERED_SUN_WORKAROUNDS1 0 -#endif -#endif - -// BOOST_UNORDERED_EMPLACE_LIMIT = The maximum number of parameters in -// emplace (not including things like hints). Don't set it to a lower value, as -// that might break something. - -#if !defined BOOST_UNORDERED_EMPLACE_LIMIT -#define BOOST_UNORDERED_EMPLACE_LIMIT 10 -#endif - -// BOOST_UNORDERED_USE_ALLOCATOR_TRAITS - Pick which version of -// allocator_traits to use. -// -// 0 = Own partial implementation -// 1 = std::allocator_traits -// 2 = boost::container::allocator_traits - -#if !defined(BOOST_UNORDERED_USE_ALLOCATOR_TRAITS) -#if !defined(BOOST_NO_CXX11_ALLOCATOR) -#define BOOST_UNORDERED_USE_ALLOCATOR_TRAITS 1 -#elif defined(BOOST_MSVC) -#if BOOST_MSVC < 1400 -// Use container's allocator_traits for older versions of Visual -// C++ as I don't test with them. -#define BOOST_UNORDERED_USE_ALLOCATOR_TRAITS 2 -#endif -#endif -#endif - -#if !defined(BOOST_UNORDERED_USE_ALLOCATOR_TRAITS) -#define BOOST_UNORDERED_USE_ALLOCATOR_TRAITS 0 -#endif - -// BOOST_UNORDERED_TUPLE_ARGS -// -// Maximum number of std::tuple members to support, or 0 if std::tuple -// isn't avaiable. More are supported when full C++11 is used. - -// Already defined, so do nothing -#if defined(BOOST_UNORDERED_TUPLE_ARGS) - -// Assume if we have C++11 tuple it's properly variadic, -// and just use a max number of 10 arguments. -#elif !defined(BOOST_NO_CXX11_HDR_TUPLE) -#define BOOST_UNORDERED_TUPLE_ARGS 10 - -// Visual C++ has a decent enough tuple for piecewise construction, -// so use that if available, using _VARIADIC_MAX for the maximum -// number of parameters. Note that this comes after the check -// for a full C++11 tuple. -#elif defined(BOOST_MSVC) -#if !BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT -#define BOOST_UNORDERED_TUPLE_ARGS 0 -#elif defined(_VARIADIC_MAX) -#define BOOST_UNORDERED_TUPLE_ARGS _VARIADIC_MAX -#else -#define BOOST_UNORDERED_TUPLE_ARGS 5 -#endif - -// Assume that we don't have std::tuple -#else -#define BOOST_UNORDERED_TUPLE_ARGS 0 -#endif - -#if BOOST_UNORDERED_TUPLE_ARGS -#include <tuple> -#endif - -// BOOST_UNORDERED_CXX11_CONSTRUCTION -// -// Use C++11 construction, requires variadic arguments, good construct support -// in allocator_traits and piecewise construction of std::pair -// Otherwise allocators aren't used for construction/destruction - -#if BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT && \ - !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && BOOST_UNORDERED_TUPLE_ARGS -#if BOOST_COMP_SUNPRO && BOOST_LIB_STD_GNU -// Sun C++ std::pair piecewise construction doesn't seem to be exception safe. -// (At least for Sun C++ 12.5 using libstdc++). -#define BOOST_UNORDERED_CXX11_CONSTRUCTION 0 -#elif BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 7, 0) -// Piecewise construction in GCC 4.6 doesn't work for uncopyable types. -#define BOOST_UNORDERED_CXX11_CONSTRUCTION 0 -#elif BOOST_UNORDERED_USE_ALLOCATOR_TRAITS == 0 && \ - !defined(BOOST_NO_SFINAE_EXPR) -#define BOOST_UNORDERED_CXX11_CONSTRUCTION 1 -#elif BOOST_UNORDERED_USE_ALLOCATOR_TRAITS == 1 -#define BOOST_UNORDERED_CXX11_CONSTRUCTION 1 -#endif -#endif - -#if !defined(BOOST_UNORDERED_CXX11_CONSTRUCTION) -#define BOOST_UNORDERED_CXX11_CONSTRUCTION 0 -#endif - -// BOOST_UNORDERED_SUPPRESS_DEPRECATED -// -// Define to stop deprecation attributes - -#if defined(BOOST_UNORDERED_SUPPRESS_DEPRECATED) -#define BOOST_UNORDERED_DEPRECATED(msg) -#endif - -// BOOST_UNORDERED_DEPRECATED -// -// Wrapper around various depreaction attributes. - -#if defined(__has_cpp_attribute) && \ - (!defined(__cplusplus) || __cplusplus >= 201402) -#if __has_cpp_attribute(deprecated) && !defined(BOOST_UNORDERED_DEPRECATED) -#define BOOST_UNORDERED_DEPRECATED(msg) [[deprecated(msg)]] -#endif -#endif - -#if !defined(BOOST_UNORDERED_DEPRECATED) -#if defined(__GNUC__) && __GNUC__ >= 4 -#define BOOST_UNORDERED_DEPRECATED(msg) __attribute__((deprecated)) -#elif defined(_MSC_VER) && _MSC_VER >= 1400 -#define BOOST_UNORDERED_DEPRECATED(msg) __declspec(deprecated(msg)) -#elif defined(_MSC_VER) && _MSC_VER >= 1310 -#define BOOST_UNORDERED_DEPRECATED(msg) __declspec(deprecated) -#else -#define BOOST_UNORDERED_DEPRECATED(msg) -#endif -#endif - -// BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES - -#if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES) -#if BOOST_COMP_CLANG && __cplusplus >= 201703 -#define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 1 -#endif -#endif - -#if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES) -#define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 0 -#endif - -namespace boost { - namespace unordered { - namespace iterator_detail { - template <typename Node> struct iterator; - template <typename Node> struct c_iterator; - template <typename Node> struct l_iterator; - template <typename Node> struct cl_iterator; - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - - template <typename Types> struct table; - template <typename NodePointer> struct bucket; - struct ptr_bucket; - - template <typename A, typename T> struct node; - template <typename T> struct ptr_node; - - static const float minimum_max_load_factor = 1e-3f; - static const std::size_t default_bucket_count = 11; - - struct move_tag - { - }; - - struct empty_emplace - { - }; - - struct no_key - { - no_key() {} - template <class T> no_key(T const&) {} - }; - - namespace func { - template <class T> inline void ignore_unused_variable_warning(T const&) - { - } - } - - ////////////////////////////////////////////////////////////////////////// - // iterator SFINAE - - template <typename I> - struct is_forward : boost::is_base_of<std::forward_iterator_tag, - typename std::iterator_traits<I>::iterator_category> - { - }; - - template <typename I, typename ReturnType> - struct enable_if_forward - : boost::enable_if_c<boost::unordered::detail::is_forward<I>::value, - ReturnType> - { - }; - - template <typename I, typename ReturnType> - struct disable_if_forward - : boost::disable_if_c<boost::unordered::detail::is_forward<I>::value, - ReturnType> - { - }; - } - } -} - -//////////////////////////////////////////////////////////////////////////////// -// primes - -// clang-format off -#define BOOST_UNORDERED_PRIMES \ - (17ul)(29ul)(37ul)(53ul)(67ul)(79ul) \ - (97ul)(131ul)(193ul)(257ul)(389ul)(521ul)(769ul) \ - (1031ul)(1543ul)(2053ul)(3079ul)(6151ul)(12289ul)(24593ul) \ - (49157ul)(98317ul)(196613ul)(393241ul)(786433ul) \ - (1572869ul)(3145739ul)(6291469ul)(12582917ul)(25165843ul) \ - (50331653ul)(100663319ul)(201326611ul)(402653189ul)(805306457ul) \ - (1610612741ul)(3221225473ul)(4294967291ul) -// clang-format on - -namespace boost { - namespace unordered { - namespace detail { - template <class T> struct prime_list_template - { - static std::size_t const value[]; - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - static std::ptrdiff_t const length; -#else - static std::ptrdiff_t const length = - BOOST_PP_SEQ_SIZE(BOOST_UNORDERED_PRIMES); -#endif - }; - - template <class T> - std::size_t const prime_list_template<T>::value[] = { - BOOST_PP_SEQ_ENUM(BOOST_UNORDERED_PRIMES)}; - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - template <class T> - std::ptrdiff_t const prime_list_template<T>::length = BOOST_PP_SEQ_SIZE( - BOOST_UNORDERED_PRIMES); -#endif - -#undef BOOST_UNORDERED_PRIMES - - typedef prime_list_template<std::size_t> prime_list; - - // no throw - inline std::size_t next_prime(std::size_t num) - { - std::size_t const* const prime_list_begin = prime_list::value; - std::size_t const* const prime_list_end = - prime_list_begin + prime_list::length; - std::size_t const* bound = - std::lower_bound(prime_list_begin, prime_list_end, num); - if (bound == prime_list_end) - bound--; - return *bound; - } - - // no throw - inline std::size_t prev_prime(std::size_t num) - { - std::size_t const* const prime_list_begin = prime_list::value; - std::size_t const* const prime_list_end = - prime_list_begin + prime_list::length; - std::size_t const* bound = - std::upper_bound(prime_list_begin, prime_list_end, num); - if (bound != prime_list_begin) - bound--; - return *bound; - } - - ////////////////////////////////////////////////////////////////////////// - // insert_size/initial_size - - template <class I> - inline std::size_t insert_size(I i, I j, - typename boost::unordered::detail::enable_if_forward<I, void*>::type = - 0) - { - return static_cast<std::size_t>(std::distance(i, j)); - } - - template <class I> - inline std::size_t insert_size(I, I, - typename boost::unordered::detail::disable_if_forward<I, void*>::type = - 0) - { - return 1; - } - - template <class I> - inline std::size_t initial_size(I i, I j, - std::size_t num_buckets = - boost::unordered::detail::default_bucket_count) - { - return (std::max)( - boost::unordered::detail::insert_size(i, j), num_buckets); - } - - ////////////////////////////////////////////////////////////////////////// - // compressed - - template <typename T, int Index> struct compressed_base : private T - { - compressed_base(T const& x) : T(x) {} - compressed_base(T& x, move_tag) : T(boost::move(x)) {} - - T& get() { return *this; } - T const& get() const { return *this; } - }; - - template <typename T, int Index> struct uncompressed_base - { - uncompressed_base(T const& x) : value_(x) {} - uncompressed_base(T& x, move_tag) : value_(boost::move(x)) {} - - T& get() { return value_; } - T const& get() const { return value_; } - - private: - T value_; - }; - - template <typename T, int Index> - struct generate_base - : boost::detail::if_true< - boost::is_empty<T>::value>::BOOST_NESTED_TEMPLATE - then<boost::unordered::detail::compressed_base<T, Index>, - boost::unordered::detail::uncompressed_base<T, Index> > - { - }; - - template <typename T1, typename T2> - struct compressed - : private boost::unordered::detail::generate_base<T1, 1>::type, - private boost::unordered::detail::generate_base<T2, 2>::type - { - typedef typename generate_base<T1, 1>::type base1; - typedef typename generate_base<T2, 2>::type base2; - - typedef T1 first_type; - typedef T2 second_type; - - first_type& first() { return static_cast<base1*>(this)->get(); } - - first_type const& first() const - { - return static_cast<base1 const*>(this)->get(); - } - - second_type& second() { return static_cast<base2*>(this)->get(); } - - second_type const& second() const - { - return static_cast<base2 const*>(this)->get(); - } - - template <typename First, typename Second> - compressed(First const& x1, Second const& x2) : base1(x1), base2(x2) - { - } - - compressed(compressed const& x) : base1(x.first()), base2(x.second()) {} - - compressed(compressed& x, move_tag m) - : base1(x.first(), m), base2(x.second(), m) - { - } - - void assign(compressed const& x) - { - first() = x.first(); - second() = x.second(); - } - - void move_assign(compressed& x) - { - first() = boost::move(x.first()); - second() = boost::move(x.second()); - } - - void swap(compressed& x) - { - boost::swap(first(), x.first()); - boost::swap(second(), x.second()); - } - - private: - // Prevent assignment just to make use of assign or - // move_assign explicit. - compressed& operator=(compressed const&); - }; - - ////////////////////////////////////////////////////////////////////////// - // pair_traits - // - // Used to get the types from a pair without instantiating it. - - template <typename Pair> struct pair_traits - { - typedef typename Pair::first_type first_type; - typedef typename Pair::second_type second_type; - }; - - template <typename T1, typename T2> struct pair_traits<std::pair<T1, T2> > - { - typedef T1 first_type; - typedef T2 second_type; - }; - -#if defined(BOOST_MSVC) -#pragma warning(push) -#pragma warning(disable : 4512) // assignment operator could not be generated. -#pragma warning(disable : 4345) // behavior change: an object of POD type -// constructed with an initializer of the form () -// will be default-initialized. -#endif - - ////////////////////////////////////////////////////////////////////////// - // Bits and pieces for implementing traits - - template <typename T> - typename boost::add_lvalue_reference<T>::type make(); - struct choice9 - { - typedef char (&type)[9]; - }; - struct choice8 : choice9 - { - typedef char (&type)[8]; - }; - struct choice7 : choice8 - { - typedef char (&type)[7]; - }; - struct choice6 : choice7 - { - typedef char (&type)[6]; - }; - struct choice5 : choice6 - { - typedef char (&type)[5]; - }; - struct choice4 : choice5 - { - typedef char (&type)[4]; - }; - struct choice3 : choice4 - { - typedef char (&type)[3]; - }; - struct choice2 : choice3 - { - typedef char (&type)[2]; - }; - struct choice1 : choice2 - { - typedef char (&type)[1]; - }; - choice1 choose(); - - typedef choice1::type yes_type; - typedef choice2::type no_type; - - struct private_type - { - private_type const& operator,(int) const; - }; - - template <typename T> no_type is_private_type(T const&); - yes_type is_private_type(private_type const&); - - struct convert_from_anything - { - template <typename T> convert_from_anything(T const&); - }; - } - } -} - -//////////////////////////////////////////////////////////////////////////// -// emplace_args -// -// Either forwarding variadic arguments, or storing the arguments in -// emplace_args##n - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#define BOOST_UNORDERED_EMPLACE_TEMPLATE typename... Args -#define BOOST_UNORDERED_EMPLACE_ARGS BOOST_FWD_REF(Args)... args -#define BOOST_UNORDERED_EMPLACE_FORWARD boost::forward<Args>(args)... - -#else - -#define BOOST_UNORDERED_EMPLACE_TEMPLATE typename Args -#define BOOST_UNORDERED_EMPLACE_ARGS Args const& args -#define BOOST_UNORDERED_EMPLACE_FORWARD args - -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - -#define BOOST_UNORDERED_EARGS_MEMBER(z, n, _) \ - typedef BOOST_FWD_REF(BOOST_PP_CAT(A, n)) BOOST_PP_CAT(Arg, n); \ - BOOST_PP_CAT(Arg, n) BOOST_PP_CAT(a, n); - -#else - -#define BOOST_UNORDERED_EARGS_MEMBER(z, n, _) \ - typedef typename boost::add_lvalue_reference<BOOST_PP_CAT(A, n)>::type \ - BOOST_PP_CAT(Arg, n); \ - BOOST_PP_CAT(Arg, n) BOOST_PP_CAT(a, n); - -#endif - -#define BOOST_UNORDERED_FWD_PARAM(z, n, a) \ - BOOST_FWD_REF(BOOST_PP_CAT(A, n)) BOOST_PP_CAT(a, n) - -#define BOOST_UNORDERED_CALL_FORWARD(z, i, a) \ - boost::forward<BOOST_PP_CAT(A, i)>(BOOST_PP_CAT(a, i)) - -#define BOOST_UNORDERED_EARGS_INIT(z, n, _) \ - BOOST_PP_CAT(a, n)(BOOST_PP_CAT(b, n)) - -#define BOOST_UNORDERED_EARGS(z, n, _) \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - struct BOOST_PP_CAT(emplace_args, n) \ - { \ - BOOST_PP_REPEAT_##z(n, BOOST_UNORDERED_EARGS_MEMBER, _) BOOST_PP_CAT( \ - emplace_args, n)(BOOST_PP_ENUM_BINARY_PARAMS_Z(z, n, Arg, b)) \ - : BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_EARGS_INIT, _) \ - { \ - } \ - }; \ - \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - inline BOOST_PP_CAT(emplace_args, n)<BOOST_PP_ENUM_PARAMS_Z(z, n, A)> \ - create_emplace_args(BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_FWD_PARAM, b)) \ - { \ - BOOST_PP_CAT(emplace_args, n)<BOOST_PP_ENUM_PARAMS_Z(z, n, A)> e( \ - BOOST_PP_ENUM_PARAMS_Z(z, n, b)); \ - return e; \ - } - -namespace boost { - namespace unordered { - namespace detail { - template <typename A0> struct emplace_args1 - { - BOOST_UNORDERED_EARGS_MEMBER(1, 0, _) - - explicit emplace_args1(Arg0 b0) : a0(b0) {} - }; - - template <typename A0> - inline emplace_args1<A0> create_emplace_args(BOOST_FWD_REF(A0) b0) - { - emplace_args1<A0> e(b0); - return e; - } - - template <typename A0, typename A1> struct emplace_args2 - { - BOOST_UNORDERED_EARGS_MEMBER(1, 0, _) - BOOST_UNORDERED_EARGS_MEMBER(1, 1, _) - - emplace_args2(Arg0 b0, Arg1 b1) : a0(b0), a1(b1) {} - }; - - template <typename A0, typename A1> - inline emplace_args2<A0, A1> create_emplace_args( - BOOST_FWD_REF(A0) b0, BOOST_FWD_REF(A1) b1) - { - emplace_args2<A0, A1> e(b0, b1); - return e; - } - - template <typename A0, typename A1, typename A2> struct emplace_args3 - { - BOOST_UNORDERED_EARGS_MEMBER(1, 0, _) - BOOST_UNORDERED_EARGS_MEMBER(1, 1, _) - BOOST_UNORDERED_EARGS_MEMBER(1, 2, _) - - emplace_args3(Arg0 b0, Arg1 b1, Arg2 b2) : a0(b0), a1(b1), a2(b2) {} - }; - - template <typename A0, typename A1, typename A2> - inline emplace_args3<A0, A1, A2> create_emplace_args( - BOOST_FWD_REF(A0) b0, BOOST_FWD_REF(A1) b1, BOOST_FWD_REF(A2) b2) - { - emplace_args3<A0, A1, A2> e(b0, b1, b2); - return e; - } - - BOOST_UNORDERED_EARGS(1, 4, _) - BOOST_UNORDERED_EARGS(1, 5, _) - BOOST_UNORDERED_EARGS(1, 6, _) - BOOST_UNORDERED_EARGS(1, 7, _) - BOOST_UNORDERED_EARGS(1, 8, _) - BOOST_UNORDERED_EARGS(1, 9, _) - BOOST_PP_REPEAT_FROM_TO(10, BOOST_PP_INC(BOOST_UNORDERED_EMPLACE_LIMIT), - BOOST_UNORDERED_EARGS, _) - } - } -} - -#undef BOOST_UNORDERED_DEFINE_EMPLACE_ARGS -#undef BOOST_UNORDERED_EARGS_MEMBER -#undef BOOST_UNORDERED_EARGS_INIT - -#endif - -//////////////////////////////////////////////////////////////////////////////// -// -// Some utilities for implementing allocator_traits, but useful elsewhere so -// they're always defined. - -namespace boost { - namespace unordered { - namespace detail { - -//////////////////////////////////////////////////////////////////////////// -// Integral_constrant, true_type, false_type -// -// Uses the standard versions if available. - -#if !defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS) - - using std::integral_constant; - using std::true_type; - using std::false_type; - -#else - - template <typename T, T Value> struct integral_constant - { - enum - { - value = Value - }; - }; - - typedef boost::unordered::detail::integral_constant<bool, true> true_type; - typedef boost::unordered::detail::integral_constant<bool, false> - false_type; - -#endif - -//////////////////////////////////////////////////////////////////////////// -// Explicitly call a destructor - -#if defined(BOOST_MSVC) -#pragma warning(push) -#pragma warning(disable : 4100) // unreferenced formal parameter -#endif - - namespace func { - template <class T> inline void destroy(T* x) { x->~T(); } - } - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - - ////////////////////////////////////////////////////////////////////////// - // value_base - // - // Space used to store values. - - template <typename ValueType> struct value_base - { - typedef ValueType value_type; - - typename boost::aligned_storage<sizeof(value_type), - boost::alignment_of<value_type>::value>::type data_; - - value_base() : data_() {} - - void* address() { return this; } - - value_type& value() { return *(ValueType*)this; } - - value_type const& value() const { return *(ValueType const*)this; } - - value_type* value_ptr() { return (ValueType*)this; } - - value_type const* value_ptr() const { return (ValueType const*)this; } - - private: - value_base& operator=(value_base const&); - }; - - ////////////////////////////////////////////////////////////////////////// - // optional - // TODO: Use std::optional when available. - - template <typename T> class optional - { - BOOST_MOVABLE_BUT_NOT_COPYABLE(optional) - - boost::unordered::detail::value_base<T> value_; - bool has_value_; - - void destroy() - { - if (has_value_) { - boost::unordered::detail::func::destroy(value_.value_ptr()); - has_value_ = false; - } - } - - void move(optional<T>& x) - { - BOOST_ASSERT(!has_value_ && x.has_value_); - new (value_.value_ptr()) T(boost::move(x.value_.value())); - boost::unordered::detail::func::destroy(x.value_.value_ptr()); - has_value_ = true; - x.has_value_ = false; - } - - public: - optional() BOOST_NOEXCEPT : has_value_(false) {} - - optional(BOOST_RV_REF(optional<T>) x) : has_value_(false) - { - if (x.has_value_) { - move(x); - } - } - - explicit optional(T const& x) : has_value_(true) - { - new (value_.value_ptr()) T(x); - } - - optional& operator=(BOOST_RV_REF(optional<T>) x) - { - destroy(); - if (x.has_value_) { - move(x); - } - return *this; - } - - ~optional() { destroy(); } - - bool has_value() const { return has_value_; } - T& operator*() { return value_.value(); } - T const& operator*() const { return value_.value(); } - T* operator->() { return value_.value_ptr(); } - T const* operator->() const { return value_.value_ptr(); } - - bool operator==(optional<T> const& x) - { - return has_value_ ? x.has_value_ && value_.value() == x.value_.value() - : !x.has_value_; - } - - bool operator!=(optional<T> const& x) { return !((*this) == x); } - - void swap(optional<T>& x) - { - if (has_value_ != x.has_value_) { - if (has_value_) { - x.move(*this); - } else { - move(x); - } - } else if (has_value_) { - boost::swap(value_.value(), x.value_.value()); - } - } - - friend void swap(optional<T>& x, optional<T>& y) { x.swap(y); } - }; - } - } -} - -//////////////////////////////////////////////////////////////////////////// -// Expression test mechanism -// -// When SFINAE expressions are available, define -// BOOST_UNORDERED_HAS_FUNCTION which can check if a function call is -// supported by a class, otherwise define BOOST_UNORDERED_HAS_MEMBER which -// can detect if a class has the specified member, but not that it has the -// correct type, this is good enough for a passable impression of -// allocator_traits. - -#if !defined(BOOST_NO_SFINAE_EXPR) - -namespace boost { - namespace unordered { - namespace detail { - template <typename T, long unsigned int> struct expr_test; - template <typename T> struct expr_test<T, sizeof(char)> : T - { - }; - } - } -} - -#define BOOST_UNORDERED_CHECK_EXPRESSION(count, result, expression) \ - template <typename U> \ - static \ - typename boost::unordered::detail::expr_test<BOOST_PP_CAT(choice, result), \ - sizeof(for_expr_test(((expression), 0)))>::type \ - test(BOOST_PP_CAT(choice, count)) - -#define BOOST_UNORDERED_DEFAULT_EXPRESSION(count, result) \ - template <typename U> \ - static BOOST_PP_CAT(choice, result)::type test(BOOST_PP_CAT(choice, count)) - -#define BOOST_UNORDERED_HAS_FUNCTION(name, thing, args, _) \ - struct BOOST_PP_CAT(has_, name) \ - { \ - template <typename U> static char for_expr_test(U const&); \ - BOOST_UNORDERED_CHECK_EXPRESSION( \ - 1, 1, boost::unordered::detail::make<thing>().name args); \ - BOOST_UNORDERED_DEFAULT_EXPRESSION(2, 2); \ - \ - enum \ - { \ - value = sizeof(test<T>(choose())) == sizeof(choice1::type) \ - }; \ - } - -#else - -namespace boost { - namespace unordered { - namespace detail { - template <typename T> struct identity - { - typedef T type; - }; - } - } -} - -#define BOOST_UNORDERED_CHECK_MEMBER(count, result, name, member) \ - \ - typedef \ - typename boost::unordered::detail::identity<member>::type BOOST_PP_CAT( \ - check, count); \ - \ - template <BOOST_PP_CAT(check, count) e> struct BOOST_PP_CAT(test, count) \ - { \ - typedef BOOST_PP_CAT(choice, result) type; \ - }; \ - \ - template <class U> \ - static typename BOOST_PP_CAT(test, count)<&U::name>::type test( \ - BOOST_PP_CAT(choice, count)) - -#define BOOST_UNORDERED_DEFAULT_MEMBER(count, result) \ - template <class U> \ - static BOOST_PP_CAT(choice, result)::type test(BOOST_PP_CAT(choice, count)) - -#define BOOST_UNORDERED_HAS_MEMBER(name) \ - struct BOOST_PP_CAT(has_, name) \ - { \ - struct impl \ - { \ - struct base_mixin \ - { \ - int name; \ - }; \ - struct base : public T, public base_mixin \ - { \ - }; \ - \ - BOOST_UNORDERED_CHECK_MEMBER(1, 1, name, int base_mixin::*); \ - BOOST_UNORDERED_DEFAULT_MEMBER(2, 2); \ - \ - enum \ - { \ - value = sizeof(choice2::type) == sizeof(test<base>(choose())) \ - }; \ - }; \ - \ - enum \ - { \ - value = impl::value \ - }; \ - } - -#endif - -//////////////////////////////////////////////////////////////////////////// -// TRAITS TYPE DETECTION MECHANISM -// -// Used to implement traits that use a type if present, or a -// default otherwise. - -#if defined(BOOST_MSVC) && BOOST_MSVC <= 1400 - -#define BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(tname) \ - template <typename Tp, typename Default> struct default_type_##tname \ - { \ - \ - template <typename X> \ - static choice1::type test(choice1, typename X::tname* = 0); \ - \ - template <typename X> static choice2::type test(choice2, void* = 0); \ - \ - struct DefaultWrap \ - { \ - typedef Default tname; \ - }; \ - \ - enum \ - { \ - value = (1 == sizeof(test<Tp>(choose()))) \ - }; \ - \ - typedef typename boost::detail::if_true<value>::BOOST_NESTED_TEMPLATE \ - then<Tp, DefaultWrap>::type::tname type; \ - } - -#else - -namespace boost { - namespace unordered { - namespace detail { - template <typename T, typename T2> struct sfinae : T2 - { - }; - } - } -} - -#define BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(tname) \ - template <typename Tp, typename Default> struct default_type_##tname \ - { \ - \ - template <typename X> \ - static typename boost::unordered::detail::sfinae<typename X::tname, \ - choice1>::type test(choice1); \ - \ - template <typename X> static choice2::type test(choice2); \ - \ - struct DefaultWrap \ - { \ - typedef Default tname; \ - }; \ - \ - enum \ - { \ - value = (1 == sizeof(test<Tp>(choose()))) \ - }; \ - \ - typedef typename boost::detail::if_true<value>::BOOST_NESTED_TEMPLATE \ - then<Tp, DefaultWrap>::type::tname type; \ - } - -#endif - -#define BOOST_UNORDERED_DEFAULT_TYPE(T, tname, arg) \ - typename default_type_##tname<T, arg>::type - -//////////////////////////////////////////////////////////////////////////////// -// -// Allocator traits -// -// First our implementation, then later light wrappers around the alternatives - -#if BOOST_UNORDERED_USE_ALLOCATOR_TRAITS == 0 - -#include <boost/limits.hpp> -#include <boost/pointer_to_other.hpp> -#include <boost/utility/enable_if.hpp> - -namespace boost { - namespace unordered { - namespace detail { - - template <typename Alloc, typename T> struct rebind_alloc; - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <template <typename, typename...> class Alloc, typename U, - typename T, typename... Args> - struct rebind_alloc<Alloc<U, Args...>, T> - { - typedef Alloc<T, Args...> type; - }; - -#else - - template <template <typename> class Alloc, typename U, typename T> - struct rebind_alloc<Alloc<U>, T> - { - typedef Alloc<T> type; - }; - - template <template <typename, typename> class Alloc, typename U, - typename T, typename A0> - struct rebind_alloc<Alloc<U, A0>, T> - { - typedef Alloc<T, A0> type; - }; - - template <template <typename, typename, typename> class Alloc, typename U, - typename T, typename A0, typename A1> - struct rebind_alloc<Alloc<U, A0, A1>, T> - { - typedef Alloc<T, A0, A1> type; - }; - -#endif - - template <typename Alloc, typename T> struct rebind_wrap - { - template <typename X> - static choice1::type test( - choice1, typename X::BOOST_NESTED_TEMPLATE rebind<T>::other* = 0); - template <typename X> static choice2::type test(choice2, void* = 0); - - enum - { - value = (1 == sizeof(test<Alloc>(choose()))) - }; - - struct fallback - { - template <typename U> struct rebind - { - typedef typename rebind_alloc<Alloc, T>::type other; - }; - }; - - typedef - typename boost::detail::if_true<value>::BOOST_NESTED_TEMPLATE then< - Alloc, fallback>::type::BOOST_NESTED_TEMPLATE rebind<T>::other type; - }; - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(pointer); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(const_pointer); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(void_pointer); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(const_void_pointer); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(difference_type); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(size_type); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT( - propagate_on_container_copy_assignment); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT( - propagate_on_container_move_assignment); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(propagate_on_container_swap); - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(is_always_equal); - -#if !defined(BOOST_NO_SFINAE_EXPR) - - template <typename T> - BOOST_UNORDERED_HAS_FUNCTION( - select_on_container_copy_construction, U const, (), 0); - - template <typename T> - BOOST_UNORDERED_HAS_FUNCTION(max_size, U const, (), 0); - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <typename T, typename ValueType, typename... Args> - BOOST_UNORDERED_HAS_FUNCTION(construct, U, - (boost::unordered::detail::make<ValueType*>(), - boost::unordered::detail::make<Args const>()...), - 2); - -#else - - template <typename T, typename ValueType> - BOOST_UNORDERED_HAS_FUNCTION(construct, U, - (boost::unordered::detail::make<ValueType*>(), - boost::unordered::detail::make<ValueType const>()), - 2); - -#endif - - template <typename T, typename ValueType> - BOOST_UNORDERED_HAS_FUNCTION( - destroy, U, (boost::unordered::detail::make<ValueType*>()), 1); - -#else - - template <typename T> - BOOST_UNORDERED_HAS_MEMBER(select_on_container_copy_construction); - - template <typename T> BOOST_UNORDERED_HAS_MEMBER(max_size); - - template <typename T, typename ValueType> - BOOST_UNORDERED_HAS_MEMBER(construct); - - template <typename T, typename ValueType> - BOOST_UNORDERED_HAS_MEMBER(destroy); - -#endif - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - - template <typename Alloc> - inline Alloc call_select_on_container_copy_construction( - const Alloc& rhs, - typename boost::enable_if_c< - boost::unordered::detail::has_select_on_container_copy_construction< - Alloc>::value, - void*>::type = 0) - { - return rhs.select_on_container_copy_construction(); - } - - template <typename Alloc> - inline Alloc call_select_on_container_copy_construction( - const Alloc& rhs, - typename boost::disable_if_c< - boost::unordered::detail::has_select_on_container_copy_construction< - Alloc>::value, - void*>::type = 0) - { - return rhs; - } - - template <typename SizeType, typename Alloc> - inline SizeType call_max_size(const Alloc& a, - typename boost::enable_if_c< - boost::unordered::detail::has_max_size<Alloc>::value, void*>::type = - 0) - { - return a.max_size(); - } - - template <typename SizeType, typename Alloc> - inline SizeType call_max_size(const Alloc&, - typename boost::disable_if_c< - boost::unordered::detail::has_max_size<Alloc>::value, void*>::type = - 0) - { - return (std::numeric_limits<SizeType>::max)(); - } - } // namespace func. - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - template <typename Alloc> struct allocator_traits - { - typedef Alloc allocator_type; - typedef typename Alloc::value_type value_type; - - typedef BOOST_UNORDERED_DEFAULT_TYPE( - Alloc, pointer, value_type*) pointer; - - template <typename T> - struct pointer_to_other : boost::pointer_to_other<pointer, T> - { - }; - - typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, const_pointer, - typename pointer_to_other<const value_type>::type) const_pointer; - - // typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, void_pointer, - // typename pointer_to_other<void>::type) - // void_pointer; - // - // typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, const_void_pointer, - // typename pointer_to_other<const void>::type) - // const_void_pointer; - - typedef BOOST_UNORDERED_DEFAULT_TYPE( - Alloc, difference_type, std::ptrdiff_t) difference_type; - - typedef BOOST_UNORDERED_DEFAULT_TYPE( - Alloc, size_type, std::size_t) size_type; - -#if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - template <typename T> - using rebind_alloc = typename rebind_wrap<Alloc, T>::type; - - template <typename T> - using rebind_traits = - boost::unordered::detail::allocator_traits<rebind_alloc<T> >; -#endif - - static pointer allocate(Alloc& a, size_type n) { return a.allocate(n); } - - // I never use this, so I'll just comment it out for now. - // - // static pointer allocate(Alloc& a, size_type n, - // const_void_pointer hint) - // { return DEFAULT_FUNC(allocate, pointer)(a, n, hint); } - - static void deallocate(Alloc& a, pointer p, size_type n) - { - a.deallocate(p, n); - } - - public: -#if BOOST_UNORDERED_CXX11_CONSTRUCTION - - template <typename T, typename... Args> - static - typename boost::enable_if_c<boost::unordered::detail::has_construct< - Alloc, T, Args...>::value>::type - construct(Alloc& a, T* p, BOOST_FWD_REF(Args)... x) - { - a.construct(p, boost::forward<Args>(x)...); - } - - template <typename T, typename... Args> - static - typename boost::disable_if_c<boost::unordered::detail::has_construct< - Alloc, T, Args...>::value>::type - construct(Alloc&, T* p, BOOST_FWD_REF(Args)... x) - { - new (static_cast<void*>(p)) T(boost::forward<Args>(x)...); - } - - template <typename T> - static typename boost::enable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value>::type - destroy(Alloc& a, T* p) - { - a.destroy(p); - } - - template <typename T> - static typename boost::disable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value>::type - destroy(Alloc&, T* p) - { - boost::unordered::detail::func::destroy(p); - } - -#elif !defined(BOOST_NO_SFINAE_EXPR) - - template <typename T> - static typename boost::enable_if_c< - boost::unordered::detail::has_construct<Alloc, T>::value>::type - construct(Alloc& a, T* p, T const& x) - { - a.construct(p, x); - } - - template <typename T> - static typename boost::disable_if_c< - boost::unordered::detail::has_construct<Alloc, T>::value>::type - construct(Alloc&, T* p, T const& x) - { - new (static_cast<void*>(p)) T(x); - } - - template <typename T> - static typename boost::enable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value>::type - destroy(Alloc& a, T* p) - { - a.destroy(p); - } - - template <typename T> - static typename boost::disable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value>::type - destroy(Alloc&, T* p) - { - boost::unordered::detail::func::destroy(p); - } - -#else - - // If we don't have SFINAE expressions, only call construct for the - // copy constructor for the allocator's value_type - as that's - // the only construct method that old fashioned allocators support. - - template <typename T> - static void construct(Alloc& a, T* p, T const& x, - typename boost::enable_if_c< - boost::unordered::detail::has_construct<Alloc, T>::value && - boost::is_same<T, value_type>::value, - void*>::type = 0) - { - a.construct(p, x); - } - - template <typename T> - static void construct(Alloc&, T* p, T const& x, - typename boost::disable_if_c< - boost::unordered::detail::has_construct<Alloc, T>::value && - boost::is_same<T, value_type>::value, - void*>::type = 0) - { - new (static_cast<void*>(p)) T(x); - } - - template <typename T> - static void destroy(Alloc& a, T* p, - typename boost::enable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value && - boost::is_same<T, value_type>::value, - void*>::type = 0) - { - a.destroy(p); - } - - template <typename T> - static void destroy(Alloc&, T* p, - typename boost::disable_if_c< - boost::unordered::detail::has_destroy<Alloc, T>::value && - boost::is_same<T, value_type>::value, - void*>::type = 0) - { - boost::unordered::detail::func::destroy(p); - } - -#endif - - static size_type max_size(const Alloc& a) - { - return boost::unordered::detail::func::call_max_size<size_type>(a); - } - - // Allocator propagation on construction - - static Alloc select_on_container_copy_construction(Alloc const& rhs) - { - return boost::unordered::detail::func:: - call_select_on_container_copy_construction(rhs); - } - - // Allocator propagation on assignment and swap. - // Return true if lhs is modified. - typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, - propagate_on_container_copy_assignment, - false_type) propagate_on_container_copy_assignment; - typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, - propagate_on_container_move_assignment, - false_type) propagate_on_container_move_assignment; - typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, propagate_on_container_swap, - false_type) propagate_on_container_swap; - - typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, is_always_equal, - typename boost::is_empty<Alloc>::type) is_always_equal; - }; - } - } -} - -#undef BOOST_UNORDERED_DEFAULT_TYPE_TMPLT -#undef BOOST_UNORDERED_DEFAULT_TYPE - -//////////////////////////////////////////////////////////////////////////////// -// -// std::allocator_traits - -#elif BOOST_UNORDERED_USE_ALLOCATOR_TRAITS == 1 - -#include <memory> - -namespace boost { - namespace unordered { - namespace detail { - - BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(is_always_equal); - - template <typename Alloc> - struct allocator_traits : std::allocator_traits<Alloc> - { - // As is_always_equal was introduced in C++17, std::allocator_traits - // doesn't always have it. So use it when available, implement it - // ourselves when not. Would be simpler not to bother with - // std::allocator_traits, but I feel like I should try to use - // it where possible. - typedef BOOST_UNORDERED_DEFAULT_TYPE(std::allocator_traits<Alloc>, - is_always_equal, - BOOST_UNORDERED_DEFAULT_TYPE(Alloc, is_always_equal, - typename boost::is_empty<Alloc>::type)) is_always_equal; - }; - - template <typename Alloc, typename T> struct rebind_wrap - { - typedef typename std::allocator_traits<Alloc>::template rebind_alloc<T> - type; - }; - } - } -} - -//////////////////////////////////////////////////////////////////////////////// -// -// boost::container::allocator_traits - -#elif BOOST_UNORDERED_USE_ALLOCATOR_TRAITS == 2 - -#include <boost/container/allocator_traits.hpp> - -namespace boost { - namespace unordered { - namespace detail { - - template <typename Alloc> - struct allocator_traits : boost::container::allocator_traits<Alloc> - { - }; - - template <typename Alloc, typename T> - struct rebind_wrap : boost::container::allocator_traits< - Alloc>::template portable_rebind_alloc<T> - { - }; - } - } -} - -#else - -#error "Invalid BOOST_UNORDERED_USE_ALLOCATOR_TRAITS value." - -#endif - -//////////////////////////////////////////////////////////////////////////// -// Functions used to construct nodes. Emulates variadic construction, -// piecewise construction etc. - -//////////////////////////////////////////////////////////////////////////// -// construct_value -// -// Only use allocator_traits::construct, allocator_traits::destroy when full -// C++11 support is available. - -#if BOOST_UNORDERED_CXX11_CONSTRUCTION - -#define BOOST_UNORDERED_CALL_CONSTRUCT1(Traits, alloc, address, a0) \ - Traits::construct(alloc, address, a0) -#define BOOST_UNORDERED_CALL_DESTROY(Traits, alloc, x) Traits::destroy(alloc, x) - -#elif !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - template <typename T, typename... Args> - inline void construct_value(T* address, BOOST_FWD_REF(Args)... args) - { - new ((void*)address) T(boost::forward<Args>(args)...); - } - } - } - } -} - -#define BOOST_UNORDERED_CALL_CONSTRUCT1(Traits, alloc, address, a0) \ - boost::unordered::detail::func::construct_value(address, a0) -#define BOOST_UNORDERED_CALL_DESTROY(Traits, alloc, x) \ - boost::unordered::detail::func::destroy(x) - -#else - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - template <typename T> inline void construct_value(T* address) - { - new ((void*)address) T(); - } - - template <typename T, typename A0> - inline void construct_value(T* address, BOOST_FWD_REF(A0) a0) - { - new ((void*)address) T(boost::forward<A0>(a0)); - } - } - } - } -} - -#define BOOST_UNORDERED_CALL_CONSTRUCT1(Traits, alloc, address, a0) \ - boost::unordered::detail::func::construct_value(address, a0) -#define BOOST_UNORDERED_CALL_DESTROY(Traits, alloc, x) \ - boost::unordered::detail::func::destroy(x) - -#endif - -//////////////////////////////////////////////////////////////////////////// -// Construct from tuple -// -// Used to emulate piecewise construction. - -#define BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(z, n, namespace_) \ - template <typename Alloc, typename T, \ - BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - void construct_from_tuple(Alloc&, T* ptr, \ - namespace_::tuple<BOOST_PP_ENUM_PARAMS_Z(z, n, A)> const& x) \ - { \ - new ((void*)ptr) \ - T(BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_GET_TUPLE_ARG, namespace_)); \ - } - -#define BOOST_UNORDERED_GET_TUPLE_ARG(z, n, namespace_) namespace_::get<n>(x) - -// construct_from_tuple for boost::tuple -// The workaround for old Sun compilers comes later in the file. - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - template <typename Alloc, typename T> - void construct_from_tuple(Alloc&, T* ptr, boost::tuple<>) - { - new ((void*)ptr) T(); - } - - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 1, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 2, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 3, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 4, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 5, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 6, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 7, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 8, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 9, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 10, boost) - } - } - } -} - -#endif - -// construct_from_tuple for std::tuple - -#if !BOOST_UNORDERED_CXX11_CONSTRUCTION && BOOST_UNORDERED_TUPLE_ARGS - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - template <typename Alloc, typename T> - void construct_from_tuple(Alloc&, T* ptr, std::tuple<>) - { - new ((void*)ptr) T(); - } - - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 1, std) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 2, std) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 3, std) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 4, std) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 5, std) - -#if BOOST_UNORDERED_TUPLE_ARGS >= 6 - BOOST_PP_REPEAT_FROM_TO(6, BOOST_PP_INC(BOOST_UNORDERED_TUPLE_ARGS), - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE, std) -#endif - } - } - } -} - -#endif - -#undef BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE -#undef BOOST_UNORDERED_GET_TUPLE_ARG - -// construct_from_tuple for boost::tuple on old versions of sunpro. -// -// Old versions of Sun C++ had problems with template overloads of -// boost::tuple, so to fix it I added a distinct type for each length to -// the overloads. That means there's no possible ambiguity between the -// different overloads, so that the compiler doesn't get confused - -#if BOOST_UNORDERED_SUN_WORKAROUNDS1 - -#define BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(z, n, namespace_) \ - template <typename Alloc, typename T, \ - BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - void construct_from_tuple_impl(boost::unordered::detail::func::length<n>, \ - Alloc&, T* ptr, \ - namespace_::tuple<BOOST_PP_ENUM_PARAMS_Z(z, n, A)> const& x) \ - { \ - new ((void*)ptr) \ - T(BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_GET_TUPLE_ARG, namespace_)); \ - } - -#define BOOST_UNORDERED_GET_TUPLE_ARG(z, n, namespace_) namespace_::get<n>(x) - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - template <int N> struct length - { - }; - - template <typename Alloc, typename T> - void construct_from_tuple_impl( - boost::unordered::detail::func::length<0>, Alloc&, T* ptr, - boost::tuple<>) - { - new ((void*)ptr) T(); - } - - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 1, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 2, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 3, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 4, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 5, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 6, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 7, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 8, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 9, boost) - BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(1, 10, boost) - - template <typename Alloc, typename T, typename Tuple> - void construct_from_tuple(Alloc& alloc, T* ptr, Tuple const& x) - { - construct_from_tuple_impl(boost::unordered::detail::func::length< - boost::tuples::length<Tuple>::value>(), - alloc, ptr, x); - } - } - } - } -} - -#undef BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE -#undef BOOST_UNORDERED_GET_TUPLE_ARG - -#endif - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - //////////////////////////////////////////////////////////////////////// - // Trait to check for piecewise construction. - - template <typename A0> struct use_piecewise - { - static choice1::type test( - choice1, boost::unordered::piecewise_construct_t); - - static choice2::type test(choice2, ...); - - enum - { - value = sizeof(choice1::type) == - sizeof(test(choose(), boost::unordered::detail::make<A0>())) - }; - }; - -#if BOOST_UNORDERED_CXX11_CONSTRUCTION - - //////////////////////////////////////////////////////////////////////// - // Construct from variadic parameters - - template <typename Alloc, typename T, typename... Args> - inline void construct_from_args( - Alloc& alloc, T* address, BOOST_FWD_REF(Args)... args) - { - boost::unordered::detail::allocator_traits<Alloc>::construct( - alloc, address, boost::forward<Args>(args)...); - } - - // For backwards compatibility, implement a special case for - // piecewise_construct with boost::tuple - - template <typename A0> struct detect_boost_tuple - { - template <typename T0, typename T1, typename T2, typename T3, - typename T4, typename T5, typename T6, typename T7, typename T8, - typename T9> - static choice1::type test(choice1, - boost::tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9> const&); - - static choice2::type test(choice2, ...); - - enum - { - value = sizeof(choice1::type) == - sizeof(test(choose(), boost::unordered::detail::make<A0>())) - }; - }; - - // Special case for piecewise_construct - - template <typename Alloc, typename A, typename B, typename A0, - typename A1, typename A2> - inline typename boost::enable_if_c<use_piecewise<A0>::value && - detect_boost_tuple<A1>::value && - detect_boost_tuple<A2>::value, - void>::type - construct_from_args(Alloc& alloc, std::pair<A, B>* address, - BOOST_FWD_REF(A0), BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->first), boost::forward<A1>(a1)); - BOOST_TRY - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->second), boost::forward<A2>(a2)); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(address->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - -#elif !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - //////////////////////////////////////////////////////////////////////// - // Construct from variadic parameters - - template <typename Alloc, typename T, typename... Args> - inline void construct_from_args( - Alloc&, T* address, BOOST_FWD_REF(Args)... args) - { - new ((void*)address) T(boost::forward<Args>(args)...); - } - - // Special case for piecewise_construct - - template <typename Alloc, typename A, typename B, typename A0, - typename A1, typename A2> - inline typename enable_if<use_piecewise<A0>, void>::type - construct_from_args(Alloc& alloc, std::pair<A, B>* address, - BOOST_FWD_REF(A0), BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->first), boost::forward<A1>(a1)); - BOOST_TRY - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->second), boost::forward<A2>(a2)); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(address->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - -#else // BOOST_NO_CXX11_VARIADIC_TEMPLATES - - //////////////////////////////////////////////////////////////////////// - // Construct from emplace_args - - // Explicitly write out first three overloads for the sake of sane - // error messages. - - template <typename Alloc, typename T, typename A0> - inline void construct_from_args( - Alloc&, T* address, emplace_args1<A0> const& args) - { - new ((void*)address) T(boost::forward<A0>(args.a0)); - } - - template <typename Alloc, typename T, typename A0, typename A1> - inline void construct_from_args( - Alloc&, T* address, emplace_args2<A0, A1> const& args) - { - new ((void*)address) - T(boost::forward<A0>(args.a0), boost::forward<A1>(args.a1)); - } - - template <typename Alloc, typename T, typename A0, typename A1, - typename A2> - inline void construct_from_args( - Alloc&, T* address, emplace_args3<A0, A1, A2> const& args) - { - new ((void*)address) T(boost::forward<A0>(args.a0), - boost::forward<A1>(args.a1), boost::forward<A2>(args.a2)); - } - -// Use a macro for the rest. - -#define BOOST_UNORDERED_CONSTRUCT_IMPL(z, num_params, _) \ - template <typename Alloc, typename T, \ - BOOST_PP_ENUM_PARAMS_Z(z, num_params, typename A)> \ - inline void construct_from_args(Alloc&, T* address, \ - boost::unordered::detail::BOOST_PP_CAT(emplace_args, num_params) < \ - BOOST_PP_ENUM_PARAMS_Z(z, num_params, A) > const& args) \ - { \ - new ((void*)address) \ - T(BOOST_PP_ENUM_##z(num_params, BOOST_UNORDERED_CALL_FORWARD, args.a)); \ - } - - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 4, _) - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 5, _) - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 6, _) - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 7, _) - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 8, _) - BOOST_UNORDERED_CONSTRUCT_IMPL(1, 9, _) - BOOST_PP_REPEAT_FROM_TO(10, BOOST_PP_INC(BOOST_UNORDERED_EMPLACE_LIMIT), - BOOST_UNORDERED_CONSTRUCT_IMPL, _) - -#undef BOOST_UNORDERED_CONSTRUCT_IMPL - - // Construct with piecewise_construct - - template <typename Alloc, typename A, typename B, typename A0, - typename A1, typename A2> - inline void construct_from_args(Alloc& alloc, std::pair<A, B>* address, - boost::unordered::detail::emplace_args3<A0, A1, A2> const& args, - typename enable_if<use_piecewise<A0>, void*>::type = 0) - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->first), args.a1); - BOOST_TRY - { - boost::unordered::detail::func::construct_from_tuple( - alloc, boost::addressof(address->second), args.a2); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(address->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - -#endif // BOOST_NO_CXX11_VARIADIC_TEMPLATES - } - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - - /////////////////////////////////////////////////////////////////// - // - // Node construction - - template <typename NodeAlloc> struct node_constructor - { - typedef NodeAlloc node_allocator; - typedef boost::unordered::detail::allocator_traits<NodeAlloc> - node_allocator_traits; - typedef typename node_allocator_traits::value_type node; - typedef typename node_allocator_traits::pointer node_pointer; - typedef typename node::value_type value_type; - - node_allocator& alloc_; - node_pointer node_; - - node_constructor(node_allocator& n) : alloc_(n), node_() {} - - ~node_constructor(); - - void create_node(); - - // no throw - node_pointer release() - { - BOOST_ASSERT(node_); - node_pointer p = node_; - node_ = node_pointer(); - return p; - } - - void reclaim(node_pointer p) - { - BOOST_ASSERT(!node_); - node_ = p; - BOOST_UNORDERED_CALL_DESTROY( - node_allocator_traits, alloc_, node_->value_ptr()); - } - - private: - node_constructor(node_constructor const&); - node_constructor& operator=(node_constructor const&); - }; - - template <typename Alloc> node_constructor<Alloc>::~node_constructor() - { - if (node_) { - boost::unordered::detail::func::destroy(boost::to_address(node_)); - node_allocator_traits::deallocate(alloc_, node_, 1); - } - } - - template <typename Alloc> void node_constructor<Alloc>::create_node() - { - BOOST_ASSERT(!node_); - node_ = node_allocator_traits::allocate(alloc_, 1); - new ((void*)boost::to_address(node_)) node(); - } - - template <typename NodeAlloc> struct node_tmp - { - typedef boost::unordered::detail::allocator_traits<NodeAlloc> - node_allocator_traits; - typedef typename node_allocator_traits::pointer node_pointer; - typedef typename node_allocator_traits::value_type node; - - NodeAlloc& alloc_; - node_pointer node_; - - explicit node_tmp(node_pointer n, NodeAlloc& a) : alloc_(a), node_(n) {} - - ~node_tmp(); - - // no throw - node_pointer release() - { - node_pointer p = node_; - node_ = node_pointer(); - return p; - } - }; - - template <typename Alloc> node_tmp<Alloc>::~node_tmp() - { - if (node_) { - BOOST_UNORDERED_CALL_DESTROY( - node_allocator_traits, alloc_, node_->value_ptr()); - boost::unordered::detail::func::destroy(boost::to_address(node_)); - node_allocator_traits::deallocate(alloc_, node_, 1); - } - } - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - namespace func { - - // Some nicer construct_node functions, might try to - // improve implementation later. - - template <typename Alloc, BOOST_UNORDERED_EMPLACE_TEMPLATE> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_from_args(Alloc& alloc, BOOST_UNORDERED_EMPLACE_ARGS) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - construct_from_args( - alloc, a.node_->value_ptr(), BOOST_UNORDERED_EMPLACE_FORWARD); - return a.release(); - } - - template <typename Alloc, typename U> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node(Alloc& alloc, BOOST_FWD_REF(U) x) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - BOOST_UNORDERED_CALL_CONSTRUCT1( - boost::unordered::detail::allocator_traits<Alloc>, alloc, - a.node_->value_ptr(), boost::forward<U>(x)); - return a.release(); - } - -#if BOOST_UNORDERED_CXX11_CONSTRUCTION - - template <typename Alloc, typename Key> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair(Alloc& alloc, BOOST_FWD_REF(Key) k) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - boost::unordered::detail::allocator_traits<Alloc>::construct(alloc, - a.node_->value_ptr(), std::piecewise_construct, - std::forward_as_tuple(boost::forward<Key>(k)), - std::forward_as_tuple()); - return a.release(); - } - - template <typename Alloc, typename Key, typename Mapped> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair( - Alloc& alloc, BOOST_FWD_REF(Key) k, BOOST_FWD_REF(Mapped) m) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - boost::unordered::detail::allocator_traits<Alloc>::construct(alloc, - a.node_->value_ptr(), std::piecewise_construct, - std::forward_as_tuple(boost::forward<Key>(k)), - std::forward_as_tuple(boost::forward<Mapped>(m))); - return a.release(); - } - - template <typename Alloc, typename Key, typename... Args> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair_from_args( - Alloc& alloc, BOOST_FWD_REF(Key) k, BOOST_FWD_REF(Args)... args) - { - node_constructor<Alloc> a(alloc); - a.create_node(); -#if !(BOOST_COMP_CLANG && BOOST_COMP_CLANG < BOOST_VERSION_NUMBER(3, 8, 0) && \ - defined(BOOST_LIBSTDCXX11)) - boost::unordered::detail::allocator_traits<Alloc>::construct(alloc, - a.node_->value_ptr(), std::piecewise_construct, - std::forward_as_tuple(boost::forward<Key>(k)), - std::forward_as_tuple(boost::forward<Args>(args)...)); -#else - // It doesn't seem to be possible to construct a tuple with 3 variadic - // rvalue reference members when using older versions of clang with - // libstdc++, so just use std::make_tuple instead of - // std::forward_as_tuple. - boost::unordered::detail::allocator_traits<Alloc>::construct(alloc, - a.node_->value_ptr(), std::piecewise_construct, - std::forward_as_tuple(boost::forward<Key>(k)), - std::make_tuple(boost::forward<Args>(args)...)); -#endif - return a.release(); - } - -#else - - template <typename Alloc, typename Key> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair(Alloc& alloc, BOOST_FWD_REF(Key) k) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - boost::unordered::detail::func::construct_value( - boost::addressof(a.node_->value_ptr()->first), - boost::forward<Key>(k)); - BOOST_TRY - { - boost::unordered::detail::func::construct_value( - boost::addressof(a.node_->value_ptr()->second)); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(a.node_->value_ptr()->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - return a.release(); - } - - template <typename Alloc, typename Key, typename Mapped> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair( - Alloc& alloc, BOOST_FWD_REF(Key) k, BOOST_FWD_REF(Mapped) m) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - boost::unordered::detail::func::construct_value( - boost::addressof(a.node_->value_ptr()->first), - boost::forward<Key>(k)); - BOOST_TRY - { - boost::unordered::detail::func::construct_value( - boost::addressof(a.node_->value_ptr()->second), - boost::forward<Mapped>(m)); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(a.node_->value_ptr()->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - return a.release(); - } - - template <typename Alloc, typename Key, - BOOST_UNORDERED_EMPLACE_TEMPLATE> - inline - typename boost::unordered::detail::allocator_traits<Alloc>::pointer - construct_node_pair_from_args( - Alloc& alloc, BOOST_FWD_REF(Key) k, BOOST_UNORDERED_EMPLACE_ARGS) - { - node_constructor<Alloc> a(alloc); - a.create_node(); - boost::unordered::detail::func::construct_value( - boost::addressof(a.node_->value_ptr()->first), - boost::forward<Key>(k)); - BOOST_TRY - { - boost::unordered::detail::func::construct_from_args(alloc, - boost::addressof(a.node_->value_ptr()->second), - BOOST_UNORDERED_EMPLACE_FORWARD); - } - BOOST_CATCH(...) - { - boost::unordered::detail::func::destroy( - boost::addressof(a.node_->value_ptr()->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - return a.release(); - } - -#endif - } - } - } -} - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -// The 'iterator_detail' namespace was a misguided attempt at avoiding ADL -// in the detail namespace. It didn't work because the template parameters -// were in detail. I'm not changing it at the moment to be safe. I might -// do in the future if I change the iterator types. -namespace boost { - namespace unordered { - namespace iterator_detail { - - ////////////////////////////////////////////////////////////////////////// - // Iterators - // - // all no throw - - template <typename Node> struct l_iterator - { -#if !defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS) - template <typename Node2> - friend struct boost::unordered::iterator_detail::cl_iterator; - - private: -#endif - typedef typename Node::node_pointer node_pointer; - node_pointer ptr_; - std::size_t bucket_; - std::size_t bucket_count_; - - public: - typedef typename Node::value_type element_type; - typedef typename Node::value_type value_type; - typedef value_type* pointer; - typedef value_type& reference; - typedef std::ptrdiff_t difference_type; - typedef std::forward_iterator_tag iterator_category; - - l_iterator() BOOST_NOEXCEPT : ptr_() {} - - l_iterator(node_pointer n, std::size_t b, std::size_t c) BOOST_NOEXCEPT - : ptr_(n), - bucket_(b), - bucket_count_(c) - { - } - - value_type& operator*() const { return ptr_->value(); } - - value_type* operator->() const { return ptr_->value_ptr(); } - - l_iterator& operator++() - { - ptr_ = static_cast<node_pointer>(ptr_->next_); - if (ptr_ && ptr_->get_bucket() != bucket_) - ptr_ = node_pointer(); - return *this; - } - - l_iterator operator++(int) - { - l_iterator tmp(*this); - ++(*this); - return tmp; - } - - bool operator==(l_iterator x) const BOOST_NOEXCEPT - { - return ptr_ == x.ptr_; - } - - bool operator!=(l_iterator x) const BOOST_NOEXCEPT - { - return ptr_ != x.ptr_; - } - }; - - template <typename Node> struct cl_iterator - { - friend struct boost::unordered::iterator_detail::l_iterator<Node>; - - private: - typedef typename Node::node_pointer node_pointer; - node_pointer ptr_; - std::size_t bucket_; - std::size_t bucket_count_; - - public: - typedef typename Node::value_type const element_type; - typedef typename Node::value_type value_type; - typedef value_type const* pointer; - typedef value_type const& reference; - typedef std::ptrdiff_t difference_type; - typedef std::forward_iterator_tag iterator_category; - - cl_iterator() BOOST_NOEXCEPT : ptr_() {} - - cl_iterator(node_pointer n, std::size_t b, std::size_t c) BOOST_NOEXCEPT - : ptr_(n), - bucket_(b), - bucket_count_(c) - { - } - - cl_iterator( - boost::unordered::iterator_detail::l_iterator<Node> const& x) - BOOST_NOEXCEPT : ptr_(x.ptr_), - bucket_(x.bucket_), - bucket_count_(x.bucket_count_) - { - } - - value_type const& operator*() const { return ptr_->value(); } - - value_type const* operator->() const { return ptr_->value_ptr(); } - - cl_iterator& operator++() - { - ptr_ = static_cast<node_pointer>(ptr_->next_); - if (ptr_ && ptr_->get_bucket() != bucket_) - ptr_ = node_pointer(); - return *this; - } - - cl_iterator operator++(int) - { - cl_iterator tmp(*this); - ++(*this); - return tmp; - } - - friend bool operator==( - cl_iterator const& x, cl_iterator const& y) BOOST_NOEXCEPT - { - return x.ptr_ == y.ptr_; - } - - friend bool operator!=( - cl_iterator const& x, cl_iterator const& y) BOOST_NOEXCEPT - { - return x.ptr_ != y.ptr_; - } - }; - - template <typename Node> struct iterator - { -#if !defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS) - template <typename> - friend struct boost::unordered::iterator_detail::c_iterator; - template <typename> friend struct boost::unordered::detail::table; - - private: -#endif - typedef typename Node::node_pointer node_pointer; - node_pointer node_; - - public: - typedef typename Node::value_type element_type; - typedef typename Node::value_type value_type; - typedef value_type* pointer; - typedef value_type& reference; - typedef std::ptrdiff_t difference_type; - typedef std::forward_iterator_tag iterator_category; - - iterator() BOOST_NOEXCEPT : node_() {} - - explicit iterator(typename Node::link_pointer x) BOOST_NOEXCEPT - : node_(static_cast<node_pointer>(x)) - { - } - - value_type& operator*() const { return node_->value(); } - - value_type* operator->() const { return node_->value_ptr(); } - - iterator& operator++() - { - node_ = static_cast<node_pointer>(node_->next_); - return *this; - } - - iterator operator++(int) - { - iterator tmp(node_); - node_ = static_cast<node_pointer>(node_->next_); - return tmp; - } - - bool operator==(iterator const& x) const BOOST_NOEXCEPT - { - return node_ == x.node_; - } - - bool operator!=(iterator const& x) const BOOST_NOEXCEPT - { - return node_ != x.node_; - } - }; - - template <typename Node> struct c_iterator - { - friend struct boost::unordered::iterator_detail::iterator<Node>; - -#if !defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS) - template <typename> friend struct boost::unordered::detail::table; - - private: -#endif - typedef typename Node::node_pointer node_pointer; - typedef boost::unordered::iterator_detail::iterator<Node> n_iterator; - node_pointer node_; - - public: - typedef typename Node::value_type const element_type; - typedef typename Node::value_type value_type; - typedef value_type const* pointer; - typedef value_type const& reference; - typedef std::ptrdiff_t difference_type; - typedef std::forward_iterator_tag iterator_category; - - c_iterator() BOOST_NOEXCEPT : node_() {} - - explicit c_iterator(typename Node::link_pointer x) BOOST_NOEXCEPT - : node_(static_cast<node_pointer>(x)) - { - } - - c_iterator(n_iterator const& x) BOOST_NOEXCEPT : node_(x.node_) {} - - value_type const& operator*() const { return node_->value(); } - - value_type const* operator->() const { return node_->value_ptr(); } - - c_iterator& operator++() - { - node_ = static_cast<node_pointer>(node_->next_); - return *this; - } - - c_iterator operator++(int) - { - c_iterator tmp(node_); - node_ = static_cast<node_pointer>(node_->next_); - return tmp; - } - - friend bool operator==( - c_iterator const& x, c_iterator const& y) BOOST_NOEXCEPT - { - return x.node_ == y.node_; - } - - friend bool operator!=( - c_iterator const& x, c_iterator const& y) BOOST_NOEXCEPT - { - return x.node_ != y.node_; - } - }; - } - } -} - -namespace boost { - namespace unordered { - namespace detail { - - /////////////////////////////////////////////////////////////////// - // - // Node Holder - // - // Temporary store for nodes. Deletes any that aren't used. - - template <typename NodeAlloc> struct node_holder - { - private: - typedef NodeAlloc node_allocator; - typedef boost::unordered::detail::allocator_traits<NodeAlloc> - node_allocator_traits; - typedef typename node_allocator_traits::value_type node; - typedef typename node_allocator_traits::pointer node_pointer; - typedef typename node::value_type value_type; - typedef typename node::link_pointer link_pointer; - typedef boost::unordered::iterator_detail::iterator<node> iterator; - - node_constructor<NodeAlloc> constructor_; - node_pointer nodes_; - - public: - template <typename Table> - explicit node_holder(Table& b) : constructor_(b.node_alloc()), nodes_() - { - if (b.size_) { - typename Table::link_pointer prev = b.get_previous_start(); - nodes_ = static_cast<node_pointer>(prev->next_); - prev->next_ = link_pointer(); - b.size_ = 0; - } - } - - ~node_holder(); - - node_pointer pop_node() - { - node_pointer n = nodes_; - nodes_ = static_cast<node_pointer>(nodes_->next_); - n->next_ = link_pointer(); - return n; - } - - template <typename T> inline node_pointer copy_of(T const& v) - { - if (nodes_) { - constructor_.reclaim(pop_node()); - } else { - constructor_.create_node(); - } - BOOST_UNORDERED_CALL_CONSTRUCT1(node_allocator_traits, - constructor_.alloc_, constructor_.node_->value_ptr(), v); - return constructor_.release(); - } - - template <typename T> inline node_pointer move_copy_of(T& v) - { - if (nodes_) { - constructor_.reclaim(pop_node()); - } else { - constructor_.create_node(); - } - BOOST_UNORDERED_CALL_CONSTRUCT1(node_allocator_traits, - constructor_.alloc_, constructor_.node_->value_ptr(), - boost::move(v)); - return constructor_.release(); - } - - iterator begin() const { return iterator(nodes_); } - }; - - template <typename Alloc> node_holder<Alloc>::~node_holder() - { - while (nodes_) { - node_pointer p = nodes_; - nodes_ = static_cast<node_pointer>(p->next_); - - BOOST_UNORDERED_CALL_DESTROY( - node_allocator_traits, constructor_.alloc_, p->value_ptr()); - boost::unordered::detail::func::destroy(boost::to_address(p)); - node_allocator_traits::deallocate(constructor_.alloc_, p, 1); - } - } - - /////////////////////////////////////////////////////////////////// - // - // Bucket - - template <typename NodePointer> struct bucket - { - typedef NodePointer link_pointer; - link_pointer next_; - - bucket() : next_() {} - bucket(link_pointer n) : next_(n) {} - - link_pointer first_from_start() { return next_; } - - enum - { - extra_node = true - }; - }; - - struct ptr_bucket - { - typedef ptr_bucket* link_pointer; - link_pointer next_; - - ptr_bucket() : next_(0) {} - ptr_bucket(link_pointer n) : next_(n) {} - - link_pointer first_from_start() { return this; } - - enum - { - extra_node = false - }; - }; - - /////////////////////////////////////////////////////////////////// - // - // Hash Policy - - template <typename SizeT> struct prime_policy - { - template <typename Hash, typename T> - static inline SizeT apply_hash(Hash const& hf, T const& x) - { - return hf(x); - } - - static inline SizeT to_bucket(SizeT bucket_count, SizeT hash) - { - return hash % bucket_count; - } - - static inline SizeT new_bucket_count(SizeT min) - { - return boost::unordered::detail::next_prime(min); - } - - static inline SizeT prev_bucket_count(SizeT max) - { - return boost::unordered::detail::prev_prime(max); - } - }; - - template <typename SizeT> struct mix64_policy - { - template <typename Hash, typename T> - static inline SizeT apply_hash(Hash const& hf, T const& x) - { - SizeT key = hf(x); - key = (~key) + (key << 21); // key = (key << 21) - key - 1; - key = key ^ (key >> 24); - key = (key + (key << 3)) + (key << 8); // key * 265 - key = key ^ (key >> 14); - key = (key + (key << 2)) + (key << 4); // key * 21 - key = key ^ (key >> 28); - key = key + (key << 31); - return key; - } - - static inline SizeT to_bucket(SizeT bucket_count, SizeT hash) - { - return hash & (bucket_count - 1); - } - - static inline SizeT new_bucket_count(SizeT min) - { - if (min <= 4) - return 4; - --min; - min |= min >> 1; - min |= min >> 2; - min |= min >> 4; - min |= min >> 8; - min |= min >> 16; - min |= min >> 32; - return min + 1; - } - - static inline SizeT prev_bucket_count(SizeT max) - { - max |= max >> 1; - max |= max >> 2; - max |= max >> 4; - max |= max >> 8; - max |= max >> 16; - max |= max >> 32; - return (max >> 1) + 1; - } - }; - - template <int digits, int radix> struct pick_policy_impl - { - typedef prime_policy<std::size_t> type; - }; - - template <> struct pick_policy_impl<64, 2> - { - typedef mix64_policy<std::size_t> type; - }; - - template <typename T> - struct pick_policy2 - : pick_policy_impl<std::numeric_limits<std::size_t>::digits, - std::numeric_limits<std::size_t>::radix> - { - }; - - // While the mix policy is generally faster, the prime policy is a lot - // faster when a large number consecutive integers are used, because - // there are no collisions. Since that is probably quite common, use - // prime policy for integeral types. But not the smaller ones, as they - // don't have enough unique values for this to be an issue. - - template <> struct pick_policy2<int> - { - typedef prime_policy<std::size_t> type; - }; - - template <> struct pick_policy2<unsigned int> - { - typedef prime_policy<std::size_t> type; - }; - - template <> struct pick_policy2<long> - { - typedef prime_policy<std::size_t> type; - }; - - template <> struct pick_policy2<unsigned long> - { - typedef prime_policy<std::size_t> type; - }; - -#if !defined(BOOST_NO_LONG_LONG) - template <> struct pick_policy2<boost::long_long_type> - { - typedef prime_policy<std::size_t> type; - }; - - template <> struct pick_policy2<boost::ulong_long_type> - { - typedef prime_policy<std::size_t> type; - }; -#endif - - template <typename T> - struct pick_policy : pick_policy2<typename boost::remove_cv<T>::type> - { - }; - - ////////////////////////////////////////////////////////////////////////// - // Functions - // - // This double buffers the storage for the hash function and key equality - // predicate in order to have exception safe copy/swap. To do so, - // use 'construct_spare' to construct in the spare space, and then when - // ready to use 'switch_functions' to switch to the new functions. - // If an exception is thrown between these two calls, use - // 'cleanup_spare_functions' to destroy the unused constructed functions. - - template <class H, class P> class functions - { - public: - static const bool nothrow_move_assignable = - boost::is_nothrow_move_assignable<H>::value && - boost::is_nothrow_move_assignable<P>::value; - static const bool nothrow_move_constructible = - boost::is_nothrow_move_constructible<H>::value && - boost::is_nothrow_move_constructible<P>::value; - static const bool nothrow_swappable = - boost::is_nothrow_swappable<H>::value && - boost::is_nothrow_swappable<P>::value; - - private: - functions& operator=(functions const&); - - typedef compressed<H, P> function_pair; - - typedef typename boost::aligned_storage<sizeof(function_pair), - boost::alignment_of<function_pair>::value>::type aligned_function; - - unsigned char current_; // 0/1 - Currently active functions - // +2 - Both constructed - aligned_function funcs_[2]; - - public: - functions(H const& hf, P const& eq) : current_(0) - { - construct_functions(current_, hf, eq); - } - - functions(functions const& bf) : current_(0) - { - construct_functions(current_, bf.current_functions()); - } - - functions(functions& bf, boost::unordered::detail::move_tag) - : current_(0) - { - construct_functions(current_, bf.current_functions(), - boost::unordered::detail::integral_constant<bool, - nothrow_move_constructible>()); - } - - ~functions() - { - BOOST_ASSERT(!(current_ & 2)); - destroy_functions(current_); - } - - H const& hash_function() const { return current_functions().first(); } - - P const& key_eq() const { return current_functions().second(); } - - function_pair const& current_functions() const - { - return *static_cast<function_pair const*>( - static_cast<void const*>(funcs_[current_ & 1].address())); - } - - function_pair& current_functions() - { - return *static_cast<function_pair*>( - static_cast<void*>(funcs_[current_ & 1].address())); - } - - void construct_spare_functions(function_pair const& f) - { - BOOST_ASSERT(!(current_ & 2)); - construct_functions(current_ ^ 1, f); - current_ |= 2; - } - - void cleanup_spare_functions() - { - if (current_ & 2) { - current_ = static_cast<unsigned char>(current_ & 1); - destroy_functions(current_ ^ 1); - } - } - - void switch_functions() - { - BOOST_ASSERT(current_ & 2); - destroy_functions(static_cast<unsigned char>(current_ & 1)); - current_ ^= 3; - } - - private: - void construct_functions(unsigned char which, H const& hf, P const& eq) - { - BOOST_ASSERT(!(which & 2)); - new ((void*)&funcs_[which]) function_pair(hf, eq); - } - - void construct_functions(unsigned char which, function_pair const& f, - boost::unordered::detail::false_type = - boost::unordered::detail::false_type()) - { - BOOST_ASSERT(!(which & 2)); - new ((void*)&funcs_[which]) function_pair(f); - } - - void construct_functions(unsigned char which, function_pair& f, - boost::unordered::detail::true_type) - { - BOOST_ASSERT(!(which & 2)); - new ((void*)&funcs_[which]) - function_pair(f, boost::unordered::detail::move_tag()); - } - - void destroy_functions(unsigned char which) - { - BOOST_ASSERT(!(which & 2)); - boost::unordered::detail::func::destroy( - (function_pair*)(&funcs_[which])); - } - }; - -//////////////////////////////////////////////////////////////////////////// -// rvalue parameters when type can't be a BOOST_RV_REF(T) parameter -// e.g. for int - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -#define BOOST_UNORDERED_RV_REF(T) BOOST_RV_REF(T) -#else - struct please_ignore_this_overload - { - typedef please_ignore_this_overload type; - }; - - template <typename T> struct rv_ref_impl - { - typedef BOOST_RV_REF(T) type; - }; - - template <typename T> - struct rv_ref - : boost::detail::if_true<boost::is_class<T>::value>:: - BOOST_NESTED_TEMPLATE then<boost::unordered::detail::rv_ref_impl<T>, - please_ignore_this_overload>::type - { - }; - -#define BOOST_UNORDERED_RV_REF(T) \ - typename boost::unordered::detail::rv_ref<T>::type -#endif - -#if defined(BOOST_MSVC) -#pragma warning(push) -#pragma warning(disable : 4127) // conditional expression is constant -#endif - - ////////////////////////////////////////////////////////////////////////// - // convert double to std::size_t - - inline std::size_t double_to_size(double f) - { - return f >= static_cast<double>( - (std::numeric_limits<std::size_t>::max)()) - ? (std::numeric_limits<std::size_t>::max)() - : static_cast<std::size_t>(f); - } - - template <typename Types> - struct table : boost::unordered::detail::functions<typename Types::hasher, - typename Types::key_equal> - { - private: - table(table const&); - table& operator=(table const&); - - public: - typedef typename Types::node node; - typedef typename Types::bucket bucket; - typedef typename Types::hasher hasher; - typedef typename Types::key_equal key_equal; - typedef typename Types::const_key_type const_key_type; - typedef typename Types::extractor extractor; - typedef typename Types::value_type value_type; - typedef typename Types::table table_impl; - typedef typename Types::link_pointer link_pointer; - typedef typename Types::policy policy; - typedef typename Types::iterator iterator; - typedef typename Types::c_iterator c_iterator; - typedef typename Types::l_iterator l_iterator; - typedef typename Types::cl_iterator cl_iterator; - - typedef boost::unordered::detail::functions<typename Types::hasher, - typename Types::key_equal> - functions; - - typedef typename Types::value_allocator value_allocator; - typedef typename boost::unordered::detail::rebind_wrap<value_allocator, - node>::type node_allocator; - typedef typename boost::unordered::detail::rebind_wrap<value_allocator, - bucket>::type bucket_allocator; - typedef boost::unordered::detail::allocator_traits<node_allocator> - node_allocator_traits; - typedef boost::unordered::detail::allocator_traits<bucket_allocator> - bucket_allocator_traits; - typedef typename node_allocator_traits::pointer node_pointer; - typedef - typename node_allocator_traits::const_pointer const_node_pointer; - typedef typename bucket_allocator_traits::pointer bucket_pointer; - typedef boost::unordered::detail::node_constructor<node_allocator> - node_constructor; - typedef boost::unordered::detail::node_tmp<node_allocator> node_tmp; - - typedef std::pair<iterator, bool> emplace_return; - - //////////////////////////////////////////////////////////////////////// - // Members - - boost::unordered::detail::compressed<bucket_allocator, node_allocator> - allocators_; - std::size_t bucket_count_; - std::size_t size_; - float mlf_; - std::size_t max_load_; - bucket_pointer buckets_; - - //////////////////////////////////////////////////////////////////////// - // Data access - - static node_pointer get_node(c_iterator it) { return it.node_; } - - static node_pointer next_node(link_pointer n) - { - return static_cast<node_pointer>(n->next_); - } - - static node_pointer next_for_find(link_pointer n) - { - node_pointer n2 = static_cast<node_pointer>(n); - do { - n2 = next_node(n2); - } while (n2 && !n2->is_first_in_group()); - return n2; - } - - node_pointer next_group(node_pointer n) const - { - node_pointer n1 = n; - do { - n1 = next_node(n1); - } while (n1 && !n1->is_first_in_group()); - return n1; - } - - std::size_t group_count(node_pointer n) const - { - std::size_t x = 0; - node_pointer it = n; - do { - ++x; - it = next_node(it); - } while (it && !it->is_first_in_group()); - - return x; - } - - std::size_t node_bucket(node_pointer n) const - { - return n->get_bucket(); - } - - bucket_allocator const& bucket_alloc() const - { - return allocators_.first(); - } - - node_allocator const& node_alloc() const - { - return allocators_.second(); - } - - bucket_allocator& bucket_alloc() { return allocators_.first(); } - - node_allocator& node_alloc() { return allocators_.second(); } - - std::size_t max_bucket_count() const - { - // -1 to account for the start bucket. - return policy::prev_bucket_count( - bucket_allocator_traits::max_size(bucket_alloc()) - 1); - } - - bucket_pointer get_bucket_pointer(std::size_t bucket_index) const - { - BOOST_ASSERT(buckets_); - return buckets_ + static_cast<std::ptrdiff_t>(bucket_index); - } - - link_pointer get_previous_start() const - { - return get_bucket_pointer(bucket_count_)->first_from_start(); - } - - link_pointer get_previous_start(std::size_t bucket_index) const - { - return get_bucket_pointer(bucket_index)->next_; - } - - node_pointer begin() const - { - return size_ ? next_node(get_previous_start()) : node_pointer(); - } - - node_pointer begin(std::size_t bucket_index) const - { - if (!size_) - return node_pointer(); - link_pointer prev = get_previous_start(bucket_index); - return prev ? next_node(prev) : node_pointer(); - } - - std::size_t hash_to_bucket(std::size_t hash_value) const - { - return policy::to_bucket(bucket_count_, hash_value); - } - - std::size_t bucket_size(std::size_t index) const - { - node_pointer n = begin(index); - if (!n) - return 0; - - std::size_t count = 0; - while (n && node_bucket(n) == index) { - ++count; - n = next_node(n); - } - - return count; - } - - //////////////////////////////////////////////////////////////////////// - // Load methods - - void recalculate_max_load() - { - using namespace std; - - // From 6.3.1/13: - // Only resize when size >= mlf_ * count - max_load_ = buckets_ ? boost::unordered::detail::double_to_size( - ceil(static_cast<double>(mlf_) * - static_cast<double>(bucket_count_))) - : 0; - } - - void max_load_factor(float z) - { - BOOST_ASSERT(z > 0); - mlf_ = (std::max)(z, minimum_max_load_factor); - recalculate_max_load(); - } - - std::size_t min_buckets_for_size(std::size_t size) const - { - BOOST_ASSERT(mlf_ >= minimum_max_load_factor); - - using namespace std; - - // From insert/emplace requirements: - // - // size <= mlf_ * count - // => count >= size / mlf_ - // - // Or from rehash post-condition: - // - // count >= size / mlf_ - - return policy::new_bucket_count( - boost::unordered::detail::double_to_size( - floor(static_cast<double>(size) / static_cast<double>(mlf_)) + - 1)); - } - - //////////////////////////////////////////////////////////////////////// - // Constructors - - table(std::size_t num_buckets, hasher const& hf, key_equal const& eq, - node_allocator const& a) - : functions(hf, eq), allocators_(a, a), - bucket_count_(policy::new_bucket_count(num_buckets)), size_(0), - mlf_(1.0f), max_load_(0), buckets_() - { - } - - table(table const& x, node_allocator const& a) - : functions(x), allocators_(a, a), - bucket_count_(x.min_buckets_for_size(x.size_)), size_(0), - mlf_(x.mlf_), max_load_(0), buckets_() - { - } - - table(table& x, boost::unordered::detail::move_tag m) - : functions(x, m), allocators_(x.allocators_, m), - bucket_count_(x.bucket_count_), size_(x.size_), mlf_(x.mlf_), - max_load_(x.max_load_), buckets_(x.buckets_) - { - x.buckets_ = bucket_pointer(); - x.size_ = 0; - x.max_load_ = 0; - } - - table(table& x, node_allocator const& a, - boost::unordered::detail::move_tag m) - : functions(x, m), allocators_(a, a), - bucket_count_(x.bucket_count_), size_(0), mlf_(x.mlf_), - max_load_(0), buckets_() - { - } - - //////////////////////////////////////////////////////////////////////// - // Clear buckets and Create buckets - // - // IMPORTANT: If the container already contains any elements, the - // buckets will not contain any links to them. This will - // need to be dealt with, for example by: - // - deleting them - // - putting them in a 'node_holder' for future use - // (as in assignment) - // - placing them in buckets (see rehash_impl) - - // Clear the bucket pointers. - void clear_buckets() - { - bucket_pointer end = get_bucket_pointer(bucket_count_); - for (bucket_pointer it = buckets_; it != end; ++it) { - it->next_ = node_pointer(); - } - } - - // Create container buckets. If the container already contains any - // buckets - // the linked list will be transferred to the new buckets, but none - // of the bucket pointers will be set. See above note. - // - // Strong exception safety. - void create_buckets(std::size_t new_count) - { - link_pointer dummy_node; - - // Construct the new buckets and dummy node, and destroy the old - // buckets - if (buckets_) { - dummy_node = - (buckets_ + static_cast<std::ptrdiff_t>(bucket_count_))->next_; - bucket_pointer new_buckets = - bucket_allocator_traits::allocate(bucket_alloc(), new_count + 1); - destroy_buckets(); - buckets_ = new_buckets; - } else if (bucket::extra_node) { - node_constructor a(node_alloc()); - a.create_node(); - buckets_ = - bucket_allocator_traits::allocate(bucket_alloc(), new_count + 1); - dummy_node = a.release(); - } else { - dummy_node = link_pointer(); - buckets_ = - bucket_allocator_traits::allocate(bucket_alloc(), new_count + 1); - } - - // nothrow from here... - bucket_count_ = new_count; - recalculate_max_load(); - - bucket_pointer end = - buckets_ + static_cast<std::ptrdiff_t>(new_count); - for (bucket_pointer i = buckets_; i != end; ++i) { - new ((void*)boost::to_address(i)) bucket(); - } - new ((void*)boost::to_address(end)) bucket(dummy_node); - } - - //////////////////////////////////////////////////////////////////////// - // Swap and Move - - void swap_allocators(table& other, false_type) - { - boost::unordered::detail::func::ignore_unused_variable_warning(other); - - // According to 23.2.1.8, if propagate_on_container_swap is - // false the behaviour is undefined unless the allocators - // are equal. - BOOST_ASSERT(node_alloc() == other.node_alloc()); - } - - void swap_allocators(table& other, true_type) - { - allocators_.swap(other.allocators_); - } - - // Not nothrow swappable - void swap(table& x, false_type) - { - if (this == &x) { - return; - } - - this->construct_spare_functions(x.current_functions()); - BOOST_TRY { x.construct_spare_functions(this->current_functions()); } - BOOST_CATCH(...) - { - this->cleanup_spare_functions(); - BOOST_RETHROW - } - BOOST_CATCH_END - this->switch_functions(); - x.switch_functions(); - - swap_allocators( - x, boost::unordered::detail::integral_constant<bool, - allocator_traits< - node_allocator>::propagate_on_container_swap::value>()); - - boost::swap(buckets_, x.buckets_); - boost::swap(bucket_count_, x.bucket_count_); - boost::swap(size_, x.size_); - std::swap(mlf_, x.mlf_); - std::swap(max_load_, x.max_load_); - } - - // Nothrow swappable - void swap(table& x, true_type) - { - swap_allocators( - x, boost::unordered::detail::integral_constant<bool, - allocator_traits< - node_allocator>::propagate_on_container_swap::value>()); - - boost::swap(buckets_, x.buckets_); - boost::swap(bucket_count_, x.bucket_count_); - boost::swap(size_, x.size_); - std::swap(mlf_, x.mlf_); - std::swap(max_load_, x.max_load_); - this->current_functions().swap(x.current_functions()); - } - - // Only swaps the allocators if propagate_on_container_swap. - // If not propagate_on_container_swap and allocators aren't - // equal, behaviour is undefined. - void swap(table& x) - { - BOOST_ASSERT(allocator_traits< - node_allocator>::propagate_on_container_swap::value || - node_alloc() == x.node_alloc()); - swap(x, boost::unordered::detail::integral_constant<bool, - functions::nothrow_swappable>()); - } - - // Only call with nodes allocated with the currect allocator, or - // one that is equal to it. (Can't assert because other's - // allocators might have already been moved). - void move_buckets_from(table& other) - { - BOOST_ASSERT(!buckets_); - buckets_ = other.buckets_; - bucket_count_ = other.bucket_count_; - size_ = other.size_; - max_load_ = other.max_load_; - other.buckets_ = bucket_pointer(); - other.size_ = 0; - other.max_load_ = 0; - } - - // For use in the constructor when allocators might be different. - void move_construct_buckets(table& src) - { - if (this->node_alloc() == src.node_alloc()) { - move_buckets_from(src); - } else { - this->create_buckets(this->bucket_count_); - link_pointer prev = this->get_previous_start(); - std::size_t last_bucket = this->bucket_count_; - for (node_pointer n = src.begin(); n; n = next_node(n)) { - std::size_t n_bucket = n->get_bucket(); - if (n_bucket != last_bucket) { - this->get_bucket_pointer(n_bucket)->next_ = prev; - } - node_pointer n2 = boost::unordered::detail::func::construct_node( - this->node_alloc(), boost::move(n->value())); - n2->bucket_info_ = n->bucket_info_; - prev->next_ = n2; - ++size_; - prev = n2; - last_bucket = n_bucket; - } - } - } - - //////////////////////////////////////////////////////////////////////// - // Delete/destruct - - ~table() { delete_buckets(); } - - void destroy_node(node_pointer n) - { - BOOST_UNORDERED_CALL_DESTROY( - node_allocator_traits, node_alloc(), n->value_ptr()); - boost::unordered::detail::func::destroy(boost::to_address(n)); - node_allocator_traits::deallocate(node_alloc(), n, 1); - } - - void delete_buckets() - { - if (buckets_) { - node_pointer n = static_cast<node_pointer>( - get_bucket_pointer(bucket_count_)->next_); - - if (bucket::extra_node) { - node_pointer next = next_node(n); - boost::unordered::detail::func::destroy(boost::to_address(n)); - node_allocator_traits::deallocate(node_alloc(), n, 1); - n = next; - } - - while (n) { - node_pointer next = next_node(n); - destroy_node(n); - n = next; - } - - destroy_buckets(); - buckets_ = bucket_pointer(); - max_load_ = 0; - size_ = 0; - } - } - - void destroy_buckets() - { - bucket_pointer end = get_bucket_pointer(bucket_count_ + 1); - for (bucket_pointer it = buckets_; it != end; ++it) { - boost::unordered::detail::func::destroy(boost::to_address(it)); - } - - bucket_allocator_traits::deallocate( - bucket_alloc(), buckets_, bucket_count_ + 1); - } - - //////////////////////////////////////////////////////////////////////// - // Fix buckets after delete/extract - // - // (prev,next) should mark an open range of nodes in a single bucket - // which - // have either been unlinked, or are about to be. - - std::size_t fix_bucket( - std::size_t bucket_index, link_pointer prev, node_pointer next) - { - std::size_t bucket_index2 = bucket_index; - - if (next) { - bucket_index2 = node_bucket(next); - - // If next is in the same bucket, then there's nothing to do. - if (bucket_index == bucket_index2) { - return bucket_index2; - } - - // Update the bucket containing next. - get_bucket_pointer(bucket_index2)->next_ = prev; - } - - // Check if this bucket is now empty. - bucket_pointer this_bucket = get_bucket_pointer(bucket_index); - if (this_bucket->next_ == prev) { - this_bucket->next_ = link_pointer(); - } - - return bucket_index2; - } - - //////////////////////////////////////////////////////////////////////// - // Clear - - void clear_impl(); - - //////////////////////////////////////////////////////////////////////// - // Assignment - - template <typename UniqueType> - void assign(table const& x, UniqueType is_unique) - { - if (this != &x) { - assign(x, is_unique, - boost::unordered::detail::integral_constant<bool, - allocator_traits<node_allocator>:: - propagate_on_container_copy_assignment::value>()); - } - } - - template <typename UniqueType> - void assign(table const& x, UniqueType is_unique, false_type) - { - // Strong exception safety. - this->construct_spare_functions(x.current_functions()); - BOOST_TRY - { - mlf_ = x.mlf_; - recalculate_max_load(); - - if (x.size_ > max_load_) { - create_buckets(min_buckets_for_size(x.size_)); - } else if (size_) { - clear_buckets(); - } - } - BOOST_CATCH(...) - { - this->cleanup_spare_functions(); - BOOST_RETHROW - } - BOOST_CATCH_END - this->switch_functions(); - assign_buckets(x, is_unique); - } - - template <typename UniqueType> - void assign(table const& x, UniqueType is_unique, true_type) - { - if (node_alloc() == x.node_alloc()) { - allocators_.assign(x.allocators_); - assign(x, is_unique, false_type()); - } else { - this->construct_spare_functions(x.current_functions()); - this->switch_functions(); - - // Delete everything with current allocators before assigning - // the new ones. - delete_buckets(); - allocators_.assign(x.allocators_); - - // Copy over other data, all no throw. - mlf_ = x.mlf_; - bucket_count_ = min_buckets_for_size(x.size_); - - // Finally copy the elements. - if (x.size_) { - copy_buckets(x, is_unique); - } - } - } - - template <typename UniqueType> - void move_assign(table& x, UniqueType is_unique) - { - if (this != &x) { - move_assign(x, is_unique, - boost::unordered::detail::integral_constant<bool, - allocator_traits<node_allocator>:: - propagate_on_container_move_assignment::value>()); - } - } - - // Propagate allocator - template <typename UniqueType> - void move_assign(table& x, UniqueType, true_type) - { - if (!functions::nothrow_move_assignable) { - this->construct_spare_functions(x.current_functions()); - this->switch_functions(); - } else { - this->current_functions().move_assign(x.current_functions()); - } - delete_buckets(); - allocators_.move_assign(x.allocators_); - mlf_ = x.mlf_; - move_buckets_from(x); - } - - // Don't propagate allocator - template <typename UniqueType> - void move_assign(table& x, UniqueType is_unique, false_type) - { - if (node_alloc() == x.node_alloc()) { - move_assign_equal_alloc(x); - } else { - move_assign_realloc(x, is_unique); - } - } - - void move_assign_equal_alloc(table& x) - { - if (!functions::nothrow_move_assignable) { - this->construct_spare_functions(x.current_functions()); - this->switch_functions(); - } else { - this->current_functions().move_assign(x.current_functions()); - } - delete_buckets(); - mlf_ = x.mlf_; - move_buckets_from(x); - } - - template <typename UniqueType> - void move_assign_realloc(table& x, UniqueType is_unique) - { - this->construct_spare_functions(x.current_functions()); - BOOST_TRY - { - mlf_ = x.mlf_; - recalculate_max_load(); - - if (x.size_ > max_load_) { - create_buckets(min_buckets_for_size(x.size_)); - } else if (size_) { - clear_buckets(); - } - } - BOOST_CATCH(...) - { - this->cleanup_spare_functions(); - BOOST_RETHROW - } - BOOST_CATCH_END - this->switch_functions(); - move_assign_buckets(x, is_unique); - } - - // Accessors - - const_key_type& get_key(node_pointer n) const - { - return extractor::extract(n->value()); - } - - std::size_t hash(const_key_type& k) const - { - return policy::apply_hash(this->hash_function(), k); - } - - // Find Node - - node_pointer find_node(std::size_t key_hash, const_key_type& k) const - { - return this->find_node_impl(key_hash, k, this->key_eq()); - } - - node_pointer find_node(const_key_type& k) const - { - return this->find_node_impl(hash(k), k, this->key_eq()); - } - - template <class Key, class Pred> - node_pointer find_node_impl( - std::size_t key_hash, Key const& k, Pred const& eq) const - { - std::size_t bucket_index = this->hash_to_bucket(key_hash); - node_pointer n = this->begin(bucket_index); - - for (;;) { - if (!n) - return n; - - if (eq(k, this->get_key(n))) { - return n; - } else if (this->node_bucket(n) != bucket_index) { - return node_pointer(); - } - - n = next_for_find(n); - } - } - - // Find the node before the key, so that it can be erased. - link_pointer find_previous_node( - const_key_type& k, std::size_t bucket_index) - { - link_pointer prev = this->get_previous_start(bucket_index); - if (!prev) { - return prev; - } - - for (;;) { - node_pointer n = next_node(prev); - if (!n) { - return link_pointer(); - } else if (n->is_first_in_group()) { - if (node_bucket(n) != bucket_index) { - return link_pointer(); - } else if (this->key_eq()(k, this->get_key(n))) { - return prev; - } - } - prev = n; - } - } - - // Extract and erase - - inline node_pointer extract_by_key(const_key_type& k) - { - if (!this->size_) { - return node_pointer(); - } - std::size_t key_hash = this->hash(k); - std::size_t bucket_index = this->hash_to_bucket(key_hash); - link_pointer prev = this->find_previous_node(k, bucket_index); - if (!prev) { - return node_pointer(); - } - node_pointer n = next_node(prev); - node_pointer n2 = next_node(n); - if (n2) { - n2->set_first_in_group(); - } - prev->next_ = n2; - --this->size_; - this->fix_bucket(bucket_index, prev, n2); - n->next_ = link_pointer(); - - return n; - } - - // Reserve and rehash - - void reserve_for_insert(std::size_t); - void rehash(std::size_t); - void reserve(std::size_t); - void rehash_impl(std::size_t); - - //////////////////////////////////////////////////////////////////////// - // Unique keys - - // equals - - bool equals_unique(table const& other) const - { - if (this->size_ != other.size_) - return false; - - for (node_pointer n1 = this->begin(); n1; n1 = next_node(n1)) { - node_pointer n2 = other.find_node(other.get_key(n1)); - - if (!n2 || n1->value() != n2->value()) - return false; - } - - return true; - } - - // Emplace/Insert - - inline node_pointer add_node_unique( - node_pointer n, std::size_t key_hash) - { - std::size_t bucket_index = this->hash_to_bucket(key_hash); - bucket_pointer b = this->get_bucket_pointer(bucket_index); - - n->bucket_info_ = bucket_index; - n->set_first_in_group(); - - if (!b->next_) { - link_pointer start_node = this->get_previous_start(); - - if (start_node->next_) { - this->get_bucket_pointer(node_bucket(next_node(start_node))) - ->next_ = n; - } - - b->next_ = start_node; - n->next_ = start_node->next_; - start_node->next_ = n; - } else { - n->next_ = b->next_->next_; - b->next_->next_ = n; - } - - ++this->size_; - return n; - } - - inline node_pointer resize_and_add_node_unique( - node_pointer n, std::size_t key_hash) - { - node_tmp b(n, this->node_alloc()); - this->reserve_for_insert(this->size_ + 1); - return this->add_node_unique(b.release(), key_hash); - } - - template <BOOST_UNORDERED_EMPLACE_TEMPLATE> - iterator emplace_hint_unique( - c_iterator hint, const_key_type& k, BOOST_UNORDERED_EMPLACE_ARGS) - { - if (hint.node_ && this->key_eq()(k, this->get_key(hint.node_))) { - return iterator(hint.node_); - } else { - return emplace_unique(k, BOOST_UNORDERED_EMPLACE_FORWARD).first; - } - } - - template <BOOST_UNORDERED_EMPLACE_TEMPLATE> - emplace_return emplace_unique( - const_key_type& k, BOOST_UNORDERED_EMPLACE_ARGS) - { - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (pos) { - return emplace_return(iterator(pos), false); - } else { - return emplace_return( - iterator(this->resize_and_add_node_unique( - boost::unordered::detail::func::construct_node_from_args( - this->node_alloc(), BOOST_UNORDERED_EMPLACE_FORWARD), - key_hash)), - true); - } - } - - template <BOOST_UNORDERED_EMPLACE_TEMPLATE> - iterator emplace_hint_unique( - c_iterator hint, no_key, BOOST_UNORDERED_EMPLACE_ARGS) - { - node_tmp b(boost::unordered::detail::func::construct_node_from_args( - this->node_alloc(), BOOST_UNORDERED_EMPLACE_FORWARD), - this->node_alloc()); - const_key_type& k = this->get_key(b.node_); - if (hint.node_ && this->key_eq()(k, this->get_key(hint.node_))) { - return iterator(hint.node_); - } - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (pos) { - return iterator(pos); - } else { - return iterator( - this->resize_and_add_node_unique(b.release(), key_hash)); - } - } - - template <BOOST_UNORDERED_EMPLACE_TEMPLATE> - emplace_return emplace_unique(no_key, BOOST_UNORDERED_EMPLACE_ARGS) - { - node_tmp b(boost::unordered::detail::func::construct_node_from_args( - this->node_alloc(), BOOST_UNORDERED_EMPLACE_FORWARD), - this->node_alloc()); - const_key_type& k = this->get_key(b.node_); - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (pos) { - return emplace_return(iterator(pos), false); - } else { - return emplace_return( - iterator(this->resize_and_add_node_unique(b.release(), key_hash)), - true); - } - } - - template <typename Key> - emplace_return try_emplace_unique(BOOST_FWD_REF(Key) k) - { - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (pos) { - return emplace_return(iterator(pos), false); - } else { - return emplace_return( - iterator(this->resize_and_add_node_unique( - boost::unordered::detail::func::construct_node_pair( - this->node_alloc(), boost::forward<Key>(k)), - key_hash)), - true); - } - } - - template <typename Key> - iterator try_emplace_hint_unique(c_iterator hint, BOOST_FWD_REF(Key) k) - { - if (hint.node_ && this->key_eq()(hint->first, k)) { - return iterator(hint.node_); - } else { - return try_emplace_unique(k).first; - } - } - - template <typename Key, BOOST_UNORDERED_EMPLACE_TEMPLATE> - emplace_return try_emplace_unique( - BOOST_FWD_REF(Key) k, BOOST_UNORDERED_EMPLACE_ARGS) - { - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (pos) { - return emplace_return(iterator(pos), false); - } else { - return emplace_return( - iterator(this->resize_and_add_node_unique( - boost::unordered::detail::func::construct_node_pair_from_args( - this->node_alloc(), boost::forward<Key>(k), - BOOST_UNORDERED_EMPLACE_FORWARD), - key_hash)), - true); - } - } - - template <typename Key, BOOST_UNORDERED_EMPLACE_TEMPLATE> - iterator try_emplace_hint_unique( - c_iterator hint, BOOST_FWD_REF(Key) k, BOOST_UNORDERED_EMPLACE_ARGS) - { - if (hint.node_ && this->key_eq()(hint->first, k)) { - return iterator(hint.node_); - } else { - return try_emplace_unique(k, BOOST_UNORDERED_EMPLACE_FORWARD).first; - } - } - - template <typename Key, typename M> - emplace_return insert_or_assign_unique( - BOOST_FWD_REF(Key) k, BOOST_FWD_REF(M) obj) - { - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - - if (pos) { - pos->value().second = boost::forward<M>(obj); - return emplace_return(iterator(pos), false); - } else { - return emplace_return( - iterator(this->resize_and_add_node_unique( - boost::unordered::detail::func::construct_node_pair( - this->node_alloc(), boost::forward<Key>(k), - boost::forward<M>(obj)), - key_hash)), - true); - } - } - - template <typename NodeType, typename InsertReturnType> - void move_insert_node_type_unique( - NodeType& np, InsertReturnType& result) - { - if (np) { - const_key_type& k = this->get_key(np.ptr_); - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - - if (pos) { - result.node = boost::move(np); - result.position = iterator(pos); - } else { - this->reserve_for_insert(this->size_ + 1); - result.position = - iterator(this->add_node_unique(np.ptr_, key_hash)); - result.inserted = true; - np.ptr_ = node_pointer(); - } - } - } - - template <typename NodeType> - iterator move_insert_node_type_with_hint_unique( - c_iterator hint, NodeType& np) - { - if (!np) { - return iterator(); - } - const_key_type& k = this->get_key(np.ptr_); - if (hint.node_ && this->key_eq()(k, this->get_key(hint.node_))) { - return iterator(hint.node_); - } - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - if (!pos) { - this->reserve_for_insert(this->size_ + 1); - pos = this->add_node_unique(np.ptr_, key_hash); - np.ptr_ = node_pointer(); - } - return iterator(pos); - } - - template <typename Types2> - void merge_unique(boost::unordered::detail::table<Types2>& other) - { - typedef boost::unordered::detail::table<Types2> other_table; - BOOST_STATIC_ASSERT( - (boost::is_same<node, typename other_table::node>::value)); - BOOST_ASSERT(this->node_alloc() == other.node_alloc()); - - if (other.size_) { - link_pointer prev = other.get_previous_start(); - - while (prev->next_) { - node_pointer n = other_table::next_node(prev); - const_key_type& k = this->get_key(n); - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - - if (pos) { - prev = n; - } else { - this->reserve_for_insert(this->size_ + 1); - node_pointer n2 = next_node(n); - prev->next_ = n2; - if (n2 && n->is_first_in_group()) { - n2->set_first_in_group(); - } - --other.size_; - other.fix_bucket(other.node_bucket(n), prev, n2); - this->add_node_unique(n, key_hash); - } - } - } - } - - //////////////////////////////////////////////////////////////////////// - // Insert range methods - // - // if hash function throws, or inserting > 1 element, basic exception - // safety strong otherwise - - template <class InputIt> - void insert_range_unique(const_key_type& k, InputIt i, InputIt j) - { - insert_range_unique2(k, i, j); - - while (++i != j) { - // Note: can't use get_key as '*i' might not be value_type - it - // could be a pair with first_types as key_type without const or - // a different second_type. - insert_range_unique2(extractor::extract(*i), i, j); - } - } - - template <class InputIt> - void insert_range_unique2(const_key_type& k, InputIt i, InputIt j) - { - // No side effects in this initial code - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - - if (!pos) { - node_tmp b(boost::unordered::detail::func::construct_node( - this->node_alloc(), *i), - this->node_alloc()); - if (this->size_ + 1 > this->max_load_) - this->reserve_for_insert( - this->size_ + boost::unordered::detail::insert_size(i, j)); - this->add_node_unique(b.release(), key_hash); - } - } - - template <class InputIt> - void insert_range_unique(no_key, InputIt i, InputIt j) - { - node_constructor a(this->node_alloc()); - - do { - if (!a.node_) { - a.create_node(); - } - BOOST_UNORDERED_CALL_CONSTRUCT1( - node_allocator_traits, a.alloc_, a.node_->value_ptr(), *i); - node_tmp b(a.release(), a.alloc_); - - const_key_type& k = this->get_key(b.node_); - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - - if (pos) { - a.reclaim(b.release()); - } else { - // reserve has basic exception safety if the hash function - // throws, strong otherwise. - this->reserve_for_insert(this->size_ + 1); - this->add_node_unique(b.release(), key_hash); - } - } while (++i != j); - } - - //////////////////////////////////////////////////////////////////////// - // Extract - - inline node_pointer extract_by_iterator_unique(c_iterator i) - { - node_pointer n = i.node_; - BOOST_ASSERT(n); - std::size_t bucket_index = this->node_bucket(n); - link_pointer prev = this->get_previous_start(bucket_index); - while (prev->next_ != n) { - prev = prev->next_; - } - node_pointer n2 = next_node(n); - prev->next_ = n2; - --this->size_; - this->fix_bucket(bucket_index, prev, n2); - n->next_ = link_pointer(); - return n; - } - - //////////////////////////////////////////////////////////////////////// - // Erase - // - // no throw - - std::size_t erase_key_unique(const_key_type& k) - { - if (!this->size_) - return 0; - std::size_t key_hash = this->hash(k); - std::size_t bucket_index = this->hash_to_bucket(key_hash); - link_pointer prev = this->find_previous_node(k, bucket_index); - if (!prev) - return 0; - node_pointer n = next_node(prev); - node_pointer n2 = next_node(n); - prev->next_ = n2; - --size_; - this->fix_bucket(bucket_index, prev, n2); - this->destroy_node(n); - return 1; - } - - void erase_nodes_unique(node_pointer i, node_pointer j) - { - std::size_t bucket_index = this->node_bucket(i); - - // Find the node before i. - link_pointer prev = this->get_previous_start(bucket_index); - while (prev->next_ != i) - prev = prev->next_; - - // Delete the nodes. - prev->next_ = j; - do { - node_pointer next = next_node(i); - destroy_node(i); - --size_; - bucket_index = this->fix_bucket(bucket_index, prev, next); - i = next; - } while (i != j); - } - - //////////////////////////////////////////////////////////////////////// - // fill_buckets_unique - - void copy_buckets(table const& src, true_type) - { - this->create_buckets(this->bucket_count_); - - for (node_pointer n = src.begin(); n; n = next_node(n)) { - std::size_t key_hash = this->hash(this->get_key(n)); - this->add_node_unique( - boost::unordered::detail::func::construct_node( - this->node_alloc(), n->value()), - key_hash); - } - } - - void assign_buckets(table const& src, true_type) - { - node_holder<node_allocator> holder(*this); - for (node_pointer n = src.begin(); n; n = next_node(n)) { - std::size_t key_hash = this->hash(this->get_key(n)); - this->add_node_unique(holder.copy_of(n->value()), key_hash); - } - } - - void move_assign_buckets(table& src, true_type) - { - node_holder<node_allocator> holder(*this); - for (node_pointer n = src.begin(); n; n = next_node(n)) { - std::size_t key_hash = this->hash(this->get_key(n)); - this->add_node_unique(holder.move_copy_of(n->value()), key_hash); - } - } - - //////////////////////////////////////////////////////////////////////// - // Equivalent keys - - // Equality - - bool equals_equiv(table const& other) const - { - if (this->size_ != other.size_) - return false; - - for (node_pointer n1 = this->begin(); n1;) { - node_pointer n2 = other.find_node(other.get_key(n1)); - if (!n2) - return false; - node_pointer end1 = next_group(n1); - node_pointer end2 = next_group(n2); - if (!group_equals_equiv(n1, end1, n2, end2)) - return false; - n1 = end1; - } - - return true; - } - - static bool group_equals_equiv(node_pointer n1, node_pointer end1, - node_pointer n2, node_pointer end2) - { - for (;;) { - if (n1->value() != n2->value()) - break; - - n1 = next_node(n1); - n2 = next_node(n2); - - if (n1 == end1) - return n2 == end2; - if (n2 == end2) - return false; - } - - for (node_pointer n1a = n1, n2a = n2;;) { - n1a = next_node(n1a); - n2a = next_node(n2a); - - if (n1a == end1) { - if (n2a == end2) - break; - else - return false; - } - - if (n2a == end2) - return false; - } - - node_pointer start = n1; - for (; n1 != end1; n1 = next_node(n1)) { - value_type const& v = n1->value(); - if (!find_equiv(start, n1, v)) { - std::size_t matches = count_equal_equiv(n2, end2, v); - if (!matches) - return false; - if (matches != 1 + count_equal_equiv(next_node(n1), end1, v)) - return false; - } - } - - return true; - } - - static bool find_equiv( - node_pointer n, node_pointer end, value_type const& v) - { - for (; n != end; n = next_node(n)) - if (n->value() == v) - return true; - return false; - } - - static std::size_t count_equal_equiv( - node_pointer n, node_pointer end, value_type const& v) - { - std::size_t count = 0; - for (; n != end; n = next_node(n)) - if (n->value() == v) - ++count; - return count; - } - - // Emplace/Insert - - inline node_pointer add_node_equiv( - node_pointer n, std::size_t key_hash, node_pointer pos) - { - std::size_t bucket_index = this->hash_to_bucket(key_hash); - n->bucket_info_ = bucket_index; - - if (pos) { - n->reset_first_in_group(); - n->next_ = pos->next_; - pos->next_ = n; - if (n->next_) { - std::size_t next_bucket = this->node_bucket(next_node(n)); - if (next_bucket != bucket_index) { - this->get_bucket_pointer(next_bucket)->next_ = n; - } - } - } else { - n->set_first_in_group(); - bucket_pointer b = this->get_bucket_pointer(bucket_index); - - if (!b->next_) { - link_pointer start_node = this->get_previous_start(); - - if (start_node->next_) { - this - ->get_bucket_pointer(this->node_bucket(next_node(start_node))) - ->next_ = n; - } - - b->next_ = start_node; - n->next_ = start_node->next_; - start_node->next_ = n; - } else { - n->next_ = b->next_->next_; - b->next_->next_ = n; - } - } - ++this->size_; - return n; - } - - inline node_pointer add_using_hint_equiv( - node_pointer n, node_pointer hint) - { - n->bucket_info_ = hint->bucket_info_; - n->reset_first_in_group(); - n->next_ = hint->next_; - hint->next_ = n; - if (n->next_) { - std::size_t next_bucket = this->node_bucket(next_node(n)); - if (next_bucket != this->node_bucket(n)) { - this->get_bucket_pointer(next_bucket)->next_ = n; - } - } - ++this->size_; - return n; - } - - iterator emplace_equiv(node_pointer n) - { - node_tmp a(n, this->node_alloc()); - const_key_type& k = this->get_key(a.node_); - std::size_t key_hash = this->hash(k); - node_pointer position = this->find_node(key_hash, k); - this->reserve_for_insert(this->size_ + 1); - return iterator( - this->add_node_equiv(a.release(), key_hash, position)); - } - - iterator emplace_hint_equiv(c_iterator hint, node_pointer n) - { - node_tmp a(n, this->node_alloc()); - const_key_type& k = this->get_key(a.node_); - if (hint.node_ && this->key_eq()(k, this->get_key(hint.node_))) { - this->reserve_for_insert(this->size_ + 1); - return iterator( - this->add_using_hint_equiv(a.release(), hint.node_)); - } else { - std::size_t key_hash = this->hash(k); - node_pointer position = this->find_node(key_hash, k); - this->reserve_for_insert(this->size_ + 1); - return iterator( - this->add_node_equiv(a.release(), key_hash, position)); - } - } - - void emplace_no_rehash_equiv(node_pointer n) - { - node_tmp a(n, this->node_alloc()); - const_key_type& k = this->get_key(a.node_); - std::size_t key_hash = this->hash(k); - node_pointer position = this->find_node(key_hash, k); - this->add_node_equiv(a.release(), key_hash, position); - } - - template <typename NodeType> - iterator move_insert_node_type_equiv(NodeType& np) - { - iterator result; - - if (np) { - const_key_type& k = this->get_key(np.ptr_); - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - this->reserve_for_insert(this->size_ + 1); - result = iterator(this->add_node_equiv(np.ptr_, key_hash, pos)); - np.ptr_ = node_pointer(); - } - - return result; - } - - template <typename NodeType> - iterator move_insert_node_type_with_hint_equiv( - c_iterator hint, NodeType& np) - { - iterator result; - - if (np) { - const_key_type& k = this->get_key(np.ptr_); - - if (hint.node_ && this->key_eq()(k, this->get_key(hint.node_))) { - this->reserve_for_insert(this->size_ + 1); - result = - iterator(this->add_using_hint_equiv(np.ptr_, hint.node_)); - } else { - std::size_t key_hash = this->hash(k); - node_pointer pos = this->find_node(key_hash, k); - this->reserve_for_insert(this->size_ + 1); - result = iterator(this->add_node_equiv(np.ptr_, key_hash, pos)); - } - np.ptr_ = node_pointer(); - } - - return result; - } - - //////////////////////////////////////////////////////////////////////// - // Insert range methods - - // if hash function throws, or inserting > 1 element, basic exception - // safety. Strong otherwise - template <class I> - void insert_range_equiv(I i, I j, - typename boost::unordered::detail::enable_if_forward<I, void*>::type = - 0) - { - if (i == j) - return; - - std::size_t distance = static_cast<std::size_t>(std::distance(i, j)); - if (distance == 1) { - emplace_equiv(boost::unordered::detail::func::construct_node( - this->node_alloc(), *i)); - } else { - // Only require basic exception safety here - this->reserve_for_insert(this->size_ + distance); - - for (; i != j; ++i) { - emplace_no_rehash_equiv( - boost::unordered::detail::func::construct_node( - this->node_alloc(), *i)); - } - } - } - - template <class I> - void insert_range_equiv(I i, I j, - typename boost::unordered::detail::disable_if_forward<I, - void*>::type = 0) - { - for (; i != j; ++i) { - emplace_equiv(boost::unordered::detail::func::construct_node( - this->node_alloc(), *i)); - } - } - - //////////////////////////////////////////////////////////////////////// - // Extract - - inline node_pointer extract_by_iterator_equiv(c_iterator n) - { - node_pointer i = n.node_; - BOOST_ASSERT(i); - node_pointer j(next_node(i)); - std::size_t bucket_index = this->node_bucket(i); - - link_pointer prev = this->get_previous_start(bucket_index); - while (prev->next_ != i) { - prev = next_node(prev); - } - - prev->next_ = j; - if (j && i->is_first_in_group()) { - j->set_first_in_group(); - } - --this->size_; - this->fix_bucket(bucket_index, prev, j); - i->next_ = link_pointer(); - - return i; - } - - //////////////////////////////////////////////////////////////////////// - // Erase - // - // no throw - - std::size_t erase_key_equiv(const_key_type& k) - { - if (!this->size_) - return 0; - - std::size_t key_hash = this->hash(k); - std::size_t bucket_index = this->hash_to_bucket(key_hash); - link_pointer prev = this->find_previous_node(k, bucket_index); - if (!prev) - return 0; - - std::size_t deleted_count = 0; - node_pointer n = next_node(prev); - do { - node_pointer n2 = next_node(n); - destroy_node(n); - ++deleted_count; - n = n2; - } while (n && !n->is_first_in_group()); - size_ -= deleted_count; - prev->next_ = n; - this->fix_bucket(bucket_index, prev, n); - return deleted_count; - } - - link_pointer erase_nodes_equiv(node_pointer i, node_pointer j) - { - std::size_t bucket_index = this->node_bucket(i); - - link_pointer prev = this->get_previous_start(bucket_index); - while (prev->next_ != i) { - prev = next_node(prev); - } - - // Delete the nodes. - // Is it inefficient to call fix_bucket for every node? - bool includes_first = false; - prev->next_ = j; - do { - includes_first = includes_first || i->is_first_in_group(); - node_pointer next = next_node(i); - destroy_node(i); - --size_; - bucket_index = this->fix_bucket(bucket_index, prev, next); - i = next; - } while (i != j); - if (j && includes_first) { - j->set_first_in_group(); - } - - return prev; - } - - //////////////////////////////////////////////////////////////////////// - // fill_buckets - - void copy_buckets(table const& src, false_type) - { - this->create_buckets(this->bucket_count_); - - for (node_pointer n = src.begin(); n;) { - std::size_t key_hash = this->hash(this->get_key(n)); - node_pointer group_end(next_group(n)); - node_pointer pos = this->add_node_equiv( - boost::unordered::detail::func::construct_node( - this->node_alloc(), n->value()), - key_hash, node_pointer()); - for (n = next_node(n); n != group_end; n = next_node(n)) { - this->add_node_equiv( - boost::unordered::detail::func::construct_node( - this->node_alloc(), n->value()), - key_hash, pos); - } - } - } - - void assign_buckets(table const& src, false_type) - { - node_holder<node_allocator> holder(*this); - for (node_pointer n = src.begin(); n;) { - std::size_t key_hash = this->hash(this->get_key(n)); - node_pointer group_end(next_group(n)); - node_pointer pos = this->add_node_equiv( - holder.copy_of(n->value()), key_hash, node_pointer()); - for (n = next_node(n); n != group_end; n = next_node(n)) { - this->add_node_equiv(holder.copy_of(n->value()), key_hash, pos); - } - } - } - - void move_assign_buckets(table& src, false_type) - { - node_holder<node_allocator> holder(*this); - for (node_pointer n = src.begin(); n;) { - std::size_t key_hash = this->hash(this->get_key(n)); - node_pointer group_end(next_group(n)); - node_pointer pos = this->add_node_equiv( - holder.move_copy_of(n->value()), key_hash, node_pointer()); - for (n = next_node(n); n != group_end; n = next_node(n)) { - this->add_node_equiv( - holder.move_copy_of(n->value()), key_hash, pos); - } - } - } - }; - - ////////////////////////////////////////////////////////////////////////// - // Clear - - template <typename Types> inline void table<Types>::clear_impl() - { - if (size_) { - bucket_pointer end = get_bucket_pointer(bucket_count_); - for (bucket_pointer it = buckets_; it != end; ++it) { - it->next_ = node_pointer(); - } - - link_pointer prev = end->first_from_start(); - node_pointer n = next_node(prev); - prev->next_ = node_pointer(); - size_ = 0; - - while (n) { - node_pointer next = next_node(n); - destroy_node(n); - n = next; - } - } - } - - ////////////////////////////////////////////////////////////////////////// - // Reserve & Rehash - - // basic exception safety - template <typename Types> - inline void table<Types>::reserve_for_insert(std::size_t size) - { - if (!buckets_) { - create_buckets((std::max)(bucket_count_, min_buckets_for_size(size))); - } else if (size > max_load_) { - std::size_t num_buckets = - min_buckets_for_size((std::max)(size, size_ + (size_ >> 1))); - - if (num_buckets != bucket_count_) - this->rehash_impl(num_buckets); - } - } - - // if hash function throws, basic exception safety - // strong otherwise. - - template <typename Types> - inline void table<Types>::rehash(std::size_t min_buckets) - { - using namespace std; - - if (!size_) { - delete_buckets(); - bucket_count_ = policy::new_bucket_count(min_buckets); - } else { - min_buckets = policy::new_bucket_count((std::max)(min_buckets, - boost::unordered::detail::double_to_size( - floor(static_cast<double>(size_) / static_cast<double>(mlf_))) + - 1)); - - if (min_buckets != bucket_count_) - this->rehash_impl(min_buckets); - } - } - - template <typename Types> - inline void table<Types>::rehash_impl(std::size_t num_buckets) - { - BOOST_ASSERT(this->buckets_); - - this->create_buckets(num_buckets); - link_pointer prev = this->get_previous_start(); - BOOST_TRY - { - while (prev->next_) { - node_pointer n = next_node(prev); - std::size_t key_hash = this->hash(this->get_key(n)); - std::size_t bucket_index = this->hash_to_bucket(key_hash); - - n->bucket_info_ = bucket_index; - n->set_first_in_group(); - - // Iterator through the rest of the group of equal nodes, - // setting the bucket. - for (;;) { - node_pointer next = next_node(n); - if (!next || next->is_first_in_group()) { - break; - } - n = next; - n->bucket_info_ = bucket_index; - n->reset_first_in_group(); - } - - // n is now the last node in the group - bucket_pointer b = this->get_bucket_pointer(bucket_index); - if (!b->next_) { - b->next_ = prev; - prev = n; - } else { - link_pointer next = n->next_; - n->next_ = b->next_->next_; - b->next_->next_ = prev->next_; - prev->next_ = next; - } - } - } - BOOST_CATCH(...) - { - node_pointer n = next_node(prev); - prev->next_ = node_pointer(); - while (n) { - node_pointer next = next_node(n); - destroy_node(n); - --size_; - n = next; - } - BOOST_RETHROW - } - BOOST_CATCH_END - } - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - - //////////////////////////////////////////////////////////////////////// - // key extractors - // - // no throw - // - // 'extract_key' is called with the emplace parameters to return a - // key if available or 'no_key' is one isn't and will need to be - // constructed. This could be done by overloading the emplace - // implementation - // for the different cases, but that's a bit tricky on compilers without - // variadic templates. - - template <typename Key, typename T> struct is_key - { - template <typename T2> static choice1::type test(T2 const&); - static choice2::type test(Key const&); - - enum - { - value = sizeof(test(boost::unordered::detail::make<T>())) == - sizeof(choice2::type) - }; - - typedef typename boost::detail::if_true<value>::BOOST_NESTED_TEMPLATE - then<Key const&, no_key>::type type; - }; - - template <class ValueType> struct set_extractor - { - typedef ValueType value_type; - typedef ValueType key_type; - - static key_type const& extract(value_type const& v) { return v; } - - static key_type const& extract(BOOST_UNORDERED_RV_REF(value_type) v) - { - return v; - } - - static no_key extract() { return no_key(); } - - template <class Arg> static no_key extract(Arg const&) - { - return no_key(); - } - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template <class Arg1, class Arg2, class... Args> - static no_key extract(Arg1 const&, Arg2 const&, Args const&...) - { - return no_key(); - } -#else - template <class Arg1, class Arg2> - static no_key extract(Arg1 const&, Arg2 const&) - { - return no_key(); - } -#endif - }; - - template <class ValueType> struct map_extractor - { - typedef ValueType value_type; - typedef typename boost::remove_const<typename boost::unordered::detail:: - pair_traits<ValueType>::first_type>::type key_type; - - static key_type const& extract(value_type const& v) { return v.first; } - - template <class Second> - static key_type const& extract(std::pair<key_type, Second> const& v) - { - return v.first; - } - - template <class Second> - static key_type const& extract( - std::pair<key_type const, Second> const& v) - { - return v.first; - } - -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <class Second> - static key_type const& extract( - boost::rv<std::pair<key_type, Second> > const& v) - { - return v.first; - } - - template <class Second> - static key_type const& extract( - boost::rv<std::pair<key_type const, Second> > const& v) - { - return v.first; - } -#endif - - template <class Arg1> - static key_type const& extract(key_type const& k, Arg1 const&) - { - return k; - } - - static no_key extract() { return no_key(); } - - template <class Arg> static no_key extract(Arg const&) - { - return no_key(); - } - - template <class Arg1, class Arg2> - static no_key extract(Arg1 const&, Arg2 const&) - { - return no_key(); - } - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template <class Arg1, class Arg2, class Arg3, class... Args> - static no_key extract( - Arg1 const&, Arg2 const&, Arg3 const&, Args const&...) - { - return no_key(); - } -#endif - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#define BOOST_UNORDERED_KEY_FROM_TUPLE(namespace_) \ - template <typename T2> \ - static no_key extract(boost::unordered::piecewise_construct_t, \ - namespace_ tuple<> const&, T2 const&) \ - { \ - return no_key(); \ - } \ - \ - template <typename T, typename T2> \ - static typename is_key<key_type, T>::type extract( \ - boost::unordered::piecewise_construct_t, namespace_ tuple<T> const& k, \ - T2 const&) \ - { \ - return typename is_key<key_type, T>::type(namespace_ get<0>(k)); \ - } - -#else - -#define BOOST_UNORDERED_KEY_FROM_TUPLE(namespace_) \ - static no_key extract( \ - boost::unordered::piecewise_construct_t, namespace_ tuple<> const&) \ - { \ - return no_key(); \ - } \ - \ - template <typename T> \ - static typename is_key<key_type, T>::type extract( \ - boost::unordered::piecewise_construct_t, namespace_ tuple<T> const& k) \ - { \ - return typename is_key<key_type, T>::type(namespace_ get<0>(k)); \ - } - -#endif - - BOOST_UNORDERED_KEY_FROM_TUPLE(boost::) - -#if BOOST_UNORDERED_TUPLE_ARGS - BOOST_UNORDERED_KEY_FROM_TUPLE(std::) -#endif - -#undef BOOST_UNORDERED_KEY_FROM_TUPLE - }; - - //////////////////////////////////////////////////////////////////////// - // Unique nodes - - template <typename A, typename T> - struct node : boost::unordered::detail::value_base<T> - { - typedef - typename ::boost::unordered::detail::rebind_wrap<A, node<A, T> >::type - allocator; - typedef typename ::boost::unordered::detail::allocator_traits< - allocator>::pointer node_pointer; - typedef node_pointer link_pointer; - typedef typename ::boost::unordered::detail::rebind_wrap<A, - bucket<node_pointer> >::type bucket_allocator; - typedef typename ::boost::unordered::detail::allocator_traits< - bucket_allocator>::pointer bucket_pointer; - - link_pointer next_; - std::size_t bucket_info_; - - node() : next_(), bucket_info_(0) {} - - std::size_t get_bucket() const - { - return bucket_info_ & ((std::size_t)-1 >> 1); - } - - std::size_t is_first_in_group() const - { - return !(bucket_info_ & ~((std::size_t)-1 >> 1)); - } - - void set_first_in_group() - { - bucket_info_ = bucket_info_ & ((std::size_t)-1 >> 1); - } - - void reset_first_in_group() - { - bucket_info_ = bucket_info_ | ~((std::size_t)-1 >> 1); - } - - private: - node& operator=(node const&); - }; - - template <typename T> - struct ptr_node : boost::unordered::detail::ptr_bucket - { - typedef T value_type; - typedef boost::unordered::detail::ptr_bucket bucket_base; - typedef ptr_node<T>* node_pointer; - typedef ptr_bucket* link_pointer; - typedef ptr_bucket* bucket_pointer; - - std::size_t bucket_info_; - boost::unordered::detail::value_base<T> value_base_; - - ptr_node() : bucket_base(), bucket_info_(0) {} - - void* address() { return value_base_.address(); } - value_type& value() { return value_base_.value(); } - value_type* value_ptr() { return value_base_.value_ptr(); } - - std::size_t get_bucket() const - { - return bucket_info_ & ((std::size_t)-1 >> 1); - } - - std::size_t is_first_in_group() const - { - return !(bucket_info_ & ~((std::size_t)-1 >> 1)); - } - - void set_first_in_group() - { - bucket_info_ = bucket_info_ & ((std::size_t)-1 >> 1); - } - - void reset_first_in_group() - { - bucket_info_ = bucket_info_ | ~((std::size_t)-1 >> 1); - } - - private: - ptr_node& operator=(ptr_node const&); - }; - - // If the allocator uses raw pointers use ptr_node - // Otherwise use node. - - template <typename A, typename T, typename NodePtr, typename BucketPtr> - struct pick_node2 - { - typedef boost::unordered::detail::node<A, T> node; - - typedef typename boost::unordered::detail::allocator_traits< - typename boost::unordered::detail::rebind_wrap<A, - node>::type>::pointer node_pointer; - - typedef boost::unordered::detail::bucket<node_pointer> bucket; - typedef node_pointer link_pointer; - }; - - template <typename A, typename T> - struct pick_node2<A, T, boost::unordered::detail::ptr_node<T>*, - boost::unordered::detail::ptr_bucket*> - { - typedef boost::unordered::detail::ptr_node<T> node; - typedef boost::unordered::detail::ptr_bucket bucket; - typedef bucket* link_pointer; - }; - - template <typename A, typename T> struct pick_node - { - typedef typename boost::remove_const<T>::type nonconst; - - typedef boost::unordered::detail::allocator_traits< - typename boost::unordered::detail::rebind_wrap<A, - boost::unordered::detail::ptr_node<nonconst> >::type> - tentative_node_traits; - - typedef boost::unordered::detail::allocator_traits< - typename boost::unordered::detail::rebind_wrap<A, - boost::unordered::detail::ptr_bucket>::type> - tentative_bucket_traits; - - typedef pick_node2<A, nonconst, typename tentative_node_traits::pointer, - typename tentative_bucket_traits::pointer> - pick; - - typedef typename pick::node node; - typedef typename pick::bucket bucket; - typedef typename pick::link_pointer link_pointer; - }; - } - } -} - -#undef BOOST_UNORDERED_EMPLACE_TEMPLATE -#undef BOOST_UNORDERED_EMPLACE_ARGS -#undef BOOST_UNORDERED_EMPLACE_FORWARD -#undef BOOST_UNORDERED_CALL_CONSTRUCT1 -#undef BOOST_UNORDERED_CALL_DESTROY - -#endif diff --git a/ThirdParty/boost/unordered/detail/set.hpp b/ThirdParty/boost/unordered/detail/set.hpp deleted file mode 100644 index b7869e3c511d09711199ec7d865dd48bcd4dbedd..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/unordered/detail/set.hpp +++ /dev/null @@ -1,66 +0,0 @@ - -// Copyright (C) 2005-2016 Daniel James -// 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/unordered/detail/implementation.hpp> -#include <boost/unordered/unordered_set_fwd.hpp> - -namespace boost { - namespace unordered { - namespace detail { - template <typename A, typename T, typename H, typename P> struct set - { - typedef boost::unordered::detail::set<A, T, H, P> types; - - typedef T value_type; - typedef H hasher; - typedef P key_equal; - typedef T const const_key_type; - - typedef - typename ::boost::unordered::detail::rebind_wrap<A, value_type>::type - value_allocator; - typedef boost::unordered::detail::allocator_traits<value_allocator> - value_allocator_traits; - - typedef boost::unordered::detail::pick_node<A, value_type> pick; - typedef typename pick::node node; - typedef typename pick::bucket bucket; - typedef typename pick::link_pointer link_pointer; - - typedef boost::unordered::detail::table<types> table; - typedef boost::unordered::detail::set_extractor<value_type> extractor; - - typedef typename boost::unordered::detail::pick_policy<T>::type policy; - - typedef boost::unordered::iterator_detail::c_iterator<node> iterator; - typedef boost::unordered::iterator_detail::c_iterator<node> c_iterator; - typedef boost::unordered::iterator_detail::cl_iterator<node> l_iterator; - typedef boost::unordered::iterator_detail::cl_iterator<node> - cl_iterator; - - typedef boost::unordered::node_handle_set<node, T, A> node_type; - typedef boost::unordered::insert_return_type_set<node, T, A> - insert_return_type; - }; - - template <typename T, typename H, typename P, typename A> - class instantiate_set - { - typedef boost::unordered_set<T, H, P, A> container; - container x; - typename container::node_type node_type; - typename container::insert_return_type insert_return_type; - }; - - template <typename T, typename H, typename P, typename A> - class instantiate_multiset - { - typedef boost::unordered_multiset<T, H, P, A> container; - container x; - typename container::node_type node_type; - }; - } - } -} diff --git a/ThirdParty/boost/unordered/unordered_set.hpp b/ThirdParty/boost/unordered/unordered_set.hpp deleted file mode 100644 index dfc24e85e5d6edc053383a09fd0c152cd6f6de6b..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/unordered/unordered_set.hpp +++ /dev/null @@ -1,2101 +0,0 @@ - -// Copyright (C) 2003-2004 Jeremy B. Maitin-Shepard. -// Copyright (C) 2005-2011 Daniel James. -// 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) - -// See http://www.boost.org/libs/unordered for documentation - -#ifndef BOOST_UNORDERED_UNORDERED_SET_HPP_INCLUDED -#define BOOST_UNORDERED_UNORDERED_SET_HPP_INCLUDED - -#include <boost/config.hpp> -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -#include <boost/core/explicit_operator_bool.hpp> -#include <boost/functional/hash.hpp> -#include <boost/move/move.hpp> -#include <boost/unordered/detail/set.hpp> - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) -#include <initializer_list> -#endif - -#if defined(BOOST_MSVC) -#pragma warning(push) -// conditional expression is constant -#pragma warning(disable : 4127) -#if BOOST_MSVC >= 1400 -// the inline specifier cannot be used when a friend declaration refers to a -// specialization of a function template -#pragma warning(disable : 4396) -#endif -#endif - -namespace boost { - namespace unordered { - template <class T, class H, class P, class A> class unordered_set - { -#if defined(BOOST_UNORDERED_USE_MOVE) - BOOST_COPYABLE_AND_MOVABLE(unordered_set) -#endif - template <typename, typename, typename, typename> - friend class unordered_multiset; - - public: - typedef T key_type; - typedef T value_type; - typedef H hasher; - typedef P key_equal; - typedef A allocator_type; - - private: - typedef boost::unordered::detail::set<A, T, H, P> types; - typedef typename types::value_allocator_traits value_allocator_traits; - typedef typename types::table table; - typedef typename table::node_pointer node_pointer; - typedef typename table::link_pointer link_pointer; - - public: - typedef typename value_allocator_traits::pointer pointer; - typedef typename value_allocator_traits::const_pointer const_pointer; - - typedef value_type& reference; - typedef value_type const& const_reference; - - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - typedef typename table::iterator iterator; - typedef typename table::c_iterator const_iterator; - typedef typename table::l_iterator local_iterator; - typedef typename table::cl_iterator const_local_iterator; - typedef typename types::node_type node_type; - typedef typename types::insert_return_type insert_return_type; - - private: - table table_; - - public: - // constructors - - unordered_set(); - - explicit unordered_set(size_type, const hasher& = hasher(), - const key_equal& = key_equal(), - const allocator_type& = allocator_type()); - - template <class InputIt> - unordered_set(InputIt, InputIt, - size_type = boost::unordered::detail::default_bucket_count, - const hasher& = hasher(), const key_equal& = key_equal(), - const allocator_type& = allocator_type()); - - unordered_set(unordered_set const&); - -#if defined(BOOST_UNORDERED_USE_MOVE) || \ - !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - unordered_set(BOOST_RV_REF(unordered_set) other) - BOOST_NOEXCEPT_IF(table::nothrow_move_constructible) - : table_(other.table_, boost::unordered::detail::move_tag()) - { - // The move is done in table_ - } -#endif - - explicit unordered_set(allocator_type const&); - - unordered_set(unordered_set const&, allocator_type const&); - - unordered_set(BOOST_RV_REF(unordered_set), allocator_type const&); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_set(std::initializer_list<value_type>, - size_type = boost::unordered::detail::default_bucket_count, - const hasher& = hasher(), const key_equal& l = key_equal(), - const allocator_type& = allocator_type()); -#endif - - explicit unordered_set(size_type, const allocator_type&); - - explicit unordered_set(size_type, const hasher&, const allocator_type&); - - template <class InputIt> - unordered_set(InputIt, InputIt, size_type, const allocator_type&); - - template <class InputIt> - unordered_set( - InputIt, InputIt, size_type, const hasher&, const allocator_type&); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_set( - std::initializer_list<value_type>, size_type, const allocator_type&); - - unordered_set(std::initializer_list<value_type>, size_type, const hasher&, - const allocator_type&); -#endif - - // Destructor - - ~unordered_set() BOOST_NOEXCEPT; - -// Assign - -#if defined(BOOST_UNORDERED_USE_MOVE) - unordered_set& operator=(BOOST_COPY_ASSIGN_REF(unordered_set) x) - { - table_.assign(x.table_, boost::unordered::detail::true_type()); - return *this; - } - - unordered_set& operator=(BOOST_RV_REF(unordered_set) x) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_move_assignable<H>::value&& - boost::is_nothrow_move_assignable<P>::value) - { - table_.move_assign(x.table_, boost::unordered::detail::true_type()); - return *this; - } -#else - unordered_set& operator=(unordered_set const& x) - { - table_.assign(x.table_, boost::unordered::detail::true_type()); - return *this; - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - unordered_set& operator=(unordered_set&& x) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_move_assignable<H>::value&& - boost::is_nothrow_move_assignable<P>::value) - { - table_.move_assign(x.table_, boost::unordered::detail::true_type()); - return *this; - } -#endif -#endif - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_set& operator=(std::initializer_list<value_type>); -#endif - - allocator_type get_allocator() const BOOST_NOEXCEPT - { - return table_.node_alloc(); - } - - // iterators - - iterator begin() BOOST_NOEXCEPT { return iterator(table_.begin()); } - - const_iterator begin() const BOOST_NOEXCEPT - { - return const_iterator(table_.begin()); - } - - iterator end() BOOST_NOEXCEPT { return iterator(); } - - const_iterator end() const BOOST_NOEXCEPT { return const_iterator(); } - - const_iterator cbegin() const BOOST_NOEXCEPT - { - return const_iterator(table_.begin()); - } - - const_iterator cend() const BOOST_NOEXCEPT { return const_iterator(); } - - // size and capacity - - bool empty() const BOOST_NOEXCEPT { return table_.size_ == 0; } - - size_type size() const BOOST_NOEXCEPT { return table_.size_; } - - size_type max_size() const BOOST_NOEXCEPT; - -// emplace - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <class... Args> - std::pair<iterator, bool> emplace(BOOST_FWD_REF(Args)... args) - { - return table_.emplace_unique( - table::extractor::extract(boost::forward<Args>(args)...), - boost::forward<Args>(args)...); - } - -#else - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - - // 0 argument emplace requires special treatment in case - // the container is instantiated with a value type that - // doesn't have a default constructor. - - std::pair<iterator, bool> emplace( - boost::unordered::detail::empty_emplace = - boost::unordered::detail::empty_emplace(), - value_type v = value_type()) - { - return this->emplace(boost::move(v)); - } - -#endif - - template <typename A0> - std::pair<iterator, bool> emplace(BOOST_FWD_REF(A0) a0) - { - return table_.emplace_unique( - table::extractor::extract(boost::forward<A0>(a0)), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0))); - } - - template <typename A0, typename A1> - std::pair<iterator, bool> emplace( - BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1) - { - return table_.emplace_unique( - table::extractor::extract( - boost::forward<A0>(a0), boost::forward<A1>(a1)), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1))); - } - - template <typename A0, typename A1, typename A2> - std::pair<iterator, bool> emplace( - BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - return table_.emplace_unique( - table::extractor::extract( - boost::forward<A0>(a0), boost::forward<A1>(a1)), - boost::unordered::detail::create_emplace_args(boost::forward<A0>(a0), - boost::forward<A1>(a1), boost::forward<A2>(a2))); - } - -#endif - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <class... Args> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(Args)... args) - { - return table_.emplace_hint_unique(hint, - table::extractor::extract(boost::forward<Args>(args)...), - boost::forward<Args>(args)...); - } - -#else - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - - iterator emplace_hint(const_iterator hint, - boost::unordered::detail::empty_emplace = - boost::unordered::detail::empty_emplace(), - value_type v = value_type()) - { - return this->emplace_hint(hint, boost::move(v)); - } - -#endif - - template <typename A0> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(A0) a0) - { - return table_.emplace_hint_unique(hint, - table::extractor::extract(boost::forward<A0>(a0)), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0))); - } - - template <typename A0, typename A1> - iterator emplace_hint( - const_iterator hint, BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1) - { - return table_.emplace_hint_unique(hint, - table::extractor::extract( - boost::forward<A0>(a0), boost::forward<A1>(a1)), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1))); - } - - template <typename A0, typename A1, typename A2> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(A0) a0, - BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - return table_.emplace_hint_unique(hint, - table::extractor::extract( - boost::forward<A0>(a0), boost::forward<A1>(a1)), - boost::unordered::detail::create_emplace_args(boost::forward<A0>(a0), - boost::forward<A1>(a1), boost::forward<A2>(a2))); - } - -#endif - -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#define BOOST_UNORDERED_EMPLACE(z, n, _) \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - std::pair<iterator, bool> emplace( \ - BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_FWD_PARAM, a)) \ - { \ - return table_.emplace_unique( \ - table::extractor::extract( \ - boost::forward<A0>(a0), boost::forward<A1>(a1)), \ - boost::unordered::detail::create_emplace_args( \ - BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_CALL_FORWARD, a))); \ - } \ - \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - iterator emplace_hint( \ - const_iterator hint, BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_FWD_PARAM, a)) \ - { \ - return table_.emplace_hint_unique(hint, \ - table::extractor::extract( \ - boost::forward<A0>(a0), boost::forward<A1>(a1)), \ - boost::unordered::detail::create_emplace_args( \ - BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_CALL_FORWARD, a))); \ - } - - BOOST_UNORDERED_EMPLACE(1, 4, _) - BOOST_UNORDERED_EMPLACE(1, 5, _) - BOOST_UNORDERED_EMPLACE(1, 6, _) - BOOST_UNORDERED_EMPLACE(1, 7, _) - BOOST_UNORDERED_EMPLACE(1, 8, _) - BOOST_UNORDERED_EMPLACE(1, 9, _) - BOOST_PP_REPEAT_FROM_TO(10, BOOST_PP_INC(BOOST_UNORDERED_EMPLACE_LIMIT), - BOOST_UNORDERED_EMPLACE, _) - -#undef BOOST_UNORDERED_EMPLACE - -#endif - - std::pair<iterator, bool> insert(value_type const& x) - { - return this->emplace(x); - } - - std::pair<iterator, bool> insert(BOOST_UNORDERED_RV_REF(value_type) x) - { - return this->emplace(boost::move(x)); - } - - iterator insert(const_iterator hint, value_type const& x) - { - return this->emplace_hint(hint, x); - } - - iterator insert(const_iterator hint, BOOST_UNORDERED_RV_REF(value_type) x) - { - return this->emplace_hint(hint, boost::move(x)); - } - - template <class InputIt> void insert(InputIt, InputIt); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - void insert(std::initializer_list<value_type>); -#endif - - // extract - - node_type extract(const_iterator position) - { - return node_type( - table_.extract_by_iterator_unique(position), table_.node_alloc()); - } - - node_type extract(const key_type& k) - { - return node_type(table_.extract_by_key(k), table_.node_alloc()); - } - - insert_return_type insert(BOOST_RV_REF(node_type) np) - { - insert_return_type result; - table_.move_insert_node_type_unique(np, result); - return boost::move(result); - } - - iterator insert(const_iterator hint, BOOST_RV_REF(node_type) np) - { - return table_.move_insert_node_type_with_hint_unique(hint, np); - } - -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \ - (BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0)) - private: - // Note: Use r-value node_type to insert. - insert_return_type insert(node_type&); - iterator insert(const_iterator, node_type& np); - - public: -#endif - - iterator erase(const_iterator); - size_type erase(const key_type&); - iterator erase(const_iterator, const_iterator); - BOOST_UNORDERED_DEPRECATED("Use erase instead") - void quick_erase(const_iterator it) { erase(it); } - BOOST_UNORDERED_DEPRECATED("Use erase instead") - void erase_return_void(const_iterator it) { erase(it); } - - void swap(unordered_set&) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_swappable<H>::value&& - boost::is_nothrow_swappable<P>::value); - void clear() BOOST_NOEXCEPT { table_.clear_impl(); } - - template <typename H2, typename P2> - void merge(boost::unordered_set<T, H2, P2, A>& source); - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <typename H2, typename P2> - void merge(boost::unordered_set<T, H2, P2, A>&& source); -#endif - - template <typename H2, typename P2> - void merge(boost::unordered_multiset<T, H2, P2, A>& source); - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <typename H2, typename P2> - void merge(boost::unordered_multiset<T, H2, P2, A>&& source); -#endif - - // observers - - hasher hash_function() const; - key_equal key_eq() const; - - // lookup - - const_iterator find(const key_type&) const; - - template <class CompatibleKey, class CompatibleHash, - class CompatiblePredicate> - const_iterator find(CompatibleKey const&, CompatibleHash const&, - CompatiblePredicate const&) const; - - size_type count(const key_type&) const; - - std::pair<const_iterator, const_iterator> equal_range( - const key_type&) const; - - // bucket interface - - size_type bucket_count() const BOOST_NOEXCEPT - { - return table_.bucket_count_; - } - - size_type max_bucket_count() const BOOST_NOEXCEPT - { - return table_.max_bucket_count(); - } - - size_type bucket_size(size_type) const; - - size_type bucket(const key_type& k) const - { - return table_.hash_to_bucket(table_.hash(k)); - } - - local_iterator begin(size_type n) - { - return local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - const_local_iterator begin(size_type n) const - { - return const_local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - local_iterator end(size_type) { return local_iterator(); } - - const_local_iterator end(size_type) const - { - return const_local_iterator(); - } - - const_local_iterator cbegin(size_type n) const - { - return const_local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - const_local_iterator cend(size_type) const - { - return const_local_iterator(); - } - - // hash policy - - float load_factor() const BOOST_NOEXCEPT; - float max_load_factor() const BOOST_NOEXCEPT { return table_.mlf_; } - void max_load_factor(float) BOOST_NOEXCEPT; - void rehash(size_type); - void reserve(size_type); - -#if !BOOST_WORKAROUND(__BORLANDC__, < 0x0582) - friend bool operator== - <T, H, P, A>(unordered_set const&, unordered_set const&); - friend bool operator!= - <T, H, P, A>(unordered_set const&, unordered_set const&); -#endif - }; // class template unordered_set - -#if BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES - - template <class InputIterator, - class Hash = - boost::hash<typename std::iterator_traits<InputIterator>::value_type>, - class Pred = - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - class Allocator = std::allocator< - typename std::iterator_traits<InputIterator>::value_type> > - unordered_set(InputIterator, InputIterator, - std::size_t = boost::unordered::detail::default_bucket_count, - Hash = Hash(), Pred = Pred(), Allocator = Allocator()) - ->unordered_set<typename std::iterator_traits<InputIterator>::value_type, - Hash, Pred, Allocator>; - - template <class T, class Hash = boost::hash<T>, - class Pred = std::equal_to<T>, class Allocator = std::allocator<T> > - unordered_set(std::initializer_list<T>, - std::size_t = boost::unordered::detail::default_bucket_count, - Hash = Hash(), Pred = Pred(), Allocator = Allocator()) - ->unordered_set<T, Hash, Pred, Allocator>; - - template <class InputIterator, class Allocator> - unordered_set(InputIterator, InputIterator, std::size_t, Allocator) - ->unordered_set<typename std::iterator_traits<InputIterator>::value_type, - boost::hash<typename std::iterator_traits<InputIterator>::value_type>, - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - Allocator>; - - template <class InputIterator, class Hash, class Allocator> - unordered_set(InputIterator, InputIterator, std::size_t, Hash, Allocator) - ->unordered_set<typename std::iterator_traits<InputIterator>::value_type, - Hash, - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - Allocator>; - - template <class T, class Allocator> - unordered_set(std::initializer_list<T>, std::size_t, Allocator) - ->unordered_set<T, boost::hash<T>, std::equal_to<T>, Allocator>; - - template <class T, class Hash, class Allocator> - unordered_set(std::initializer_list<T>, std::size_t, Hash, Allocator) - ->unordered_set<T, Hash, std::equal_to<T>, Allocator>; - -#endif - - template <class T, class H, class P, class A> class unordered_multiset - { -#if defined(BOOST_UNORDERED_USE_MOVE) - BOOST_COPYABLE_AND_MOVABLE(unordered_multiset) -#endif - template <typename, typename, typename, typename> - friend class unordered_set; - - public: - typedef T key_type; - typedef T value_type; - typedef H hasher; - typedef P key_equal; - typedef A allocator_type; - - private: - typedef boost::unordered::detail::set<A, T, H, P> types; - typedef typename types::value_allocator_traits value_allocator_traits; - typedef typename types::table table; - typedef typename table::node_pointer node_pointer; - typedef typename table::link_pointer link_pointer; - - public: - typedef typename value_allocator_traits::pointer pointer; - typedef typename value_allocator_traits::const_pointer const_pointer; - - typedef value_type& reference; - typedef value_type const& const_reference; - - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - typedef typename table::iterator iterator; - typedef typename table::c_iterator const_iterator; - typedef typename table::l_iterator local_iterator; - typedef typename table::cl_iterator const_local_iterator; - typedef typename types::node_type node_type; - - private: - table table_; - - public: - // constructors - - unordered_multiset(); - - explicit unordered_multiset(size_type, const hasher& = hasher(), - const key_equal& = key_equal(), - const allocator_type& = allocator_type()); - - template <class InputIt> - unordered_multiset(InputIt, InputIt, - size_type = boost::unordered::detail::default_bucket_count, - const hasher& = hasher(), const key_equal& = key_equal(), - const allocator_type& = allocator_type()); - - unordered_multiset(unordered_multiset const&); - -#if defined(BOOST_UNORDERED_USE_MOVE) || \ - !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - unordered_multiset(BOOST_RV_REF(unordered_multiset) other) - BOOST_NOEXCEPT_IF(table::nothrow_move_constructible) - : table_(other.table_, boost::unordered::detail::move_tag()) - { - // The move is done in table_ - } -#endif - - explicit unordered_multiset(allocator_type const&); - - unordered_multiset(unordered_multiset const&, allocator_type const&); - - unordered_multiset( - BOOST_RV_REF(unordered_multiset), allocator_type const&); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_multiset(std::initializer_list<value_type>, - size_type = boost::unordered::detail::default_bucket_count, - const hasher& = hasher(), const key_equal& l = key_equal(), - const allocator_type& = allocator_type()); -#endif - - explicit unordered_multiset(size_type, const allocator_type&); - - explicit unordered_multiset( - size_type, const hasher&, const allocator_type&); - - template <class InputIt> - unordered_multiset(InputIt, InputIt, size_type, const allocator_type&); - - template <class InputIt> - unordered_multiset( - InputIt, InputIt, size_type, const hasher&, const allocator_type&); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_multiset( - std::initializer_list<value_type>, size_type, const allocator_type&); - - unordered_multiset(std::initializer_list<value_type>, size_type, - const hasher&, const allocator_type&); -#endif - - // Destructor - - ~unordered_multiset() BOOST_NOEXCEPT; - -// Assign - -#if defined(BOOST_UNORDERED_USE_MOVE) - unordered_multiset& operator=(BOOST_COPY_ASSIGN_REF(unordered_multiset) x) - { - table_.assign(x.table_, boost::unordered::detail::false_type()); - return *this; - } - - unordered_multiset& operator=(BOOST_RV_REF(unordered_multiset) x) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_move_assignable<H>::value&& - boost::is_nothrow_move_assignable<P>::value) - { - table_.move_assign(x.table_, boost::unordered::detail::false_type()); - return *this; - } -#else - unordered_multiset& operator=(unordered_multiset const& x) - { - table_.assign(x.table_, boost::unordered::detail::false_type()); - return *this; - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - unordered_multiset& operator=(unordered_multiset&& x) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_move_assignable<H>::value&& - boost::is_nothrow_move_assignable<P>::value) - { - table_.move_assign(x.table_, boost::unordered::detail::false_type()); - return *this; - } -#endif -#endif - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - unordered_multiset& operator=(std::initializer_list<value_type>); -#endif - - allocator_type get_allocator() const BOOST_NOEXCEPT - { - return table_.node_alloc(); - } - - // iterators - - iterator begin() BOOST_NOEXCEPT { return iterator(table_.begin()); } - - const_iterator begin() const BOOST_NOEXCEPT - { - return const_iterator(table_.begin()); - } - - iterator end() BOOST_NOEXCEPT { return iterator(); } - - const_iterator end() const BOOST_NOEXCEPT { return const_iterator(); } - - const_iterator cbegin() const BOOST_NOEXCEPT - { - return const_iterator(table_.begin()); - } - - const_iterator cend() const BOOST_NOEXCEPT { return const_iterator(); } - - // size and capacity - - bool empty() const BOOST_NOEXCEPT { return table_.size_ == 0; } - - size_type size() const BOOST_NOEXCEPT { return table_.size_; } - - size_type max_size() const BOOST_NOEXCEPT; - -// emplace - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <class... Args> iterator emplace(BOOST_FWD_REF(Args)... args) - { - return iterator(table_.emplace_equiv( - boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), boost::forward<Args>(args)...))); - } - -#else - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - - // 0 argument emplace requires special treatment in case - // the container is instantiated with a value type that - // doesn't have a default constructor. - - iterator emplace(boost::unordered::detail::empty_emplace = - boost::unordered::detail::empty_emplace(), - value_type v = value_type()) - { - return this->emplace(boost::move(v)); - } - -#endif - - template <typename A0> iterator emplace(BOOST_FWD_REF(A0) a0) - { - return iterator(table_.emplace_equiv( - boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0))))); - } - - template <typename A0, typename A1> - iterator emplace(BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1) - { - return iterator(table_.emplace_equiv( - boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1))))); - } - - template <typename A0, typename A1, typename A2> - iterator emplace( - BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - return iterator(table_.emplace_equiv( - boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1), - boost::forward<A2>(a2))))); - } - -#endif - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template <class... Args> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(Args)... args) - { - return iterator(table_.emplace_hint_equiv( - hint, boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), boost::forward<Args>(args)...))); - } - -#else - -#if !BOOST_UNORDERED_SUN_WORKAROUNDS1 - - iterator emplace_hint(const_iterator hint, - boost::unordered::detail::empty_emplace = - boost::unordered::detail::empty_emplace(), - value_type v = value_type()) - { - return this->emplace_hint(hint, boost::move(v)); - } - -#endif - - template <typename A0> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(A0) a0) - { - return iterator(table_.emplace_hint_equiv(hint, - boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0))))); - } - - template <typename A0, typename A1> - iterator emplace_hint( - const_iterator hint, BOOST_FWD_REF(A0) a0, BOOST_FWD_REF(A1) a1) - { - return iterator(table_.emplace_hint_equiv( - hint, boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1))))); - } - - template <typename A0, typename A1, typename A2> - iterator emplace_hint(const_iterator hint, BOOST_FWD_REF(A0) a0, - BOOST_FWD_REF(A1) a1, BOOST_FWD_REF(A2) a2) - { - return iterator(table_.emplace_hint_equiv( - hint, boost::unordered::detail::func::construct_node_from_args( - table_.node_alloc(), - boost::unordered::detail::create_emplace_args( - boost::forward<A0>(a0), boost::forward<A1>(a1), - boost::forward<A2>(a2))))); - } - -#endif - -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#define BOOST_UNORDERED_EMPLACE(z, n, _) \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - iterator emplace(BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_FWD_PARAM, a)) \ - { \ - return iterator(table_.emplace_equiv( \ - boost::unordered::detail::func::construct_node_from_args( \ - table_.node_alloc(), \ - boost::unordered::detail::create_emplace_args( \ - BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_CALL_FORWARD, a))))); \ - } \ - \ - template <BOOST_PP_ENUM_PARAMS_Z(z, n, typename A)> \ - iterator emplace_hint( \ - const_iterator hint, BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_FWD_PARAM, a)) \ - { \ - return iterator(table_.emplace_hint_equiv( \ - hint, boost::unordered::detail::func::construct_node_from_args( \ - table_.node_alloc(), \ - boost::unordered::detail::create_emplace_args( \ - BOOST_PP_ENUM_##z(n, BOOST_UNORDERED_CALL_FORWARD, a))))); \ - } - - BOOST_UNORDERED_EMPLACE(1, 4, _) - BOOST_UNORDERED_EMPLACE(1, 5, _) - BOOST_UNORDERED_EMPLACE(1, 6, _) - BOOST_UNORDERED_EMPLACE(1, 7, _) - BOOST_UNORDERED_EMPLACE(1, 8, _) - BOOST_UNORDERED_EMPLACE(1, 9, _) - BOOST_PP_REPEAT_FROM_TO(10, BOOST_PP_INC(BOOST_UNORDERED_EMPLACE_LIMIT), - BOOST_UNORDERED_EMPLACE, _) - -#undef BOOST_UNORDERED_EMPLACE - -#endif - - iterator insert(value_type const& x) { return this->emplace(x); } - - iterator insert(BOOST_UNORDERED_RV_REF(value_type) x) - { - return this->emplace(boost::move(x)); - } - - iterator insert(const_iterator hint, value_type const& x) - { - return this->emplace_hint(hint, x); - } - - iterator insert(const_iterator hint, BOOST_UNORDERED_RV_REF(value_type) x) - { - return this->emplace_hint(hint, boost::move(x)); - } - - template <class InputIt> void insert(InputIt, InputIt); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - void insert(std::initializer_list<value_type>); -#endif - - // extract - - node_type extract(const_iterator position) - { - return node_type( - table_.extract_by_iterator_equiv(position), table_.node_alloc()); - } - - node_type extract(const key_type& k) - { - return node_type(table_.extract_by_key(k), table_.node_alloc()); - } - - iterator insert(BOOST_RV_REF(node_type) np) - { - return table_.move_insert_node_type_equiv(np); - } - - iterator insert(const_iterator hint, BOOST_RV_REF(node_type) np) - { - return table_.move_insert_node_type_with_hint_equiv(hint, np); - } - -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \ - (BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0)) - private: - // Note: Use r-value node_type to insert. - iterator insert(node_type&); - iterator insert(const_iterator, node_type& np); - - public: -#endif - - iterator erase(const_iterator); - size_type erase(const key_type&); - iterator erase(const_iterator, const_iterator); - BOOST_UNORDERED_DEPRECATED("Use erase instead") - void quick_erase(const_iterator it) { erase(it); } - BOOST_UNORDERED_DEPRECATED("Use erase instead") - void erase_return_void(const_iterator it) { erase(it); } - - void swap(unordered_multiset&) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_swappable<H>::value&& - boost::is_nothrow_swappable<P>::value); - void clear() BOOST_NOEXCEPT { table_.clear_impl(); } - - template <typename H2, typename P2> - void merge(boost::unordered_multiset<T, H2, P2, A>& source); - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <typename H2, typename P2> - void merge(boost::unordered_multiset<T, H2, P2, A>&& source); -#endif - - template <typename H2, typename P2> - void merge(boost::unordered_set<T, H2, P2, A>& source); - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <typename H2, typename P2> - void merge(boost::unordered_set<T, H2, P2, A>&& source); -#endif - - // observers - - hasher hash_function() const; - key_equal key_eq() const; - - // lookup - - const_iterator find(const key_type&) const; - - template <class CompatibleKey, class CompatibleHash, - class CompatiblePredicate> - const_iterator find(CompatibleKey const&, CompatibleHash const&, - CompatiblePredicate const&) const; - - size_type count(const key_type&) const; - - std::pair<const_iterator, const_iterator> equal_range( - const key_type&) const; - - // bucket interface - - size_type bucket_count() const BOOST_NOEXCEPT - { - return table_.bucket_count_; - } - - size_type max_bucket_count() const BOOST_NOEXCEPT - { - return table_.max_bucket_count(); - } - - size_type bucket_size(size_type) const; - - size_type bucket(const key_type& k) const - { - return table_.hash_to_bucket(table_.hash(k)); - } - - local_iterator begin(size_type n) - { - return local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - const_local_iterator begin(size_type n) const - { - return const_local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - local_iterator end(size_type) { return local_iterator(); } - - const_local_iterator end(size_type) const - { - return const_local_iterator(); - } - - const_local_iterator cbegin(size_type n) const - { - return const_local_iterator(table_.begin(n), n, table_.bucket_count_); - } - - const_local_iterator cend(size_type) const - { - return const_local_iterator(); - } - - // hash policy - - float load_factor() const BOOST_NOEXCEPT; - float max_load_factor() const BOOST_NOEXCEPT { return table_.mlf_; } - void max_load_factor(float) BOOST_NOEXCEPT; - void rehash(size_type); - void reserve(size_type); - -#if !BOOST_WORKAROUND(__BORLANDC__, < 0x0582) - friend bool operator== - <T, H, P, A>(unordered_multiset const&, unordered_multiset const&); - friend bool operator!= - <T, H, P, A>(unordered_multiset const&, unordered_multiset const&); -#endif - }; // class template unordered_multiset - -#if BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES - - template <class InputIterator, - class Hash = - boost::hash<typename std::iterator_traits<InputIterator>::value_type>, - class Pred = - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - class Allocator = std::allocator< - typename std::iterator_traits<InputIterator>::value_type> > - unordered_multiset(InputIterator, InputIterator, - std::size_t = boost::unordered::detail::default_bucket_count, - Hash = Hash(), Pred = Pred(), Allocator = Allocator()) - ->unordered_multiset< - typename std::iterator_traits<InputIterator>::value_type, Hash, Pred, - Allocator>; - - template <class T, class Hash = boost::hash<T>, - class Pred = std::equal_to<T>, class Allocator = std::allocator<T> > - unordered_multiset(std::initializer_list<T>, - std::size_t = boost::unordered::detail::default_bucket_count, - Hash = Hash(), Pred = Pred(), Allocator = Allocator()) - ->unordered_multiset<T, Hash, Pred, Allocator>; - - template <class InputIterator, class Allocator> - unordered_multiset(InputIterator, InputIterator, std::size_t, Allocator) - ->unordered_multiset< - typename std::iterator_traits<InputIterator>::value_type, - boost::hash<typename std::iterator_traits<InputIterator>::value_type>, - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - Allocator>; - - template <class InputIterator, class Hash, class Allocator> - unordered_multiset( - InputIterator, InputIterator, std::size_t, Hash, Allocator) - ->unordered_multiset< - typename std::iterator_traits<InputIterator>::value_type, Hash, - std::equal_to<typename std::iterator_traits<InputIterator>::value_type>, - Allocator>; - - template <class T, class Allocator> - unordered_multiset(std::initializer_list<T>, std::size_t, Allocator) - ->unordered_multiset<T, boost::hash<T>, std::equal_to<T>, Allocator>; - - template <class T, class Hash, class Allocator> - unordered_multiset(std::initializer_list<T>, std::size_t, Hash, Allocator) - ->unordered_multiset<T, Hash, std::equal_to<T>, Allocator>; - -#endif - - //////////////////////////////////////////////////////////////////////////// - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set() - : table_(boost::unordered::detail::default_bucket_count, hasher(), - key_equal(), allocator_type()) - { - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set(size_type n, const hasher& hf, - const key_equal& eql, const allocator_type& a) - : table_(n, hf, eql, a) - { - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_set<T, H, P, A>::unordered_set(InputIt f, InputIt l, size_type n, - const hasher& hf, const key_equal& eql, const allocator_type& a) - : table_(boost::unordered::detail::initial_size(f, l, n), hf, eql, a) - { - this->insert(f, l); - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set(unordered_set const& other) - : table_(other.table_, - unordered_set::value_allocator_traits:: - select_on_container_copy_construction(other.get_allocator())) - { - if (other.table_.size_) { - table_.copy_buckets( - other.table_, boost::unordered::detail::true_type()); - } - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set(allocator_type const& a) - : table_(boost::unordered::detail::default_bucket_count, hasher(), - key_equal(), a) - { - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - unordered_set const& other, allocator_type const& a) - : table_(other.table_, a) - { - if (other.table_.size_) { - table_.copy_buckets( - other.table_, boost::unordered::detail::true_type()); - } - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - BOOST_RV_REF(unordered_set) other, allocator_type const& a) - : table_(other.table_, a, boost::unordered::detail::move_tag()) - { - table_.move_construct_buckets(other.table_); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - std::initializer_list<value_type> list, size_type n, const hasher& hf, - const key_equal& eql, const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hf, eql, a) - { - this->insert(list.begin(), list.end()); - } - -#endif - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - size_type n, const allocator_type& a) - : table_(n, hasher(), key_equal(), a) - { - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - size_type n, const hasher& hf, const allocator_type& a) - : table_(n, hf, key_equal(), a) - { - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_set<T, H, P, A>::unordered_set( - InputIt f, InputIt l, size_type n, const allocator_type& a) - : table_(boost::unordered::detail::initial_size(f, l, n), hasher(), - key_equal(), a) - { - this->insert(f, l); - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_set<T, H, P, A>::unordered_set(InputIt f, InputIt l, size_type n, - const hasher& hf, const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(f, l, n), hf, key_equal(), a) - { - this->insert(f, l); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - std::initializer_list<value_type> list, size_type n, - const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hasher(), key_equal(), a) - { - this->insert(list.begin(), list.end()); - } - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::unordered_set( - std::initializer_list<value_type> list, size_type n, const hasher& hf, - const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hf, key_equal(), a) - { - this->insert(list.begin(), list.end()); - } - -#endif - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>::~unordered_set() BOOST_NOEXCEPT - { - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_set<T, H, P, A>& unordered_set<T, H, P, A>::operator=( - std::initializer_list<value_type> list) - { - this->clear(); - this->insert(list.begin(), list.end()); - return *this; - } - -#endif - - // size and capacity - - template <class T, class H, class P, class A> - std::size_t unordered_set<T, H, P, A>::max_size() const BOOST_NOEXCEPT - { - using namespace std; - - // size < mlf_ * count - return boost::unordered::detail::double_to_size( - ceil(static_cast<double>(table_.mlf_) * - static_cast<double>(table_.max_bucket_count()))) - - 1; - } - - // modifiers - - template <class T, class H, class P, class A> - template <class InputIt> - void unordered_set<T, H, P, A>::insert(InputIt first, InputIt last) - { - if (first != last) { - table_.insert_range_unique( - table::extractor::extract(*first), first, last); - } - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - template <class T, class H, class P, class A> - void unordered_set<T, H, P, A>::insert( - std::initializer_list<value_type> list) - { - this->insert(list.begin(), list.end()); - } -#endif - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::iterator - unordered_set<T, H, P, A>::erase(const_iterator position) - { - node_pointer node = table::get_node(position); - BOOST_ASSERT(node); - node_pointer next = table::next_node(node); - table_.erase_nodes_unique(node, next); - return iterator(next); - } - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::size_type - unordered_set<T, H, P, A>::erase(const key_type& k) - { - return table_.erase_key_unique(k); - } - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::iterator - unordered_set<T, H, P, A>::erase(const_iterator first, const_iterator last) - { - node_pointer last_node = table::get_node(last); - if (first == last) - return iterator(last_node); - table_.erase_nodes_unique(table::get_node(first), last_node); - return iterator(last_node); - } - - template <class T, class H, class P, class A> - void unordered_set<T, H, P, A>::swap(unordered_set& other) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_swappable<H>::value&& - boost::is_nothrow_swappable<P>::value) - { - table_.swap(other.table_); - } - - // observers - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::hasher - unordered_set<T, H, P, A>::hash_function() const - { - return table_.hash_function(); - } - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::key_equal - unordered_set<T, H, P, A>::key_eq() const - { - return table_.key_eq(); - } - - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_set<T, H, P, A>::merge( - boost::unordered_set<T, H2, P2, A>& source) - { - table_.merge_unique(source.table_); - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_set<T, H, P, A>::merge( - boost::unordered_set<T, H2, P2, A>&& source) - { - table_.merge_unique(source.table_); - } -#endif - - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_set<T, H, P, A>::merge( - boost::unordered_multiset<T, H2, P2, A>& source) - { - table_.merge_unique(source.table_); - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_set<T, H, P, A>::merge( - boost::unordered_multiset<T, H2, P2, A>&& source) - { - table_.merge_unique(source.table_); - } -#endif - - // lookup - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::const_iterator - unordered_set<T, H, P, A>::find(const key_type& k) const - { - return const_iterator(table_.find_node(k)); - } - - template <class T, class H, class P, class A> - template <class CompatibleKey, class CompatibleHash, - class CompatiblePredicate> - typename unordered_set<T, H, P, A>::const_iterator - unordered_set<T, H, P, A>::find(CompatibleKey const& k, - CompatibleHash const& hash, CompatiblePredicate const& eq) const - { - return const_iterator( - table_.find_node_impl(table::policy::apply_hash(hash, k), k, eq)); - } - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::size_type - unordered_set<T, H, P, A>::count(const key_type& k) const - { - return table_.find_node(k) ? 1 : 0; - } - - template <class T, class H, class P, class A> - std::pair<typename unordered_set<T, H, P, A>::const_iterator, - typename unordered_set<T, H, P, A>::const_iterator> - unordered_set<T, H, P, A>::equal_range(const key_type& k) const - { - node_pointer n = table_.find_node(k); - return std::make_pair( - const_iterator(n), const_iterator(n ? table::next_node(n) : n)); - } - - template <class T, class H, class P, class A> - typename unordered_set<T, H, P, A>::size_type - unordered_set<T, H, P, A>::bucket_size(size_type n) const - { - return table_.bucket_size(n); - } - - // hash policy - - template <class T, class H, class P, class A> - float unordered_set<T, H, P, A>::load_factor() const BOOST_NOEXCEPT - { - BOOST_ASSERT(table_.bucket_count_ != 0); - return static_cast<float>(table_.size_) / - static_cast<float>(table_.bucket_count_); - } - - template <class T, class H, class P, class A> - void unordered_set<T, H, P, A>::max_load_factor(float m) BOOST_NOEXCEPT - { - table_.max_load_factor(m); - } - - template <class T, class H, class P, class A> - void unordered_set<T, H, P, A>::rehash(size_type n) - { - table_.rehash(n); - } - - template <class T, class H, class P, class A> - void unordered_set<T, H, P, A>::reserve(size_type n) - { - table_.rehash(static_cast<std::size_t>( - std::ceil(static_cast<double>(n) / table_.mlf_))); - } - - template <class T, class H, class P, class A> - inline bool operator==( - unordered_set<T, H, P, A> const& m1, unordered_set<T, H, P, A> const& m2) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_set<T, H, P, A> x; - }; -#endif - return m1.table_.equals_unique(m2.table_); - } - - template <class T, class H, class P, class A> - inline bool operator!=( - unordered_set<T, H, P, A> const& m1, unordered_set<T, H, P, A> const& m2) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_set<T, H, P, A> x; - }; -#endif - return !m1.table_.equals_unique(m2.table_); - } - - template <class T, class H, class P, class A> - inline void swap( - unordered_set<T, H, P, A>& m1, unordered_set<T, H, P, A>& m2) - BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(m1.swap(m2))) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_set<T, H, P, A> x; - }; -#endif - m1.swap(m2); - } - - //////////////////////////////////////////////////////////////////////////// - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset() - : table_(boost::unordered::detail::default_bucket_count, hasher(), - key_equal(), allocator_type()) - { - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset(size_type n, - const hasher& hf, const key_equal& eql, const allocator_type& a) - : table_(n, hf, eql, a) - { - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_multiset<T, H, P, A>::unordered_multiset(InputIt f, InputIt l, - size_type n, const hasher& hf, const key_equal& eql, - const allocator_type& a) - : table_(boost::unordered::detail::initial_size(f, l, n), hf, eql, a) - { - this->insert(f, l); - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - unordered_multiset const& other) - : table_(other.table_, - unordered_multiset::value_allocator_traits:: - select_on_container_copy_construction(other.get_allocator())) - { - if (other.table_.size_) { - table_.copy_buckets( - other.table_, boost::unordered::detail::false_type()); - } - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset(allocator_type const& a) - : table_(boost::unordered::detail::default_bucket_count, hasher(), - key_equal(), a) - { - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - unordered_multiset const& other, allocator_type const& a) - : table_(other.table_, a) - { - if (other.table_.size_) { - table_.copy_buckets( - other.table_, boost::unordered::detail::false_type()); - } - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - BOOST_RV_REF(unordered_multiset) other, allocator_type const& a) - : table_(other.table_, a, boost::unordered::detail::move_tag()) - { - table_.move_construct_buckets(other.table_); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - std::initializer_list<value_type> list, size_type n, const hasher& hf, - const key_equal& eql, const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hf, eql, a) - { - this->insert(list.begin(), list.end()); - } - -#endif - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - size_type n, const allocator_type& a) - : table_(n, hasher(), key_equal(), a) - { - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - size_type n, const hasher& hf, const allocator_type& a) - : table_(n, hf, key_equal(), a) - { - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_multiset<T, H, P, A>::unordered_multiset( - InputIt f, InputIt l, size_type n, const allocator_type& a) - : table_(boost::unordered::detail::initial_size(f, l, n), hasher(), - key_equal(), a) - { - this->insert(f, l); - } - - template <class T, class H, class P, class A> - template <class InputIt> - unordered_multiset<T, H, P, A>::unordered_multiset(InputIt f, InputIt l, - size_type n, const hasher& hf, const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(f, l, n), hf, key_equal(), a) - { - this->insert(f, l); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - std::initializer_list<value_type> list, size_type n, - const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hasher(), key_equal(), a) - { - this->insert(list.begin(), list.end()); - } - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::unordered_multiset( - std::initializer_list<value_type> list, size_type n, const hasher& hf, - const allocator_type& a) - : table_( - boost::unordered::detail::initial_size(list.begin(), list.end(), n), - hf, key_equal(), a) - { - this->insert(list.begin(), list.end()); - } - -#endif - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>::~unordered_multiset() BOOST_NOEXCEPT - { - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - - template <class T, class H, class P, class A> - unordered_multiset<T, H, P, A>& unordered_multiset<T, H, P, A>::operator=( - std::initializer_list<value_type> list) - { - this->clear(); - this->insert(list.begin(), list.end()); - return *this; - } - -#endif - - // size and capacity - - template <class T, class H, class P, class A> - std::size_t unordered_multiset<T, H, P, A>::max_size() const BOOST_NOEXCEPT - { - using namespace std; - - // size < mlf_ * count - return boost::unordered::detail::double_to_size( - ceil(static_cast<double>(table_.mlf_) * - static_cast<double>(table_.max_bucket_count()))) - - 1; - } - - // modifiers - - template <class T, class H, class P, class A> - template <class InputIt> - void unordered_multiset<T, H, P, A>::insert(InputIt first, InputIt last) - { - table_.insert_range_equiv(first, last); - } - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - template <class T, class H, class P, class A> - void unordered_multiset<T, H, P, A>::insert( - std::initializer_list<value_type> list) - { - this->insert(list.begin(), list.end()); - } -#endif - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::iterator - unordered_multiset<T, H, P, A>::erase(const_iterator position) - { - node_pointer node = table::get_node(position); - BOOST_ASSERT(node); - node_pointer next = table::next_node(node); - table_.erase_nodes_equiv(node, next); - return iterator(next); - } - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::size_type - unordered_multiset<T, H, P, A>::erase(const key_type& k) - { - return table_.erase_key_equiv(k); - } - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::iterator - unordered_multiset<T, H, P, A>::erase( - const_iterator first, const_iterator last) - { - node_pointer last_node = table::get_node(last); - if (first == last) - return iterator(last_node); - table_.erase_nodes_equiv(table::get_node(first), last_node); - return iterator(last_node); - } - - template <class T, class H, class P, class A> - void unordered_multiset<T, H, P, A>::swap(unordered_multiset& other) - BOOST_NOEXCEPT_IF(value_allocator_traits::is_always_equal::value&& - boost::is_nothrow_swappable<H>::value&& - boost::is_nothrow_swappable<P>::value) - { - table_.swap(other.table_); - } - - // observers - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::hasher - unordered_multiset<T, H, P, A>::hash_function() const - { - return table_.hash_function(); - } - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::key_equal - unordered_multiset<T, H, P, A>::key_eq() const - { - return table_.key_eq(); - } - - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_multiset<T, H, P, A>::merge( - boost::unordered_multiset<T, H2, P2, A>& source) - { - while (!source.empty()) { - insert(source.extract(source.begin())); - } - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_multiset<T, H, P, A>::merge( - boost::unordered_multiset<T, H2, P2, A>&& source) - { - while (!source.empty()) { - insert(source.extract(source.begin())); - } - } -#endif - - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_multiset<T, H, P, A>::merge( - boost::unordered_set<T, H2, P2, A>& source) - { - while (!source.empty()) { - insert(source.extract(source.begin())); - } - } - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - template <class T, class H, class P, class A> - template <typename H2, typename P2> - void unordered_multiset<T, H, P, A>::merge( - boost::unordered_set<T, H2, P2, A>&& source) - { - while (!source.empty()) { - insert(source.extract(source.begin())); - } - } -#endif - - // lookup - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::const_iterator - unordered_multiset<T, H, P, A>::find(const key_type& k) const - { - return const_iterator(table_.find_node(k)); - } - - template <class T, class H, class P, class A> - template <class CompatibleKey, class CompatibleHash, - class CompatiblePredicate> - typename unordered_multiset<T, H, P, A>::const_iterator - unordered_multiset<T, H, P, A>::find(CompatibleKey const& k, - CompatibleHash const& hash, CompatiblePredicate const& eq) const - { - return const_iterator( - table_.find_node_impl(table::policy::apply_hash(hash, k), k, eq)); - } - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::size_type - unordered_multiset<T, H, P, A>::count(const key_type& k) const - { - node_pointer n = table_.find_node(k); - return n ? table_.group_count(n) : 0; - } - - template <class T, class H, class P, class A> - std::pair<typename unordered_multiset<T, H, P, A>::const_iterator, - typename unordered_multiset<T, H, P, A>::const_iterator> - unordered_multiset<T, H, P, A>::equal_range(const key_type& k) const - { - node_pointer n = table_.find_node(k); - return std::make_pair( - const_iterator(n), const_iterator(n ? table_.next_group(n) : n)); - } - - template <class T, class H, class P, class A> - typename unordered_multiset<T, H, P, A>::size_type - unordered_multiset<T, H, P, A>::bucket_size(size_type n) const - { - return table_.bucket_size(n); - } - - // hash policy - - template <class T, class H, class P, class A> - float unordered_multiset<T, H, P, A>::load_factor() const BOOST_NOEXCEPT - { - BOOST_ASSERT(table_.bucket_count_ != 0); - return static_cast<float>(table_.size_) / - static_cast<float>(table_.bucket_count_); - } - - template <class T, class H, class P, class A> - void unordered_multiset<T, H, P, A>::max_load_factor(float m) BOOST_NOEXCEPT - { - table_.max_load_factor(m); - } - - template <class T, class H, class P, class A> - void unordered_multiset<T, H, P, A>::rehash(size_type n) - { - table_.rehash(n); - } - - template <class T, class H, class P, class A> - void unordered_multiset<T, H, P, A>::reserve(size_type n) - { - table_.rehash(static_cast<std::size_t>( - std::ceil(static_cast<double>(n) / table_.mlf_))); - } - - template <class T, class H, class P, class A> - inline bool operator==(unordered_multiset<T, H, P, A> const& m1, - unordered_multiset<T, H, P, A> const& m2) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_multiset<T, H, P, A> x; - }; -#endif - return m1.table_.equals_equiv(m2.table_); - } - - template <class T, class H, class P, class A> - inline bool operator!=(unordered_multiset<T, H, P, A> const& m1, - unordered_multiset<T, H, P, A> const& m2) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_multiset<T, H, P, A> x; - }; -#endif - return !m1.table_.equals_equiv(m2.table_); - } - - template <class T, class H, class P, class A> - inline void swap( - unordered_multiset<T, H, P, A>& m1, unordered_multiset<T, H, P, A>& m2) - BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(m1.swap(m2))) - { -#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x0613)) - struct dummy - { - unordered_multiset<T, H, P, A> x; - }; -#endif - m1.swap(m2); - } - - template <typename N, typename T, typename A> class node_handle_set - { - BOOST_MOVABLE_BUT_NOT_COPYABLE(node_handle_set) - - template <typename Types> friend struct ::boost::unordered::detail::table; - template <class T2, class H2, class P2, class A2> - friend class unordered_set; - template <class T2, class H2, class P2, class A2> - friend class unordered_multiset; - - typedef typename boost::unordered::detail::rebind_wrap<A, T>::type - value_allocator; - typedef boost::unordered::detail::allocator_traits<value_allocator> - value_allocator_traits; - typedef N node; - typedef typename boost::unordered::detail::rebind_wrap<A, node>::type - node_allocator; - typedef boost::unordered::detail::allocator_traits<node_allocator> - node_allocator_traits; - typedef typename node_allocator_traits::pointer node_pointer; - - public: - typedef T value_type; - typedef A allocator_type; - - private: - node_pointer ptr_; - bool has_alloc_; - boost::unordered::detail::optional<value_allocator> alloc_; - - node_handle_set(node_pointer ptr, allocator_type const& a) - : ptr_(ptr), alloc_(a) - { - } - - public: - BOOST_CONSTEXPR node_handle_set() BOOST_NOEXCEPT : ptr_(), - has_alloc_(false) - { - } - - ~node_handle_set() - { - if (ptr_) { - node_allocator node_alloc(*alloc_); - boost::unordered::detail::node_tmp<node_allocator> tmp( - ptr_, node_alloc); - } - } - - node_handle_set(BOOST_RV_REF(node_handle_set) n) BOOST_NOEXCEPT - : ptr_(n.ptr_), - alloc_(boost::move(n.alloc_)) - { - n.ptr_ = node_pointer(); - } - - node_handle_set& operator=(BOOST_RV_REF(node_handle_set) n) - { - BOOST_ASSERT(!alloc_.has_value() || - value_allocator_traits:: - propagate_on_container_move_assignment::value || - (n.alloc_.has_value() && alloc_ == n.alloc_)); - - if (ptr_) { - node_allocator node_alloc(*alloc_); - boost::unordered::detail::node_tmp<node_allocator> tmp( - ptr_, node_alloc); - ptr_ = node_pointer(); - } - - if (!alloc_.has_value() || - value_allocator_traits::propagate_on_container_move_assignment:: - value) { - alloc_ = boost::move(n.alloc_); - } - ptr_ = n.ptr_; - n.ptr_ = node_pointer(); - - return *this; - } - - value_type& value() const { return ptr_->value(); } - - allocator_type get_allocator() const { return *alloc_; } - - BOOST_EXPLICIT_OPERATOR_BOOL_NOEXCEPT() - - bool operator!() const BOOST_NOEXCEPT { return ptr_ ? 0 : 1; } - - bool empty() const BOOST_NOEXCEPT { return ptr_ ? 0 : 1; } - - void swap(node_handle_set& n) BOOST_NOEXCEPT_IF( - value_allocator_traits::propagate_on_container_swap::value || - value_allocator_traits::is_always_equal::value) - { - BOOST_ASSERT( - !alloc_.has_value() || !n.alloc_.has_value() || - value_allocator_traits::propagate_on_container_swap::value || - alloc_ == n.alloc_); - if (value_allocator_traits::propagate_on_container_swap::value || - !alloc_.has_value() || !n.alloc_.has_value()) { - boost::swap(alloc_, n.alloc_); - } - boost::swap(ptr_, n.ptr_); - } - }; - - template <typename N, typename T, typename A> - void swap(node_handle_set<N, T, A>& x, node_handle_set<N, T, A>& y) - BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(x.swap(y))) - { - x.swap(y); - } - - template <typename N, typename T, typename A> struct insert_return_type_set - { - private: - BOOST_MOVABLE_BUT_NOT_COPYABLE(insert_return_type_set) - - typedef typename boost::unordered::detail::rebind_wrap<A, T>::type - value_allocator; - typedef N node_; - - public: - bool inserted; - boost::unordered::iterator_detail::c_iterator<node_> position; - boost::unordered::node_handle_set<N, T, A> node; - - insert_return_type_set() : inserted(false), position(), node() {} - - insert_return_type_set(BOOST_RV_REF(insert_return_type_set) - x) BOOST_NOEXCEPT : inserted(x.inserted), - position(x.position), - node(boost::move(x.node)) - { - } - - insert_return_type_set& operator=(BOOST_RV_REF(insert_return_type_set) x) - { - inserted = x.inserted; - position = x.position; - node = boost::move(x.node); - return *this; - } - }; - - template <typename N, typename T, typename A> - void swap( - insert_return_type_set<N, T, A>& x, insert_return_type_set<N, T, A>& y) - { - boost::swap(x.node, y.node); - boost::swap(x.inserted, y.inserted); - boost::swap(x.position, y.position); - } - } // namespace unordered -} // namespace boost - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#endif // BOOST_UNORDERED_UNORDERED_SET_HPP_INCLUDED diff --git a/ThirdParty/boost/unordered/unordered_set_fwd.hpp b/ThirdParty/boost/unordered/unordered_set_fwd.hpp deleted file mode 100644 index 35e2820f95fdcfaa1a3997ad77e027374868343e..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/unordered/unordered_set_fwd.hpp +++ /dev/null @@ -1,62 +0,0 @@ - -// Copyright (C) 2008-2011 Daniel James. -// 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_UNORDERED_SET_FWD_HPP_INCLUDED -#define BOOST_UNORDERED_SET_FWD_HPP_INCLUDED - -#include <boost/config.hpp> -#if defined(BOOST_HAS_PRAGMA_ONCE) -#pragma once -#endif - -#include <boost/functional/hash_fwd.hpp> -#include <boost/unordered/detail/fwd.hpp> -#include <functional> -#include <memory> - -namespace boost { - namespace unordered { - template <class T, class H = boost::hash<T>, class P = std::equal_to<T>, - class A = std::allocator<T> > - class unordered_set; - - template <class T, class H, class P, class A> - inline bool operator==( - unordered_set<T, H, P, A> const&, unordered_set<T, H, P, A> const&); - template <class T, class H, class P, class A> - inline bool operator!=( - unordered_set<T, H, P, A> const&, unordered_set<T, H, P, A> const&); - template <class T, class H, class P, class A> - inline void swap( - unordered_set<T, H, P, A>& m1, unordered_set<T, H, P, A>& m2) - BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(m1.swap(m2))); - - template <class T, class H = boost::hash<T>, class P = std::equal_to<T>, - class A = std::allocator<T> > - class unordered_multiset; - - template <class T, class H, class P, class A> - inline bool operator==(unordered_multiset<T, H, P, A> const&, - unordered_multiset<T, H, P, A> const&); - template <class T, class H, class P, class A> - inline bool operator!=(unordered_multiset<T, H, P, A> const&, - unordered_multiset<T, H, P, A> const&); - template <class T, class H, class P, class A> - inline void swap( - unordered_multiset<T, H, P, A>& m1, unordered_multiset<T, H, P, A>& m2) - BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(m1.swap(m2))); - - template <class N, class T, class A> class node_handle_set; - template <class N, class T, class A> struct insert_return_type_set; - } - - using boost::unordered::unordered_set; - using boost::unordered::unordered_multiset; - using boost::unordered::swap; - using boost::unordered::operator==; - using boost::unordered::operator!=; -} - -#endif diff --git a/ThirdParty/boost/variant2/variant.hpp b/ThirdParty/boost/variant2/variant.hpp deleted file mode 100644 index 9c1fba9607af503dc0cc2738be189f55f971d4d7..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/variant2/variant.hpp +++ /dev/null @@ -1,2048 +0,0 @@ -#ifndef BOOST_VARIANT2_VARIANT_HPP_INCLUDED -#define BOOST_VARIANT2_VARIANT_HPP_INCLUDED - -// Copyright 2017-2019 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 - -#if defined(_MSC_VER) && _MSC_VER < 1910 -# pragma warning( push ) -# pragma warning( disable: 4521 4522 ) // multiple copy operators -#endif - -#ifndef BOOST_MP11_HPP_INCLUDED -#include <boost/mp11.hpp> -#endif -#include <boost/config.hpp> -#include <boost/detail/workaround.hpp> -#include <boost/cstdint.hpp> -#include <cstddef> -#include <type_traits> -#include <exception> -#include <cassert> -#include <initializer_list> -#include <utility> -#include <functional> // std::hash - -// - -namespace boost -{ - -#ifdef BOOST_NO_EXCEPTIONS - -BOOST_NORETURN void throw_exception( std::exception const & e ); // user defined - -#endif - -namespace variant2 -{ - -// bad_variant_access - -class bad_variant_access: public std::exception -{ -public: - - bad_variant_access() noexcept - { - } - - char const * what() const noexcept - { - return "bad_variant_access"; - } -}; - -namespace detail -{ - -BOOST_NORETURN inline void throw_bad_variant_access() -{ -#ifdef BOOST_NO_EXCEPTIONS - - boost::throw_exception( bad_variant_access() ); - -#else - - throw bad_variant_access(); - -#endif -} - -} // namespace detail - -// monostate - -struct monostate -{ -}; - -constexpr bool operator<(monostate, monostate) noexcept { return false; } -constexpr bool operator>(monostate, monostate) noexcept { return false; } -constexpr bool operator<=(monostate, monostate) noexcept { return true; } -constexpr bool operator>=(monostate, monostate) noexcept { return true; } -constexpr bool operator==(monostate, monostate) noexcept { return true; } -constexpr bool operator!=(monostate, monostate) noexcept { return false; } - -// variant forward declaration - -template<class... T> class variant; - -// variant_size - -template<class T> struct variant_size -{ -}; - -template<class T> struct variant_size<T const>: variant_size<T> -{ -}; - -template<class T> struct variant_size<T volatile>: variant_size<T> -{ -}; - -template<class T> struct variant_size<T const volatile>: variant_size<T> -{ -}; - -template<class T> struct variant_size<T&>: variant_size<T> -{ -}; - -template<class T> struct variant_size<T&&>: variant_size<T> -{ -}; - -#if !defined(BOOST_NO_CXX14_VARIABLE_TEMPLATES) - -template <class T> /*inline*/ constexpr std::size_t variant_size_v = variant_size<T>::value; - -#endif - -template <class... T> struct variant_size<variant<T...>>: mp11::mp_size<variant<T...>> -{ -}; - -// variant_alternative - -template<std::size_t I, class T> struct variant_alternative; - -template<std::size_t I, class T> using variant_alternative_t = typename variant_alternative<I, T>::type; - -#if BOOST_WORKAROUND(BOOST_GCC, < 40900) - -namespace detail -{ - -template<std::size_t I, class T, bool E> struct variant_alternative_impl -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...>, true> -{ - using type = mp11::mp_at_c<variant<T...>, I>; -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const, true>: std::add_const< mp11::mp_at_c<variant<T...>, I> > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> volatile, true>: std::add_volatile< mp11::mp_at_c<variant<T...>, I> > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const volatile, true>: std::add_cv< mp11::mp_at_c<variant<T...>, I> > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...>&, true>: std::add_lvalue_reference< mp11::mp_at_c<variant<T...>, I> > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const&, true>: std::add_lvalue_reference< mp11::mp_at_c<variant<T...>, I> const > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> volatile&, true>: std::add_lvalue_reference< mp11::mp_at_c<variant<T...>, I> volatile > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const volatile&, true>: std::add_lvalue_reference< mp11::mp_at_c<variant<T...>, I> const volatile > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...>&&, true>: std::add_rvalue_reference< mp11::mp_at_c<variant<T...>, I> > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const&&, true>: std::add_rvalue_reference< mp11::mp_at_c<variant<T...>, I> const > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> volatile&&, true>: std::add_rvalue_reference< mp11::mp_at_c<variant<T...>, I> volatile > -{ -}; - -template<std::size_t I, class... T> struct variant_alternative_impl<I, variant<T...> const volatile&&, true>: std::add_rvalue_reference< mp11::mp_at_c<variant<T...>, I> const volatile > -{ -}; - -} // namespace detail - -template<std::size_t I, class T> struct variant_alternative -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...>>: public detail::variant_alternative_impl<I, variant<T...>, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const>: public detail::variant_alternative_impl<I, variant<T...> const, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> volatile>: public detail::variant_alternative_impl<I, variant<T...> volatile, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const volatile>: public detail::variant_alternative_impl<I, variant<T...> const volatile, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...>&>: public detail::variant_alternative_impl<I, variant<T...>&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const&>: public detail::variant_alternative_impl<I, variant<T...> const&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> volatile&>: public detail::variant_alternative_impl<I, variant<T...> volatile&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const volatile&>: public detail::variant_alternative_impl<I, variant<T...> const volatile&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...>&&>: public detail::variant_alternative_impl<I, variant<T...>&&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const&&>: public detail::variant_alternative_impl<I, variant<T...> const&&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> volatile&&>: public detail::variant_alternative_impl<I, variant<T...> volatile&&, (I < sizeof...(T))> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...> const volatile&&>: public detail::variant_alternative_impl<I, variant<T...> const volatile&&, (I < sizeof...(T))> -{ -}; - -#else - -namespace detail -{ - -#if defined( BOOST_MP11_VERSION ) && BOOST_MP11_VERSION >= 107000 - -template<class I, class T, class Q> using var_alt_impl = mp11::mp_invoke_q<Q, variant_alternative_t<I::value, T>>; - -#else - -template<class I, class T, class Q> using var_alt_impl = mp11::mp_invoke<Q, variant_alternative_t<I::value, T>>; - -#endif - -} // namespace detail - -template<std::size_t I, class T> struct variant_alternative -{ -}; - -template<std::size_t I, class T> struct variant_alternative<I, T const>: mp11::mp_defer<detail::var_alt_impl, mp11::mp_size_t<I>, T, mp11::mp_quote_trait<std::add_const>> -{ -}; - -template<std::size_t I, class T> struct variant_alternative<I, T volatile>: mp11::mp_defer<detail::var_alt_impl, mp11::mp_size_t<I>, T, mp11::mp_quote_trait<std::add_volatile>> -{ -}; - -template<std::size_t I, class T> struct variant_alternative<I, T const volatile>: mp11::mp_defer<detail::var_alt_impl, mp11::mp_size_t<I>, T, mp11::mp_quote_trait<std::add_cv>> -{ -}; - -template<std::size_t I, class T> struct variant_alternative<I, T&>: mp11::mp_defer<detail::var_alt_impl, mp11::mp_size_t<I>, T, mp11::mp_quote_trait<std::add_lvalue_reference>> -{ -}; - -template<std::size_t I, class T> struct variant_alternative<I, T&&>: mp11::mp_defer<detail::var_alt_impl, mp11::mp_size_t<I>, T, mp11::mp_quote_trait<std::add_rvalue_reference>> -{ -}; - -template<std::size_t I, class... T> struct variant_alternative<I, variant<T...>>: mp11::mp_defer<mp11::mp_at, variant<T...>, mp11::mp_size_t<I>> -{ -}; - -#endif - -// variant_npos - -constexpr std::size_t variant_npos = ~static_cast<std::size_t>( 0 ); - -// holds_alternative - -template<class U, class... T> constexpr bool holds_alternative( variant<T...> const& v ) noexcept -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - return v.index() == mp11::mp_find<variant<T...>, U>::value; -} - -// get (index) - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>>& get(variant<T...>& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return ( v.index() != I? detail::throw_bad_variant_access(): (void)0 ), v._get_impl( mp11::mp_size_t<I>() ); -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>>&& get(variant<T...>&& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1930) - - return ( v.index() != I? detail::throw_bad_variant_access(): (void)0 ), std::move( v._get_impl( mp11::mp_size_t<I>() ) ); - -#else - - if( v.index() != I ) detail::throw_bad_variant_access(); - return std::move( v._get_impl( mp11::mp_size_t<I>() ) ); - -#endif -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>> const& get(variant<T...> const& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return ( v.index() != I? detail::throw_bad_variant_access(): (void)0 ), v._get_impl( mp11::mp_size_t<I>() ); -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>> const&& get(variant<T...> const&& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1930) - - return ( v.index() != I? detail::throw_bad_variant_access(): (void)0 ), std::move( v._get_impl( mp11::mp_size_t<I>() ) ); - -#else - - if( v.index() != I ) detail::throw_bad_variant_access(); - return std::move( v._get_impl( mp11::mp_size_t<I>() ) ); - -#endif -} - -// detail::unsafe_get (for visit) - -namespace detail -{ - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>>& unsafe_get(variant<T...>& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return v._get_impl( mp11::mp_size_t<I>() ); -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>>&& unsafe_get(variant<T...>&& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return std::move( v._get_impl( mp11::mp_size_t<I>() ) ); -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>> const& unsafe_get(variant<T...> const& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return v._get_impl( mp11::mp_size_t<I>() ); -} - -template<std::size_t I, class... T> constexpr variant_alternative_t<I, variant<T...>> const&& unsafe_get(variant<T...> const&& v) -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return std::move( v._get_impl( mp11::mp_size_t<I>() ) ); -} - -} // namespace detail - -// get (type) - -template<class U, class... T> constexpr U& get(variant<T...>& v) -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - - return ( v.index() != I::value? detail::throw_bad_variant_access(): (void)0 ), v._get_impl( I() ); -} - -template<class U, class... T> constexpr U&& get(variant<T...>&& v) -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1930) - - return ( v.index() != I::value? detail::throw_bad_variant_access(): (void)0 ), std::move( v._get_impl( I() ) ); - -#else - - if( v.index() != I::value ) detail::throw_bad_variant_access(); - return std::move( v._get_impl( I() ) ); - -#endif -} - -template<class U, class... T> constexpr U const& get(variant<T...> const& v) -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - - return ( v.index() != I::value? detail::throw_bad_variant_access(): (void)0 ), v._get_impl( I() ); -} - -template<class U, class... T> constexpr U const&& get(variant<T...> const&& v) -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1930) - - return ( v.index() != I::value? detail::throw_bad_variant_access(): (void)0 ), std::move( v._get_impl( I() ) ); - -#else - - if( v.index() != I::value ) detail::throw_bad_variant_access(); - return std::move( v._get_impl( I() ) ); - -#endif -} - -// get_if - -template<std::size_t I, class... T> constexpr typename std::add_pointer<variant_alternative_t<I, variant<T...>>>::type get_if(variant<T...>* v) noexcept -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return v && v->index() == I? &v->_get_impl( mp11::mp_size_t<I>() ): 0; -} - -template<std::size_t I, class... T> constexpr typename std::add_pointer<const variant_alternative_t<I, variant<T...>>>::type get_if(variant<T...> const * v) noexcept -{ - static_assert( I < sizeof...(T), "Index out of bounds" ); - return v && v->index() == I? &v->_get_impl( mp11::mp_size_t<I>() ): 0; -} - -template<class U, class... T> constexpr typename std::add_pointer<U>::type get_if(variant<T...>* v) noexcept -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - - return v && v->index() == I::value? &v->_get_impl( I() ): 0; -} - -template<class U, class... T> constexpr typename std::add_pointer<U const>::type get_if(variant<T...> const * v) noexcept -{ - static_assert( mp11::mp_count<variant<T...>, U>::value == 1, "The type must occur exactly once in the list of variant alternatives" ); - - using I = mp11::mp_find<variant<T...>, U>; - - return v && v->index() == I::value? &v->_get_impl( I() ): 0; -} - -// - -namespace detail -{ - -// trivially_* - -#if defined( BOOST_LIBSTDCXX_VERSION ) && BOOST_LIBSTDCXX_VERSION < 50000 - -template<class T> struct is_trivially_copy_constructible: mp11::mp_bool<std::is_copy_constructible<T>::value && std::has_trivial_copy_constructor<T>::value> -{ -}; - -template<class T> struct is_trivially_copy_assignable: mp11::mp_bool<std::is_copy_assignable<T>::value && std::has_trivial_copy_assign<T>::value> -{ -}; - -template<class T> struct is_trivially_move_constructible: mp11::mp_bool<std::is_move_constructible<T>::value && std::is_trivial<T>::value> -{ -}; - -template<class T> struct is_trivially_move_assignable: mp11::mp_bool<std::is_move_assignable<T>::value && std::is_trivial<T>::value> -{ -}; - -#else - -using std::is_trivially_copy_constructible; -using std::is_trivially_copy_assignable; -using std::is_trivially_move_constructible; -using std::is_trivially_move_assignable; - -#endif - -// variant_storage - -template<class D, class... T> union variant_storage_impl; - -template<class... T> using variant_storage = variant_storage_impl<mp11::mp_all<std::is_trivially_destructible<T>...>, T...>; - -template<class D> union variant_storage_impl<D> -{ -}; - -// not all trivially destructible -template<class T1, class... T> union variant_storage_impl<mp11::mp_false, T1, T...> -{ - T1 first_; - variant_storage<T...> rest_; - - template<class... A> constexpr explicit variant_storage_impl( mp11::mp_size_t<0>, A&&... a ): first_( std::forward<A>(a)... ) - { - } - - template<std::size_t I, class... A> constexpr explicit variant_storage_impl( mp11::mp_size_t<I>, A&&... a ): rest_( mp11::mp_size_t<I-1>(), std::forward<A>(a)... ) - { - } - - ~variant_storage_impl() - { - } - - template<class... A> void emplace( mp11::mp_size_t<0>, A&&... a ) - { - ::new( &first_ ) T1( std::forward<A>(a)... ); - } - - template<std::size_t I, class... A> void emplace( mp11::mp_size_t<I>, A&&... a ) - { - rest_.emplace( mp11::mp_size_t<I-1>(), std::forward<A>(a)... ); - } - - BOOST_CXX14_CONSTEXPR T1& get( mp11::mp_size_t<0> ) noexcept { return first_; } - constexpr T1 const& get( mp11::mp_size_t<0> ) const noexcept { return first_; } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<mp11::mp_list<T...>, I-1>& get( mp11::mp_size_t<I> ) noexcept { return rest_.get( mp11::mp_size_t<I-1>() ); } - template<std::size_t I> constexpr mp11::mp_at_c<mp11::mp_list<T...>, I-1> const& get( mp11::mp_size_t<I> ) const noexcept { return rest_.get( mp11::mp_size_t<I-1>() ); } -}; - -// all trivially destructible -template<class T1, class... T> union variant_storage_impl<mp11::mp_true, T1, T...> -{ - T1 first_; - variant_storage<T...> rest_; - - template<class... A> constexpr explicit variant_storage_impl( mp11::mp_size_t<0>, A&&... a ): first_( std::forward<A>(a)... ) - { - } - - template<std::size_t I, class... A> constexpr explicit variant_storage_impl( mp11::mp_size_t<I>, A&&... a ): rest_( mp11::mp_size_t<I-1>(), std::forward<A>(a)... ) - { - } - - template<class... A> void emplace_impl( mp11::mp_false, mp11::mp_size_t<0>, A&&... a ) - { - ::new( &first_ ) T1( std::forward<A>(a)... ); - } - - template<std::size_t I, class... A> BOOST_CXX14_CONSTEXPR void emplace_impl( mp11::mp_false, mp11::mp_size_t<I>, A&&... a ) - { - rest_.emplace( mp11::mp_size_t<I-1>(), std::forward<A>(a)... ); - } - - template<std::size_t I, class... A> BOOST_CXX14_CONSTEXPR void emplace_impl( mp11::mp_true, mp11::mp_size_t<I>, A&&... a ) - { - *this = variant_storage_impl( mp11::mp_size_t<I>(), std::forward<A>(a)... ); - } - - template<std::size_t I, class... A> BOOST_CXX14_CONSTEXPR void emplace( mp11::mp_size_t<I>, A&&... a ) - { - this->emplace_impl( mp11::mp_all<detail::is_trivially_move_assignable<T1>, detail::is_trivially_move_assignable<T>...>(), mp11::mp_size_t<I>(), std::forward<A>(a)... ); - } - - BOOST_CXX14_CONSTEXPR T1& get( mp11::mp_size_t<0> ) noexcept { return first_; } - constexpr T1 const& get( mp11::mp_size_t<0> ) const noexcept { return first_; } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<mp11::mp_list<T...>, I-1>& get( mp11::mp_size_t<I> ) noexcept { return rest_.get( mp11::mp_size_t<I-1>() ); } - template<std::size_t I> constexpr mp11::mp_at_c<mp11::mp_list<T...>, I-1> const& get( mp11::mp_size_t<I> ) const noexcept { return rest_.get( mp11::mp_size_t<I-1>() ); } -}; - -// resolve_overload_* - -template<class... T> struct overload; - -template<> struct overload<> -{ - void operator()() const; -}; - -template<class T1, class... T> struct overload<T1, T...>: overload<T...> -{ - using overload<T...>::operator(); - mp11::mp_identity<T1> operator()(T1) const; -}; - -#if BOOST_WORKAROUND( BOOST_MSVC, < 1930 ) - -template<class U, class... T> using resolve_overload_type_ = decltype( overload<T...>()(std::declval<U>()) ); - -template<class U, class... T> struct resolve_overload_type_impl: mp11::mp_defer< resolve_overload_type_, U, T... > -{ -}; - -template<class U, class... T> using resolve_overload_type = typename resolve_overload_type_impl<U, T...>::type::type; - -#else - -template<class U, class... T> using resolve_overload_type = typename decltype( overload<T...>()(std::declval<U>()) )::type; - -#endif - -template<class U, class... T> using resolve_overload_index = mp11::mp_find<mp11::mp_list<T...>, resolve_overload_type<U, T...>>; - -// variant_base - -template<bool is_trivially_destructible, bool is_single_buffered, class... T> struct variant_base_impl; -template<class... T> using variant_base = variant_base_impl<mp11::mp_all<std::is_trivially_destructible<T>...>::value, mp11::mp_all<std::is_nothrow_move_constructible<T>...>::value, T...>; - -struct none {}; - -// trivially destructible, single buffered -template<class... T> struct variant_base_impl<true, true, T...> -{ - int ix_; - variant_storage<none, T...> st1_; - - constexpr variant_base_impl(): ix_( 0 ), st1_( mp11::mp_size_t<0>() ) - { - } - - template<class I, class... A> constexpr explicit variant_base_impl( I, A&&... a ): ix_( I::value + 1 ), st1_( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ) - { - } - - // requires: ix_ == 0 - template<class I, class... A> void _replace( I, A&&... a ) - { - ::new( &st1_ ) variant_storage<none, T...>( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ); - ix_ = I::value + 1; - } - - constexpr std::size_t index() const noexcept - { - return ix_ - 1; - } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<variant<T...>, I>& _get_impl( mp11::mp_size_t<I> ) noexcept - { - size_t const J = I+1; - - assert( ix_ == J ); - - return st1_.get( mp11::mp_size_t<J>() ); - } - - template<std::size_t I> constexpr mp11::mp_at_c<variant<T...>, I> const& _get_impl( mp11::mp_size_t<I> ) const noexcept - { - // size_t const J = I+1; - // assert( ix_ == I+1 ); - - return st1_.get( mp11::mp_size_t<I+1>() ); - } - - template<std::size_t J, class U, class... A> BOOST_CXX14_CONSTEXPR void emplace_impl( mp11::mp_true, A&&... a ) - { - static_assert( std::is_nothrow_constructible<U, A&&...>::value, "Logic error: U must be nothrow constructible from A&&..." ); - - st1_.emplace( mp11::mp_size_t<J>(), std::forward<A>(a)... ); - ix_ = J; - } - - template<std::size_t J, class U, class... A> BOOST_CXX14_CONSTEXPR void emplace_impl( mp11::mp_false, A&&... a ) - { - static_assert( std::is_nothrow_move_constructible<U>::value, "Logic error: U must be nothrow move constructible" ); - - U tmp( std::forward<A>(a)... ); - - st1_.emplace( mp11::mp_size_t<J>(), std::move(tmp) ); - ix_ = J; - } - - template<std::size_t I, class... A> BOOST_CXX14_CONSTEXPR void emplace( A&&... a ) - { - std::size_t const J = I+1; - using U = mp11::mp_at_c<variant<T...>, I>; - - this->emplace_impl<J, U>( std::is_nothrow_constructible<U, A&&...>(), std::forward<A>(a)... ); - } -}; - -// trivially destructible, double buffered -template<class... T> struct variant_base_impl<true, false, T...> -{ - int ix_; - variant_storage<none, T...> st1_; - variant_storage<none, T...> st2_; - - constexpr variant_base_impl(): ix_( 0 ), st1_( mp11::mp_size_t<0>() ), st2_( mp11::mp_size_t<0>() ) - { - } - - template<class I, class... A> constexpr explicit variant_base_impl( I, A&&... a ): ix_( I::value + 1 ), st1_( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ), st2_( mp11::mp_size_t<0>() ) - { - } - - // requires: ix_ == 0 - template<class I, class... A> void _replace( I, A&&... a ) - { - ::new( &st1_ ) variant_storage<none, T...>( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ); - ix_ = I::value + 1; - } - - constexpr std::size_t index() const noexcept - { - return ix_ >= 0? ix_ - 1: -ix_ - 1; - } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<variant<T...>, I>& _get_impl( mp11::mp_size_t<I> ) noexcept - { - size_t const J = I+1; - - assert( ix_ == J || -ix_ == J ); - - constexpr mp11::mp_size_t<J> j{}; - return ix_ >= 0? st1_.get( j ): st2_.get( j ); - } - - template<std::size_t I> constexpr mp11::mp_at_c<variant<T...>, I> const& _get_impl( mp11::mp_size_t<I> ) const noexcept - { - // size_t const J = I+1; - // assert( ix_ == J || -ix_ == J ); - // constexpr mp_size_t<J> j{}; - - return ix_ >= 0? st1_.get( mp11::mp_size_t<I+1>() ): st2_.get( mp11::mp_size_t<I+1>() ); - } - - template<std::size_t I, class... A> BOOST_CXX14_CONSTEXPR void emplace( A&&... a ) - { - size_t const J = I+1; - - if( ix_ >= 0 ) - { - st2_.emplace( mp11::mp_size_t<J>(), std::forward<A>(a)... ); - ix_ = -static_cast<int>( J ); - } - else - { - st1_.emplace( mp11::mp_size_t<J>(), std::forward<A>(a)... ); - ix_ = J; - } - } -}; - -// not trivially destructible, single buffered -template<class... T> struct variant_base_impl<false, true, T...> -{ - int ix_; - variant_storage<none, T...> st1_; - - constexpr variant_base_impl(): ix_( 0 ), st1_( mp11::mp_size_t<0>() ) - { - } - - template<class I, class... A> constexpr explicit variant_base_impl( I, A&&... a ): ix_( I::value + 1 ), st1_( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ) - { - } - - // requires: ix_ == 0 - template<class I, class... A> void _replace( I, A&&... a ) - { - ::new( &st1_ ) variant_storage<none, T...>( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ); - ix_ = I::value + 1; - } - - //[&]( auto I ){ - // using U = mp_at_c<mp_list<none, T...>, I>; - // st1_.get( I ).~U(); - //} - - struct _destroy_L1 - { - variant_base_impl * this_; - - template<class I> void operator()( I ) const noexcept - { - using U = mp11::mp_at<mp11::mp_list<none, T...>, I>; - this_->st1_.get( I() ).~U(); - } - }; - - void _destroy() noexcept - { - if( ix_ > 0 ) - { - mp11::mp_with_index<1 + sizeof...(T)>( ix_, _destroy_L1{ this } ); - } - } - - ~variant_base_impl() noexcept - { - _destroy(); - } - - constexpr std::size_t index() const noexcept - { - return ix_ - 1; - } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<variant<T...>, I>& _get_impl( mp11::mp_size_t<I> ) noexcept - { - size_t const J = I+1; - - assert( ix_ == J ); - - return st1_.get( mp11::mp_size_t<J>() ); - } - - template<std::size_t I> constexpr mp11::mp_at_c<variant<T...>, I> const& _get_impl( mp11::mp_size_t<I> ) const noexcept - { - // size_t const J = I+1; - // assert( ix_ == J ); - - return st1_.get( mp11::mp_size_t<I+1>() ); - } - - template<std::size_t I, class... A> void emplace( A&&... a ) - { - size_t const J = I+1; - - using U = mp11::mp_at_c<variant<T...>, I>; - - static_assert( std::is_nothrow_move_constructible<U>::value, "Logic error: U must be nothrow move constructible" ); - - U tmp( std::forward<A>(a)... ); - - _destroy(); - - st1_.emplace( mp11::mp_size_t<J>(), std::move(tmp) ); - ix_ = J; - } -}; - -// not trivially destructible, double buffered -template<class... T> struct variant_base_impl<false, false, T...> -{ - int ix_; - variant_storage<none, T...> st1_; - variant_storage<none, T...> st2_; - - constexpr variant_base_impl(): ix_( 0 ), st1_( mp11::mp_size_t<0>() ), st2_( mp11::mp_size_t<0>() ) - { - } - - template<class I, class... A> constexpr explicit variant_base_impl( I, A&&... a ): ix_( I::value + 1 ), st1_( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ), st2_( mp11::mp_size_t<0>() ) - { - } - - // requires: ix_ == 0 - template<class I, class... A> void _replace( I, A&&... a ) - { - ::new( &st1_ ) variant_storage<none, T...>( mp11::mp_size_t<I::value + 1>(), std::forward<A>(a)... ); - ix_ = I::value + 1; - } - - //[&]( auto I ){ - // using U = mp_at_c<mp_list<none, T...>, I>; - // st1_.get( I ).~U(); - //} - - struct _destroy_L1 - { - variant_base_impl * this_; - - template<class I> void operator()( I ) const noexcept - { - using U = mp11::mp_at<mp11::mp_list<none, T...>, I>; - this_->st1_.get( I() ).~U(); - } - }; - - struct _destroy_L2 - { - variant_base_impl * this_; - - template<class I> void operator()( I ) const noexcept - { - using U = mp11::mp_at<mp11::mp_list<none, T...>, I>; - this_->st2_.get( I() ).~U(); - } - }; - - void _destroy() noexcept - { - if( ix_ > 0 ) - { - mp11::mp_with_index<1 + sizeof...(T)>( ix_, _destroy_L1{ this } ); - } - else if( ix_ < 0 ) - { - mp11::mp_with_index<1 + sizeof...(T)>( -ix_, _destroy_L2{ this } ); - } - } - - ~variant_base_impl() noexcept - { - _destroy(); - } - - constexpr std::size_t index() const noexcept - { - return ix_ >= 0? ix_ - 1: -ix_ - 1; - } - - template<std::size_t I> BOOST_CXX14_CONSTEXPR mp11::mp_at_c<variant<T...>, I>& _get_impl( mp11::mp_size_t<I> ) noexcept - { - size_t const J = I+1; - - assert( ix_ == J || -ix_ == J ); - - constexpr mp11::mp_size_t<J> j{}; - return ix_ >= 0? st1_.get( j ): st2_.get( j ); - } - - template<std::size_t I> constexpr mp11::mp_at_c<variant<T...>, I> const& _get_impl( mp11::mp_size_t<I> ) const noexcept - { - // size_t const J = I+1; - // assert( ix_ == J || -ix_ == J ); - // constexpr mp_size_t<J> j{}; - - return ix_ >= 0? st1_.get( mp11::mp_size_t<I+1>() ): st2_.get( mp11::mp_size_t<I+1>() ); - } - - template<std::size_t I, class... A> void emplace( A&&... a ) - { - size_t const J = I+1; - - if( ix_ >= 0 ) - { - st2_.emplace( mp11::mp_size_t<J>(), std::forward<A>(a)... ); - _destroy(); - - ix_ = -static_cast<int>( J ); - } - else - { - st1_.emplace( mp11::mp_size_t<J>(), std::forward<A>(a)... ); - _destroy(); - - ix_ = J; - } - } -}; - -} // namespace detail - -// in_place_type_t - -template<class T> struct in_place_type_t -{ -}; - -#if !defined(BOOST_NO_CXX14_VARIABLE_TEMPLATES) - -template<class T> constexpr in_place_type_t<T> in_place_type{}; - -#endif - -namespace detail -{ - -template<class T> struct is_in_place_type: std::false_type {}; -template<class T> struct is_in_place_type<in_place_type_t<T>>: std::true_type {}; - -} // namespace detail - -// in_place_index_t - -template<std::size_t I> struct in_place_index_t -{ -}; - -#if !defined(BOOST_NO_CXX14_VARIABLE_TEMPLATES) - -template<std::size_t I> constexpr in_place_index_t<I> in_place_index{}; - -#endif - -namespace detail -{ - -template<class T> struct is_in_place_index: std::false_type {}; -template<std::size_t I> struct is_in_place_index<in_place_index_t<I>>: std::true_type {}; - -} // namespace detail - -// is_nothrow_swappable - -namespace detail -{ - -namespace det2 -{ - -using std::swap; - -template<class T> using is_swappable_impl = decltype(swap(std::declval<T&>(), std::declval<T&>())); - -#if BOOST_WORKAROUND( BOOST_MSVC, < 1920 ) - -template<class T> struct is_nothrow_swappable_impl_ -{ - static constexpr bool value = noexcept(swap(std::declval<T&>(), std::declval<T&>())); -}; - -template<class T> using is_nothrow_swappable_impl = mp11::mp_bool< is_nothrow_swappable_impl_<T>::value >; - -#else - -template<class T> using is_nothrow_swappable_impl = typename std::enable_if<noexcept(swap(std::declval<T&>(), std::declval<T&>()))>::type; - -#endif - -} // namespace det2 - -template<class T> struct is_swappable: mp11::mp_valid<det2::is_swappable_impl, T> -{ -}; - -#if BOOST_WORKAROUND( BOOST_MSVC, < 1920 ) - -template<class T> struct is_nothrow_swappable: mp11::mp_eval_if<mp11::mp_not<is_swappable<T>>, mp11::mp_false, det2::is_nothrow_swappable_impl, T> -{ -}; - -#else - -template<class T> struct is_nothrow_swappable: mp11::mp_valid<det2::is_nothrow_swappable_impl, T> -{ -}; - -#endif - -// variant_cc_base - -template<bool CopyConstructible, bool TriviallyCopyConstructible, class... T> struct variant_cc_base_impl; - -template<class... T> using variant_cc_base = variant_cc_base_impl< - mp11::mp_all<std::is_copy_constructible<T>...>::value, - mp11::mp_all<detail::is_trivially_copy_constructible<T>...>::value, - T...>; - -template<class... T> struct variant_cc_base_impl<true, true, T...>: public variant_base<T...> -{ - using variant_base = detail::variant_base<T...>; - using variant_base::variant_base; - - variant_cc_base_impl() = default; - variant_cc_base_impl( variant_cc_base_impl const& ) = default; - variant_cc_base_impl( variant_cc_base_impl && ) = default; - variant_cc_base_impl& operator=( variant_cc_base_impl const& ) = default; - variant_cc_base_impl& operator=( variant_cc_base_impl && ) = default; -}; - -template<bool B, class... T> struct variant_cc_base_impl<false, B, T...>: public variant_base<T...> -{ - using variant_base = detail::variant_base<T...>; - using variant_base::variant_base; - - variant_cc_base_impl() = default; - variant_cc_base_impl( variant_cc_base_impl const& ) = delete; - variant_cc_base_impl( variant_cc_base_impl && ) = default; - variant_cc_base_impl& operator=( variant_cc_base_impl const& ) = default; - variant_cc_base_impl& operator=( variant_cc_base_impl && ) = default; -}; - -template<class... T> struct variant_cc_base_impl<true, false, T...>: public variant_base<T...> -{ - using variant_base = detail::variant_base<T...>; - using variant_base::variant_base; - -public: - - // constructors - - variant_cc_base_impl() = default; - - // copy constructor - -private: - - struct L1 - { - variant_base * this_; - variant_base const & r; - - template<class I> void operator()( I i ) const - { - this_->_replace( i, r._get_impl( i ) ); - } - }; - -public: - - variant_cc_base_impl( variant_cc_base_impl const& r ) - noexcept( mp11::mp_all<std::is_nothrow_copy_constructible<T>...>::value ) - : variant_base() - { - mp11::mp_with_index<sizeof...(T)>( r.index(), L1{ this, r } ); - } - - // move constructor - - variant_cc_base_impl( variant_cc_base_impl && ) = default; - - // assignment - - variant_cc_base_impl& operator=( variant_cc_base_impl const & ) = default; - variant_cc_base_impl& operator=( variant_cc_base_impl && ) = default; -}; - -// variant_ca_base - -template<bool CopyAssignable, bool TriviallyCopyAssignable, class... T> struct variant_ca_base_impl; - -template<class... T> using variant_ca_base = variant_ca_base_impl< - mp11::mp_all<std::is_copy_constructible<T>..., std::is_copy_assignable<T>...>::value, - mp11::mp_all<std::is_trivially_destructible<T>..., detail::is_trivially_copy_constructible<T>..., detail::is_trivially_copy_assignable<T>...>::value, - T...>; - -template<class... T> struct variant_ca_base_impl<true, true, T...>: public variant_cc_base<T...> -{ - using variant_base = detail::variant_cc_base<T...>; - using variant_base::variant_base; - - variant_ca_base_impl() = default; - variant_ca_base_impl( variant_ca_base_impl const& ) = default; - variant_ca_base_impl( variant_ca_base_impl && ) = default; - variant_ca_base_impl& operator=( variant_ca_base_impl const& ) = default; - variant_ca_base_impl& operator=( variant_ca_base_impl && ) = default; -}; - -template<bool B, class... T> struct variant_ca_base_impl<false, B, T...>: public variant_cc_base<T...> -{ - using variant_base = detail::variant_cc_base<T...>; - using variant_base::variant_base; - - variant_ca_base_impl() = default; - variant_ca_base_impl( variant_ca_base_impl const& ) = default; - variant_ca_base_impl( variant_ca_base_impl && ) = default; - variant_ca_base_impl& operator=( variant_ca_base_impl const& ) = delete; - variant_ca_base_impl& operator=( variant_ca_base_impl && ) = default; -}; - -template<class... T> struct variant_ca_base_impl<true, false, T...>: public variant_cc_base<T...> -{ - using variant_base = detail::variant_cc_base<T...>; - using variant_base::variant_base; - -public: - - // constructors - - variant_ca_base_impl() = default; - variant_ca_base_impl( variant_ca_base_impl const& ) = default; - variant_ca_base_impl( variant_ca_base_impl && ) = default; - - // copy assignment - -private: - - struct L3 - { - variant_base * this_; - variant_base const & r; - - template<class I> void operator()( I i ) const - { - this_->template emplace<I::value>( r._get_impl( i ) ); - } - }; - -public: - - BOOST_CXX14_CONSTEXPR variant_ca_base_impl& operator=( variant_ca_base_impl const & r ) - noexcept( mp11::mp_all<std::is_nothrow_copy_constructible<T>...>::value ) - { - mp11::mp_with_index<sizeof...(T)>( r.index(), L3{ this, r } ); - return *this; - } - - // move assignment - - variant_ca_base_impl& operator=( variant_ca_base_impl && ) = default; -}; - -// variant_mc_base - -template<bool MoveConstructible, bool TriviallyMoveConstructible, class... T> struct variant_mc_base_impl; - -template<class... T> using variant_mc_base = variant_mc_base_impl< - mp11::mp_all<std::is_move_constructible<T>...>::value, - mp11::mp_all<detail::is_trivially_move_constructible<T>...>::value, - T...>; - -template<class... T> struct variant_mc_base_impl<true, true, T...>: public variant_ca_base<T...> -{ - using variant_base = detail::variant_ca_base<T...>; - using variant_base::variant_base; - - variant_mc_base_impl() = default; - variant_mc_base_impl( variant_mc_base_impl const& ) = default; - variant_mc_base_impl( variant_mc_base_impl && ) = default; - variant_mc_base_impl& operator=( variant_mc_base_impl const& ) = default; - variant_mc_base_impl& operator=( variant_mc_base_impl && ) = default; -}; - -template<bool B, class... T> struct variant_mc_base_impl<false, B, T...>: public variant_ca_base<T...> -{ - using variant_base = detail::variant_ca_base<T...>; - using variant_base::variant_base; - - variant_mc_base_impl() = default; - variant_mc_base_impl( variant_mc_base_impl const& ) = default; - variant_mc_base_impl( variant_mc_base_impl && ) = delete; - variant_mc_base_impl& operator=( variant_mc_base_impl const& ) = default; - variant_mc_base_impl& operator=( variant_mc_base_impl && ) = default; -}; - -template<class... T> struct variant_mc_base_impl<true, false, T...>: public variant_ca_base<T...> -{ - using variant_base = detail::variant_ca_base<T...>; - using variant_base::variant_base; - -public: - - // constructors - - variant_mc_base_impl() = default; - variant_mc_base_impl( variant_mc_base_impl const& ) = default; - - // move constructor - -private: - - struct L2 - { - variant_base * this_; - variant_base & r; - - template<class I> void operator()( I i ) const - { - this_->_replace( i, std::move( r._get_impl( i ) ) ); - } - }; - -public: - - variant_mc_base_impl( variant_mc_base_impl && r ) - noexcept( mp11::mp_all<std::is_nothrow_move_constructible<T>...>::value ) - { - mp11::mp_with_index<sizeof...(T)>( r.index(), L2{ this, r } ); - } - - // assignment - - variant_mc_base_impl& operator=( variant_mc_base_impl const & ) = default; - variant_mc_base_impl& operator=( variant_mc_base_impl && ) = default; -}; - -// variant_ma_base - -template<bool MoveAssignable, bool TriviallyMoveAssignable, class... T> struct variant_ma_base_impl; - -template<class... T> using variant_ma_base = variant_ma_base_impl< - mp11::mp_all<std::is_move_constructible<T>..., std::is_move_assignable<T>...>::value, - mp11::mp_all<std::is_trivially_destructible<T>..., detail::is_trivially_move_constructible<T>..., detail::is_trivially_move_assignable<T>...>::value, - T...>; - -template<class... T> struct variant_ma_base_impl<true, true, T...>: public variant_mc_base<T...> -{ - using variant_base = detail::variant_mc_base<T...>; - using variant_base::variant_base; - - variant_ma_base_impl() = default; - variant_ma_base_impl( variant_ma_base_impl const& ) = default; - variant_ma_base_impl( variant_ma_base_impl && ) = default; - variant_ma_base_impl& operator=( variant_ma_base_impl const& ) = default; - variant_ma_base_impl& operator=( variant_ma_base_impl && ) = default; -}; - -template<bool B, class... T> struct variant_ma_base_impl<false, B, T...>: public variant_mc_base<T...> -{ - using variant_base = detail::variant_mc_base<T...>; - using variant_base::variant_base; - - variant_ma_base_impl() = default; - variant_ma_base_impl( variant_ma_base_impl const& ) = default; - variant_ma_base_impl( variant_ma_base_impl && ) = default; - variant_ma_base_impl& operator=( variant_ma_base_impl const& ) = default; - variant_ma_base_impl& operator=( variant_ma_base_impl && ) = delete; -}; - -template<class... T> struct variant_ma_base_impl<true, false, T...>: public variant_mc_base<T...> -{ - using variant_base = detail::variant_mc_base<T...>; - using variant_base::variant_base; - -public: - - // constructors - - variant_ma_base_impl() = default; - variant_ma_base_impl( variant_ma_base_impl const& ) = default; - variant_ma_base_impl( variant_ma_base_impl && ) = default; - - // copy assignment - - variant_ma_base_impl& operator=( variant_ma_base_impl const & ) = default; - - // move assignment - -private: - - struct L4 - { - variant_base * this_; - variant_base & r; - - template<class I> void operator()( I i ) const - { - this_->template emplace<I::value>( std::move( r._get_impl( i ) ) ); - } - }; - -public: - - variant_ma_base_impl& operator=( variant_ma_base_impl && r ) - noexcept( mp11::mp_all<std::is_nothrow_move_constructible<T>...>::value ) - { - mp11::mp_with_index<sizeof...(T)>( r.index(), L4{ this, r } ); - return *this; - } -}; - -} // namespace detail - -// variant - -template<class... T> class variant: private detail::variant_ma_base<T...> -{ -private: - - using variant_base = detail::variant_ma_base<T...>; - -public: - - // constructors - - template<class E1 = void, class E2 = mp11::mp_if<std::is_default_constructible< mp11::mp_first<variant<T...>> >, E1>> - constexpr variant() - noexcept( std::is_nothrow_default_constructible< mp11::mp_first<variant<T...>> >::value ) - : variant_base( mp11::mp_size_t<0>() ) - { - } - - // variant( variant const& ) = default; - // variant( variant && ) = default; - - template<class U, - class Ud = typename std::decay<U>::type, - class E1 = typename std::enable_if< !std::is_same<Ud, variant>::value && !detail::is_in_place_index<Ud>::value && !detail::is_in_place_type<Ud>::value >::type, - class V = detail::resolve_overload_type<U&&, T...>, - class E2 = typename std::enable_if<std::is_constructible<V, U&&>::value>::type - > - constexpr variant( U&& u ) - noexcept( std::is_nothrow_constructible<V, U&&>::value ) - : variant_base( detail::resolve_overload_index<U&&, T...>(), std::forward<U>(u) ) - { - } - - template<class U, class... A, class I = mp11::mp_find<variant<T...>, U>, class E = typename std::enable_if<std::is_constructible<U, A&&...>::value>::type> - constexpr explicit variant( in_place_type_t<U>, A&&... a ): variant_base( I(), std::forward<A>(a)... ) - { - } - - template<class U, class V, class... A, class I = mp11::mp_find<variant<T...>, U>, class E = typename std::enable_if<std::is_constructible<U, std::initializer_list<V>&, A&&...>::value>::type> - constexpr explicit variant( in_place_type_t<U>, std::initializer_list<V> il, A&&... a ): variant_base( I(), il, std::forward<A>(a)... ) - { - } - - template<std::size_t I, class... A, class E = typename std::enable_if<std::is_constructible<mp11::mp_at_c<variant<T...>, I>, A&&...>::value>::type> - constexpr explicit variant( in_place_index_t<I>, A&&... a ): variant_base( mp11::mp_size_t<I>(), std::forward<A>(a)... ) - { - } - - template<std::size_t I, class V, class... A, class E = typename std::enable_if<std::is_constructible<mp11::mp_at_c<variant<T...>, I>, std::initializer_list<V>&, A&&...>::value>::type> - constexpr explicit variant( in_place_index_t<I>, std::initializer_list<V> il, A&&... a ): variant_base( mp11::mp_size_t<I>(), il, std::forward<A>(a)... ) - { - } - - // assignment - - // variant& operator=( variant const& ) = default; - // variant& operator=( variant && ) = default; - - template<class U, - class E1 = typename std::enable_if<!std::is_same<typename std::decay<U>::type, variant>::value>::type, - class V = detail::resolve_overload_type<U, T...>, - class E2 = typename std::enable_if<std::is_assignable<V&, U&&>::value && std::is_constructible<V, U&&>::value>::type - > - BOOST_CXX14_CONSTEXPR variant& operator=( U&& u ) - noexcept( std::is_nothrow_constructible<V, U&&>::value ) - { - std::size_t const I = detail::resolve_overload_index<U, T...>::value; - this->template emplace<I>( std::forward<U>(u) ); - return *this; - } - - // modifiers - - template<class U, class... A, - class E = typename std::enable_if< mp11::mp_count<variant<T...>, U>::value == 1 && std::is_constructible<U, A&&...>::value >::type> - BOOST_CXX14_CONSTEXPR U& emplace( A&&... a ) - { - using I = mp11::mp_find<variant<T...>, U>; - variant_base::template emplace<I::value>( std::forward<A>(a)... ); - return _get_impl( I() ); - } - - template<class U, class V, class... A, - class E = typename std::enable_if< mp11::mp_count<variant<T...>, U>::value == 1 && std::is_constructible<U, std::initializer_list<V>&, A&&...>::value >::type> - BOOST_CXX14_CONSTEXPR U& emplace( std::initializer_list<V> il, A&&... a ) - { - using I = mp11::mp_find<variant<T...>, U>; - variant_base::template emplace<I::value>( il, std::forward<A>(a)... ); - return _get_impl( I() ); - } - - template<std::size_t I, class... A, class E = typename std::enable_if<std::is_constructible<mp11::mp_at_c<variant<T...>, I>, A&&...>::value>::type> - BOOST_CXX14_CONSTEXPR variant_alternative_t<I, variant<T...>>& emplace( A&&... a ) - { - variant_base::template emplace<I>( std::forward<A>(a)... ); - return _get_impl( mp11::mp_size_t<I>() ); - } - - template<std::size_t I, class V, class... A, class E = typename std::enable_if<std::is_constructible<mp11::mp_at_c<variant<T...>, I>, std::initializer_list<V>&, A&&...>::value>::type> - BOOST_CXX14_CONSTEXPR variant_alternative_t<I, variant<T...>>& emplace( std::initializer_list<V> il, A&&... a ) - { - variant_base::template emplace<I>( il, std::forward<A>(a)... ); - return _get_impl( mp11::mp_size_t<I>() ); - } - - // value status - - constexpr bool valueless_by_exception() const noexcept - { - return false; - } - - using variant_base::index; - - // swap - -private: - - struct L5 - { - variant * this_; - variant & r; - - template<class I> void operator()( I i ) const - { - using std::swap; - swap( this_->_get_impl( i ), r._get_impl( i ) ); - } - }; - -public: - - void swap( variant& r ) noexcept( mp11::mp_all<std::is_nothrow_move_constructible<T>..., detail::is_nothrow_swappable<T>...>::value ) - { - if( index() == r.index() ) - { - mp11::mp_with_index<sizeof...(T)>( index(), L5{ this, r } ); - } - else - { - variant tmp( std::move(*this) ); - *this = std::move( r ); - r = std::move( tmp ); - } - } - - // private accessors - - using variant_base::_get_impl; - - // converting constructors (extension) - -private: - - template<class... U> struct L6 - { - variant_base * this_; - variant<U...> const & r; - - template<class I> void operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<T...>, mp11::mp_at<mp11::mp_list<U...>, I>>; - this_->_replace( J{}, r._get_impl( i ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_copy_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - variant( variant<U...> const& r ) - noexcept( mp11::mp_all<std::is_nothrow_copy_constructible<U>...>::value ) - { - mp11::mp_with_index<sizeof...(U)>( r.index(), L6<U...>{ this, r } ); - } - -private: - - template<class... U> struct L7 - { - variant_base * this_; - variant<U...> & r; - - template<class I> void operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<T...>, mp11::mp_at<mp11::mp_list<U...>, I>>; - this_->_replace( J{}, std::move( r._get_impl( i ) ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_move_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - variant( variant<U...> && r ) - noexcept( mp11::mp_all<std::is_nothrow_move_constructible<U>...>::value ) - { - mp11::mp_with_index<sizeof...(U)>( r.index(), L7<U...>{ this, r } ); - } - - // subset (extension) - -private: - - template<class... U, class V, std::size_t J, class E = typename std::enable_if<J != sizeof...(U)>::type> static constexpr variant<U...> _subset_impl( mp11::mp_size_t<J>, V && v ) - { - return variant<U...>( in_place_index_t<J>(), std::forward<V>(v) ); - } - - template<class... U, class V> static variant<U...> _subset_impl( mp11::mp_size_t<sizeof...(U)>, V && /*v*/ ) - { - detail::throw_bad_variant_access(); - } - -private: - - template<class... U> struct L8 - { - variant * this_; - - template<class I> variant<U...> operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<U...>, mp11::mp_at<mp11::mp_list<T...>, I>>; - return this_->_subset_impl<U...>( J{}, this_->_get_impl( i ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_copy_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - BOOST_CXX14_CONSTEXPR variant<U...> subset() & - { - return mp11::mp_with_index<sizeof...(T)>( index(), L8<U...>{ this } ); - } - -private: - - template<class... U> struct L9 - { - variant const * this_; - - template<class I> variant<U...> operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<U...>, mp11::mp_at<mp11::mp_list<T...>, I>>; - return this_->_subset_impl<U...>( J{}, this_->_get_impl( i ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_copy_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - constexpr variant<U...> subset() const& - { - return mp11::mp_with_index<sizeof...(T)>( index(), L9<U...>{ this } ); - } - -private: - - template<class... U> struct L10 - { - variant * this_; - - template<class I> variant<U...> operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<U...>, mp11::mp_at<mp11::mp_list<T...>, I>>; - return this_->_subset_impl<U...>( J{}, std::move( this_->_get_impl( i ) ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_copy_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - BOOST_CXX14_CONSTEXPR variant<U...> subset() && - { - return mp11::mp_with_index<sizeof...(T)>( index(), L10<U...>{ this } ); - } - -#if !BOOST_WORKAROUND(BOOST_GCC, < 40900) - - // g++ 4.8 doesn't handle const&& particularly well - -private: - - template<class... U> struct L11 - { - variant const * this_; - - template<class I> variant<U...> operator()( I i ) const - { - using J = mp11::mp_find<mp11::mp_list<U...>, mp11::mp_at<mp11::mp_list<T...>, I>>; - return this_->_subset_impl<U...>( J{}, std::move( this_->_get_impl( i ) ) ); - } - }; - -public: - - template<class... U, - class E2 = mp11::mp_if<mp11::mp_all<std::is_copy_constructible<U>..., mp11::mp_contains<mp11::mp_list<T...>, U>...>, void> > - constexpr variant<U...> subset() const&& - { - return mp11::mp_with_index<sizeof...(T)>( index(), L11<U...>{ this } ); - } - -#endif -}; - -// relational operators - -namespace detail -{ - -template<class... T> struct eq_L -{ - variant<T...> const & v; - variant<T...> const & w; - - template<class I> constexpr bool operator()( I i ) const - { - return v._get_impl( i ) == w._get_impl( i ); - } -}; - -} // namespace detail - -template<class... T> constexpr bool operator==( variant<T...> const & v, variant<T...> const & w ) -{ - return v.index() == w.index() && mp11::mp_with_index<sizeof...(T)>( v.index(), detail::eq_L<T...>{ v, w } ); -} - -namespace detail -{ - -template<class... T> struct ne_L -{ - variant<T...> const & v; - variant<T...> const & w; - - template<class I> constexpr bool operator()( I i ) const - { - return v._get_impl( i ) != w._get_impl( i ); - } -}; - -} // namespace detail - -template<class... T> constexpr bool operator!=( variant<T...> const & v, variant<T...> const & w ) -{ - return v.index() != w.index() || mp11::mp_with_index<sizeof...(T)>( v.index(), detail::ne_L<T...>{ v, w } ); -} - -namespace detail -{ - -template<class... T> struct lt_L -{ - variant<T...> const & v; - variant<T...> const & w; - - template<class I> constexpr bool operator()( I i ) const - { - return v._get_impl( i ) < w._get_impl( i ); - } -}; - -} // namespace detail - -template<class... T> constexpr bool operator<( variant<T...> const & v, variant<T...> const & w ) -{ - return v.index() < w.index() || ( v.index() == w.index() && mp11::mp_with_index<sizeof...(T)>( v.index(), detail::lt_L<T...>{ v, w } ) ); -} - -template<class... T> constexpr bool operator>( variant<T...> const & v, variant<T...> const & w ) -{ - return w < v; -} - -namespace detail -{ - -template<class... T> struct le_L -{ - variant<T...> const & v; - variant<T...> const & w; - - template<class I> constexpr bool operator()( I i ) const - { - return v._get_impl( i ) <= w._get_impl( i ); - } -}; - -} // namespace detail - -template<class... T> constexpr bool operator<=( variant<T...> const & v, variant<T...> const & w ) -{ - return v.index() < w.index() || ( v.index() == w.index() && mp11::mp_with_index<sizeof...(T)>( v.index(), detail::le_L<T...>{ v, w } ) ); -} - -template<class... T> constexpr bool operator>=( variant<T...> const & v, variant<T...> const & w ) -{ - return w <= v; -} - -// visitation -namespace detail -{ - -template<class T> using remove_cv_ref_t = typename std::remove_cv<typename std::remove_reference<T>::type>::type; - -template<class T, class U> struct copy_cv_ref -{ - using type = T; -}; - -template<class T, class U> struct copy_cv_ref<T, U const> -{ - using type = T const; -}; - -template<class T, class U> struct copy_cv_ref<T, U volatile> -{ - using type = T volatile; -}; - -template<class T, class U> struct copy_cv_ref<T, U const volatile> -{ - using type = T const volatile; -}; - -template<class T, class U> struct copy_cv_ref<T, U&> -{ - using type = typename copy_cv_ref<T, U>::type&; -}; - -template<class T, class U> struct copy_cv_ref<T, U&&> -{ - using type = typename copy_cv_ref<T, U>::type&&; -}; - -template<class T, class U> using copy_cv_ref_t = typename copy_cv_ref<T, U>::type; - -template<class F> struct Qret -{ - template<class... T> using fn = decltype( std::declval<F>()( std::declval<T>()... ) ); -}; - -template<class L> using front_if_same = mp11::mp_if<mp11::mp_apply<mp11::mp_same, L>, mp11::mp_front<L>>; - -template<class V> using apply_cv_ref = mp11::mp_product<copy_cv_ref_t, remove_cv_ref_t<V>, mp11::mp_list<V>>; - -template<class F, class... V> using Vret = front_if_same<mp11::mp_product_q<Qret<F>, apply_cv_ref<V>...>>; - -} // namespace detail - -template<class F> constexpr auto visit( F&& f ) -> decltype(std::forward<F>(f)()) -{ - return std::forward<F>(f)(); -} - -namespace detail -{ - -template<class F, class V1> struct visit_L1 -{ - F&& f; - V1&& v1; - - template<class I> auto operator()( I ) const -> Vret<F, V1> - { - return std::forward<F>(f)( unsafe_get<I::value>( std::forward<V1>(v1) ) ); - } -}; - -} // namespace detail - -template<class F, class V1> constexpr auto visit( F&& f, V1&& v1 ) -> detail::Vret<F, V1> -{ - return mp11::mp_with_index<variant_size<V1>>( v1.index(), detail::visit_L1<F, V1>{ std::forward<F>(f), std::forward<V1>(v1) } ); -} - -#if defined(BOOST_NO_CXX14_GENERIC_LAMBDAS) || BOOST_WORKAROUND( BOOST_MSVC, < 1920 ) - -namespace detail -{ - -template<class F, class A> struct bind_front_ -{ - F&& f; - A&& a; - - template<class... T> auto operator()( T&&... t ) -> decltype( std::forward<F>(f)( std::forward<A>(a), std::forward<T>(t)... ) ) - { - return std::forward<F>(f)( std::forward<A>(a), std::forward<T>(t)... ); - } -}; - -template<class F, class A> bind_front_<F, A> bind_front( F&& f, A&& a ) -{ - return bind_front_<F, A>{ std::forward<F>(f), std::forward<A>(a) }; -} - -template<class F, class V1, class V2> struct visit_L2 -{ - F&& f; - - V1&& v1; - V2&& v2; - - template<class I> auto operator()( I ) const -> Vret<F, V1, V2> - { - auto f2 = bind_front( std::forward<F>(f), unsafe_get<I::value>( std::forward<V1>(v1) ) ); - return visit( f2, std::forward<V2>(v2) ); - } -}; - -} // namespace detail - -template<class F, class V1, class V2> constexpr auto visit( F&& f, V1&& v1, V2&& v2 ) -> detail::Vret<F, V1, V2> -{ - return mp11::mp_with_index<variant_size<V1>>( v1.index(), detail::visit_L2<F, V1, V2>{ std::forward<F>(f), std::forward<V1>(v1), std::forward<V2>(v2) } ); -} - -namespace detail -{ - -template<class F, class V1, class V2, class V3> struct visit_L3 -{ - F&& f; - - V1&& v1; - V2&& v2; - V3&& v3; - - template<class I> auto operator()( I ) const -> Vret<F, V1, V2, V3> - { - auto f2 = bind_front( std::forward<F>(f), unsafe_get<I::value>( std::forward<V1>(v1) ) ); - return visit( f2, std::forward<V2>(v2), std::forward<V3>(v3) ); - } -}; - -} // namespace detail - -template<class F, class V1, class V2, class V3> constexpr auto visit( F&& f, V1&& v1, V2&& v2, V3&& v3 ) -> detail::Vret<F, V1, V2, V3> -{ - return mp11::mp_with_index<variant_size<V1>>( v1.index(), detail::visit_L3<F, V1, V2, V3>{ std::forward<F>(f), std::forward<V1>(v1), std::forward<V2>(v2), std::forward<V3>(v3) } ); -} - -namespace detail -{ - -template<class F, class V1, class V2, class V3, class V4> struct visit_L4 -{ - F&& f; - - V1&& v1; - V2&& v2; - V3&& v3; - V4&& v4; - - template<class I> auto operator()( I ) const -> Vret<F, V1, V2, V3, V4> - { - auto f2 = bind_front( std::forward<F>(f), unsafe_get<I::value>( std::forward<V1>(v1) ) ); - return visit( f2, std::forward<V2>(v2), std::forward<V3>(v3), std::forward<V4>(v4) ); - } -}; - -} // namespace detail - -template<class F, class V1, class V2, class V3, class V4> constexpr auto visit( F&& f, V1&& v1, V2&& v2, V3&& v3, V4&& v4 ) -> detail::Vret<F, V1, V2, V3, V4> -{ - return mp11::mp_with_index<variant_size<V1>>( v1.index(), detail::visit_L4<F, V1, V2, V3, V4>{ std::forward<F>(f), std::forward<V1>(v1), std::forward<V2>(v2), std::forward<V3>(v3), std::forward<V4>(v4) } ); -} - -#else - -template<class F, class V1, class V2, class... V> constexpr auto visit( F&& f, V1&& v1, V2&& v2, V&&... v ) -> detail::Vret<F, V1, V2, V...> -{ - return mp11::mp_with_index<variant_size<V1>>( v1.index(), [&]( auto I ){ - - auto f2 = [&]( auto&&... a ){ return std::forward<F>(f)( detail::unsafe_get<I.value>( std::forward<V1>(v1) ), std::forward<decltype(a)>(a)... ); }; - return visit( f2, std::forward<V2>(v2), std::forward<V>(v)... ); - - }); -} - -#endif - -// specialized algorithms -template<class... T, - class E = typename std::enable_if<mp11::mp_all<std::is_move_constructible<T>..., detail::is_swappable<T>...>::value>::type> -void swap( variant<T...> & v, variant<T...> & w ) - noexcept( noexcept(v.swap(w)) ) -{ - v.swap( w ); -} - -// hashing support - -namespace detail -{ - -template<class V> struct hash_value_L -{ - V const & v; - - template<class I> std::size_t operator()( I ) const - { - boost::ulong_long_type hv = ( boost::ulong_long_type( 0xCBF29CE4 ) << 32 ) + 0x84222325; - boost::ulong_long_type const prime = ( boost::ulong_long_type( 0x00000100 ) << 32 ) + 0x000001B3; - - // index - - hv ^= I::value; - hv *= prime; - - // value - - auto const & t = unsafe_get<I::value>( v ); - - hv ^= std::hash<remove_cv_ref_t<decltype(t)>>()( t ); - hv *= prime; - - return static_cast<std::size_t>( hv ); - } -}; - -} // namespace detail - -inline std::size_t hash_value( monostate const & ) -{ - return 0xA7EE4757u; -} - -template<class... T> std::size_t hash_value( variant<T...> const & v ) -{ - return mp11::mp_with_index<sizeof...(T)>( v.index(), detail::hash_value_L< variant<T...> >{ v } ); -} - -namespace detail -{ - -template<class T> using is_hash_enabled = std::is_default_constructible< std::hash<typename std::remove_const<T>::type> >; - -template<class V, bool E = mp11::mp_all_of<V, is_hash_enabled>::value> struct std_hash_impl; - -template<class V> struct std_hash_impl<V, false> -{ - std_hash_impl() = delete; - std_hash_impl( std_hash_impl const& ) = delete; - std_hash_impl& operator=( std_hash_impl const& ) = delete; -}; - -template<class V> struct std_hash_impl<V, true> -{ - std::size_t operator()( V const & v ) const - { - return hash_value( v ); - } -}; - -} // namespace detail - -} // namespace variant2 -} // namespace boost - -namespace std -{ - -template<class... T> struct hash< ::boost::variant2::variant<T...> >: public ::boost::variant2::detail::std_hash_impl< ::boost::variant2::variant<T...> > -{ -}; - -template<> struct hash< ::boost::variant2::monostate > -{ - std::size_t operator()( ::boost::variant2::monostate const & v ) const - { - return hash_value( v ); - } -}; - -} // namespace std - -#if defined(_MSC_VER) && _MSC_VER < 1910 -# pragma warning( pop ) -#endif - -#endif // #ifndef BOOST_VARIANT2_VARIANT_HPP_INCLUDED diff --git a/ThirdParty/boost/version.hpp b/ThirdParty/boost/version.hpp deleted file mode 100644 index ce7aa4d6f0cb80ca88ae4ab0b27ce098fd3f2d48..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/version.hpp +++ /dev/null @@ -1,32 +0,0 @@ -// Boost version.hpp configuration header file ------------------------------// - -// (C) Copyright John maddock 1999. 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) - -// See http://www.boost.org/libs/config for documentation - -#ifndef BOOST_VERSION_HPP -#define BOOST_VERSION_HPP - -// -// Caution: this is the only Boost header that is guaranteed -// to change with every Boost release. Including this header -// will cause a recompile every time a new Boost version is -// used. -// -// BOOST_VERSION % 100 is the patch level -// BOOST_VERSION / 100 % 1000 is the minor version -// BOOST_VERSION / 100000 is the major version - -#define BOOST_VERSION 107300 - -// -// BOOST_LIB_VERSION must be defined to be the same as BOOST_VERSION -// but as a *string* in the form "x_y[_z]" where x is the major version -// number, y is the minor version number, and z is the patch level if not 0. -// This is used by <config/auto_link.hpp> to select which library version to link to. - -#define BOOST_LIB_VERSION "1_73" - -#endif diff --git a/ThirdParty/boost/winapi/basic_types.hpp b/ThirdParty/boost/winapi/basic_types.hpp deleted file mode 100644 index 4a0ca3cb63cfcfabc73201b377efed328aa46464..0000000000000000000000000000000000000000 --- a/ThirdParty/boost/winapi/basic_types.hpp +++ /dev/null @@ -1,289 +0,0 @@ -/* - * Copyright 2010 Vicente J. Botet Escriba - * Copyright 2015-2018 Andrey Semashev - * - * Distributed under the Boost Software License, Version 1.0. - * See http://www.boost.org/LICENSE_1_0.txt - */ - -#ifndef BOOST_WINAPI_BASIC_TYPES_HPP_INCLUDED_ -#define BOOST_WINAPI_BASIC_TYPES_HPP_INCLUDED_ - -#include <boost/winapi/config.hpp> - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#if defined(BOOST_USE_WINDOWS_H) -# include <windows.h> -#elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__) -# ifdef UNDER_CE -# ifndef WINAPI -# ifndef _WIN32_WCE_EMULATION -# define WINAPI __cdecl // Note this doesn't match the desktop definition -# else -# define WINAPI __stdcall -# endif -# endif -// Windows CE defines a few functions as inline functions in kfuncs.h -typedef int BOOL; -typedef unsigned long DWORD; -typedef void* HANDLE; -# include <kfuncs.h> -# endif // UNDER_CE -#else -# error "Win32 functions not available" -#endif - -#if defined(_M_IX86) || defined(__i386__) -#define BOOST_WINAPI_DETAIL_STDCALL __stdcall -#else -// On architectures other than 32-bit x86 __stdcall is ignored. Clang also issues a warning. -#define BOOST_WINAPI_DETAIL_STDCALL -#endif - -#if defined(WINAPI) -#define BOOST_WINAPI_WINAPI_CC WINAPI -#else -#define BOOST_WINAPI_WINAPI_CC BOOST_WINAPI_DETAIL_STDCALL -#endif - -#if defined(CALLBACK) -#define BOOST_WINAPI_CALLBACK_CC CALLBACK -#else -#define BOOST_WINAPI_CALLBACK_CC BOOST_WINAPI_DETAIL_STDCALL -#endif - -#if defined(NTAPI) -#define BOOST_WINAPI_NTAPI_CC NTAPI -#else -#define BOOST_WINAPI_NTAPI_CC BOOST_WINAPI_DETAIL_STDCALL -#endif - -#ifndef NO_STRICT -#ifndef STRICT -#define STRICT 1 -#endif -#endif - -#if defined(STRICT) -#define BOOST_WINAPI_DETAIL_DECLARE_HANDLE(x) struct x##__; typedef struct x##__ *x -#else -#define BOOST_WINAPI_DETAIL_DECLARE_HANDLE(x) typedef void* x -#endif - -#if !defined(BOOST_USE_WINDOWS_H) -extern "C" { -union _LARGE_INTEGER; -struct _SECURITY_ATTRIBUTES; -BOOST_WINAPI_DETAIL_DECLARE_HANDLE(HINSTANCE); -typedef HINSTANCE HMODULE; -} -#endif - -#if defined(__GNUC__) -#define BOOST_WINAPI_DETAIL_EXTENSION __extension__ -#else -#define BOOST_WINAPI_DETAIL_EXTENSION -#endif - -// MinGW64 gcc 4.8.2 fails to compile function declarations with boost::winapi::VOID_ arguments even though -// the typedef expands to void. In Windows SDK, VOID is a macro which unfolds to void. We use our own macro in such cases. -#define BOOST_WINAPI_DETAIL_VOID void - -namespace boost { -namespace winapi { -#if defined(BOOST_USE_WINDOWS_H) - -typedef ::BOOL BOOL_; -typedef ::PBOOL PBOOL_; -typedef ::LPBOOL LPBOOL_; -typedef ::BOOLEAN BOOLEAN_; -typedef ::PBOOLEAN PBOOLEAN_; -typedef ::BYTE BYTE_; -typedef ::PBYTE PBYTE_; -typedef ::LPBYTE LPBYTE_; -typedef ::UCHAR UCHAR_; -typedef ::PUCHAR PUCHAR_; -typedef ::WORD WORD_; -typedef ::PWORD PWORD_; -typedef ::LPWORD LPWORD_; -typedef ::DWORD DWORD_; -typedef ::PDWORD PDWORD_; -typedef ::LPDWORD LPDWORD_; -typedef ::HANDLE HANDLE_; -typedef ::PHANDLE PHANDLE_; -typedef ::SHORT SHORT_; -typedef ::PSHORT PSHORT_; -typedef ::USHORT USHORT_; -typedef ::PUSHORT PUSHORT_; -typedef ::INT INT_; -typedef ::PINT PINT_; -typedef ::LPINT LPINT_; -typedef ::UINT UINT_; -typedef ::PUINT PUINT_; -typedef ::LONG LONG_; -typedef ::PLONG PLONG_; -typedef ::LPLONG LPLONG_; -typedef ::ULONG ULONG_; -typedef ::PULONG PULONG_; -typedef ::LONGLONG ULONG64_; -typedef ::ULONGLONG PULONG64_; -typedef ::LONGLONG LONGLONG_; -typedef ::ULONGLONG ULONGLONG_; -typedef ::INT_PTR INT_PTR_; -typedef ::UINT_PTR UINT_PTR_; -typedef ::LONG_PTR LONG_PTR_; -typedef ::ULONG_PTR ULONG_PTR_; -typedef ::DWORD_PTR DWORD_PTR_; -typedef ::PDWORD_PTR PDWORD_PTR_; -typedef ::SIZE_T SIZE_T_; -typedef ::PSIZE_T PSIZE_T_; -typedef ::SSIZE_T SSIZE_T_; -typedef ::PSSIZE_T PSSIZE_T_; -typedef VOID VOID_; // VOID is a macro -typedef ::PVOID PVOID_; -typedef ::LPVOID LPVOID_; -typedef ::LPCVOID LPCVOID_; -typedef ::CHAR CHAR_; -typedef ::LPSTR LPSTR_; -typedef ::LPCSTR LPCSTR_; -typedef ::WCHAR WCHAR_; -typedef ::LPWSTR LPWSTR_; -typedef ::LPCWSTR LPCWSTR_; - -#else // defined( BOOST_USE_WINDOWS_H ) - -#if defined(__GNUC__) && !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) \ - && (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 -#pragma GCC diagnostic push -// ISO C++ 1998 does not support 'long long' -#pragma GCC diagnostic ignored "-Wlong-long" -#endif - -typedef int BOOL_; -typedef BOOL_* PBOOL_; -typedef BOOL_* LPBOOL_; -typedef unsigned char BYTE_; -typedef BYTE_* PBYTE_; -typedef BYTE_* LPBYTE_; -typedef unsigned char UCHAR_; -typedef UCHAR_* PUCHAR_; -typedef BYTE_ BOOLEAN_; -typedef BOOLEAN_* PBOOLEAN_; -typedef unsigned short WORD_; -typedef WORD_* PWORD_; -typedef WORD_* LPWORD_; -#if !defined(__LP64__) -typedef unsigned long DWORD_; -#else -typedef unsigned int DWORD_; -#endif -typedef DWORD_* PDWORD_; -typedef DWORD_* LPDWORD_; -typedef void* HANDLE_; -typedef void** PHANDLE_; - -typedef short SHORT_; -typedef SHORT_* PSHORT_; -typedef unsigned short USHORT_; -typedef USHORT_* PUSHORT_; -typedef int INT_; -typedef INT_* PINT_; -typedef INT_* LPINT_; -typedef unsigned int UINT_; -typedef UINT_* PUINT_; -#if !defined(__LP64__) -typedef long LONG_; -typedef unsigned long ULONG_; -#else -typedef int LONG_; -typedef unsigned int ULONG_; -#endif -typedef LONG_* PLONG_; -typedef LONG_* LPLONG_; -typedef ULONG_* PULONG_; -#if defined(BOOST_HAS_MS_INT64) -BOOST_WINAPI_DETAIL_EXTENSION typedef __int64 LONGLONG_; -BOOST_WINAPI_DETAIL_EXTENSION typedef unsigned __int64 ULONGLONG_; -#else -BOOST_WINAPI_DETAIL_EXTENSION typedef long long LONGLONG_; -BOOST_WINAPI_DETAIL_EXTENSION typedef unsigned long long ULONGLONG_; -#endif -typedef LONGLONG_ LONG64_, *PLONG64_; -typedef ULONGLONG_ ULONG64_, *PULONG64_; - -#if defined(_WIN64) -typedef LONGLONG_ INT_PTR_; -typedef ULONGLONG_ UINT_PTR_; -typedef LONGLONG_ LONG_PTR_; -typedef ULONGLONG_ ULONG_PTR_; -#else -typedef int INT_PTR_; -typedef unsigned int UINT_PTR_; -typedef long LONG_PTR_; -typedef unsigned long ULONG_PTR_; -#endif - -typedef ULONG_PTR_ DWORD_PTR_, *PDWORD_PTR_; -typedef ULONG_PTR_ SIZE_T_, *PSIZE_T_; -typedef LONG_PTR_ SSIZE_T_, *PSSIZE_T_; - -typedef void VOID_; -typedef void *PVOID_; -typedef void *LPVOID_; -typedef const void *LPCVOID_; - -typedef char CHAR_; -typedef CHAR_ *LPSTR_; -typedef const CHAR_ *LPCSTR_; - -typedef wchar_t WCHAR_; -typedef WCHAR_ *LPWSTR_; -typedef const WCHAR_ *LPCWSTR_; - -#if defined(__GNUC__) && !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) \ - && (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 -#pragma GCC diagnostic pop -#endif - -#endif // defined( BOOST_USE_WINDOWS_H ) - -// ::NTSTATUS is defined in ntdef.h, which is not included by windows.h by default, so alwaus use LONG_ -typedef LONG_ NTSTATUS_; -typedef NTSTATUS_ *PNTSTATUS_; - -typedef ::HMODULE HMODULE_; - -#ifdef BOOST_MSVC -#pragma warning(push) -#pragma warning(disable:4201) // nonstandard extension used : nameless struct/union -#endif - -typedef union BOOST_MAY_ALIAS _LARGE_INTEGER { - BOOST_WINAPI_DETAIL_EXTENSION struct { - DWORD_ LowPart; - LONG_ HighPart; - }; - struct { - DWORD_ LowPart; - LONG_ HighPart; - } u; - LONGLONG_ QuadPart; -} LARGE_INTEGER_, *PLARGE_INTEGER_; - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -typedef struct BOOST_MAY_ALIAS _SECURITY_ATTRIBUTES { - DWORD_ nLength; - LPVOID_ lpSecurityDescriptor; - BOOL_ bInheritHandle; -} SECURITY_ATTRIBUTES_, *PSECURITY_ATTRIBUTES_, *LPSECURITY_ATTRIBUTES_; - -} -} - -#endif // BOOST_WINAPI_BASIC_TYPES_HPP_INCLUDED_ diff --git a/ThirdParty/pythia8235-stripped.tar.bz2 b/ThirdParty/pythia8235-stripped.tar.bz2 index 7c0271507db1261ad9f534da277447b3003df33f..da280f738809e54eace85622485d13492448250e 100644 Binary files a/ThirdParty/pythia8235-stripped.tar.bz2 and b/ThirdParty/pythia8235-stripped.tar.bz2 differ