Skip to main content

Module TableclothMap.Int

Construct a Map with Ints for keys.

type t​

type nonrec 'value t = 'value Of(TableclothInt).t

val empty​

val empty : 'value t

A map with nothing in it.

val singleton​

val singleton : key:int -> value:'value -> 'value t

Create a map from a key and value

Examples

Map.Int.singleton ~key:1 ~value:"Ant" |> Map.toList = [(1, "Ant")]

val fromArray​

val fromArray : (int * 'value) array -> 'value t

Create a map from an Array of key-value tuples

val from_array​

val from_array : (int * 'value) array -> 'value t

val fromList​

val fromList : (int * 'value) list -> 'value t

Create a map of a List of key-value tuples

val from_list​

val from_list : (int * 'value) list -> 'value t