package tezos-protocol-020-PsParisC

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type 'elt t = private {
  1. elements : 'elt list;
  2. length : int;
}
val of_list : 'a list -> 'a t

Convert an OCaml list into Michelson list.

val to_list : 'a t -> 'a list

Convert a Michelson list to an OCaml list.

val length : 'a t -> int

length l returns the number of elements in l as int.

val empty : 'a t

Empty list.

val cons : 'a -> 'a t -> 'a t

Prepend an element.

val uncons : 'a t -> ('a * 'a t) option

uncons l returns Some (hd, tl) where hd :: tl = l if l is not empty or None otherwise.

val rev : 'a t -> 'a t

rev l returns a list containing all elements of l in reversed order.

OCaml

Innovation. Community. Security.