[issue16831] Better docs for ABCMeta.__subclasshook__

2012-12-31 Thread Ramchandra Apte
Changes by Ramchandra Apte : -- assignee: -> docs@python components: +Documentation nosy: +docs@python ___ Python tracker ___ ___ Pyt

[issue16831] Better docs for ABCMeta.__subclasshook__

2012-12-31 Thread Nick Coghlan
Nick Coghlan added the comment: Also, we should probably explain the approach we chose to follow in the stdlib, where we block implicit inheritance of __subclasshook__ behaviour by include an explicit type check at the start of the implementation, so it always returns NotImplemented when the f

[issue16831] Better docs for ABCMeta.__subclasshook__

2012-12-31 Thread Nick Coghlan
New submission from Nick Coghlan: Authors of __subclasshook__ methods need to decide between returning True, False and NotImplemented in various cases. Making that decision requires a clear understanding that the checks in ABCMeta.__subclasscheck__ occur in the following order: - explicit reg