Add folly::coro::semi_await_result_t<T>
Summary: - Change folly::coro::co_viaIfAsync to be a customization-point object. - Modify co_viaIfAsync() to call a .viaIfAsync() member function if one exists. Otherwise it calls the co_viaIfAsync() function found by ADL. - Add FOLLY_DEFINE_CPO() helper macro to folly/Portability.h Borrows some techniques from range-v3 to support CPOs in different compilers and C++ versions. - Redefined co_viaIfAsync() CPO in terms of this macro. This allows it to be callable as folly::coro::co_viaIfAsync() while still allowing other types in folly::coro namespace to define friend functions that customise the behaviour of this customisation point without causing conflicts. - Add folly::coro::is_semi_awaitable<T> metafunction. - Add folly::coro::semi_await_result_t<T> metafunction. Reviewed By: yfeldblum Differential Revision: D14016389 fbshipit-source-id: 63998993b2fa8560700f81666a910dee31f3ba72
Showing
folly/detail/StaticConst.h
0 → 100644
Please register or sign in to comment