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 Mark.Shannon, methane, rhettinger, serhiy.storchaka
Date 2021-09-22.19:02:33
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1632337353.9.0.484296096357.issue40116@roundup.psfhosted.org>
In-reply-to
Content
> Overall, I expect the improved sharing to more than
> compensate for the disadvantages.

I expect the opposite.  This makes all dicts pay a price (in space, initialization time, and complexity) for a micro-optimization of an uncommon case (the normal case is for __init__ to run and set all the keys in a consistent order).  It is unlikely that the "benefits" to never be felt in real-word applications, but "disadvantages" would affect every Python program.

> The language specification says that the dicts maintain insertion 
> order, but the wording implies that this only to explicit 
> dictionaries, not instance attribute or other namespace dicts.

That is a quite liberal reading of the spec.  I would object to making instance and namespace dicts behave differently.  That would be a behavior regression and we would forever have to wrestle with the difference.
History
Date User Action Args
2021-09-22 19:02:33rhettingersetrecipients: + rhettinger, methane, Mark.Shannon, serhiy.storchaka
2021-09-22 19:02:33rhettingersetmessageid: <1632337353.9.0.484296096357.issue40116@roundup.psfhosted.org>
2021-09-22 19:02:33rhettingerlinkissue40116 messages
2021-09-22 19:02:33rhettingercreate