diff --git a/M2/Macaulay2/d/hashtables.dd b/M2/Macaulay2/d/hashtables.dd index 0628e53e09..316b9df4b9 100644 --- a/M2/Macaulay2/d/hashtables.dd +++ b/M2/Macaulay2/d/hashtables.dd @@ -255,11 +255,13 @@ export toHashTable(v:Sequence):Expr := ( Expr(sethash(o,false))); toHashTable(e:Expr):Expr := ( when e + -- # typical value: hashTable, BasicList, HashTable is w:List do toHashTable(w.v) is s:Sequence do ( if length(s) == 2 then ( if isFunction(s.0) then ( when s.1 + -- # typical value: hashTable, Function, BasicList, HashTable is w:Sequence do toHashTableWithCollisionHandler(w, s.0) is w:List do toHashTableWithCollisionHandler(w.v, s.0) else WrongArg(2, "a list or sequence")) diff --git a/M2/Macaulay2/m2/typicalvalues.m2 b/M2/Macaulay2/m2/typicalvalues.m2 index c353e341f3..7b393266b4 100644 --- a/M2/Macaulay2/m2/typicalvalues.m2 +++ b/M2/Macaulay2/m2/typicalvalues.m2 @@ -51,8 +51,6 @@ take(BasicList,ZZ) := take(BasicList,List) := BasicList => take take(Thing,ZZ) := take(Thing,List) := List => take isMutable(Thing) := Boolean => isMutable -hashTable List := HashTable => hashTable -hashTable(Function,List) := HashTable => hashTable remove(MutableList,ZZ) := Nothing => remove remove(Database,String) := Nothing => remove remove(HashTable,Thing) := Nothing => remove diff --git a/M2/Macaulay2/packages/Macaulay2Doc/types.m2 b/M2/Macaulay2/packages/Macaulay2Doc/types.m2 index 002f784788..da6c6c40ce 100644 --- a/M2/Macaulay2/packages/Macaulay2Doc/types.m2 +++ b/M2/Macaulay2/packages/Macaulay2Doc/types.m2 @@ -544,7 +544,10 @@ document { } document { - Key => {hashTable,(hashTable, List)}, + Key => { + hashTable, + (hashTable, BasicList), + (hashTable, Function, BasicList)}, Headline => "make a hash table", TT "hashTable(h,v)", " -- produce a hash table from a list ", TT "v", " of key-value pairs, with an optional collision handler function ", TT "h", ".", PARA{},