Fixes collections/ttables.
This commit is contained in:
parent
63d384d0cd
commit
00dc93b65b
1 changed files with 1 additions and 1 deletions
|
|
@ -196,7 +196,7 @@ proc `==`*[A, B](s, t: TTable[A, B]): bool =
|
||||||
# to use the slow route here:
|
# to use the slow route here:
|
||||||
for key, val in s:
|
for key, val in s:
|
||||||
if not hasKey(t, key): return false
|
if not hasKey(t, key): return false
|
||||||
if mget(t, key) != val: return false
|
if t[key] != val: return false
|
||||||
return true
|
return true
|
||||||
|
|
||||||
proc indexBy*[A, B, C](collection: A, index: proc(x: B): C): TTable[C, B] =
|
proc indexBy*[A, B, C](collection: A, index: proc(x: B): C): TTable[C, B] =
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue