summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qlinkedlist.cpp
diff options
context:
space:
mode:
authorSona Kurazyan <sona.kurazyan@qt.io>2020-02-03 11:50:57 +0100
committerSona Kurazyan <sona.kurazyan@qt.io>2020-02-04 20:01:18 +0100
commita20dbcf7c77c9bc92cce87eed7bada4ab202f2af (patch)
treec71211e00b0c55ddead7e4ef7c7db016e92e03f2 /src/corelib/tools/qlinkedlist.cpp
parentf8e39a66569b27bb45cc7a49508dba29038122a4 (diff)
Deprecate QLinkedList
[ChangeLog][Deprecation Notice] QLinkedList is deprecated and will be moved to Qt5Compat in Qt 6. It is recommended to use std::list instead. Task-number: QTBUG-81630 Task-number: QTBUG-80312 Change-Id: I2c2b64e51d1cc2fd305aee6a11e9a89788f51eb4 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/corelib/tools/qlinkedlist.cpp')
-rw-r--r--src/corelib/tools/qlinkedlist.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/corelib/tools/qlinkedlist.cpp b/src/corelib/tools/qlinkedlist.cpp
index 3b1bc8aab1..6a423545da 100644
--- a/src/corelib/tools/qlinkedlist.cpp
+++ b/src/corelib/tools/qlinkedlist.cpp
@@ -45,6 +45,11 @@
QT_BEGIN_NAMESPACE
+#if QT_DEPRECATED_SINCE(5, 15)
+
+QT_WARNING_PUSH
+QT_WARNING_DISABLE_DEPRECATED
+
const QLinkedListData QLinkedListData::shared_null = {
const_cast<QLinkedListData *>(&QLinkedListData::shared_null),
const_cast<QLinkedListData *>(&QLinkedListData::shared_null),
@@ -53,6 +58,7 @@ const QLinkedListData QLinkedListData::shared_null = {
/*! \class QLinkedList
\inmodule QtCore
+ \obsolete
\brief The QLinkedList class is a template class that provides linked lists.
\ingroup tools
@@ -60,6 +66,8 @@ const QLinkedListData QLinkedListData::shared_null = {
\reentrant
+ \note This class is obsolete, please use std::list instead.
+
QLinkedList\<T\> is one of Qt's generic \l{container classes}. It
stores a list of values and provides iterator-based access as
well as \l{constant time} insertions and removals.
@@ -720,6 +728,7 @@ const QLinkedListData QLinkedListData::shared_null = {
/*! \class QLinkedList::iterator
\inmodule QtCore
+ \obsolete
\brief The QLinkedList::iterator class provides an STL-style non-const iterator for QLinkedList.
QLinkedList features both \l{STL-style iterators} and
@@ -965,6 +974,7 @@ const QLinkedListData QLinkedListData::shared_null = {
/*! \class QLinkedList::const_iterator
\inmodule QtCore
+ \obsolete
\brief The QLinkedList::const_iterator class provides an STL-style const iterator for QLinkedList.
QLinkedList features both \l{STL-style iterators} and
@@ -1221,4 +1231,8 @@ const QLinkedListData QLinkedListData::shared_null = {
\sa fromStdList()
*/
+QT_WARNING_POP
+
+#endif // QT_DEPRECATED_SINCE(5, 15)
+
QT_END_NAMESPACE