Next: , Previous: Structure of the source code, Up: Developers


9.5 C/C++ coexistence

There is no problem in having both C and C++ in the same program. However, there is no technical reason for this heterogeneity. The only reason is the different origins of the code. It is desirable to get a more homogeneous program in the future.

PolyGlot and Fruit have a common origin, which means that there is a lot of shared code. The point is that the shared code is very similar but not identical, which would make hard an eventual unification. In order to avoid massive name clash, all the code has been wrapped in namespaces, one for the adapter, one for the engine. The frontend remains compiled as C code.