Revert "QMetaType: support manual unregistration"

This reverts commit cf000d080c.

Reason for revert: This API is not needed (anymore) by qtdeclarative.

Change-Id: I8af604c2babe3afc11f183ddb3ce3a9038a456ad
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
bb10
Simon Hausmann 2020-03-23 10:26:31 +00:00
parent f3ce9e9332
commit 865d3846d8
3 changed files with 0 additions and 17 deletions

View File

@ -669,13 +669,6 @@ void QtMetaTypePrivate::derefAndDestroy(QtPrivate::QMetaTypeInterface *d_ptr)
}
}
Q_CORE_EXPORT void QtMetaTypePrivate::unsafeUnregister(QtPrivate::QMetaTypeInterface *d_ptr)
{
if (auto reg = customTypeRegistry())
reg->unregisterDynamicType(d_ptr->typeId.loadRelaxed());
d_ptr->typeId = 0;
}
/*!
\fn QMetaType::~QMetaType()
@ -1775,12 +1768,6 @@ QT_FOR_EACH_STATIC_PRIMITIVE_POINTER(QT_METATYPE_DECLARE_TEMPLATE_ITER)
QT_FOR_EACH_STATIC_CORE_CLASS(QT_METATYPE_DECLARE_TEMPLATE_ITER)
QT_FOR_EACH_STATIC_CORE_POINTER(QT_METATYPE_DECLARE_TEMPLATE_ITER)
QT_FOR_EACH_STATIC_CORE_TEMPLATE(QT_METATYPE_DECLARE_TEMPLATE_ITER)
Q_CORE_EXPORT QMetaTypeInterface *QMetaTypeInterface::get(const QMetaType &metatype)
{
return metatype.d_ptr;
}
#undef QT_METATYPE_DECLARE_TEMPLATE_ITER
#endif
}

View File

@ -700,7 +700,6 @@ public:
static void unregisterConverterFunction(int from, int to);
private:
friend class QVariant;
friend class QtPrivate::QMetaTypeInterface;
QtPrivate::QMetaTypeInterface *d_ptr = nullptr;
};
@ -2285,8 +2284,6 @@ public:
using LegacyRegisterOp = void (*)();
LegacyRegisterOp legacyRegisterOp;
Q_CORE_EXPORT static QMetaTypeInterface *get(const QMetaType &metatype);
};
struct QTypeNormalizer

View File

@ -218,7 +218,6 @@ static QtPrivate::QMetaTypeInterface *getInterfaceFromType()
return true;
void derefAndDestroy(QtPrivate::QMetaTypeInterface *d_ptr);
Q_CORE_EXPORT void unsafeUnregister(QtPrivate::QMetaTypeInterface *d_ptr);
} //namespace QtMetaTypePrivate