Re: Qt4, Windows, and Euphoria
- Posted by Matt Lewis <matthewwalkerlewis at gmail.com> Jul 05, 2005
- 558 views
Travis Beaty wrote: > > > Vincent wrote: > > >How does one go about wrapping Object Oriented C++ libraries with Euphoria? > >It can be done, Matt > has demonstrated that with wxEuphoria. But I just dont understand how. Is > there some interfacing library?</font></i> > > > >If there is a C++ interfacing Euphoria library. I would like to have it in my > >library> > > > Hello. > > I am unsure at what specific libraries are available in Euphoria for > this task. > > The key problem to interfacing with C++ code is "name mangling." This > mangling is done by C++ compilers in order to enable overloaded > functions, functions which have the same name but are differentiated > only by their footprint, or the types of parameters they take. Because > of name mangling, a C++ method, say Foo(), could end up being seen by > Euphoria as Z9943_object_Foo6. The process of name mangling is not > random, but it is complicated. > > This can be defeated by externing functions. An example: The way I dealt with it was to output the list of exports mangled and demangled. On Windows I used Dependency Walker, and on Linux I used nm. Then I could translate between mangled and demangled easily. How does using extern handle overloaded methods? Matt Lewis