SWIG vs. ctypes (Was: ANN: PyEnchant 1.5.0)

Diez B. Roggisch deets at nospam.web.de
Tue Nov 25 10:34:39 EST 2008


Roy Smith wrote:

> In article <mailman.4514.1227625056.3487.python-announce-list at python.org>,
>  Ryan Kelly <ryan at rfk.id.au> wrote:
> 
>> * Migrated from SWIG to ctypes for the C binding:
> 
> Ryan,
> 
> I'm looking at a doing a Python wrapper for a C++ library.  We've already
> done a Perl wrapper for this library using SWIG (I wasn't personally
> involved in that effort).  I'm debating whether I should do the Python
> version with SWIG or ctypes.  I'd be interested to hear about your
> experiences with both and why you switched.

You can't use ctypes for C++, only for C-style APIs.

Diez



More information about the Python-list mailing list