package containers

  1. Overview
  2. Docs
val list : ?start:string -> ?stop:string -> ?sep:string -> 'a t -> 'a list t

list p parses a list of p, with the OCaml conventions for start token "[", stop token "]" and separator ";". Whitespace between items are skipped.

val int : int t

Parse an int.

val word : string t

Non empty string of alpha num, start with alpha.

val pair : ?start:string -> ?stop:string -> ?sep:string -> 'a t -> 'b t -> ('a * 'b) t

Parse a pair using OCaml whitespace conventions. The default is "(a, b)".

val triple : ?start:string -> ?stop:string -> ?sep:string -> 'a t -> 'b t -> 'c t -> ('a * 'b * 'c) t

Parse a triple using OCaml whitespace conventions. The default is "(a, b, c)".

OCaml

Innovation. Community. Security.