Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update dict.popitem() docstring
  • Loading branch information
methane committed Apr 12, 2019
commit c1641501fb2dc87d362a843778a12ddf9e8ccfc6
5 changes: 3 additions & 2 deletions Objects/clinic/dictobject.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions Objects/dictobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -3007,14 +3007,15 @@ dict_pop_impl(PyDictObject *self, PyObject *key, PyObject *default_value)
/*[clinic input]
dict.popitem

Remove and return some (key, value) pair as a 2-tuple.
Remove and return a (key, value) pair as a 2-tuple.

Pairs are returned in LIFO (last-in, first-out) order.
Raises KeyError if the dict is empty.
[clinic start generated code]*/

static PyObject *
dict_popitem_impl(PyDictObject *self)
/*[clinic end generated code: output=e65fcb04420d230d input=d8f2b7a50b271c28]*/
/*[clinic end generated code: output=e65fcb04420d230d input=1c38a49f21f64941]*/
{
Py_ssize_t i, j;
PyDictKeyEntry *ep0, *ep;
Expand Down