diff options
| author | Marc Mutz <marc.mutz@qt.io> | 2022-10-20 07:16:57 +0200 |
|---|---|---|
| committer | Marc Mutz <marc.mutz@qt.io> | 2022-10-20 23:59:33 +0200 |
| commit | dbff59d279182e6cd35be9a7f5240e666ba02eee (patch) | |
| tree | d4579223e98c1f313781319eb82eae2b324490b7 | |
| parent | 1f9ae93ccfb267e1d0a2e5056b7ddb48cb0b535c (diff) | |
Short live Q_UNREACHABLE_RETURN for qmldom standalone
The qmldom part of qtdeclarative must compile against Qt 6.3. To avoid
special teatment regarding the automated port to Q_UNREACHABLE_RETURN
in a subsequent commit, add a simplified version of the macro to the
existing compatibility layer in standalone/private's
qtqmlcompilerexports_p.h.
Change-Id: Id6b2baa476ad8200518ce7b8619a05420dd331a0
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
| -rw-r--r-- | src/qmldom/standalone/private/qtqmlcompilerexports_p.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/qmldom/standalone/private/qtqmlcompilerexports_p.h b/src/qmldom/standalone/private/qtqmlcompilerexports_p.h index 28864cd96f..9191d6ab81 100644 --- a/src/qmldom/standalone/private/qtqmlcompilerexports_p.h +++ b/src/qmldom/standalone/private/qtqmlcompilerexports_p.h @@ -17,6 +17,7 @@ // #if QT_VERSION < QT_VERSION_CHECK(6, 4, 0) + #include <QtCore/qstring.h> namespace Qt { inline namespace Literals { @@ -35,9 +36,16 @@ inline QString operator"" _s(const char16_t *str, size_t size) noexcept } // StringLiterals } // Literals } // Qt + #ifdef Q_QMLCOMPILER_PRIVATE_EXPORT // clashing declaration fixed in ce53e48504f #undef Q_QMLCOMPILER_PRIVATE_EXPORT #endif + +#endif // 6.4.0 + +#ifndef Q_UNREACHABLE_RETURN // new in QT_VERSION_CHECK(6, 5, 0) +# define Q_UNREACHABLE_RETURN(...) do { Q_UNREACHABLE(); return __VA_ARGS__; } while (0) #endif + #define Q_QMLCOMPILER_PRIVATE_EXPORT QMLDOM_EXPORT #endif |
