[Python-Dev] Python 3.6 dict becomes compact and gets a private version; and keywords become ordered

Elvis Pranskevichus elprans at gmail.com
Fri Sep 9 15:40:32 EDT 2016


On Friday, September 9, 2016 2:01:08 PM EDT David Mertz wrote:
> It feels best to me only to promise order in specific cases like kwargs,
> but say nothing (even in 3.6 or 3.7) about the requirement for how dict
> itself is implemented.

On Saturday, September 10, 2016 6:39:27 AM EDT Barry Warsaw wrote:
> If people start relying on all dicts being ordered now, their code won't 
> be compatible with both 3.5 and 3.6, and I think it's important to 
> emphasize this to developers.

OK, that makes sense.  Putting an explicit note in the documentation that one 
should not rely on the key order will probably be enough to reduce the 
concern.


                                 Elvis


More information about the Python-Dev mailing list