Fix build with Asio 1.13-1.17
This commit is contained in:
parent
9662d87fbf
commit
2f29926dbb
1 changed files with 5 additions and 0 deletions
|
|
@ -31,7 +31,12 @@ namespace SimpleWeb {
|
||||||
using io_context = asio::io_context;
|
using io_context = asio::io_context;
|
||||||
using resolver_results = asio::ip::tcp::resolver::results_type;
|
using resolver_results = asio::ip::tcp::resolver::results_type;
|
||||||
using async_connect_endpoint = asio::ip::tcp::endpoint;
|
using async_connect_endpoint = asio::ip::tcp::endpoint;
|
||||||
|
|
||||||
|
#if(ASIO_STANDALONE && ASIO_VERSION >= 101800) || BOOST_ASIO_VERSION >= 101800
|
||||||
using strand = asio::strand<asio::any_io_executor>;
|
using strand = asio::strand<asio::any_io_executor>;
|
||||||
|
#else
|
||||||
|
using strand = asio::strand<asio::executor>;
|
||||||
|
#endif
|
||||||
|
|
||||||
template <typename handler_type>
|
template <typename handler_type>
|
||||||
inline void post(io_context &context, handler_type &&handler) {
|
inline void post(io_context &context, handler_type &&handler) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue