Cython cimport cannot find .pxd module

两盒软妹~` 提交于 2019-12-06 09:19:16

I overlook that I had some lines as:

cdef INT_t some_int = 1

However, in the .pxd file, there cannot be any executable code. In this case, it seems Cython treats it as a package, which is not as there is .pyx file.

There might be two methods to work around:

  1. cdef extern from a C header.

  2. Wrap-up to inline functions.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!