Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source
Page
Library
Module
Module type
Parameter
Class
Class type
Source
SEK.StackThe submodule Stack is a replacement for OCaml's standard Stack module, where a stack is implemented as an ephemeral sequence. Elements are pushed and popped at the front end of the sequence.
type 'a t = 'a E.tval create : 'a -> 'a tcreate requires a default value. The functor SupplyDefault remedies this problem.
val push : 'a -> 'a t -> unitval pop : 'a t -> 'aval pop_opt : 'a t -> 'a optionval top : 'a t -> 'aval top_opt : 'a t -> 'a optionval clear : 'a t -> unitval is_empty : 'a t -> boolval length : 'a t -> intval iter : ('a -> unit) -> 'a t -> unitval fold : ('a -> 'b -> 'a) -> 'a -> 'b t -> 'a