Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Loading...
Searching...
No Matches
nix::Goal::AwaitableFrame< T > Class Template Reference

#include <goal.hh>

Inheritance diagram for nix::Goal::AwaitableFrame< T >:
nix::Goal::AwaitableFrameBase

Public Member Functions

Co< T > get_return_object ()
template<typename R>
void return_value (R &&r)
Public Member Functions inherited from nix::Goal::AwaitableFrameBase
InitialSuspend initial_suspend ()
FinalAwaiter final_suspend () noexcept
void unhandled_exception ()
template<typename T>
CoAwaiter< T > await_transform (Co< T > &&co)
template<typename T>
auto await_transform (AsyncCallback< T > &&acb)
SuspendAwaiter await_transform (Suspend)
ChildEventAwaiter await_transform (WaitForChildEvent)

Additional Inherited Members

Protected Attributes inherited from nix::Goal::AwaitableFrameBase
std::optional< CoBase > continuation
void * resultSlot = nullptr
void(*) moveResult (AwaitableFrameBase *from, void *to) noexcept = nullptr
Goal * goal = nullptr
bool alive = true

Detailed Description

template<typename T>
class nix::Goal::AwaitableFrame< T >

Promise type for coroutines defined using Co. Attached to coroutine handle.

See also
boost::asio::detail::awaitable_frame for a reference implementation of a similar pattern.

Member Function Documentation

◆ get_return_object()

template<typename T>
Co< T > nix::Goal::AwaitableFrame< T >::get_return_object ( )
inline

Called by compiler generated code to construct the Co that is returned from a Co-returning coroutine.


The documentation for this class was generated from the following file:
  • libstore/include/nix/store/build/goal.hh