| 2345 | } |
| 2346 | |
| 2347 | void GenericClusterImpl::GetDescendantRefs(const TxGraphImpl& graph, std::span<std::pair<Cluster*, DepGraphIndex>>& args, std::vector<TxGraph::Ref*>& output) noexcept |
| 2348 | { |
| 2349 | /** The union of all descendants to be returned. */ |
| 2350 | SetType descendants_union; |
| 2351 | // Process elements from the front of args, as long as they apply. |
| 2352 | while (!args.empty()) { |
| 2353 | if (args.front().first != this) break; |
| 2354 | descendants_union |= m_depgraph.Descendants(args.front().second); |
| 2355 | args = args.subspan(1); |
| 2356 | } |
| 2357 | Assume(descendants_union.Any()); |
| 2358 | // Translate all descendants (in arbitrary order) to Refs (if they have any), and return them. |
| 2359 | for (auto idx : descendants_union) { |
| 2360 | const auto& entry = graph.m_entries[m_mapping[idx]]; |
| 2361 | Assume(entry.m_ref != nullptr); |
| 2362 | output.push_back(entry.m_ref); |
| 2363 | } |
| 2364 | } |
| 2365 | |
| 2366 | void SingletonClusterImpl::GetDescendantRefs(const TxGraphImpl& graph, std::span<std::pair<Cluster*, DepGraphIndex>>& args, std::vector<TxGraph::Ref*>& output) noexcept |
| 2367 | { |
no test coverage detected