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 eric.snow
Recipients Arfrever, Jim.Jewett, Mark.Shannon, alex, asvetlov, benjamin.peterson, eric.araujo, eric.smith, eric.snow, ezio.melotti, flox, gregory.p.smith, introom, josh.r, mrabarnett, ncoghlan, ned.deily, pitrou, refi64, rhettinger, scoder, serhiy.storchaka, tonn81, westurner, yselivanov
Date 2015-05-25.18:52:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CALFfu7DwsD1JNyoAO5OqKu0ejqiS3dr7Jsj4MKCw4dQcMeqKxA@mail.gmail.com>
In-reply-to <1432437694.78.0.999900807186.issue16991@psf.upfronthosting.co.za>
Content
> I'm going to echo the previous comment that maybe trying to emulate the existing dict implementation too carefully just adds complexity.

The whole dance with _odict_get_index and _odict_resize is due to the
requirement that OrderedDict maintain O(1) operation for deletion
operations.  Due to using a linked list, we needed a secondary
mechanism for efficiently indexing into the list.  There is a note at
the top of the file explaining the alternatives I considered and the
rationale for mirroring dict's hash table.

>
> The split-keys implementation shows that there is at least some flexibility to the implementation.  Enough that the keys could map to an array offset, rather than directly to the values?

What do you mean by this?  If you are suggesting changes to dict or
its accessory types then it is something I considered and rejected.
Personally I don't want to change anything on dict itself for the sake
of OrderedDict.  If others would like to pursue that they're welcome
to do so. :)
History
Date User Action Args
2015-05-25 18:52:54eric.snowsetrecipients: + eric.snow, rhettinger, gregory.p.smith, ncoghlan, pitrou, scoder, eric.smith, benjamin.peterson, ned.deily, ezio.melotti, eric.araujo, mrabarnett, Arfrever, alex, asvetlov, flox, Mark.Shannon, Jim.Jewett, serhiy.storchaka, yselivanov, westurner, refi64, josh.r, tonn81, introom
2015-05-25 18:52:54eric.snowlinkissue16991 messages
2015-05-25 18:52:54eric.snowcreate