[Python-3000] Ctypes as cross-interpreter C calling interface

Thomas Heller theller at python.net
Fri Aug 11 08:58:51 CEST 2006


Greg Ewing schrieb:
> Another thought about ctypes: What if you want to pass
> a Python function into C as a callback? Does ctypes
> have a way of handling that?
> 
Sure.  The tutorial has an example that calls qsort with a Python
comparison function:

http://docs.python.org/dev/lib/ctypes-callback-functions.html

Thomas



More information about the Python-3000 mailing list