Min-heap ordering for cursor frontiers: earliest (ts, chunk, row) on top.
| 51 | |
| 52 | // Min-heap ordering for cursor frontiers: earliest (ts, chunk, row) on top. |
| 53 | [[nodiscard]] bool frontierAfter(const CursorFrontier& a, const CursorFrontier& b) { |
| 54 | return std::tie(a.ts, a.chunk, a.row) > std::tie(b.ts, b.chunk, b.row); |
| 55 | } |
| 56 | |
| 57 | // Replace the heap top with its in-chunk successor (has_next) or drop it. |
| 58 | // O(1) when the successor is still the global minimum — which is every |