Hi,
UFFI is prepared to call C functions, all the handling of the
functions is intended to call libraries exposing a C API. C++ presents
a series of complexities, the main two are the mangling of the names
(as C++ allows to have parameter overloading in the functions, the
name of the real functions in the generated binary have codified the
type of the return value and the parameters), and the templating of
types when performing calls with complex types. Both elements (and
others) are implementation dependant, each compiler is free to
implement in a different way. So, there is no single ABI (Application
Binary Interface), there is an attempt to have a single ABI since
C++11 but that is not 100% compatible. These behavior can be
implemented in Pharo, for UFFI, but there is nothing done in that
sense.
That is why many libraries and API exposes a C API to use it.
Cheers,
Pablo
On Fri, Jun 12, 2020 at 10:55 AM shawon58 <
[hidden email]> wrote:
>
> Hello There
> i am new to Pharo, so as i learn UFFI can handle c code, but i want to know
> that, is there any way to compile/run a c++ file using pharo, because i made
> a file for creating a box in FreeCAD using C++ code, so if i can compile
> that file using pharo than one part of my work will be done than i can start
> other part.
>
> So if anyone have idea please share with me. It will be a great help to me.
>
> Thanks for your kind help
>
>
>
> --
> Sent from:
http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html>
--
Pablo Tesone.
[hidden email]