DEV Community

loading...

Discussion on: When your C++ code complains about undefined references

Collapse
dynamicsquid profile image
DynamicSquid

Is extern "C" all you need to compile C code in C++? What about the C only features?

Collapse
tenry profile image
Tenry Author

I never had trouble with that approach in the past, and most C libraries I see I could also only spot the extern "C" thing (if __cplusplus is defined). Do you have any C specific features in mind that could not work?

Collapse
dynamicsquid profile image
DynamicSquid

I think variable length arrays are one