Module Sek__.PrivateSignatures

exception Empty

The exception Empty is raised by pop and peek operations.

exception End

The exception End is raised by the iterator operation get.

type pov =
| Front
| Back

When passed as a parameter to an iter function, Front means left-to-right iteration, whereas Back means right-to-left iteration.

val dual : pov -> pov
val sign : pov -> int
val exchange : pov -> 'a -> 'a -> 'a * 'a
val show_pov : pov -> string
type side = pov
val front : pov
val back : pov
val other : pov -> pov
type direction = pov
val forward : pov
val backward : pov
val sign : pov -> int
val opposite : pov -> pov
type weight = int

The type weight represents the weight of an element or the total weight of a sequence of elements. It is a nonnegative integer.

type 'a update = 'a -> weight -> 'a

A function of type 'a update is a function that knows how to update an element in a sequence. Its arguments are the element x that must be updated and the weight-index at which x must be updated, if it is itself a sequence. (One might say that the function does not represent a single update but a weight-indexed family of updates.)

module type ECHUNK = sig ... end

The module EphemeralChunk implements an ephemeral chunk, that is, a mutable circular buffer. This is its signature.

type owner = Sek__.Owner.owner
module type SCHUNK = sig ... end

The module ShareableChunk implements a shareable chunk, that is, a chunk that is either owned by a single owner or shared between multiple owners. This is its signature.

module type SSEQ = sig ... end

The module ShareableSequence implements a shareable sequence, which is essentially a persistent sequence data structure built on top of shareable chunks. This is its signature.

module type WITER = sig ... end

The signature WITER is our internal API for iterators on weighted sequences.

module type IITER = sig ... end

The signature IITER is our internal iterator API. It is essentially a subset of the public signature ITER.

module type PSEQ = sig ... end