The unpac monorepo manager self-hosting as a monorepo using unpac
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

fixed String module for old OCaml versions

+10 -2
+10 -2
examples/words.ml
··· 1 1 2 2 (* Word Graph 3 + (example taken from The Stanford GraphBase) 3 4 4 5 Given a number of letters n and a file containing words (one per line), 5 6 this program builds the undirected graph where ··· 14 15 15 16 open Format 16 17 open Graph 17 - module H = Hashtbl.Make(String) 18 + 19 + module S = struct 20 + type t = string 21 + let compare = compare 22 + let hash = Hashtbl.hash 23 + let equal = (=) 24 + end 25 + module H = Hashtbl.Make(S) 18 26 19 - module G = Imperative.Graph.Abstract(String) 27 + module G = Imperative.Graph.Abstract(S) 20 28 let g = G.create () 21 29 22 30 let words : G.V.t H.t = H.create 16