On Mon, Dec 22, 2003 at 01:34:17PM +1100, Daniel Stone wrote: > #ifdef __cplusplus > extern "C" { > #endif > > [...] > > #ifdef __cplusplus > } > #endif
There seem to be macros in place for this already, in Xfuncproto.h: #ifndef _XFUNCPROTOBEGIN #if defined(__cplusplus) || defined(c_plusplus) /* for C++ V2.0 */ #define _XFUNCPROTOBEGIN extern "C" { /* do not leave open across includes */ #define _XFUNCPROTOEND } #else #define _XFUNCPROTOBEGIN #define _XFUNCPROTOEND #endif #endif /* _XFUNCPROTOBEGIN */ The other headers wrap their declarations in these macros. -- - mdz