Skip to content

Commit

Permalink
Reverted changes in query_heap.hpp
Browse files Browse the repository at this point in the history
  • Loading branch information
Mugr Rex committed Apr 17, 2023
1 parent ec74be3 commit 7f6900d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions include/util/query_heap.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ class QueryHeap
if (index >= static_cast<decltype(index)>(inserted_nodes.size()) ||
inserted_nodes[index].node != node)
{
return 0;
return nullptr;
}
return &inserted_nodes[index];
}
Expand Down Expand Up @@ -356,13 +356,13 @@ class QueryHeap
const auto index = node_index.peek_index(node);
auto &reference = inserted_nodes[index];
reference.weight = weight;
heap.decrease(reference.handle, std::make_pair(weight, index));
heap.increase(reference.handle, std::make_pair(weight, index));
}

void DecreaseKey(const HeapNode &heapNode)
{
BOOST_ASSERT(!WasRemoved(heapNode.node));
heap.decrease(heapNode.handle, std::make_pair(heapNode.weight, (*heapNode.handle).second));
heap.increase(heapNode.handle, std::make_pair(heapNode.weight, (*heapNode.handle).second));
}

private:
Expand Down

0 comments on commit 7f6900d

Please sign in to comment.