You can use a simple vector or array to store items, and then use std::make_heap , std::push_heap , std::pop_heap , std::sort_heap , std::is_heap and std::is_heap_until to control it.
This allows you to break containment and implement custom operations in the priority queue without having to perform standard operations yourself.
Andrew Tomazos
source share