PriorityQueue

A priority queue implementation. Items with the highest priority (as defined by the supplied predicate) come off the queue first. You can change the order of the queue by supplying a custom predicate, or overriding opCmp on the type being queued.

struct PriorityQueue (
T
alias Predicate = "a > b"
) {}

Members

Functions

front
inout(T) front()

Fetches a reference to the highest-priority element in the queue.

pop
void pop()

Removes the highest-priority item from the queue. The queue must not be empty.

Meta