Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
|
|
@ -0,0 +1,10 @@
|
|||
structure StringMap = BinaryMapFn (struct
|
||||
type ord_key = string
|
||||
val compare = String.compare
|
||||
end);
|
||||
|
||||
val keys = [ "foo", "bar", "baz" ]
|
||||
and vals = [ 16384, 32768, 65536 ]
|
||||
and myMap = StringMap.empty;
|
||||
|
||||
val myMap = foldl StringMap.insert' myMap (ListPair.zipEq (keys, vals));
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
exception NotFound;
|
||||
|
||||
val keys = [ "foo", "bar", "baz" ]
|
||||
and vals = [ 16384, 32768, 65536 ]
|
||||
and hash = HashTable.mkTable (HashString.hashString, op=) (42, NotFound);
|
||||
|
||||
ListPair.appEq (HashTable.insert hash) (keys, vals);
|
||||
Loading…
Add table
Add a link
Reference in a new issue