diff options
author | Marc Mutz <marc.mutz@qt.io> | 2022-12-05 11:12:55 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2022-12-14 19:07:19 +0100 |
commit | e1b76ee928beff434d220c7711ea6798318d367e (patch) | |
tree | ed71e360161a78a2586bc8351656c2f672c09796 /cmake/QtInternalTargets.cmake | |
parent | c262a1805a062fd99abc890f58ea951da80ff0af (diff) |
Remove the last in-tree user of qExchange() and mark all of Qt free of it
We've ported all qExchange() to std::exchange by now, across all
modules, but the one in QScopedValueRollback was left behind, because
it requires C++20's version of std::exchange (constexpr).
Since q20::exchange was not approved, replace the qExchange() here
with two moves and add a comment to port to std::exchange() once we
can depend on C++20.
Then add QT_NO_QEXCHANGE to avoid new uses from creeping in.
Change-Id: I488e252433e78fb2766639dbe77a22a55196cfd1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'cmake/QtInternalTargets.cmake')
-rw-r--r-- | cmake/QtInternalTargets.cmake | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/cmake/QtInternalTargets.cmake b/cmake/QtInternalTargets.cmake index dc45b57eec..8de5f8a080 100644 --- a/cmake/QtInternalTargets.cmake +++ b/cmake/QtInternalTargets.cmake @@ -151,6 +151,7 @@ qt_internal_add_target_aliases(PlatformToolInternal) target_link_libraries(PlatformToolInternal INTERFACE PlatformAppInternal) qt_internal_add_global_definition(QT_NO_JAVA_STYLE_ITERATORS) +qt_internal_add_global_definition(QT_NO_QEXCHANGE) qt_internal_add_global_definition(QT_NO_NARROWING_CONVERSIONS_IN_CONNECT) qt_internal_add_global_definition(QT_EXPLICIT_QFILE_CONSTRUCTION_FROM_PATH) |