Joshua J Cogliati added the comment:
>> using namespace std;
>Doing this in a header is ugly.
If you put it in the:
#ifdef __cplusplus
extern "C" {
#endif
then it would only apply till the end of the pyatomic header, and not to
anything that includes it. Something like:
#ifdef __cplusplus
extern "C" {
#if defined(HAVE_STD_ATOMIC)
using namespace std;
#endif
#endif
But if you are already defining:
#define _Atomic(T) atomic<T>
maybe it should be:
#define _Atomic(T) std::atomic<T>
(I haven't checked any of this code, but they would get around the namespace
std being changed in code that includes pyatomic.h problem. )
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue23644>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com