On Wed, May 6, 2009 at 10:38 AM, Robert Bradshaw <[email protected]> wrote: > I already implemented this optimization, though only for cdef classes > within the same module. (If they're small enough, they may get even > inlined by the C compiler.) I'm not sure how possible this would be > to do across modules, but one difficulty is that the contents of > tp_new can change based on the .pyx file, not just the .pxd file.
Really? What in the .pyx file can change tp_new? (I'm mostly just curious.) Across modules, you should at least be able to call the tp_new function directly instead of going through the vtable. (I assume from the .pxd file you can at least determine the mangled name of the base's tp_new function?) Carl _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
