Module Prelude.Queue
Purely functional FIFO queues.
This is the data structure due to F. Warren Burton, "An Efficient Functional Implementation of FIFO Queues", Information Processing Letters, 1982.
val compare : 'a t -> 'a t -> intval enq : 'a -> 'a t -> 'a tval push : 'a -> 'a t -> 'a tval peek : 'a t -> 'a optionval deq : 'a t -> 'a option * 'a tval pop : 'a t -> 'a option * 'a tval of_list : 'a list -> 'a tval to_list : 'a t -> 'a listval random : ?size:(unit -> int) -> (unit -> 'a) -> unit -> 'a t