Extern "C" function internally uses C++ class

This question already has an answer here:

  • What is the effect of extern “C” in C++? 12 answers

  • This is perfectly legitimate. The purpose of extern "C" is to prevent Func() from getting its name mangled (decorated with type information) so that a C module can link to it using its plain name. C++ mangles names so that functions with the same name but different parameter lists can be resolved (function overloading).

    链接地址: http://www.djcxy.com/p/40488.html

    上一篇: jni无法从本地库找到方法?

    下一篇: 外部“C”函数内部使用C ++类