<div dir="ltr">It was a mistake. I just wanted to export a function from the .pyx, and I did not consider the fact that inline functions should be treated differently (the standard procedure for me was just to add the declaration in the .pxd, the inline thingy looked inoffensive =) ). The inconvenient was that in my local machine, and the reviewers' everything worked ok, but we started getting a lot of compilation errors in other platforms after my pull request was merged.</div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, May 28, 2015 at 1:16 PM, Robert Bradshaw <span dir="ltr"><<a href="mailto:robertwb@gmail.com" target="_blank">robertwb@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Tue, May 26, 2015 at 7:17 PM, Jesus-Omar Ocegueda-Gonzalez<br>
<<a href="mailto:jomaroceguedag@gmail.com">jomaroceguedag@gmail.com</a>> wrote:<br>
> Dear Cython developers,<br>
> thanks for the awesome compiler!, we recently faced an issue exporting<br>
> inline functions defined in a .pyx. According to this:<br>
> <a href="http://docs.cython.org/src/tutorial/pxd_files.html" target="_blank">http://docs.cython.org/src/tutorial/pxd_files.html</a><br>
> the full inline definition (not just the declaration) should be in the pxd.<br>
> However, if we put the definition in the .pyx and just its declaration<br>
> header in the .pxd,<br>
<br>
</span>Yes, it sounds like there's a bug here, but is there a reason you're doing this?<br>
<span class=""><br>
> Cython declares a pointer to the inline function<br>
> similar to:<br>
><br>
> static CYTHON_INLINE double (*__function_name)(...); /*proto*/<br>
><br>
> but this causes a compilation error in some platforms (but successfully<br>
> compiles in others) because variables cannot be declare as inline. You can<br>
> find a log with the compilation errors here:<br>
> <a href="http://nipy.bic.berkeley.edu/builders/dipy-py2.7-osx-10.8/builds/362/steps/shell_5/logs/stdio" target="_blank">http://nipy.bic.berkeley.edu/builders/dipy-py2.7-osx-10.8/builds/362/steps/shell_5/logs/stdio</a><br>
><br>
> I guess it should be possible to detect when a function is inline and in<br>
> that case remove the CYTHON_INLINE from the pointer declaration, or at least<br>
> consistently fail in all platforms. Is this a known issue?<br>
><br>
> Thank you very much!<br>
> With warm regards,<br>
> -Omar.<br>
> --<br>
> "Cada quien es dueño de lo que calla y esclavo de lo que dice"<br>
> -Proverbio chino.<br>
> "We all are owners of what we keep silent and slaves of what we say"<br>
> -Chinese proverb.<br>
><br>
> <a href="http://www.cimat.mx/~omar" target="_blank">http://www.cimat.mx/~omar</a><br>
><br>
</span>> _______________________________________________<br>
> cython-devel mailing list<br>
> <a href="mailto:cython-devel@python.org">cython-devel@python.org</a><br>
> <a href="https://mail.python.org/mailman/listinfo/cython-devel" target="_blank">https://mail.python.org/mailman/listinfo/cython-devel</a><br>
><br>
_______________________________________________<br>
cython-devel mailing list<br>
<a href="mailto:cython-devel@python.org">cython-devel@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/cython-devel" target="_blank">https://mail.python.org/mailman/listinfo/cython-devel</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">"Cada quien es dueño de lo que calla y esclavo de lo que dice"<br>-Proverbio chino.<br>"We all are owners of what we keep silent and slaves of what we say"<br>-Chinese proverb.<br><br><a href="http://www.cimat.mx/~omar" target="_blank">http://www.cimat.mx/~omar</a><br></div>
</div>