[Zope3-dev] Interface.Implements module still broken for
2.2 metaclasses
Phillip J. Eby
pje@telecommunity.com
Mon, 08 Jul 2002 12:06:18 -0400
At 11:51 AM 7/8/02 -0400, Jim Fulton wrote:
>Steve Alexander wrote:
>> Phillip J. Eby wrote:
>>
>..
>
>
>> Ideally, they should, although that still doesn't deal with rolling your
>> own metaclass that doesn't derive from a standard class type. I don't
>> think there's a particularly elegant way to deal with that, though. yagni.
>
>If you're going to write your own meta class, you could write one that
>kept it's own dang __implements__ attribute separate from it's instances'.
>Then you wouldn't even need this awful hack. :)
>
I did that, or something like it. I wrote a metaclass that wraps
__implements__ and __class_implements__ in a descriptor that returns a
different value depending on whether it's retrieved from the class, or the
instance. Unfortunately, it doesn't help!