> On 12 sep. 2013, at 17:30, "R. David Murray" <rdmur...@bitdance.com> wrote: > >> On Thu, 12 Sep 2013 16:42:39 +0200, Ronald Oussoren <ronaldousso...@mac.com> >> wrote: >> >>> On 9 Sep, 2013, at 20:23, Jan Kaliszewski <z...@chopin.edu.pl> wrote: >>> >>> Is '__locallookup__' a really good name? In Python, *local* -- >>> especially in context of *lookups* -- usually associates with >>> locals() i.e. a namespace of a function/method execution frame or a >>> namespace of a class, during *definition* of that class... So >>> '__locallookup__' can be confusing. >>> >>> Why not just '__getclassattribute__' or '__classlookup__', or >>> '__classattribute__'...? >> >> I don't particularly like __locallookup__ either, but haven't found a >> better name yet. "__lookup_in_class__" was the best alternative I >> could come up with, and that feels different than other special >> methods. The name in the PEP is more or less derived from >> _PyType_Lookup, with "local" meaning "only in this class, don't >> recurse in the rest of the MRO". > > Why is __getclassattribute__ worse than __locallookup__?
Getclassattribute feels like it is related to classmethod, or fetches an attribute of a class. The method does however fetch a value from the class that is transformed to the actual attribute value through the descriptor protocol. Ronald > > --David > _______________________________________________ > Python-Dev mailing list > Python-Dev@python.org > https://mail.python.org/mailman/listinfo/python-dev > Unsubscribe: > https://mail.python.org/mailman/options/python-dev/ronaldoussoren%40mac.com _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com