Re: [Cython] Compiler crash: forward declaration of cdef class with "public" attributes

2014-07-23 Thread Alok Singhal
On Wed, Jul 23, 2014 at 8:28 AM, Robert Bradshaw wrote: >> Also, if forward declarations are not recommended, what is the best >> way to declare two cdef classes that need to know about each other? >> (Short of "don't do that!" :-) ). > > Just do it without the forward declarations. Thanks! I di

Re: [Cython] Compiler crash: forward declaration of cdef class with "public" attributes

2014-07-23 Thread Robert Bradshaw
On Wed, Jul 23, 2014 at 12:29 AM, Alok Singhal wrote: > On Tue, Jul 22, 2014 at 11:42 PM, Robert Bradshaw wrote: >> On Tue, Jul 8, 2014 at 4:34 PM, Alok Singhal wrote: >> >> Thanks. >> https://github.com/cython/cython/commit/967c8e11da94ddae1ea7f1524f6beef2e030c4d9 > > Thanks for the fix! > >>

Re: [Cython] Compiler crash: forward declaration of cdef class with "public" attributes

2014-07-23 Thread Alok Singhal
On Tue, Jul 22, 2014 at 11:42 PM, Robert Bradshaw wrote: > On Tue, Jul 8, 2014 at 4:34 PM, Alok Singhal wrote: > > Thanks. > https://github.com/cython/cython/commit/967c8e11da94ddae1ea7f1524f6beef2e030c4d9 Thanks for the fix! > FWIW, forward declarations should not generally be needed, and > c

Re: [Cython] Compiler crash: forward declaration of cdef class with "public" attributes

2014-07-22 Thread Robert Bradshaw
On Tue, Jul 8, 2014 at 4:34 PM, Alok Singhal wrote: > Hi, > > I am getting a compiler crash with the following code: > > $ cat foo.pxd > cdef class Foo: > cdef public object x > $ cat foo.pyx > cdef class Foo > > cdef class Foo: > pass > $ ./cython.py foo.pyx > > Error compiling Cython fi

[Cython] Compiler crash: forward declaration of cdef class with "public" attributes

2014-07-08 Thread Alok Singhal
Hi, I am getting a compiler crash with the following code: $ cat foo.pxd cdef class Foo: cdef public object x $ cat foo.pyx cdef class Foo cdef class Foo: pass $ ./cython.py foo.pyx Error compiling Cython file: ... cdef class