[C++-sig] Re: Re: Boost.Python v2: object facilities updated

Dave Hawkes daveh at cadlink.com
Thu Jun 20 04:30:34 CEST 2002


"David Abrahams" <david.abrahams at rcn.com> wrote in message
news:0c2701c217f5$a62e3e30$6601a8c0 at boostconsulting.com...
I
> > anticipated, but that will probably change when the API wrappers are
> > complete. If that's not far away then it's probably not worth worrying
> > about.
>
> In theory it's not, but I could really use some help with that stuff. Do
> you think you might take on the job of fleshing out the missing pieces?
> It's fairly mechanical, mostly, but requires some attention. My idea was
to
> follow the Python/C API documentation and make files like
> object_protocol.hpp which mirror pages like
> http://www.python.org/dev/doc/devel/api/object.html. Of course, many
> functions are covered by the operators already defined, so we don't need
> separate functions for those. The idea is just to cover the built-in
> functions (http://www.python.org/dev/doc/devel/lib/built-in-funcs.html)
and
> any 'C' API functions which aren't otherwise handled.
>

I have a number of ideas for an aproach to this, but I want to try a couple
of things before I post here. Once I'm clear what's involved I can let you
know if I can do this, plus some timescales.

An issue I keep having with 'object' is the lack of a default constructor. I
think this may have been discussed before, but I can't remember the outcome.
What is the reason for not creating a Py_None object with the default
constructor? With all its extra functionality now it can be used for much
more than just capturing return values. It is occasionally useful to declare
an object and defer its actual assignment.

Dave Hawkes










More information about the Cplusplus-sig mailing list