summaryrefslogtreecommitdiffstats
path: root/src/corelib/compat/removed_api.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2022-07-18 10:46:16 +0200
committerMarc Mutz <marc.mutz@qt.io>2022-07-20 11:15:55 +0000
commit749b2df889ac94c106e59b915ec5862384978878 (patch)
treea24652dc88d773185473b3820d5b9da7a16f42de /src/corelib/compat/removed_api.cpp
parent16c453069f7b44ba7328a178b4b9ce99a150813e (diff)
QCollator: port compare(ptr, n, ptr, n) to qsizetype
While the function is inline, the class is exported wholesale, so the function forms part of the ABI on Windows (but not Unix), so we must overload, can't replace. To avoid ambiguities where users pass different integer types as the lengths of the LHS and RHS strings, QT_REMOVED_SINCE the old overload. Since the removed function has an inline definition, it suffices to just include the header into the corresponding QT_REMOVED_SINCE section of the removed_api.cpp file, to elegantly solve the BiC problem only for those platforms (MSVC) where it matters. Pick-to: 6.4 Task-number: QTBUG-103531 Change-Id: I74d446f08fcd6247a2ec44575b8afef8d014c3b5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/compat/removed_api.cpp')
-rw-r--r--src/corelib/compat/removed_api.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/compat/removed_api.cpp b/src/corelib/compat/removed_api.cpp
index ba844715d8..c4fe85f84f 100644
--- a/src/corelib/compat/removed_api.cpp
+++ b/src/corelib/compat/removed_api.cpp
@@ -169,6 +169,8 @@ QCalendar::QCalendar(QStringView name)
QCalendar::QCalendar(QLatin1StringView name)
: QCalendar(QAnyStringView{name}) {}
+#include "qcollator.h" // inline function compare(ptr, n, ptr, n) (for MSVC)
+
#if QT_CONFIG(future)
#include "qfutureinterface.h"