diff options
author | Son Ho | 2021-11-18 15:24:27 +0100 |
---|---|---|
committer | Son Ho | 2021-11-18 15:24:27 +0100 |
commit | 807c590113718d8c20419ab31782dd0368e2b045 (patch) | |
tree | 8df67a14ad39d7c06149cebf3946a01253906514 /src/Identifiers.ml | |
parent | 20ddbb9633ce9273ef6bf6e7e0381ddaef11b0fc (diff) |
Start working on the values for the interpreter
Diffstat (limited to 'src/Identifiers.ml')
-rw-r--r-- | src/Identifiers.ml | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/Identifiers.ml b/src/Identifiers.ml index 28ed1909..7d440f4d 100644 --- a/src/Identifiers.ml +++ b/src/Identifiers.ml @@ -17,7 +17,9 @@ module type Id = sig val to_string : id -> string - val empty : 'a vector + val empty_vector : 'a vector + + module Set : Set.S with type elt = id val id_of_json : Yojson.Basic.t -> (id, string) result @@ -47,7 +49,13 @@ module IdGen () : Id = struct let to_string = string_of_int - let empty = [] + let empty_vector = [] + + module Set = Set.Make (struct + type t = id + + let compare = compare + end) let id_of_json js = match js with |