diff options
author | Cristian Adam <cristian.adam@qt.io> | 2021-06-03 16:06:39 +0200 |
---|---|---|
committer | Cristian Adam <cristian.adam@qt.io> | 2021-06-04 07:13:36 +0000 |
commit | df571577b6d9212b265f72675128b97858e618d4 (patch) | |
tree | 72d63d4cfaabf1a2f98a7172e07c459e1f46293a /src/libs/3rdparty/cplusplus | |
parent | 5ec611b68e3e910b609ed8e72fd87cd45b86fb3a (diff) |
CPlusPlus: Fix MSVC Debug build
Amends 011f62dfc255b73e9fc952fa35abbb8219856f8d
Change-Id: I33aea095341ee5e1cb38763cde04b567ea030986
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
Diffstat (limited to 'src/libs/3rdparty/cplusplus')
-rw-r--r-- | src/libs/3rdparty/cplusplus/AST.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/libs/3rdparty/cplusplus/AST.h b/src/libs/3rdparty/cplusplus/AST.h index 60374d2e0f..be73cab1ed 100644 --- a/src/libs/3rdparty/cplusplus/AST.h +++ b/src/libs/3rdparty/cplusplus/AST.h @@ -26,6 +26,14 @@ namespace CPlusPlus { +// clang-cl needs an export for the subclass, while msvc fails to build in debug mode if +// the export is present. +#if defined(Q_CC_CLANG) && defined(Q_CC_MSVC) +#define CPLUSPLUS_EXPORT_SUBCLASS CPLUSPLUS_EXPORT +#else +#define CPLUSPLUS_EXPORT_SUBCLASS +#endif + template <typename Tptr> class CPLUSPLUS_EXPORT List: public Managed { @@ -76,7 +84,7 @@ public: Tptr value; List *next; - class CPLUSPLUS_EXPORT ListIterator + class CPLUSPLUS_EXPORT_SUBCLASS ListIterator { List<Tptr> *iter; |