template External Linkage ?can anyone Explain this?

后端 未结 4 1268
夕颜
夕颜 2021-02-10 02:05

A template name has linkage (3.5). A non-member function template can have internal linkage; any other template name shall have external linkage. Entities generat

4条回答
  •  无人及你
    2021-02-10 02:14

    extern "C" is used to change symbol name of C++ function in order to use them from a C program.

    In C++, function prototype is "coded" in symbol name, this is a requirement for overloading. But in C, you don't have a such feature.

    extern "C" allow to call C++ function from a C program.

    extern "C" is not what you are looking for.

    Could you please explain what do you want to do ?

提交回复
热议问题