update boost on linux
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -30,9 +30,9 @@
|
||||
#include <cstddef>
|
||||
#include <string>
|
||||
#include <boost/limits.hpp>
|
||||
#include <boost/mpl/bool.hpp>
|
||||
#include <boost/mpl/identity.hpp>
|
||||
#include <boost/mpl/if.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>
|
||||
@@ -90,35 +90,35 @@ namespace boost {
|
||||
// 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::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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* > >
|
||||
@@ -137,14 +137,14 @@ namespace boost {
|
||||
};
|
||||
|
||||
template < typename Char, std::size_t N >
|
||||
struct stream_char_common< boost::array< Char, N > >: public boost::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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 > >
|
||||
@@ -152,14 +152,14 @@ namespace boost {
|
||||
|
||||
#ifndef BOOST_NO_CXX11_HDR_ARRAY
|
||||
template < typename Char, std::size_t N >
|
||||
struct stream_char_common< std::array<Char, N > >: public boost::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
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 > >
|
||||
@@ -167,8 +167,8 @@ namespace boost {
|
||||
#endif
|
||||
|
||||
#ifdef BOOST_HAS_INT128
|
||||
template <> struct stream_char_common< boost::int128_type >: public boost::mpl::identity< char > {};
|
||||
template <> struct stream_char_common< boost::uint128_type >: public boost::mpl::identity< char > {};
|
||||
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)
|
||||
@@ -203,7 +203,7 @@ namespace boost {
|
||||
"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::mpl::if_c<
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
result_t::value, char, wchar_t
|
||||
>::type type;
|
||||
|
||||
@@ -236,7 +236,7 @@ namespace boost {
|
||||
"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::mpl::if_c<
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
result_t::value, char, wchar_t
|
||||
>::type type;
|
||||
|
||||
@@ -421,21 +421,21 @@ namespace boost {
|
||||
"Your compiler does not have full support for char32_t" );
|
||||
#endif
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_c<
|
||||
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::mpl::bool_
|
||||
<
|
||||
boost::is_same<char, src_char_t>::value && // source is not a wide character based type
|
||||
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::mpl::bool_
|
||||
<
|
||||
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
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2016.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -33,7 +33,7 @@
|
||||
#include <cstring>
|
||||
#include <cstdio>
|
||||
#include <boost/limits.hpp>
|
||||
#include <boost/mpl/if.hpp>
|
||||
#include <boost/type_traits/conditional.hpp>
|
||||
#include <boost/type_traits/is_pointer.hpp>
|
||||
#include <boost/static_assert.hpp>
|
||||
#include <boost/detail/workaround.hpp>
|
||||
@@ -137,13 +137,13 @@ namespace boost {
|
||||
, std::size_t CharacterBufferSize
|
||||
>
|
||||
class lexical_istream_limited_src: boost::noncopyable {
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_c<
|
||||
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::mpl::if_c<
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
RequiresStringbuffer,
|
||||
BOOST_DEDUCED_TYPENAME out_stream_helper_trait<CharT, Traits>::stringbuffer_t,
|
||||
do_not_construct_out_buffer_t
|
||||
@@ -200,18 +200,18 @@ namespace boost {
|
||||
}
|
||||
#endif
|
||||
|
||||
bool shl_char_array(CharT const* str) BOOST_NOEXCEPT {
|
||||
start = str;
|
||||
finish = start + Traits::length(str);
|
||||
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) {
|
||||
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);
|
||||
return shl_input_streamable(str_value);
|
||||
}
|
||||
|
||||
bool shl_char_array_limited(CharT const* str, std::size_t max_size) BOOST_NOEXCEPT {
|
||||
@@ -424,8 +424,8 @@ namespace boost {
|
||||
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) { return shl_char_array(str); }
|
||||
bool operator<<(char* str) { return shl_char_array(str); }
|
||||
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); }
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2016.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -24,9 +24,8 @@
|
||||
#endif
|
||||
|
||||
#include <boost/limits.hpp>
|
||||
#include <boost/mpl/eval_if.hpp>
|
||||
#include <boost/mpl/identity.hpp>
|
||||
#include <boost/mpl/if.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>
|
||||
@@ -43,8 +42,8 @@ struct detect_precision_loss
|
||||
{
|
||||
typedef Source source_type;
|
||||
typedef boost::numeric::Trunc<Source> Rounder;
|
||||
typedef BOOST_DEDUCED_TYPENAME mpl::if_<
|
||||
boost::is_arithmetic<Source>, Source, Source const&
|
||||
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 {
|
||||
@@ -66,8 +65,8 @@ template <typename Base, class Source>
|
||||
struct fake_precision_loss: public Base
|
||||
{
|
||||
typedef Source source_type ;
|
||||
typedef BOOST_DEDUCED_TYPENAME mpl::if_<
|
||||
boost::is_arithmetic<Source>, Source, Source const&
|
||||
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 {
|
||||
@@ -92,7 +91,7 @@ inline bool noexcept_numeric_convert(const Source& arg, Target& result) BOOST_NO
|
||||
detect_precision_loss<Source >
|
||||
> converter_orig_t;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_c<
|
||||
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>
|
||||
@@ -115,11 +114,12 @@ 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::mpl::eval_if_c<
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
boost::is_float<Source>::value,
|
||||
boost::mpl::identity<Source>,
|
||||
boost::type_identity<Source>,
|
||||
boost::make_unsigned<Source>
|
||||
>::type usource_t;
|
||||
>::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);
|
||||
@@ -153,7 +153,7 @@ 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::mpl::if_c<
|
||||
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) &&
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -23,7 +23,7 @@
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
#include <boost/mpl/bool.hpp>
|
||||
#include <boost/type_traits/integral_constant.hpp>
|
||||
#include <boost/type_traits/is_same.hpp>
|
||||
|
||||
namespace boost {
|
||||
@@ -34,8 +34,9 @@ namespace boost {
|
||||
template < typename T >
|
||||
struct is_character
|
||||
{
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::mpl::bool_<
|
||||
boost::is_same< T, char >::value ||
|
||||
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
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -29,7 +29,7 @@
|
||||
#include <cstring>
|
||||
#include <cstdio>
|
||||
#include <boost/limits.hpp>
|
||||
#include <boost/mpl/if.hpp>
|
||||
#include <boost/type_traits/conditional.hpp>
|
||||
#include <boost/static_assert.hpp>
|
||||
#include <boost/detail/workaround.hpp>
|
||||
|
||||
@@ -71,9 +71,9 @@ namespace boost
|
||||
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::mpl::if_c<
|
||||
(sizeof(int_type) > sizeof(T))
|
||||
, int_type
|
||||
BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
(sizeof(unsigned) > sizeof(T))
|
||||
, unsigned
|
||||
, T
|
||||
>::type m_value;
|
||||
CharT* m_finish;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Copyright Kevlin Henney, 2000-2005.
|
||||
// Copyright Alexander Nasonov, 2006-2010.
|
||||
// Copyright Antony Polukhin, 2011-2014.
|
||||
// Copyright Antony Polukhin, 2011-2019.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
@@ -23,11 +23,14 @@
|
||||
# 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::mpl::if_c<
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::conditional<
|
||||
(sizeof(TargetChar) > sizeof(SourceChar))
|
||||
, TargetChar
|
||||
, SourceChar
|
||||
|
||||
Reference in New Issue
Block a user