| History. You do what your operating system vendor does. Not few operating systems have a C interface.
The implementation of binaries (see also application binary interfaces) depends on the operating system. Shared libraries (e.g., DLL) are binaries, too. C compiler developers have the ability to generate consistent[1] binary outputs. In simpler terms, vendors of these compilers can reach a consensus on how to convert C code into binary files, known as Application Binary Interfaces (ABI). It is not uncommon[2] to have a foreign function interface in C. 1. http://yosefk.com/c++fqa/defective.html 2. https://learn.microsoft.com/en-us/cpp/dotnet/calling-native-... |