diff --git a/.travis.yml b/.travis.yml index ea70aa26..ec8b6665 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,8 +11,8 @@ env: # to boost's .tar.gz. - LCOV_ROOT=$HOME/lcov - VALGRIND_ROOT=$HOME/valgrind-install - - BOOST_ROOT=$HOME/boost_1_64_0 - - BOOST_URL='http://sourceforge.net/projects/boost/files/boost/1.64.0/boost_1_64_0.tar.gz' + - BOOST_ROOT=$HOME/boost_1_58_0 + - BOOST_URL='http://sourceforge.net/projects/boost/files/boost/1.58.0/boost_1_58_0.tar.gz' addons: apt: diff --git a/CHANGELOG.md b/CHANGELOG.md index b903b15c..407b8b98 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ Version 44 * Use BOOST_THROW_EXCEPTION * Tidy up read_size_helper and dynamic buffers +* Require Boost 1.58.0 or later -------------------------------------------------------------------------------- diff --git a/README.md b/README.md index a698853a..671236a6 100644 --- a/README.md +++ b/README.md @@ -76,7 +76,7 @@ The library has been submitted to the ## Requirements -* Boost 1.64.0 or later +* Boost 1.58.0 or later * C++11 or later When using Microsoft Visual C++, Visual Studio 2015 Update 3 or later is required. diff --git a/include/beast/core/consuming_buffers.hpp b/include/beast/core/consuming_buffers.hpp index 9c9f1dee..a51e529c 100644 --- a/include/beast/core/consuming_buffers.hpp +++ b/include/beast/core/consuming_buffers.hpp @@ -9,6 +9,7 @@ #define BEAST_CONSUMING_BUFFERS_HPP #include +#include #include #include #include diff --git a/include/beast/core/detail/in_place_init.hpp b/include/beast/core/detail/in_place_init.hpp new file mode 100644 index 00000000..f97ad085 --- /dev/null +++ b/include/beast/core/detail/in_place_init.hpp @@ -0,0 +1,40 @@ +// +// Copyright (c) 2013-2017 Vinnie Falco (vinnie dot falco at gmail dot 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 BEAST_DETAIL_IN_PLACE_INIT_HPP +#define BEAST_DETAIL_IN_PLACE_INIT_HPP + +#include + +// Provide boost::in_place_init_t and boost::in_place_init +// for Boost versions earlier than 1.63.0. + +#if BOOST_VERSION < 106300 + +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())); + +} // namespace optional_ns + +using optional_ns::in_place_init_t; +using optional_ns::in_place_init; + +} + +#endif + +#endif +