Python 3.1 beta 1

Terry Reedy tjreedy at udel.edu
Thu May 7 16:21:52 EDT 2009


bearophileHUGS at lycos.com wrote:

> Is the order inside OrderedDict kept with a double linked list of the
> items?

That is one of the things Raymond tried.  Check the code for what he 
settled on for the Python version.  I believe he thinks the best C 
implementation might be different from the best Python version.

>> The OrderedDict constructor and update() method both accept
 >> keyword arguments, but their order is lost because Python's
 >> function call semantics pass-in keyword arguments using a regular
 >> unordered dictionary.
> 
> This is unfortunate :-(
> Well, I'd like function call semantics pass-in keyword arguments to
> use OrderedDicts then... :-)

This possibility has been discussed on pydev.
It would require a sufficiently fast C implementation.

tjr




More information about the Python-list mailing list