[Numpy-discussion] numpy.i

Ross Harder rharderlists@gmail....
Tue Jan 26 00:42:38 CST 2010


I'm struggling with using some of the macros in numpy.i for my own typemap.
The problem is that the arrayobject.h include does not end up in the c
wrapper code after swig runs.
numpy.i has at the beginning:
%{
#ifndef SWIG_FILE_WITH_INIT
#  define NO_IMPORT_ARRAY
#endif
#include "stdio.h"
#include <numpy/arrayobject.h>
%}

I tried explicitly putting %{#include "arrayobject.h"%} into the
interface file.  It ends up after the fragment code in the wrapper so
the compiler is complaining.

thanks,
ross


More information about the NumPy-Discussion mailing list