| 90 | } |
| 91 | |
| 92 | void release(T *ptr) noexcept { |
| 93 | if (ptr == nullptr) { |
| 94 | return; |
| 95 | } |
| 96 | std::unique_ptr<T> item(ptr); |
| 97 | SpinLockGuard guard(lock_); |
| 98 | items_.push_back(std::move(item)); |
| 99 | } |
| 100 | |
| 101 | SpinLock lock_; |
| 102 | std::vector<std::unique_ptr<T>> items_; |
no outgoing calls
no test coverage detected