homepage

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 georg.brandl
Recipients amaury.forgeotdarc, eryksun, georg.brandl, pitrou, techdragon
Date 2014年11月04日.09:59:58
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1415095199.37.0.230269612912.issue22790@psf.upfronthosting.co.za>
In-reply-to
Content
"Attributes from the metaclass have always been excluded from the dir() of a class."
Be that as it may, I think it is wrong. I can understand excluding methods of the metaclass, but __qualname__ (and friends) are only defined in the metaclass because they are properties and not __dict__ members, but they are regular attributes of the class, not of the metaclass.
E.g. why is __module__ in there and not __qualname__? Both are determined dynamically at class creation time.
The answer is that it's an implementation detail: there is no tp_module (or ht_module) member in the PyHeapTypeObject struct to store it, so it's stored in __dict__, while __qualname__ is stored in a struct member.
History
Date User Action Args
2014年11月04日 09:59:59georg.brandlsetrecipients: + georg.brandl, amaury.forgeotdarc, pitrou, eryksun, techdragon
2014年11月04日 09:59:59georg.brandlsetmessageid: <1415095199.37.0.230269612912.issue22790@psf.upfronthosting.co.za>
2014年11月04日 09:59:59georg.brandllinkissue22790 messages
2014年11月04日 09:59:58georg.brandlcreate

AltStyle によって変換されたページ (->オリジナル) /