Ask your own question, for FREE!
Computer Science 13 Online
OpenStudy (anonymous):

On lots of C++ header files I read, I see constructs like this: // Near the top, after the header guard: #ifdef __cplusplus extern "C" { #endif // ... // Rest of header file // ... And at the bottom..., often right before the closing #ifdef for the header guard: #ifdef __cplusplus } #endif What are they for?

OpenStudy (espex):

It hides certain code from the C compilers which enables you to share libraries without confusing the compiler. The wrapped section will only be visible IF the compiler is defined as a C++ compiler.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!