The C++ compiler must know that f(int, char, float) is to be called by a C compiler using the same extern C construct detailed in the previous FAQ. Then you define the function in your C++ module:
void f(int x, char y, float z) { //... }The extern C line tells the compiler that the external information sent to the linker should use C calling conventions and name mangling (e.g., preceded by a single underscore). Since name overloading isn't supported by C, you can't make several overloaded fns simultaneously callable by a C program.
Caveats and implementation dependencies: