➜

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.

作者 avrahami.ben
收信人 avrahami.ben, eric.smith, gvanrossum, python-dev, rhettinger
日期 2020-10-03.15:29:55
SpamBayes Score -1.0
Marked as misclassified 是
Message-id <1601738995.61.0.526442189939.issue41905@roundup.psfhosted.org>
In-reply-to
内容
> Maybe you misunderstand what I tried to say?

Possibly, right now, total_ordering avoids overriding any method that is declared, either in the class or its superclasses (except for object), regardless of whether or not it is abstract. For it to be ABC-aware, it would need the ability to override abstract methods defined in superclasses, so we need to check whether an exisitng method is abstract.

Additionally we want to not override abstract methods defined in the subject class, so we also need to check whether the method is defined in the class __dict__ (that's the extra logic I was referring to).

An argument could be made that total_ordering should override any method not defined in the subject class, abstract or no (implementing this logic would also speed up total_ordering, but that's beside the point).

Is this what you meant?
历史
日期 用户 动作 参数
2020-10-03 15:29:55avrahami.ben修改recipients: + avrahami.ben, gvanrossum, rhettinger, eric.smith, python-dev
2020-10-03 15:29:55avrahami.ben修改messageid: <1601738995.61.0.526442189939.issue41905@roundup.psfhosted.org>
2020-10-03 15:29:55avrahami.ben链接issue41905 messages
2020-10-03 15:29:55avrahami.ben创建