update boost

This commit is contained in:
2023-11-24 12:56:13 -06:00
parent cfc99971af
commit 19d727037a
9260 changed files with 849256 additions and 299957 deletions

View File

@@ -195,20 +195,11 @@ namespace boost { namespace spirit { namespace qi
};
///////////////////////////////////////////////////////////////////////
template <BOOST_SCOPED_ENUM(boost::spirit::endian::endianness) bits>
template <BOOST_SCOPED_ENUM(boost::endian::order) bits>
struct what;
template <>
struct what<boost::spirit::endian::endianness::native>
{
static std::string is()
{
return "native-endian binary";
}
};
template <>
struct what<boost::spirit::endian::endianness::little>
struct what<boost::endian::order::little>
{
static char const* is()
{
@@ -217,7 +208,7 @@ namespace boost { namespace spirit { namespace qi
};
template <>
struct what<boost::spirit::endian::endianness::big>
struct what<boost::endian::order::big>
{
static char const* is()
{
@@ -227,13 +218,13 @@ namespace boost { namespace spirit { namespace qi
}
///////////////////////////////////////////////////////////////////////////
template <typename T, BOOST_SCOPED_ENUM(boost::spirit::endian::endianness) endian, int bits>
template <typename T, BOOST_SCOPED_ENUM(boost::endian::order) endian, int bits>
struct any_binary_parser : primitive_parser<any_binary_parser<T, endian, bits> >
{
template <typename Context, typename Iterator>
struct attribute
{
typedef boost::spirit::endian::endian<endian, typename T::type,
typedef boost::endian::endian_arithmetic<endian, typename T::type,
bits> type;
};
@@ -246,7 +237,7 @@ namespace boost { namespace spirit { namespace qi
qi::skip_over(first, last, skipper);
typename attribute<Context, Iterator>::type attr_;
unsigned char* bytes = reinterpret_cast<unsigned char*>(&attr_);
unsigned char* bytes = attr_.data();
Iterator it = first;
for (unsigned int i = 0; i < sizeof(attr_); ++i)
@@ -270,7 +261,7 @@ namespace boost { namespace spirit { namespace qi
///////////////////////////////////////////////////////////////////////////
template <typename V, typename T
, BOOST_SCOPED_ENUM(boost::spirit::endian::endianness) endian, int bits>
, BOOST_SCOPED_ENUM(boost::endian::order) endian, int bits>
struct binary_lit_parser
: primitive_parser<binary_lit_parser<V, T, endian, bits> >
{
@@ -291,11 +282,7 @@ namespace boost { namespace spirit { namespace qi
{
qi::skip_over(first, last, skipper);
// Even if the endian types are not pod's (at least not in the
// definition of C++03) it seems to be safe to assume they are
// (but in C++0x the endian types _are_ PODs).
// This allows us to treat them as a sequence of consecutive bytes.
boost::spirit::endian::endian<endian, typename T::type, bits> attr_;
boost::endian::endian_arithmetic<endian, typename T::type, bits> attr_;
#if defined(BOOST_MSVC)
// warning C4244: 'argument' : conversion from 'const int' to 'foo', possible loss of data
@@ -307,7 +294,7 @@ namespace boost { namespace spirit { namespace qi
#pragma warning(pop)
#endif
unsigned char* bytes = reinterpret_cast<unsigned char*>(&attr_);
unsigned char* bytes = attr_.data();
Iterator it = first;
for (unsigned int i = 0; i < sizeof(attr_); ++i)
@@ -333,7 +320,7 @@ namespace boost { namespace spirit { namespace qi
///////////////////////////////////////////////////////////////////////////
// Parser generators: make_xxx function (objects)
///////////////////////////////////////////////////////////////////////////
template <typename T, BOOST_SCOPED_ENUM(boost::spirit::endian::endianness) endian, int bits>
template <typename T, BOOST_SCOPED_ENUM(boost::endian::order) endian, int bits>
struct make_binary_parser
{
typedef any_binary_parser<T, endian, bits> result_type;
@@ -344,7 +331,7 @@ namespace boost { namespace spirit { namespace qi
};
template <typename V, typename T
, BOOST_SCOPED_ENUM(boost::spirit::endian::endianness) endian, int bits>
, BOOST_SCOPED_ENUM(boost::endian::order) endian, int bits>
struct make_binary_lit_parser
{
typedef binary_lit_parser<V, T, endian, bits> result_type;
@@ -359,13 +346,13 @@ namespace boost { namespace spirit { namespace qi
template <typename Modifiers> \
struct make_primitive<tag::name, Modifiers> \
: make_binary_parser<detail::integer<bits>, \
boost::spirit::endian::endianness::endiantype, bits> {}; \
boost::endian::order::endiantype, bits> {}; \
\
template <typename Modifiers, typename A0> \
struct make_primitive< \
terminal_ex<tag::name, fusion::vector1<A0> > , Modifiers> \
: make_binary_lit_parser<A0, detail::integer<bits>, \
boost::spirit::endian::endianness::endiantype, bits> {}; \
boost::endian::order::endiantype, bits> {}; \
\
/***/
@@ -388,13 +375,13 @@ namespace boost { namespace spirit { namespace qi
template<typename Modifiers> \
struct make_primitive<tag::name, Modifiers> \
: make_binary_parser<detail::floating_point<bits>, \
boost::spirit::endian::endianness::endiantype, bits> {}; \
boost::endian::order::endiantype, bits> {}; \
\
template<typename Modifiers, typename A0> \
struct make_primitive< \
terminal_ex<tag::name, fusion::vector1<A0> >, Modifiers> \
: make_binary_lit_parser<A0, detail::floating_point<bits>, \
boost::spirit::endian::endianness::endiantype, \
boost::endian::order::endiantype, \
bits> {}; \
\
/***/