[Cython] Exporting inline functions from a pyx.
robertwb at gmail.com
Thu May 28 20:16:13 CEST 2015
On Tue, May 26, 2015 at 7:17 PM, Jesus-Omar Ocegueda-Gonzalez
<jomaroceguedag at gmail.com> wrote:
> Dear Cython developers,
> thanks for the awesome compiler!, we recently faced an issue exporting
> inline functions defined in a .pyx. According to this:
> the full inline definition (not just the declaration) should be in the pxd.
> However, if we put the definition in the .pyx and just its declaration
> header in the .pxd,
Yes, it sounds like there's a bug here, but is there a reason you're doing this?
> Cython declares a pointer to the inline function
> similar to:
> static CYTHON_INLINE double (*__function_name)(...); /*proto*/
> but this causes a compilation error in some platforms (but successfully
> compiles in others) because variables cannot be declare as inline. You can
> find a log with the compilation errors here:
> I guess it should be possible to detect when a function is inline and in
> that case remove the CYTHON_INLINE from the pointer declaration, or at least
> consistently fail in all platforms. Is this a known issue?
> Thank you very much!
> With warm regards,
> "Cada quien es dueño de lo que calla y esclavo de lo que dice"
> -Proverbio chino.
> "We all are owners of what we keep silent and slaves of what we say"
> -Chinese proverb.
> cython-devel mailing list
> cython-devel at python.org
More information about the cython-devel