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.

Author r.david.murray
Recipients Justin.Eldridge, docs@python, r.david.murray
Date 2015-01-25.20:28:10
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1422217690.54.0.82660210641.issue23317@psf.upfronthosting.co.za>
In-reply-to
Content
I believe that you are correct: special methods are looked up on the type, and this is assumed implicitly in the Class Binding description. (This was not 100% true in python2, but it is in current python3.)  But the Class Binding description is correct, since if the __get__ method is *not* defined on the type (of the descriptor), the descriptor instance itself is returned (so explicitly calling type in the "equivalent expression" would be wrong).

This is one of the most complex topics to describe in Python (I still don't have it solid in my head and I've been working with Python for years now).  If we can come up with clearer wording that is good, but we've tried several times already to improve it :(

I don't know what you are referring to for the 'instance binding' that makes the same 'mistake', but I suspect it is also covered by the "special methods are looked up on the type" rule.
History
Date User Action Args
2015-01-25 20:28:10r.david.murraysetrecipients: + r.david.murray, docs@python, Justin.Eldridge
2015-01-25 20:28:10r.david.murraysetmessageid: <1422217690.54.0.82660210641.issue23317@psf.upfronthosting.co.za>
2015-01-25 20:28:10r.david.murraylinkissue23317 messages
2015-01-25 20:28:10r.david.murraycreate