async: change namespace for sync_wait
Upstream stdexec moved the sync_wait from the `stdexec::this_thread`
namespace directly into `stdexec`.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I9a28b4c5920d0f9892ba466d919fd29f2397f64a
diff --git a/test/async/task.cpp b/test/async/task.cpp
index a7e5a15..d838e33 100644
--- a/test/async/task.cpp
+++ b/test/async/task.cpp
@@ -17,7 +17,7 @@
EXPECT_FALSE(value);
// Run it and confirm the value is updated.
- stdexec::this_thread::sync_wait(t());
+ stdexec::sync_wait(t());
EXPECT_TRUE(value);
}
@@ -41,7 +41,7 @@
// Add boolean to confirm that co-routine actually executed by the
// end.
bool executed = false;
- stdexec::this_thread::sync_wait(_::two(executed));
+ stdexec::sync_wait(_::two(executed));
EXPECT_TRUE(executed);
}
@@ -69,11 +69,11 @@
};
// Ensure throws surface up.
- EXPECT_THROW(stdexec::this_thread::sync_wait(_::one()), std::logic_error);
+ EXPECT_THROW(stdexec::sync_wait(_::one()), std::logic_error);
// Ensure throws can be caught inside a co-routine.
bool caught = false;
- stdexec::this_thread::sync_wait(_::two(caught));
+ stdexec::sync_wait(_::two(caught));
EXPECT_TRUE(caught);
}
@@ -95,7 +95,7 @@
static constexpr size_t count = 100;
size_t executed = 0;
- stdexec::this_thread::sync_wait(
+ stdexec::sync_wait(
_::one(count, executed) |
stdexec::then([=](auto result) { EXPECT_EQ(result, count); }));