Skip to content

Commit

Permalink
Remove QBAV(QL1SV) and QBAV(QU8SV) constructors
Browse files Browse the repository at this point in the history
They were added because of conditional noexcept on the relational
operators that was preventing the other constructors from being picked
up by the compiler.

Now when we removed the conditional noexcept on the relational
operators, we no longer need this constructors.

This patch reverts bd581e3 and
partially reverts fff6562.

Pick-to: 6.8
Change-Id: I22cb4507bff0a929a25d2f15caed66cc30d20dc9
Reviewed-by: Thiago Macieira <[email protected]>
  • Loading branch information
isolovev committed Jul 16, 2024
1 parent d292648 commit 6cafe0f
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 13 deletions.
4 changes: 0 additions & 4 deletions src/corelib/text/qbytearrayview.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,6 @@ class Q_CORE_EXPORT QByteArrayView
constexpr QByteArrayView(const char (&data)[Size]) noexcept
: QByteArrayView(data, lengthHelperCharArray(data, Size)) {}

constexpr QByteArrayView(QLatin1StringView v) noexcept; // defined in qlatin1stringview.h
template <bool UseChar8T>
constexpr QByteArrayView(QBasicUtf8StringView<UseChar8T> v) noexcept; // defined in qutf8stringview.h

#ifdef Q_QDOC
template <typename Byte, size_t Size>
#else
Expand Down
4 changes: 0 additions & 4 deletions src/corelib/text/qlatin1stringview.h
Original file line number Diff line number Diff line change
Expand Up @@ -349,10 +349,6 @@ Q_DECLARE_TYPEINFO(QLatin1StringView, Q_RELOCATABLE_TYPE);
Q_DECLARE_TYPEINFO(QLatin1String, Q_RELOCATABLE_TYPE);
#endif

constexpr QByteArrayView::QByteArrayView(QLatin1StringView v) noexcept
: QByteArrayView(v.data(), v.size())
{}

namespace Qt {
inline namespace Literals {
inline namespace StringLiterals {
Expand Down
5 changes: 0 additions & 5 deletions src/corelib/text/qutf8stringview.h
Original file line number Diff line number Diff line change
Expand Up @@ -411,11 +411,6 @@ class QBasicUtf8StringView
qsizetype m_size;
};

template <bool UseChar8T>
constexpr QByteArrayView::QByteArrayView(QBasicUtf8StringView<UseChar8T> v) noexcept
: QByteArrayView(v.data(), v.size())
{}

#ifdef Q_QDOC
#undef QBasicUtf8StringView
#else
Expand Down

0 comments on commit 6cafe0f

Please sign in to comment.