diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/thread/qbasicatomic.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/corelib/thread/qbasicatomic.h b/src/corelib/thread/qbasicatomic.h index 6072212350..4177ddbd39 100644 --- a/src/corelib/thread/qbasicatomic.h +++ b/src/corelib/thread/qbasicatomic.h @@ -117,7 +117,18 @@ QT_END_HEADER // New atomics #if defined(Q_COMPILER_CONSTEXPR) && defined(Q_COMPILER_DEFAULT_MEMBERS) && defined(Q_COMPILER_DELETE_MEMBERS) -# define QT_BASIC_ATOMIC_HAS_CONSTRUCTORS +# if defined(Q_CC_CLANG) && ((((__clang_major__ * 100) + __clang_minor__) < 302) \ + || defined(__apple_build_version__) \ + ) + /* Do not define QT_BASIC_ATOMIC_HAS_CONSTRUCTORS for "stock" clang before version 3.2. + Apple's version has different (higher!) version numbers, so disable it for all of them for now. + (The only way to distinguish between them seems to be a check for __apple_build_version__ .) + + For details about the bug: see http://llvm.org/bugs/show_bug.cgi?id=12670 + */ +# else +# define QT_BASIC_ATOMIC_HAS_CONSTRUCTORS +# endif #endif template <typename T> |