diff --git a/include/cxx/cwctype b/include/cxx/cwctype index 5a8f35c0fb..7c0424c539 100644 --- a/include/cxx/cwctype +++ b/include/cxx/cwctype @@ -48,7 +48,9 @@ namespace std { + using ::wint_t; using ::wctrans_t; + using ::wctype_t; using ::iswalnum; using ::iswalpha; diff --git a/include/wctype.h b/include/wctype.h index fac596eae1..39f338940e 100644 --- a/include/wctype.h +++ b/include/wctype.h @@ -81,6 +81,14 @@ typedef int wctrans_t; * Public Function Prototypes ****************************************************************************/ +#ifdef __cplusplus +#define EXTERN extern "C" +extern "C" +{ +#else +#define EXTERN extern +#endif + /* "The header declares the following as functions and may also * define them as macros. Function prototypes must be provided for use with * an ISO C compiler." @@ -108,4 +116,9 @@ wctrans_t wctrans(FAR const char *); int iswctype(wint_t, wctype_t); wctype_t wctype(FAR const char *); +#undef EXTERN +#ifdef __cplusplus +} +#endif + #endif /* INCLUDE_WTYPE_H */