basileis
7/12/2011 6:28:00 AM
On Jul 12, 11:15 am, Wang WolfLouis <wolflouisw...@gmail.com> wrote:
> Now, I want to use C code calling library which is created by g++,
> how could I define the c++ library header file?
> it should be extern "C" {
>
> ....
>
> }
>
> ?
Whatever function or variable exposed in extern "C" block can be used
by C source . A function which is declared to have C linkage can use
all the features of C++ but it's parameter and return type should be
accessible from C source from where you are calling this code.