On Jun 17, 2010, at 9:31 AM, Lisandro Dalcin wrote:

> If we special case a __dict__ attribute in extension types, i.e:
>
> cdef class Foo:
>    cdef dict __dict__
>
> and fill type->tp_dictoffset, then we can support __dict__ in  
> extension types.
>
> What do you think?

Sounds like a good idea to me. Note that we check tp_dictoffset for  
fast dispatching for cpdef methods (which would be correct as a dict  
lookup *would* be needed if __dict__ is available).

- Robert

_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to