From: Dimitri Schoolwerth Date: Mon, 14 Feb 2005 14:53:28 +0000 (+0000) Subject: fixed Cygwin compilation (can't use extern "C" in C compilation) X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/724a248d8d53c894b9e44e0980cac11407d0cdf9 fixed Cygwin compilation (can't use extern "C" in C compilation) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/wxchar.h b/include/wx/wxchar.h index 32b9a24d1d..a47178e611 100644 --- a/include/wx/wxchar.h +++ b/include/wx/wxchar.h @@ -87,12 +87,17 @@ /* Cygwin versions, wchar.h requires sys/types.h */ #ifdef __CYGWIN__ #include - extern "C" { + #ifdef __cplusplus + extern "C" { + #endif #endif /* Cygwin */ - #include - #ifdef __CYGWIN__ + + #include + + #if defined(__CYGWIN__) && defined(__cplusplus) } - #endif /* Cygwin */ + #endif /* Cygwin and C++ */ + #elif defined(HAVE_WCSTR_H) /* old compilers have relevant declarations here */ #include