Closed gabortim closed 1 year ago
The header files of the library currently lack extern "C" {} block, making it tricky to use in C++ projects. To improve compatibility, I propose adding the following to the library's header files:
extern "C" {}
#ifdef __cplusplus extern "C" { #endif // existing header content #ifdef __cplusplus } #endif
This change ensures that the library can be linked in C++ projects without encountering name mangling issues.
Reference: Stack Overflow - Explanation of extern "C".
Thank you for the suggestion. We will add a c++ header guard to ensure out-of-the box compatibility with c++ programs.
The header files of the library currently lack
extern "C" {}
block, making it tricky to use in C++ projects. To improve compatibility, I propose adding the following to the library's header files:This change ensures that the library can be linked in C++ projects without encountering name mangling issues.
Reference: Stack Overflow - Explanation of extern "C".