Re: [sage-devel] Re: Cython and #define

2010-07-26 Thread Peter Jeremy
On 2010-Jul-26 02:52:50 -0700, Simon King wrote: >Hi! > >On 26 Jul., 11:09, Jeroen Demeyer wrote: >> More concretely: in the pari source file src/headers/parigen.h, there is >> #define lgefint(x)      ((long)(((ulong*)(x))[1] & LGBITS)) >> >> But in Sage, in sage/libs/pari/decl.pxi, there is >>  

Re: [sage-devel] Re: Cython and #define

2010-07-26 Thread Carl Witty
On Mon, Jul 26, 2010 at 2:52 AM, Simon King wrote: > Nonetheless, Cython needs to know what argument type and type of > output to expect. Therefore, one has "long lgefint(GEN x)" in the > Cython header. > > It works (at least for me). I admit that it somehow looks wrong, and > indeed it results in