diff options
author | Marc Mutz <marc.mutz@qt.io> | 2022-02-15 11:48:32 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2022-07-20 13:15:55 +0200 |
commit | 16c453069f7b44ba7328a178b4b9ce99a150813e (patch) | |
tree | 381cb018518643e8aa5d58c7c84f31a6af965746 /src/corelib/text/qstring.cpp | |
parent | ad17a1674c21223719ffcf54d35c1ea3eb2356cd (diff) |
QtBase: eradicate QT_STRINGVIEW_LEVEL uses
It's not used and not useful.
The macro itself has to stay, for now, because Qt5Compat uses it, too.
Task-number: QTBUG-100861
Pick-to: 6.4 6.3 6.2
Change-Id: I5d0557a6c959d6facf6e47f26786a9d365339e95
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Diffstat (limited to 'src/corelib/text/qstring.cpp')
-rw-r--r-- | src/corelib/text/qstring.cpp | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/src/corelib/text/qstring.cpp b/src/corelib/text/qstring.cpp index c569bf627d..1a78c1d0cd 100644 --- a/src/corelib/text/qstring.cpp +++ b/src/corelib/text/qstring.cpp @@ -4079,7 +4079,6 @@ QString &QString::replace(QChar c, QLatin1StringView after, Qt::CaseSensitivity go through QObject::tr(), for example. */ -#if QT_STRINGVIEW_LEVEL < 2 /*! Returns the index position of the first occurrence of the string \a str in this string, searching forward from index position \a @@ -4101,7 +4100,6 @@ qsizetype QString::indexOf(const QString &str, qsizetype from, Qt::CaseSensitivi { return QtPrivate::findString(QStringView(unicode(), length()), from, QStringView(str.unicode(), str.length()), cs); } -#endif // QT_STRINGVIEW_LEVEL < 2 /*! \fn qsizetype QString::indexOf(QStringView str, qsizetype from, Qt::CaseSensitivity cs) const @@ -4157,7 +4155,6 @@ qsizetype QString::indexOf(QChar ch, qsizetype from, Qt::CaseSensitivity cs) con return qFindChar(QStringView(unicode(), length()), ch, from, cs); } -#if QT_STRINGVIEW_LEVEL < 2 /*! Returns the index position of the last occurrence of the string \a str in this string, searching backward from index position \a @@ -4204,7 +4201,6 @@ qsizetype QString::lastIndexOf(const QString &str, qsizetype from, Qt::CaseSensi \sa indexOf(), contains(), count() */ -#endif // QT_STRINGVIEW_LEVEL < 2 /*! \since 4.5 @@ -4496,7 +4492,6 @@ qsizetype QString::count(QStringView str, Qt::CaseSensitivity cs) const return QtPrivate::count(*this, str, cs); } -#if QT_STRINGVIEW_LEVEL < 2 /*! \fn bool QString::contains(const QString &str, Qt::CaseSensitivity cs = Qt::CaseSensitive) const Returns \c true if this string contains an occurrence of the string @@ -4510,7 +4505,6 @@ qsizetype QString::count(QStringView str, Qt::CaseSensitivity cs) const \sa indexOf(), count() */ -#endif // QT_STRINGVIEW_LEVEL < 2 /*! \fn bool QString::contains(QLatin1StringView str, Qt::CaseSensitivity cs = Qt::CaseSensitive) const \since 5.3 @@ -5036,7 +5030,6 @@ QString QString::mid(qsizetype position, qsizetype n) const \sa endsWith(), first(), last(), sliced(), chop(), truncate() */ -#if QT_STRINGVIEW_LEVEL < 2 /*! Returns \c true if the string starts with \a s; otherwise returns \c false. @@ -5052,7 +5045,6 @@ bool QString::startsWith(const QString& s, Qt::CaseSensitivity cs) const { return qt_starts_with_impl(QStringView(*this), QStringView(s), cs); } -#endif /*! \overload startsWith() @@ -5091,7 +5083,6 @@ bool QString::startsWith(QChar c, Qt::CaseSensitivity cs) const \sa endsWith() */ -#if QT_STRINGVIEW_LEVEL < 2 /*! Returns \c true if the string ends with \a s; otherwise returns \c false. @@ -5107,7 +5098,6 @@ bool QString::endsWith(const QString &s, Qt::CaseSensitivity cs) const { return qt_ends_with_impl(QStringView(*this), QStringView(s), cs); } -#endif // QT_STRINGVIEW_LEVEL < 2 /*! \fn bool QString::endsWith(QStringView str, Qt::CaseSensitivity cs) const @@ -6215,7 +6205,6 @@ QString& QString::fill(QChar ch, qsizetype size) sensitivity setting \a cs. */ -#if QT_STRINGVIEW_LEVEL < 2 /*! \overload compare() \since 4.2 @@ -6231,7 +6220,6 @@ int QString::compare(const QString &other, Qt::CaseSensitivity cs) const noexcep { return QtPrivate::compareStrings(*this, other, cs); } -#endif /*! \internal @@ -8108,7 +8096,6 @@ static QString replaceArgEscapes(QStringView s, const ArgEscapeData &d, qsizetyp return result; } -#if QT_STRINGVIEW_LEVEL < 2 /*! Returns a copy of this string with the lowest numbered place marker replaced by string \a a, i.e., \c %1, \c %2, ..., \c %99. @@ -8142,7 +8129,6 @@ QString QString::arg(const QString &a, int fieldWidth, QChar fillChar) const { return arg(qToStringViewIgnoringNull(a), fieldWidth, fillChar); } -#endif // QT_STRINGVIEW_LEVEL < 2 /*! \overload |