Build python extensions on-the-fly. Run C++ code directly from Python
Project description
Build python extensions on-the-fly.
Run C++ code directly from Python.
Links
Example
from cfly import build_module
mymodule = build_module('mymodule', '''
#define PY_SSIZE_T_CLEAN
#include <Python.h>
struct Foobar {
PyObject_HEAD
};
PyObject * meth_hello_world(PyObject * self) {
return PyLong_FromLong(1234);
}
''')
print(mymodule.Foobar)
print(mymodule.hello_world())
output
<class 'mymodule.Foobar'>
1234
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cfly-1.0.3.tar.gz
(9.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cfly-1.0.3.tar.gz.
File metadata
- Download URL: cfly-1.0.3.tar.gz
- Upload date:
- Size: 9.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c84696286ce80326596876600aec36c8ad96673e0752e11b32e927f05d94a815
|
|
| MD5 |
c77f0ecbf87a818878239f35ed3ad3e1
|
|
| BLAKE2b-256 |
106072118609267111d3fcb4d8c83eb1219cd2842f5c6ca10163abec2cbaa869
|
File details
Details for the file cfly-1.0.3-py2.py3-none-any.whl.
File metadata
- Download URL: cfly-1.0.3-py2.py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
615d3a509ca8453fdb6654aba9ee3f861d7459becd0a9a55250101636f179c6a
|
|
| MD5 |
09b516509c74773cebaf0d25b5775dcb
|
|
| BLAKE2b-256 |
f12d04b804f50a8479f64a7e0aa76907ddd05bb9f50fedf3fd4586adb4b7a64f
|