You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bpo-4395: Document auto ne generation; provide a use case for non-trivial ne
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2013-02-07.16:27:09.031>created_at=<Date2013-02-07.15:34:19.227>labels= ['docs']
title='Python 3 changement of behavior with __ne__: documentation not updated'updated_at=<Date2013-02-07.16:27:09.029>user='https://bugs.python.org/franck'
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.
There's a (long-standing) issue already open for this: bpo-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.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: