|
|
|
|
|
by reipahb
4055 days ago
|
|
Personally, I would really like to see more Python extensions written using the ctypes foreign function library. This has two advantages: * Supported on more than just CPython. I.e. you can use them on PyPy as well. * The extensions are far easier to install, since one doesn't need both a full C compiler as well as all development headers for the library installed on the server where you install the extension. |
|
I wanted to use ctypes to wrap a C library for a recent project (for the ease of installation and development that you mention) but had to give up when it turned out to be more than 10x slower than a wrapper written in Cython, and barely faster than doing a pure Python implementation of the C library itself.