Module Dequeue

module Dequeue: Dequeue

type 'a t 
include Sexpable.S1
include Binable.S1
val create : ?never_shrink:bool -> ?initial_index:int -> dummy:'a -> unit -> 'a t
val length : 'a t -> int
val is_empty : 'a t -> bool
val front_index : 'a t -> int
val back_index : 'a t -> int
val get_exn : 'a t -> int -> 'a
val get_front : 'a t -> 'a option
val get_front_exn : 'a t -> 'a
val get_back : 'a t -> 'a option
val get_back_exn : 'a t -> 'a
val set_exn : 'a t -> int -> 'a -> unit
val iteri : f:(int -> 'a -> unit) -> 'a t -> unit
val iter : f:('a -> unit) -> 'a t -> unit
val foldi : f:('a -> int -> 'b -> 'a) -> init:'a -> 'b t -> 'a
val fold : f:('a -> 'b -> 'a) -> init:'a -> 'b t -> 'a
val push_front : 'a t -> 'a -> unit
val push_back : 'a t -> 'a -> unit
val drop_front_exn : ?n:int -> 'a t -> unit
val drop_back_exn : ?n:int -> 'a t -> unit
val take_front_exn : 'a t -> 'a
val take_back_exn : 'a t -> 'a
val drop_indices_less_than_exn : 'a t -> int -> unit
val drop_indices_greater_than_exn : 'a t -> int -> unit
val invariant : 'a t -> unit