diff --git a/CHANGELOG.md b/CHANGELOG.md index e674ac63..8e32a4df 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ Version 253: * Fix async_detect_ssl handler type * member get_executor const-correctness * Fix min/max on MSVC +* Relax requirements for vector_body -------------------------------------------------------------------------------- diff --git a/include/boost/beast/http/vector_body.hpp b/include/boost/beast/http/vector_body.hpp index b44ef0f6..1317ec3f 100644 --- a/include/boost/beast/http/vector_body.hpp +++ b/include/boost/beast/http/vector_body.hpp @@ -39,8 +39,7 @@ template> struct vector_body { private: - static_assert(sizeof(T) == 1 && - std::is_integral::value, + static_assert(sizeof(T) == 1, "T requirements not met"); public: diff --git a/test/beast/http/vector_body.cpp b/test/beast/http/vector_body.cpp index 588df5e8..142d17e1 100644 --- a/test/beast/http/vector_body.cpp +++ b/test/beast/http/vector_body.cpp @@ -9,6 +9,7 @@ // Test that header file is self-contained. #include +#include namespace boost { namespace beast { @@ -18,6 +19,12 @@ BOOST_STATIC_ASSERT(is_body>::value); BOOST_STATIC_ASSERT(is_body_writer>::value); BOOST_STATIC_ASSERT(is_body_reader>::value); +#if __cpp_lib_byte >= 201603 +BOOST_STATIC_ASSERT(is_body>::value); +BOOST_STATIC_ASSERT(is_body_writer>::value); +BOOST_STATIC_ASSERT(is_body_reader>::value); +#endif + } // http } // beast } // boost