[C++-sig] Re: Interest in luabind

Daniel Wallin dalwan01 at student.umu.se
Mon Jun 23 15:12:47 CEST 2003

> --- Daniel Wallin <dalwan01 at student.umu.se> wrote:
> > I mostly agree with everything you say. However, it may
> > still be of interest to be able to bypass the dynamic
> > dispatch system and use converters with static dispatch.
> I
> > fail to see how wrapping arrays of user-defined types is
> > easier with dynamic dispatch though.
> Maybe I wasn't precise enough here. It's not the wrapping
> that is
> easier***, but that fact that I do not have to explicitly
> export and
> import the converters.


> > How do you import the converters from one module to
> another?
> Hm, not having done the implementation I cannot tell for
> sure. I am
> guessing that the registry, which resides in
> boost_python.dll, holds
> essentially a few pointers to functions for the
> convertible() test and
> the construct() stage. The machine code for these
> functions is in the
> extension with the wrappers (i.e. the translation unit
> with the class_<>
> instantiation). The other extensions get these function
> pointers from
> the registry and then use the machine code from the first
> extension.


> > And how does type_info objects compare between dll
> > boundries?
> Again I can only offer a second-hand view. IIUC, on some
> platforms it is
> possible to compare type_info objects across dll
> boundaries as if they
> are in the same static link unit. I.e. there is nothing
> special. On some
> platforms this is not possible, and type_id::name is used
> instead.
> There is only one platform where relying on type_id::name
> caused a bit
> of a hick-up, namely IRIX/MIPSpro. See the comment near
> the top of the
> flew_fwd.h file (link in my previous message).

Ok. I guess you could unmangle the names to a standardized
format if there are problems with this?

Daniel Wallin

More information about the Cplusplus-sig mailing list