This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rhettinger
Recipients arigo, bup, docs@python, methane, rhettinger
Date 2018-07-16.07:57:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1531727869.8.0.56676864532.issue34123@psf.upfronthosting.co.za>
In-reply-to
Content
> Is there no possible optimizations by breaking LIFO dict.popitem()?

Even if there were a possible optimization, we wouldn't care.  The API is too desirable to forgo in the name of micro-optimization.  We don't design our APIs that way -- trading the relevant and actionable for ethereal and unknown.

Also, it is common sense that addition of a key/value pair at the end is a readily undoable operation (no more expensive to remove than it was to add). There will be a dummy entry in the hash array just like there is now.
History
Date User Action Args
2018-07-16 07:57:49rhettingersetrecipients: + rhettinger, arigo, methane, docs@python, bup
2018-07-16 07:57:49rhettingersetmessageid: <1531727869.8.0.56676864532.issue34123@psf.upfronthosting.co.za>
2018-07-16 07:57:49rhettingerlinkissue34123 messages
2018-07-16 07:57:49rhettingercreate