| 236 | // Provides an abstraction for asynchronously executing a function. |
| 237 | template <typename F> |
| 238 | Future<typename result_of<F()>::type> async( |
| 239 | const F& f, |
| 240 | typename std::enable_if<!std::is_void<typename result_of<F()>::type>::value>::type*) // NOLINT(whitespace/line_length) |
| 241 | { |
| 242 | return AsyncExecutor().execute(f); |
| 243 | } |
| 244 | |
| 245 | |
| 246 | template <typename F> |