On Feb 5, 2008 11:23 AM, David Cournapeau <[EMAIL PROTECTED]> wrote:
> Gael Varoquaux wrote:
> > On Tue, Feb 05, 2008 at 09:15:29AM +0100, Sebastian Haase wrote:
> >
> >> Can ctypes do this ?
> >>
> >
> > No. Ctypes is only a way of loading C (and not C++) libraries in Python.
> > That makes it very simple, but not very powerful.
> >
> I would not call ctypes not very powerful :) For sure you cannot do the
> same way as swig does, but you could imagine some automatic scheme to
> solve Sebastian's problem.
>
> Typically, having a C wrapper automatically generated from the C++
> headers, you could use the ctypes code generator, and you have something
> almost automatic (with a bit some boilerplate code in python, maybe).
>
> cheers,

Also feel free to extend this wiki:

http://wiki.cython.org/WrappingCorCpp

I use Cython, mostly for the same reasons Gael is using ctypes - it's trivial.

Ondrej
_______________________________________________
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to