[docs] [issue34123] ambiguous documentation for dict.popitem

Dan Snider report at bugs.python.org
Mon Jul 16 02:00:27 EDT 2018


New submission from Dan Snider <mr.assume.away at gmail.com>:

https://docs.python.org/3/library/stdtypes.html#dict.popitem


`dict.popitem` no longer returns an "arbitrary" (key, value) pair as the documentation suggests. Rather, it always returns the pair whose key was most recently *inserted* (ie., the last entry in `dk_entries`).

Perhaps the docs could reflect that this method is now always LIFO rather arbitrary now that insertion order is guaranteed?

----------
assignee: docs at python
components: Documentation
messages: 321708
nosy: bup, docs at python
priority: normal
severity: normal
status: open
title: ambiguous documentation for dict.popitem
versions: Python 3.7, Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34123>
_______________________________________


More information about the docs mailing list