[fpc-pascal] Re: Library callback : how do I do that?
Marco van de Voort
marcov at stack.nl
Fri Aug 9 13:23:13 CEST 2013
In our previous episode, Sven Barth said:
> It's not only the memory that needs to be shared. All DLLs need to use
> the same RTL functions and the VMT pointers need to be equal as well. If
> you have two DLLs and both use TObject than for a TObject variable of
> DLL A "is" is not true for a TObject from DLL B. This is what runtime
> packages solve correctly (in addition to dependency loading, etc).
I assume I don't have to tell you, but for the benefits of others:
In general, there is only one copy of anything in a system with packages, so
the unit's code and const parts (rtti/vmts) and its state
(variables) only exist once. Both from RTL and user parts.
And there already is much more crucial global state (locale,
exception/synchronize system, unicode codepage stuff in trunk etc) than just
More information about the fpc-pascal