[Python-Dev] The current dict is not an "OrderedDict"

Chris Barker chris.barker at noaa.gov
Tue Nov 7 15:47:03 EST 2017


On Tue, Nov 7, 2017 at 11:50 AM, Tim Peters <tim.peters at gmail.com> wrote:

> Is it worth guaranteeing that will always "work" (as intended)?  Not
> to me, but I do have code that relies on it now -


This is critically important -- no one looks at the language spec to figure
out how something works -- they try it, and if it works assume it will
continue to work.

if dict order is preserved in cPython , people WILL count on it!

And similarly, having order preserved only until a delete is going to cause
bugs in people's code that are less than careful :-( -- and that's most of
us.

-CHB




-- 

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20171107/c4360424/attachment.html>


More information about the Python-Dev mailing list