summaryrefslogtreecommitdiffstats
path: root/src/corelib/serialization
diff options
context:
space:
mode:
authorJarek Kobus <jaroslaw.kobus@qt.io>2020-06-26 08:21:15 +0200
committerJarek Kobus <jaroslaw.kobus@qt.io>2020-06-29 12:35:09 +0200
commitb0f9c06a9b199a7474eb94a6292b5824364344b6 (patch)
tree15bfdcd6322d34b9dfeaf1f7b170219b0bab9fa0 /src/corelib/serialization
parentbe1bb192955631c44a872014fcb631efc5fcfb8a (diff)
Use QList instead of QVector in corelib implementation
Omitting state machine and docs for now. Task-number: QTBUG-84469 Change-Id: Ibfa5e7035515773461f6cdbff35299315ef65737 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
Diffstat (limited to 'src/corelib/serialization')
-rw-r--r--src/corelib/serialization/qcborarray.cpp2
-rw-r--r--src/corelib/serialization/qcbormap.cpp4
-rw-r--r--src/corelib/serialization/qcborvalue.cpp2
-rw-r--r--src/corelib/serialization/qdatastream.cpp2
-rw-r--r--src/corelib/serialization/qxmlstream.cpp12
5 files changed, 11 insertions, 11 deletions
diff --git a/src/corelib/serialization/qcborarray.cpp b/src/corelib/serialization/qcborarray.cpp
index 4a96d3dc32..2e0de4f4fc 100644
--- a/src/corelib/serialization/qcborarray.cpp
+++ b/src/corelib/serialization/qcborarray.cpp
@@ -66,7 +66,7 @@ using namespace QtCbor;
from those two, though there may be loss of information in some
conversions.
- \sa QCborValue, QCborMap, QJsonArray, QList, QVector
+ \sa QCborValue, QCborMap, QJsonArray, QList
*/
/*!
diff --git a/src/corelib/serialization/qcbormap.cpp b/src/corelib/serialization/qcbormap.cpp
index 9179ed81b6..34c8c72059 100644
--- a/src/corelib/serialization/qcbormap.cpp
+++ b/src/corelib/serialization/qcbormap.cpp
@@ -298,9 +298,9 @@ void QCborMap::clear()
\sa QMap::keys(), QHash::keys()
*/
-QVector<QCborValue> QCborMap::keys() const
+QList<QCborValue> QCborMap::keys() const
{
- QVector<QCborValue> result;
+ QList<QCborValue> result;
if (d) {
result.reserve(size());
for (qsizetype i = 0; i < d->elements.size(); i += 2)
diff --git a/src/corelib/serialization/qcborvalue.cpp b/src/corelib/serialization/qcborvalue.cpp
index b9eb2b646c..7e2d8003c7 100644
--- a/src/corelib/serialization/qcborvalue.cpp
+++ b/src/corelib/serialization/qcborvalue.cpp
@@ -1494,7 +1494,7 @@ static inline QCborContainerPrivate *createContainerFromCbor(QCborStreamReader &
// Clamp allocation to 1M elements (avoids crashing due to corrupt
// stream or loss of precision when converting from quint64 to
- // QVector::size_type).
+ // QList::size_type).
len = qMin(len, quint64(1024 * 1024 - 1));
if (len) {
d = new QCborContainerPrivate;
diff --git a/src/corelib/serialization/qdatastream.cpp b/src/corelib/serialization/qdatastream.cpp
index 316a164c6d..7888296b85 100644
--- a/src/corelib/serialization/qdatastream.cpp
+++ b/src/corelib/serialization/qdatastream.cpp
@@ -163,7 +163,7 @@ QT_BEGIN_NAMESPACE
\section1 Reading and Writing Qt Collection Classes
The Qt container classes can also be serialized to a QDataStream.
- These include QList, QVector, QSet, QHash, and QMap.
+ These include QList, QSet, QHash, and QMap.
The stream operators are declared as non-members of the classes.
\target Serializing Qt Classes
diff --git a/src/corelib/serialization/qxmlstream.cpp b/src/corelib/serialization/qxmlstream.cpp
index c26b0d11d2..21f80eec66 100644
--- a/src/corelib/serialization/qxmlstream.cpp
+++ b/src/corelib/serialization/qxmlstream.cpp
@@ -1935,7 +1935,7 @@ QStringRef QXmlStreamReader::text() const
/*! If the tokenType() is \l DTD, this function returns the DTD's
notation declarations. Otherwise an empty vector is returned.
- The QXmlStreamNotationDeclarations class is defined to be a QVector
+ The QXmlStreamNotationDeclarations class is defined to be a QList
of QXmlStreamNotationDeclaration.
*/
QXmlStreamNotationDeclarations QXmlStreamReader::notationDeclarations() const
@@ -1950,7 +1950,7 @@ QXmlStreamNotationDeclarations QXmlStreamReader::notationDeclarations() const
/*! If the tokenType() is \l DTD, this function returns the DTD's
unparsed (external) entity declarations. Otherwise an empty vector is returned.
- The QXmlStreamEntityDeclarations class is defined to be a QVector
+ The QXmlStreamEntityDeclarations class is defined to be a QList
of QXmlStreamEntityDeclaration.
*/
QXmlStreamEntityDeclarations QXmlStreamReader::entityDeclarations() const
@@ -2046,7 +2046,7 @@ void QXmlStreamReader::setEntityExpansionLimit(int limit)
element's namespace declarations. Otherwise an empty vector is
returned.
- The QXmlStreamNamespaceDeclarations class is defined to be a QVector
+ The QXmlStreamNamespaceDeclarations class is defined to be a QList
of QXmlStreamNamespaceDeclaration.
\sa addExtraNamespaceDeclaration(), addExtraNamespaceDeclarations()
@@ -2428,7 +2428,7 @@ QXmlStreamAttribute& QXmlStreamAttribute::operator=(const QXmlStreamAttribute &o
\typedef QXmlStreamNotationDeclarations
\relates QXmlStreamNotationDeclaration
- Synonym for QVector<QXmlStreamNotationDeclaration>.
+ Synonym for QList<QXmlStreamNotationDeclaration>.
*/
@@ -2507,7 +2507,7 @@ Returns the public identifier.
\typedef QXmlStreamNamespaceDeclarations
\relates QXmlStreamNamespaceDeclaration
- Synonym for QVector<QXmlStreamNamespaceDeclaration>.
+ Synonym for QList<QXmlStreamNamespaceDeclaration>.
*/
/*!
@@ -2592,7 +2592,7 @@ Returns the namespaceUri.
\typedef QXmlStreamEntityDeclarations
\relates QXmlStreamEntityDeclaration
- Synonym for QVector<QXmlStreamEntityDeclaration>.
+ Synonym for QList<QXmlStreamEntityDeclaration>.
*/
/*!