| 99 | |
| 100 | template <typename Fn> |
| 101 | auto Call(Fn fn) |
| 102 | { |
| 103 | assert(!IsExecutorThread()); |
| 104 | std::packaged_task<decltype(fn()) ()> task(fn); |
| 105 | Add([&task]() { task(); }); |
| 106 | return task.get_future().get(); |
| 107 | } |
| 108 | |
| 109 | template <typename Fn> |
| 110 | auto CallAsync(Fn fn) |
nothing calls this directly
no outgoing calls
no test coverage detected