diff --git a/src/corelib/kernel/qmetatype.h b/src/corelib/kernel/qmetatype.h index 1ae0fb45bc..2ae4ae1103 100644 --- a/src/corelib/kernel/qmetatype.h +++ b/src/corelib/kernel/qmetatype.h @@ -2701,7 +2701,7 @@ QMetaTypeInterface QMetaTypeForType::metaType = { } }), /*.copyCtr=*/ QT_METATYPE_CONSTEXPRLAMDA( -> QMetaTypeInterface::CopyCtrFn { - if (std::is_copy_constructible_v) { + if constexpr (std::is_copy_constructible_v) { return [](const QMetaTypeInterface *, void *addr, const void *other) { new (addr) T(*reinterpret_cast(other)); };