[Python-ideas] Fwd: Why do equality tests between OrderedDict keys/values views behave not as expected?
Guido van Rossum
guido at python.org
Thu Dec 17 14:55:30 EST 2015
More information about the Python-ideas mailing list
Thu Dec 17 14:55:30 EST 2015
- Previous message (by thread): [Python-ideas] Fwd: Why do equality tests between OrderedDict keys/values views behave not as expected?
- Next message (by thread): [Python-ideas] Fwd: Why do equality tests between OrderedDict keys/values views behave not as expected?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
So I think that not using the __eq__ method of the keys or values is wrong (dicts do use it), but there's a philosophical question: if two OrderedDicts have the same key/value pairs in a different order, should they be considered equal or not? (Only when we've answered this can we answer the question about keys/values/items). I'm not a frequent user of OrderedDict, so I don't have a good intuition, unfortunately. -- --Guido van Rossum (python.org/~guido) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/python-ideas/attachments/20151217/46f22df5/attachment.html>
- Previous message (by thread): [Python-ideas] Fwd: Why do equality tests between OrderedDict keys/values views behave not as expected?
- Next message (by thread): [Python-ideas] Fwd: Why do equality tests between OrderedDict keys/values views behave not as expected?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-ideas mailing list