diff options
author | Marc Mutz <marc.mutz@qt.io> | 2023-08-07 17:42:52 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2023-08-08 16:03:28 +0200 |
commit | a4d968adc05055be0000dc55a5a7f3889b06e676 (patch) | |
tree | 66c8428549c48e60e375e6e7f574094a8f5b0059 /src/plugins/platforms/ios/qiosintegration.mm | |
parent | 52ef958429cf09a46f71d0165bb4150c61f76ebc (diff) |
Mark ios plugin as free of Q_FOREACH, except where it isn't
The density of Q_FOREACH uses is high here, too high for this author
to tackle in a short amount of time. But they're concentrated in just
a few TUs, so pick a different strategy:
Mark the whole plugin with QT_NO_FOREACH, to prevent new uses from
creeping in, and whitelist the affected TUs by #undef'ing
QT_NO_FOREACH locally, at the top of each file. Since the TUs are part
of a larger executable, this requires these files to be compiled
separately, so add them to NO_PCH_SOURCES (which implies
NO_UNITY_BUILD_SOURCES, too). I'm aware that Objective-C/C++ files are
currently probably implicitly NO_PCH_SOURCES, but don't rely on that.
Task-number: QTBUG-115839
Change-Id: If451501f3cb7cc3a182854a94bc5d27c907f6161
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'src/plugins/platforms/ios/qiosintegration.mm')
-rw-r--r-- | src/plugins/platforms/ios/qiosintegration.mm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/platforms/ios/qiosintegration.mm b/src/plugins/platforms/ios/qiosintegration.mm index 27d0f7f2ba..44aeaabec2 100644 --- a/src/plugins/platforms/ios/qiosintegration.mm +++ b/src/plugins/platforms/ios/qiosintegration.mm @@ -1,6 +1,8 @@ // Copyright (C) 2016 The Qt Company Ltd. // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only +#undef QT_NO_FOREACH // this file contains unported legacy Q_FOREACH uses + #include "qiosintegration.h" #include "qioseventdispatcher.h" #include "qiosglobal.h" |