summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/pure/collections/tables.nim6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/pure/collections/tables.nim b/lib/pure/collections/tables.nim
index 50c727be1..c6d5cc9e2 100644
--- a/lib/pure/collections/tables.nim
+++ b/lib/pure/collections/tables.nim
@@ -87,7 +87,7 @@
 ##   for pairs in zip(years, names):
 ##     let (birthYear, name) = pairs
 ##     if not beatlesByYear.hasKey(birthYear):
-##       # if a key doesn't exists, we create one with an empty sequence
+##       # if a key doesn't exist, we create one with an empty sequence
 ##       # before we can add elements to it
 ##       beatlesByYear[birthYear] = @[]
 ##     beatlesByYear[birthYear].add(name)
@@ -977,6 +977,8 @@ proc add*[A, B](t: TableRef[A, B], key: A, val: B) =
 proc del*[A, B](t: TableRef[A, B], key: A) =
   ## Deletes ``key`` from hash table ``t``. Does nothing if the key does not exist.
   ##
+  ## **If duplicate keys were added, this may need to be called multiple times.**
+  ##
   ## See also:
   ## * `take proc<#take,TableRef[A,B],A,B>`_
   ## * `clear proc<#clear,TableRef[A,B]>`_ to empty the whole table
@@ -994,6 +996,8 @@ proc take*[A, B](t: TableRef[A, B], key: A, val: var B): bool =
   ## mapping of the key. Otherwise, returns ``false``, and the ``val`` is
   ## unchanged.
   ##
+  ## **If duplicate keys were added, this may need to be called multiple times.**
+  ##
   ## See also:
   ## * `del proc<#del,TableRef[A,B],A>`_
   ## * `clear proc<#clear,TableRef[A,B]>`_ to empty the whole table