| 107 | class SimpleExecutor { |
| 108 | public: |
| 109 | explicit SimpleExecutor(int nfutures) |
| 110 | : pool_(ThreadPool::Make(/*threads=*/4).ValueOrDie()) { |
| 111 | for (int i = 0; i < nfutures; ++i) { |
| 112 | futures_.push_back(Future<T>::Make()); |
| 113 | } |
| 114 | } |
| 115 | |
| 116 | std::vector<Future<T>>& futures() { return futures_; } |
| 117 |
nothing calls this directly
no test coverage detected