From 57ec47921e1e703372c1a69a5e3b375ef3918acc Mon Sep 17 00:00:00 2001 From: Tatiana Borisova Date: Wed, 13 Oct 2021 14:29:36 +0300 Subject: [PATCH] Compile Private API autotests for INTEGRITY - GHS's __PRETTY_FUNCTION__ (used by QT as Q_FUNC_INFO) doesn't have spaces round the = operator when indicating the type of the template parameter. The compilation error: qt5/qtbase/src/corelib/kernel/qmetatype.h", line 2104: note #3316-D: cannot access position 53 in array of 49 elements constexpr const char *begin = func + prefix; ^ detected during: instantiation of "auto QtPrivate::typenameHelper() [with T=void]" at line 2186 Task-number: QTBUG-97087 Pick-to: 6.2 Change-Id: I33e61f5d54a61944a5aecf07d149a8dee0ef1e5d Reviewed-by: Thiago Macieira --- src/corelib/kernel/qmetatype.h | 2 +- tests/auto/corelib/kernel/CMakeLists.txt | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/corelib/kernel/qmetatype.h b/src/corelib/kernel/qmetatype.h index 327f918d6b..346ae3667a 100644 --- a/src/corelib/kernel/qmetatype.h +++ b/src/corelib/kernel/qmetatype.h @@ -2154,7 +2154,7 @@ constexpr auto typenameHelper() #elif defined(Q_CC_CLANG) "auto QtPrivate::typenameHelper() [T = " #elif defined(Q_CC_GHS) - "auto QtPrivate::typenameHelper() [with T = " + "auto QtPrivate::typenameHelper() [with T=" #else "constexpr auto QtPrivate::typenameHelper() [with T = " #endif diff --git a/tests/auto/corelib/kernel/CMakeLists.txt b/tests/auto/corelib/kernel/CMakeLists.txt index f3277566be..39f16bc970 100644 --- a/tests/auto/corelib/kernel/CMakeLists.txt +++ b/tests/auto/corelib/kernel/CMakeLists.txt @@ -23,9 +23,7 @@ if(TARGET Qt::Network) add_subdirectory(qeventloop) endif() if(TARGET Qt::Gui) - if(NOT INTEGRITY) - add_subdirectory(qmetatype) - endif() + add_subdirectory(qmetatype) add_subdirectory(qmimedata) add_subdirectory(qvariant) endif()