let iter t ~f = Heap.iter t.heap ~f:(fun (k, v) -> f ~key:k ~data:v)