Assuming your C interfaces are appropriately wrapped for C++, it is unnecessary to force the fakes to be declared extern "C", and doing so causes any functions declared with C++ linkage to be impossible to fake due to the conflicting linkage declarations.
This also adds a test case that proves a function with C++ linkage can be faked correctly, and fixes one test case that required some declarations to be seen with extern "C" before providing the fake implementation.
Assuming your C interfaces are appropriately wrapped for C++, it is unnecessary to force the fakes to be declared
extern "C"
, and doing so causes any functions declared with C++ linkage to be impossible to fake due to the conflicting linkage declarations.This also adds a test case that proves a function with C++ linkage can be faked correctly, and fixes one test case that required some declarations to be seen with
extern "C"
before providing the fake implementation.