[pypy-dev] cppyy and callbacks

Armin Rigo arigo at tunes.org
Fri Jan 24 14:15:27 CET 2014


Hi,

On Thu, Jan 23, 2014 at 10:36 PM,  <wlavrijsen at lbl.gov> wrote:
>> I was considering the possibility of taking an index or id() of the object
>> and just casting it into "void*" form, and then converting it back and
>> using it to look up objects in a list/dict somewhere..
>
> Alex Pyattaev did this (is in the pypy-dev mail archives, somewhere around
> early Summer 2012).

This exists in CFFI (see ffi.new_handle()).  More generally, wouldn't
it make some sense to try to bring cppyy closer to cffi?  It is a
change of some of the basics, so only suitable for people without an
existing code base.  What I'm thinking of is if we could consider a
cppyy-like interface as an extension of the cffi interface, like C++
is an extension of C, or if it doesn't really make sense.


A bientôt,

Armin.


More information about the pypy-dev mailing list