Hi, Could I include cpp files in a pascal program? How to do? I tried with c file and it works. But I would like to know the problems about name mangling. Actually, what happens if in my cpp file, I have 2 functions with the same name? What are their declarations to use them in my pascal programs? thanks
Mehdi Khaldi wrote:
Could I include cpp files in a pascal program? How to do? I tried with c file and it works. But I would like to know the problems about name mangling. Actually, what happens if in my cpp file, I have 2 functions with the same name? What are their declarations to use them in my pascal programs?
I suppose cpp = C++?
You can't directly access C++ declarations from GPC. You need a "plain C" interface (`extern "C" { ... }' in C++), which might require wrapper functions.
Frank