9#if defined(ASYNCPP_SO_COMPAT)
10 static thread_local dispatcher* g_current_dispatcher;
12 static thread_local inline dispatcher* g_current_dispatcher =
nullptr;
29 const auto old = g_current_dispatcher;
30 g_current_dispatcher = disp;
41 virtual void push(std::function<
void()> cbfn) = 0;
51#if defined(ASYNCPP_SO_COMPAT_IMPL)
52 thread_local dispatcher* dispatcher::g_current_dispatcher =
nullptr;
Basic dispatcher interface class.
Definition dispatcher.h:8
static dispatcher * current(dispatcher *disp)
Set the current dispatcher for this thread and reurns the current one. Implementers of dispatchers ca...
Definition dispatcher.h:28
static dispatcher * current() noexcept
Definition dispatcher.h:48
virtual void push(std::function< void()> cbfn)=0