| 8 | namespace internal { |
| 9 | |
| 10 | template <class T> struct simple_queue { |
| 11 | std::vector<T> payload; |
| 12 | int pos = 0; |
| 13 | void reserve(int n) { payload.reserve(n); } |
| 14 | int size() const { return int(payload.size()) - pos; } |
| 15 | bool empty() const { return pos == int(payload.size()); } |
| 16 | void push(const T& t) { payload.push_back(t); } |
| 17 | T& front() { return payload[pos]; } |
| 18 | void clear() { |
| 19 | payload.clear(); |
| 20 | pos = 0; |
| 21 | } |
| 22 | void pop() { pos++; } |
| 23 | }; |
| 24 | |
| 25 | } // namespace internal |
| 26 |
nothing calls this directly
no outgoing calls
no test coverage detected