diff options
author | Edward Welbourne <edward.welbourne@qt.io> | 2020-10-23 14:31:25 +0200 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2020-11-07 06:24:52 +0100 |
commit | cfac358fa3cfe7056f9d71b7cdb8e557dd711810 (patch) | |
tree | 5224481606481ace9495af9da7c71cb238e589a2 /src/corelib/text/qlocale.cpp | |
parent | 9a1a15b42fb526ad4f80944afb7761bfff1b5c9d (diff) |
Turn QLocale's operator==() and operator!=() into hidden friends
Update docs to match. Add note on the conditions for equality.
Change-Id: I973b7a5dae3fae2e62f8a0d1db1f3115d24bee8b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'src/corelib/text/qlocale.cpp')
-rw-r--r-- | src/corelib/text/qlocale.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/corelib/text/qlocale.cpp b/src/corelib/text/qlocale.cpp index 260af879db..1ac7742593 100644 --- a/src/corelib/text/qlocale.cpp +++ b/src/corelib/text/qlocale.cpp @@ -1060,14 +1060,14 @@ QLocale &QLocale::operator=(const QLocale &other) return *this; } -bool QLocale::operator==(const QLocale &other) const -{ - return d->m_data == other.d->m_data && d->m_numberOptions == other.d->m_numberOptions; -} +/*! + \internal + Equality comparison. +*/ -bool QLocale::operator!=(const QLocale &other) const +bool QLocale::equals(const QLocale &other) const { - return d->m_data != other.d->m_data || d->m_numberOptions != other.d->m_numberOptions; + return d->m_data == other.d->m_data && d->m_numberOptions == other.d->m_numberOptions; } /*! |