[Tutor] attribute of built-in type

spir denis.spir at free.fr
Fri Nov 28 21:55:59 CET 2008


I try to find a way to give a cutom type ('s instances) attributes like some 
built-in types have, for instance __name__. (For any reason, such attributes 
are not equally shared by all kinds of objects.)
I tried to achieve that with inheritance, but I couldn't make it work with 
built-in types. I suspect I should use metatypes -- but have no experience in 
that field. It is probably not a proper use, anyway.
Any hints welcome, thank you,

More information about the Tutor mailing list