complement notes of two doc strings of tables module (#18527)
* complement notes of two doc strings warning the deprecated procedure's side effect * Update lib/pure/collections/tables.nim Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> * Update lib/pure/collections/tables.nim Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> Co-authored-by: BillyZee <billyzee@localhost.localdomain> Co-authored-by: Andreas Rumpf <rumpf_a@web.de> Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
This commit is contained in:
parent
6f34829ee5
commit
880353c0ad
1 changed files with 4 additions and 0 deletions
|
|
@ -496,6 +496,8 @@ template tabCellHash(i) = t.data[i].hcode
|
|||
proc del*[A, B](t: var Table[A, B], key: A) =
|
||||
## Deletes `key` from hash table `t`. Does nothing if the key does not exist.
|
||||
##
|
||||
## .. warning:: If duplicate keys were added, this may need to be called multiple times.
|
||||
##
|
||||
## See also:
|
||||
## * `pop proc<#pop,Table[A,B],A,B>`_
|
||||
## * `clear proc<#clear,Table[A,B]>`_ to empty the whole table
|
||||
|
|
@ -514,6 +516,8 @@ proc pop*[A, B](t: var Table[A, B], key: A, val: var B): bool =
|
|||
## mapping of the key. Otherwise, returns `false`, and the `val` is
|
||||
## unchanged.
|
||||
##
|
||||
## .. warning:: If duplicate keys were added, this may need to be called multiple times.
|
||||
##
|
||||
## See also:
|
||||
## * `del proc<#del,Table[A,B],A>`_
|
||||
## * `clear proc<#clear,Table[A,B]>`_ to empty the whole table
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue