diff --git a/src/corelib/kernel/qmetatype.h b/src/corelib/kernel/qmetatype.h index 7a66767258..18d59e1298 100644 --- a/src/corelib/kernel/qmetatype.h +++ b/src/corelib/kernel/qmetatype.h @@ -831,6 +831,20 @@ QT_FOR_EACH_AUTOMATIC_TEMPLATE_SMART_POINTER(QT_FORWARD_DECLARE_SHARED_POINTER_T namespace QtPrivate { + namespace detail { + template + struct is_complete_helper + { + template + static auto check(U *) -> std::integral_constant; + static auto check(...) -> std::false_type; + using type = decltype(check(static_cast(nullptr))); + }; + } // namespace detail + + template + struct is_complete : detail::is_complete_helper::type {}; + template struct IsPointerToTypeDerivedFromQObject { @@ -2464,7 +2478,6 @@ QT_FOR_EACH_STATIC_CORE_POINTER(QT_METATYPE_DECLARE_EXTERN_TEMPLATE_ITER) QT_FOR_EACH_STATIC_CORE_TEMPLATE(QT_METATYPE_DECLARE_EXTERN_TEMPLATE_ITER) #undef QT_METATYPE_DECLARE_EXTERN_TEMPLATE_ITER #endif - template constexpr const QMetaTypeInterface *qMetaTypeInterfaceForType() { @@ -2472,20 +2485,6 @@ constexpr const QMetaTypeInterface *qMetaTypeInterfaceForType() return &QMetaTypeInterfaceWrapper::metaType; } -namespace detail { -template -struct is_complete_helper -{ - template - static auto check(U *) -> std::integral_constant; - static auto check(...) -> std::false_type; - using type = decltype(check(static_cast(nullptr))); -}; -} // namespace detail - -template -struct is_complete : detail::is_complete_helper::type {}; - template struct qRemovePointerLike {