On Mon, Jan 18, 2010 at 9:48 PM, Ben Fitzpatrick <
bfitzpatr...@vtiinstruments.com> wrote:

>  Hi everyone,
>
>
>
> I am trying to wrap a section of C++ code with many enum types in it, of
> the form:
>
>
>
> enum Blah
>
> {
>
>   BlahSomething1 = 1000;
>
>   BlahSomething2 = 1001;
>
> }
>
>
>
> Thanks to this definition - pulled into pybindgen via automagical pygccxml
> parsing of some header files - code of the form
>
> Blah here_is_a_variable;
>
>
>
> Is recognized just fine and works great. However, code of the form
>
> Blah* here_is_a_variable;
>
>
>
> Is not recognized because pybindgen/pygccxml can’t find an explicit
> definition of a Blah*.  I am wondering if there’s a simple way to convert
> these programmatically – that is, not have to write a to_python converter
> for each one, especially since they’re all of the generic form “(enum)*”.
> The code I am wrapping is not guaranteed API-stable, and I’m trying to
> automate as much parsing as possible. Any suggestions?
>

If I understand correctly, you are just missing the enum* type handler,
which should have been implemented in pybindgen, but I am lazy and often
only implement things as they become needed.

You can download a patch from here:

http://bazaar.launchpad.net/~gjc/pybindgen/trunk/revision/741


>
>
> Thanks,
>
> Ben
>
> _______________________________________________
> Cplusplus-sig mailing list
> Cplusplus-sig@python.org
> http://mail.python.org/mailman/listinfo/cplusplus-sig
>



-- 
Gustavo J. A. M. Carneiro
INESC Porto, Telecommunications and Multimedia Unit
"The universe is always one step beyond logic." -- Frank Herbert
_______________________________________________
Cplusplus-sig mailing list
Cplusplus-sig@python.org
http://mail.python.org/mailman/listinfo/cplusplus-sig

Reply via email to