GCC target-specific extension
Michael S. Zick
mszick@goquest.com
Wed May 7 14:53:00 GMT 2003
On Wednesday 07 May 2003 12:51 am, Fabio Alemagna wrote:
> On Tue, 6 May 2003, Richard Henderson wrote:
> > On Wed, May 07, 2003 at 01:33:44AM +0200, Fabio Alemagna wrote:
> > > Inline functions aren't good because they need a global libbase (unless
> > > you passed one to it as parameter, which again I want to avoid),
> >
> > Oh, I thought a parameter was where you were getting your
> > libbase in the first place.
>
> Implicitely, not explicitely. It's like a C++ virtual method call, the
> libbase being the "this" pointer.
>
Just lurking on the sidelines here, but perhaps that is a workaround
to consider:
Define a C++ "wrapper" for your library;
The entry points in your library as virtual methods;
Compile;
Do some linker magic to extract just the virtual method table.
Mike
PS: Too bad about "arbitrary transforms" being out of the
question - no: C++ -> Basic allowed
[GoSub( virtual-method, arguments...)].
More information about the Gcc
mailing list