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.
Created on 2013年02月07日 15:34 by franck, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg181620 - (view) | Author: Franck Michea (franck) * | Date: 2013年02月07日 15:34 | |
Hi. As of python 3, behavior of object.__ne__ changed to call (not object.__eq__) if implemented. This changement can be seen in function object_richcompare in file Objects/typeobject.c. Documentation didn't change though, still saying[1] that "There are no implied relationships among the comparison operators. [...] Accordingly, when defining __eq__(), one should also define __ne__()". Maybe a paragraph about this new behavior would be fine? I am not sure if last sentence of last paragraph is what it means, but it was already there in python 2 doc so guess no. I am not sure about how to write it so no patch, sorry. [1] http://docs.python.org/3.3/reference/datamodel.html#object.__eq__ |
|||
| msg181629 - (view) | Author: Mark Dickinson (mark.dickinson) * (Python committer) | Date: 2013年02月07日 16:27 | |
There's a (long-standing) issue already open for this: #4395. I'll close this as a duplicate and add a note to that issue; with any luck, pinging that issue might produce some movement. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:41 | admin | set | github: 61353 |
| 2013年02月07日 16:27:09 | mark.dickinson | set | status: open -> closed nosy: + mark.dickinson messages: + msg181629 superseder: Document auto __ne__ generation; provide a use case for non-trivial __ne__ resolution: duplicate |
| 2013年02月07日 15:34:19 | franck | create | |