![]() |
Bitcoin Core 29.99.0
P2P Digital Currency
|
Wrapper around callback function for compatibility with std::async. More...
#include <util.h>
Public Member Functions | |
AsyncCallable (Callable &&callable) | |
AsyncCallable (const AsyncCallable &)=default | |
AsyncCallable (AsyncCallable &&)=default | |
~AsyncCallable () noexcept=default | |
ResultOf< Callable > | operator() () const |
Public Attributes | |
std::shared_ptr< DestructorCatcher< Callable > > | m_callable |
Wrapper around callback function for compatibility with std::async.
std::async requires callbacks to be copyable and requires noexcept destructors, but this doesn't work well with kj types which are generally move-only and not noexcept.
|
inline |
|
default |
|
default |
|
defaultnoexcept |
|
inline |
|
mutable |