forked from boostorg/beast
Use bind_front_handler:
The implementation uses bind_front_handler to reduce the resources consumed when instantiating templates during compilation.
This commit is contained in:
1 parent
d581bcc348
commit
15dd535c24
12 files changed
+29
-25
No files matched your search
@@ -269,7 +269,7 @@ operator()(error_code ec, std::size_t)
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
d.ws.get_executor(),
|
||||
bind_handler(std::move(*this), ec));
|
||||
bind_front_handler(std::move(*this), ec));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -304,7 +304,7 @@ operator()(
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
d.ws.get_executor(),
|
||||
bind_handler(std::move(*this), ec));
|
||||
bind_front_handler(std::move(*this), ec));
|
||||
}
|
||||
{
|
||||
auto wg = std::move(d.wg);
|
||||
|
||||
@@ -140,7 +140,7 @@ operator()(error_code ec, std::size_t)
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
d.ws.get_executor(),
|
||||
bind_handler(std::move(*this), ec));
|
||||
bind_front_handler(std::move(*this), ec));
|
||||
goto upcall;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -705,7 +705,7 @@ operator()(
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
ws_.get_executor(),
|
||||
bind_handler(std::move(*this),
|
||||
bind_front_handler(std::move(*this),
|
||||
ec, bytes_written_));
|
||||
}
|
||||
h_(ec, bytes_written_);
|
||||
@@ -813,7 +813,7 @@ operator()(
|
||||
if(ec)
|
||||
boost::asio::post(
|
||||
ws_.get_executor(),
|
||||
bind_handler(
|
||||
bind_front_handler(
|
||||
std::move(*this), ec, 0));
|
||||
else
|
||||
read_some_op<typename
|
||||
|
||||
@@ -118,7 +118,7 @@ operator()(error_code ec, std::size_t bytes_transferred)
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
s_.get_executor(),
|
||||
bind_handler(std::move(*this), ec, 0));
|
||||
bind_front_handler(std::move(*this), ec, 0));
|
||||
goto upcall;
|
||||
}
|
||||
for(;;)
|
||||
|
||||
@@ -578,7 +578,9 @@ operator()(
|
||||
BOOST_ASIO_CORO_YIELD
|
||||
boost::asio::post(
|
||||
ws_.get_executor(),
|
||||
bind_handler(std::move(*this), ec, bytes_transferred_));
|
||||
bind_front_handler(
|
||||
std::move(*this),
|
||||
ec, bytes_transferred_));
|
||||
}
|
||||
h_(ec, bytes_transferred_);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user