diff --git a/Include/pyport.h b/Include/pyport.h --- a/Include/pyport.h +++ b/Include/pyport.h @@ -657,6 +657,9 @@ #endif #ifdef _PY_PORT_CTYPE_UTF8_ISSUE + +#ifndef __cplusplus + #include #include #undef isalnum @@ -673,7 +676,11 @@ #define tolower(c) towlower(btowc(c)) #undef toupper #define toupper(c) towupper(btowc(c)) -#endif + +#endif /* !__cplusplus */ + + +#endif /* _PY_PORT_CTYPE_UTF8_ISSUE */ /* Declarations for symbol visibility.