forked from boostorg/beast
Tests adopting asio code changes for asio 1.25.0.
This commit is contained in:
committed by
Klemens Morgenstern
parent
4a8ced4b6f
commit
19f91bcb32
@@ -107,6 +107,11 @@ struct nested_alloc
|
||||
struct allocator_type
|
||||
{
|
||||
};
|
||||
|
||||
allocator_type get_allocator() const noexcept
|
||||
{
|
||||
return allocator_type{};
|
||||
}
|
||||
};
|
||||
|
||||
struct intrusive_alloc
|
||||
@@ -114,11 +119,21 @@ struct intrusive_alloc
|
||||
struct allocator_type
|
||||
{
|
||||
};
|
||||
|
||||
allocator_type get_allocator() const noexcept
|
||||
{
|
||||
return allocator_type{};
|
||||
}
|
||||
};
|
||||
|
||||
struct no_ex
|
||||
{
|
||||
using executor_type = net::system_executor;
|
||||
|
||||
executor_type get_executor() const noexcept
|
||||
{
|
||||
return executor_type{};
|
||||
}
|
||||
};
|
||||
|
||||
struct nested_ex
|
||||
@@ -126,6 +141,11 @@ struct nested_ex
|
||||
struct executor_type
|
||||
{
|
||||
};
|
||||
|
||||
executor_type get_executor() const noexcept
|
||||
{
|
||||
return executor_type{};
|
||||
}
|
||||
};
|
||||
|
||||
struct intrusive_ex
|
||||
@@ -133,6 +153,11 @@ struct intrusive_ex
|
||||
struct executor_type
|
||||
{
|
||||
};
|
||||
|
||||
executor_type get_executor() const noexcept
|
||||
{
|
||||
return executor_type{};
|
||||
}
|
||||
};
|
||||
|
||||
template<class E, class A>
|
||||
|
||||
@@ -186,7 +186,7 @@ public:
|
||||
if (blocking_ == net::execution::blocking.possibly)
|
||||
{
|
||||
s_.on_invoke();
|
||||
net::execution::execute(ex_, std::forward<F>(f));
|
||||
ex_.execute(std::forward<F>(f));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -220,11 +220,9 @@ public:
|
||||
dispatch(F&& f, Alloc const& a)
|
||||
{
|
||||
s_.on_invoke();
|
||||
net::execution::execute(
|
||||
net::prefer(ex_,
|
||||
net::execution::blocking.possibly,
|
||||
net::execution::allocator(a)),
|
||||
std::forward<F>(f));
|
||||
net::prefer(ex_,
|
||||
net::execution::blocking.possibly,
|
||||
net::execution::allocator(a)).execute(std::forward<F>(f));
|
||||
// previously equivalent to
|
||||
// ex_.dispatch(std::forward<F>(f), a);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user