cplusplus-sig  

[C++-sig] Boost Python: C++ struct with a function pointer

puneet goel
Tue, 02 Mar 2010 03:10:00 -0800

Greetings

I am boost.python newbie. I tried searching the web for a solution but
could not find one.
I am trying to generate Python Bindings for a C++ API. The API has
some data structures with a set function pointers as its members.

struct foo {
public:
  int a, b;
  char *str;

  int (*func1) ();
  int (*func2) ();
};

I am wondering if it is possible to bind this struct to Python. Let me
know how this can be done.

Regards
- Puneet
_______________________________________________
Cplusplus-sig mailing list
Cplusplus-sig@python.org
http://mail.python.org/mailman/listinfo/cplusplus-sig