diff --git a/src/corelib/compat/removed_api.cpp b/src/corelib/compat/removed_api.cpp index a06dcbb87fa..cf96ac41e1a 100644 --- a/src/corelib/compat/removed_api.cpp +++ b/src/corelib/compat/removed_api.cpp @@ -928,6 +928,8 @@ QUrl QUrl::fromEncoded(const QByteArray &input, ParsingMode mode) #endif // QT_CORE_REMOVED_SINCE(6, 7) #if QT_CORE_REMOVED_SINCE(6, 8) + +#if QT_CONFIG(itemmodel) #include "qabstractitemmodel.h" bool QPersistentModelIndex::operator<(const QPersistentModelIndex &other) const noexcept @@ -950,6 +952,8 @@ bool QPersistentModelIndex::operator!=(const QModelIndex &other) const noexcept return !comparesEqual(*this, other); } +#endif // QT_CONFIG(itemmodel) + #include "qbitarray.h" // inlined API #include "qbytearray.h" // inlined API