non-blocking wait
| 21 | |
| 22 | // non-blocking wait |
| 23 | bool tryWait(int k) { |
| 24 | Lock l(mu_); |
| 25 | return (task_.count(k) && task_[k] == true); |
| 26 | } |
| 27 | |
| 28 | // start task k, do nothing if it has been started or finished |
| 29 | void start(int k) { |
no test coverage detected