diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2017-04-04 14:41:11 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2017-04-05 09:10:33 +0000 |
commit | a8c046a2a32e742a1b71c6c392e39c85b99b5129 (patch) | |
tree | 64894f1444ace57f08a8ec879fa20eb84605a8b2 | |
parent | 8a6b20eb0e98d781a1bec49c16409ca29eee0185 (diff) |
Use (new) QStringIterator(QStringView) to avoid casts
This is the only one in QtBase that casts to be able to use QStringIterator.
Amends d40dcee642c69784f771aae86531ae65b458f1a5.
Change-Id: I709e0285717e8d17feab9ab0020c8d0aed0dbe36
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
-rw-r--r-- | src/corelib/tools/qstring.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp index 53784dd570..6c97e2563c 100644 --- a/src/corelib/tools/qstring.cpp +++ b/src/corelib/tools/qstring.cpp @@ -1596,7 +1596,7 @@ int QString::toUcs4_helper(const ushort *uc, int length, uint *out) { int count = 0; - QStringIterator i(reinterpret_cast<const QChar *>(uc), reinterpret_cast<const QChar *>(uc + length)); + QStringIterator i(QStringView(uc, length)); while (i.hasNext()) out[count++] = i.next(); |