[C++-sig] Protected destructor compile error

Allen Bierbaum abierbaum at gmail.com
Sat Jun 24 16:10:47 CEST 2006

On 6/23/06, Roman Yakovenko <roman.yakovenko at gmail.com> wrote:
> On 6/23/06, Allen Bierbaum <abierbaum at gmail.com> wrote:
> > I could always just try to make some smart wrapper code with
> > pyplusplus that automatically detects this case and creates a thin
> > wrapper for me.  (any ideas here Roman?)
> Actually yes. You have 2 ways to go:
> 1. Contribute to pyplusplus:
>     1. Add code to pyplusplus.decl_wrappers.calldef_t.has_wrapper.
> This code should
>         "understand", that function takes an argument const reference to
>         non-destructable object.
>     2. Add code that generates wrapper code to
> code_creators/calldef.py relevant
>         classes.
>     This is not should be very difficult. If you need more
> information, please ask on
>     pyplusplus mailing list.

Sounds interesting but I don't know that code nearly as well as you.  :)

> 2. Easy and quick.
>     Build custom small code generator, that will generate function
> wrapper, for every
>     function, that takes as argument "const Viewport&". After this, exclude all
>     original functions and replace them with new functions. This
> should work and it
>     should take less then an hour to implement it.

This one sounds more approachable to me right now.  The question I
have though is how to add the function wrapper code to the generated
code.  Is this something I can do to the class decl wrapper?  What
method do I use to add it?  (if you provide pseudo code I can fill in
all the details and debug it)

Thanks for the quick reply.


> --
> Roman Yakovenko
> C++ Python language binding
> http://www.language-binding.net/
> _______________________________________________
> C++-sig mailing list
> C++-sig at python.org
> http://mail.python.org/mailman/listinfo/c++-sig

More information about the Cplusplus-sig mailing list