path: root/src/corelib
diff options
authorThiago Macieira <>2020-01-29 12:57:25 -0800
committerThiago Macieira <>2020-02-13 15:12:29 -0800
commit7af5619836cb3bd2eca87fd10b81674c9e201e76 (patch)
treec70ff76f385de406519e3853ac6c3523b06ea207 /src/corelib
parentc0c2efc3c62432b4ae159b911018682f573b54e4 (diff)
QLinkedListData: Move Q_CORE_EXPORT from class to shared_null
This makes no difference for the IA-64 C++ ABI nor for MSVC until MSVC 2019 16.6. But it does with 16.6, where the std::atomic constructor becomes non-trivial, which makes QtPrivate::RefCount non-trivial, which makes QLinkedListData non-trivial. Before this change: User code \ Qt MSVC <=16.5 MSVC >=16.6 MSVC <=16.5 works works MSVC >=16.6 fails works With this change, they should all work. The list of symbols exported should not change either, so linking against a Qt compiled with MSVC <=16.5 should continue to work. [ChangeLog][MSVC] Fixed a compatibility issue found when linking code compiled with version 16.6 to a Qt compiled with 16.5. Fixes: QTBUG-81727 Change-Id: If79a52e476594446baccfffd15ee771397467f8b Reviewed-by: Simon Hausmann <>
Diffstat (limited to 'src/corelib')
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/tools/qlinkedlist.h b/src/corelib/tools/qlinkedlist.h
index 8970d39be0..3b8c75b122 100644
--- a/src/corelib/tools/qlinkedlist.h
+++ b/src/corelib/tools/qlinkedlist.h
@@ -58,14 +58,14 @@
-struct Q_CORE_EXPORT QLinkedListData
+struct QLinkedListData
QLinkedListData *n, *p;
QtPrivate::RefCount ref;
int size;
uint sharable : 1;
- static const QLinkedListData shared_null;
+ Q_CORE_EXPORT static const QLinkedListData shared_null;
template <typename T>