@@ -2739,7 +2739,7 @@ concept returnable = std::is_void_v<T> || std::is_reference_v<T> || std::movable
27392739 */
27402740template <returnable T = void >
27412741struct LF_CORO_ATTRIBUTES task : std::type_identity<T> {
2742- void *promise ; // /< An opaque handle to the coroutine promise.
2742+ void *prom ; // /< An opaque handle to the coroutine promise.
27432743};
27442744
27452745} // namespace core
@@ -2961,13 +2961,13 @@ concept async_function_object = std::is_object_v<F> && std::copy_constructible<F
29612961 * @brief This describes the public-API of the first argument passed to an async function.
29622962 *
29632963 * An async functions' invocability and return type must be independent of their first argument except for its
2964- * tag value. A user may query the first argument's static member `tag ` to obtain this value. Additionally, a
2965- * user may query the first argument's static member function `context()` to obtain a pointer to the current
2964+ * tag value. A user may query the first argument's static member `tagged ` to obtain this value. Additionally,
2965+ * a user may query the first argument's static member function `context()` to obtain a pointer to the current
29662966 * workers `lf::context`. Finally a user may cache an exception in-flight by calling `.stash_exception()`.
29672967 */
29682968template <typename T>
29692969concept first_arg = async_function_object<T> && requires (T arg) {
2970- { T::tag } -> std::convertible_to<tag>;
2970+ { T::tagged } -> std::convertible_to<tag>;
29712971 { T::context () } -> std::same_as<context *>;
29722972 { arg.stash_exception () } noexcept ;
29732973};
@@ -2990,7 +2990,7 @@ namespace impl {
29902990template <quasi_pointer I, tag Tag, async_function_object F, typename ... Cargs>
29912991class first_arg_t {
29922992 public:
2993- static constexpr tag tag = Tag; // /< The way this async function was called.
2993+ static constexpr tag tagged = Tag; // /< The way this async function was called.
29942994
29952995 first_arg_t () = default ;
29962996
@@ -3552,7 +3552,7 @@ struct promise;
35523552 */
35533553template <returnable R, return_address_for<R> I, tag Tag>
35543554struct [[nodiscard(" A quasi_awaitable MUST be immediately co_awaited!" )]] quasi_awaitable {
3555- promise<R, I, Tag> *promise ; // /< The parent/semaphore needs to be set!
3555+ promise<R, I, Tag> *prom ; // /< The parent/semaphore needs to be set!
35563556};
35573557
35583558// ---------------------------- //
@@ -3583,7 +3583,7 @@ struct [[nodiscard("A bound function SHOULD be immediately invoked!")]] y_combin
35833583 using R = async_result_t <F, Args...>;
35843584 using P = promise<R, I, Tag>;
35853585
3586- auto *prom = static_cast <P *>(task.promise );
3586+ auto *prom = static_cast <P *>(task.prom );
35873587
35883588 if constexpr (!std::is_void_v<R>) {
35893589 prom->set_return (std::move (ret));
@@ -3857,8 +3857,8 @@ auto sync_wait(Sch &&sch, F fun, Args &&...args) -> async_result_t<F, Args...> {
38573857
38583858 [&]() noexcept {
38593859 //
3860- await.promise ->set_root_notify (¬ifier);
3861- auto *handle = std::bit_cast<submit_handle>(static_cast <impl::frame *>(await.promise ));
3860+ await.prom ->set_root_notify (¬ifier);
3861+ auto *handle = std::bit_cast<submit_handle>(static_cast <impl::frame *>(await.prom ));
38623862
38633863 impl::ignore_t {} = impl::tls::thread_stack->release ();
38643864
@@ -4242,14 +4242,14 @@ struct promise_base : frame {
42424242 requires (Tg == tag::call || Tg == tag::fork)
42434243 auto await_transform (quasi_awaitable<R2, I2, Tg> awaitable) noexcept {
42444244
4245- awaitable.promise ->set_parent (this );
4245+ awaitable.prom ->set_parent (this );
42464246
42474247 if constexpr (Tg == tag::call) {
4248- return call_awaitable{{}, awaitable.promise };
4248+ return call_awaitable{{}, awaitable.prom };
42494249 }
42504250
42514251 if constexpr (Tg == tag::fork) {
4252- return fork_awaitable{{}, awaitable.promise , this };
4252+ return fork_awaitable{{}, awaitable.prom , this };
42534253 }
42544254 }
42554255};
0 commit comments