Module Nonempty_list.Partition3Source
A Partition3 represents a splitting of a nonempty list into three parts, a "fst", a "snd", and a "trd" part.
Unlike List, partitioning a nonempty list does not produce three nonempty lists, because one of the parts could be empty. However, we know for sure that at least one of the parts is nonempty, so we represent this information in a structured type indicating which parts are nonempty.
Source
type ('fst, 'snd, 'trd) t = | Fst of 'fst Base.Nonempty_list.nonempty_list| Snd of 'snd Base.Nonempty_list.nonempty_list| Trd of 'trd Base.Nonempty_list.nonempty_list| Fst_snd of 'fst Base.Nonempty_list.nonempty_list * 'snd Base.Nonempty_list.nonempty_list| Fst_trd of 'fst Base.Nonempty_list.nonempty_list * 'trd Base.Nonempty_list.nonempty_list| Snd_trd of 'snd Base.Nonempty_list.nonempty_list * 'trd Base.Nonempty_list.nonempty_list| Fst_snd_trd of 'fst Base.Nonempty_list.nonempty_list * 'snd Base.Nonempty_list.nonempty_list * 'trd Base.Nonempty_list.nonempty_list
include sig ... end
Source
val sexp_of_t :
('fst -> Sexplib0.Sexp.t) ->
('snd -> Sexplib0.Sexp.t) ->
('trd -> Sexplib0.Sexp.t) ->
('fst, 'snd, 'trd) Base.Nonempty_list.Partition3.t ->
Sexplib0.Sexp.t