Message293252
| Author |
rhettinger |
| Recipients |
David Becher, Mariatta, dholth, docs@python, eryksun, marco.buttu, martin.panter, rhettinger |
| Date |
2017年05月08日.20:28:45 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1494275325.99.0.861229065795.issue25435@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
> I think it is misleading, because a class is actually an object.
This is only misleading *after* you know all the interesting details about Python and metaclasses. Prior to that, it is a reasonable and important distinction that I don't want to get lost in weasel words. The calls from object.__getattribute__ are different that those from type.__getattribute__. Likewise, data and non-data descriptors can only be described in terms of objects versus classes. Lastly, descriptors only work when stored in a class, if you store them in instances, they don't get invoked. |
|