[Cython] [Python-Dev] C-level duck typing
robertwb at gmail.com
Thu May 31 20:22:18 CEST 2012
On Thu, May 31, 2012 at 7:20 AM, Dag Sverre Seljebotn
<d.s.seljebotn at astro.uio.no> wrote:
> SEP updated (to what I hope is the final form):
> - Remove the flags concept; option a) above
> - Use the tp_flags bit. (I benchmarked walking the type hierarchy, and it
> doesn't cost if you don't take the branch, but I'm much happier for clients
> to avoid having to rendezvous on the metaclass, in particular if this is
> used in the NumPy API).
> - All manually allocated IDs have the least significant bit set, so that
> one can also use 2-byte aligned pointers as IDs (e.g., objects representing
> interfaces or interned strings can be used as slot IDs).
More information about the cython-devel