2
0
mirror of https://github.com/boostorg/cobalt.git synced 2026-01-19 16:12:15 +00:00

removed logic_error usage.

This commit is contained in:
Klemens Morgenstern
2023-10-12 12:00:35 +08:00
parent b22be92238
commit 783cdb2ea7
8 changed files with 13 additions and 20 deletions

View File

@@ -193,7 +193,7 @@ struct py_coroutine
void initiate(py::object loop, py::object future)
{
if (!handle_)
throw std::logic_error("Awaited invalid coroutine");
throw std::invalid_argument("Awaited invalid coroutine");
if (handle_->done_)
throw py::stop_iteration("coroutine completed");