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 wim.glenn
Recipients docs@python, rhettinger, wim.glenn
Date 2019-05-13.22:21:50
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1557786110.6.0.397786860144.issue36909@roundup.psfhosted.org>
In-reply-to
Content
Section https://docs.python.org/3/library/collections.html#ordereddict-examples-and-recipes

    class LastUpdatedOrderedDict(OrderedDict):
        'Store items in the order the keys were last added'

        def __setitem__(self, key, value):
            super().__setitem__(key, value)
            super().move_to_end(key)

Why does it use super().move_to_end(key), isn't self.move_to_end(key) more direct/Pythonic?
History
Date User Action Args
2019-05-13 22:21:50wim.glennsetrecipients: + wim.glenn, rhettinger, docs@python
2019-05-13 22:21:50wim.glennsetmessageid: <1557786110.6.0.397786860144.issue36909@roundup.psfhosted.org>
2019-05-13 22:21:50wim.glennlinkissue36909 messages
2019-05-13 22:21:50wim.glenncreate