[Pyrex] casting warning
Eric Huss
e-huss at netmeridian.com
Thu Dec 15 10:13:47 CET 2005
The following snippet of code generates warnings when compiled by gcc:
cdef class A:
cdef foo(self):
print 'A.foo'
cdef class B(A):
cdef foo(self):
print 'B.foo'
test.c: In function `__pyx_tp_new_4test_B':
test.c:267: warning: assignment from incompatible pointer type
This only happens when you subclass something that has a cdef function and
redefine it. It seems benign, but I as wondering if anyone has figured
out a fix. It looks like the cast for the vtable assignment is simply
using the wrong type (perhaps should be using its base_type?).
-Eric
More information about the Pyrex
mailing list