summaryrefslogtreecommitdiffstats
path: root/src/corelib/text/qbytearraylist.cpp
Commit message (Collapse)AuthorAgeFilesLines
* QByteArrayList: fix narrowing in join() implementations [2/2]Marc Mutz2021-11-051-3/+3
| | | | | | | | | | | | | | | | | | | We forgot to adjust the interface and implementation of join() to the int → qsizetype change in Qt 6. This part of the two-part patch fixes things in a non-forwards-BC way, so it can't be picked into released versions. The forwards-BC part is in the first patch of the series. We can't just replace the int seplen with qsizetype, because qsizetype is an alias to int on 32-bit platforms. So, pass the separator by QByteArrayView. [ChangeLog][QtCore][QByteArrayList] Fixed a bug when calling join() with separators of length > INTMAX. Change-Id: I2ccc61de1c8901ac5504aea1ebd895d12dbcb064 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* QByteArrayList: fix narrowing in join() implementations [1/2]Marc Mutz2021-11-041-7/+7
| | | | | | | | | | | | | | | | | We forgot to adjust the interface and implementation of join() to the int → qsizetype change in Qt 6. This part of the two-part patch fixes things in a forwards-BC way, to allow picking into released versions. The forwards-BC break is in the second patch of the series. [ChangeLog][QtCore][QByteArrayList] Fixed a bug when calling join() on lists with more than INTMAX elements. Pick-to: 6.2 Change-Id: I26976864e77169ff0db7c672d1d42d88dbfcc437 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* QByteArrayList: add join(QByteArrayView)Marc Mutz2021-11-041-0/+8
| | | | | | | | | | | | | | | | | | | Since QByteArray/QByteArrayView don't overload nicely, we need to make the existing QByteArray overload a Q_WEAK_OVERLOAD (= a template) as a tie breaker. This automatically prefers the QByteArrayView version over the QByteArray overload, transparently optimizing existing users passing char string literals to avoid the implicit creation of a QByteArray just for passing the separator. None of our modules exports a subclass of QByteArrayList, so turning join(QByteArray) into a function template should be ok. [ChangeLog][QtCore][QByteArrayList] Added join(QByteArrayView) overload. Change-Id: I090671d9b94c30b63a986f17e966d124c22b5c54 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Remove QByteArrayList_indexOfGiuseppe D'Angelo2020-10-181-6/+0
| | | | | | | | | It was used as exported symbol for the implementation of QByteArrayList::indexOf. Since then, the implementation has been changed, and this code is unused. Change-Id: I468d05507b6b520cf5bfa4bc567a3d67c43b9a32 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix a number of qdoc warnings related to deprecationFriedemann Kleint2020-07-241-16/+0
| | | | | | | Remove obsolete documentation. Change-Id: Iaf4b6f9852a883dea0f256c5c89e74f6ebbe85f3 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* Move text-related code out of corelib/tools/ to corelib/text/Edward Welbourne2019-07-101-0/+175
This includes byte array, string, char, unicode, locale, collation and regular expressions. Change-Id: I8b125fa52c8c513eb57a0f1298b91910e5a0d786 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>