[issue27350] Compact and ordered dict
INADA Naoki
report at bugs.python.org
Tue Jun 21 11:38:46 EDT 2016
INADA Naoki added the comment:
As I posted to python-dev ML, this compact ordered dict doesn't keep insertion order
for key-shared dict.
>>> class A:
... ...
...
>>> a = A()
>>> b = A()
>>> a.a = 1
>>> a.b = 2
>>> b.b = 3
>>> b.a = 4
>>> a.__dict__.items()
dict_items([('a', 1), ('b', 2)])
>>> b.__dict__.items()
dict_items([('a', 4), ('b', 3)])
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue27350>
_______________________________________
More information about the Python-bugs-list
mailing list