Remove some dead code
Change-Id: I4e3906d5e6313014b207aa7bc63a0ff5e21b0261 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
This commit is contained in:
parent
a42dd2ffe0
commit
3898c022a6
@ -1828,14 +1828,6 @@ QVariant::QVariant(QDataStream &s)
|
||||
QT_NO_CAST_FROM_ASCII when you compile your applications.
|
||||
*/
|
||||
|
||||
#ifndef QT_NO_CAST_FROM_ASCII
|
||||
QVariant::QVariant(const char *val)
|
||||
{
|
||||
QString s = QString::fromUtf8(val);
|
||||
create(String, &s);
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\fn QVariant::QVariant(const QStringList &val)
|
||||
|
||||
@ -4305,11 +4297,7 @@ QDebug operator<<(QDebug dbg, const QVariant::Type p)
|
||||
/*!
|
||||
\internal
|
||||
*/
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||
QSequentialIterable::QSequentialIterable(QtMetaTypePrivate::QSequentialIterableImpl impl)
|
||||
#else
|
||||
QSequentialIterable::QSequentialIterable(const QtMetaTypePrivate::QSequentialIterableImpl &impl)
|
||||
#endif
|
||||
: m_impl(impl)
|
||||
{
|
||||
}
|
||||
@ -4624,11 +4612,7 @@ QSequentialIterable::const_iterator QSequentialIterable::const_iterator::operato
|
||||
/*!
|
||||
\internal
|
||||
*/
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||
QAssociativeIterable::QAssociativeIterable(QtMetaTypePrivate::QAssociativeIterableImpl impl)
|
||||
#else
|
||||
QAssociativeIterable::QAssociativeIterable(const QtMetaTypePrivate::QAssociativeIterableImpl &impl)
|
||||
#endif
|
||||
: m_impl(impl)
|
||||
{
|
||||
}
|
||||
|
@ -224,7 +224,9 @@ class Q_CORE_EXPORT QVariant
|
||||
QVariant(double d);
|
||||
QVariant(float f);
|
||||
#ifndef QT_NO_CAST_FROM_ASCII
|
||||
QT_ASCII_CAST_WARN QVariant(const char *str);
|
||||
QT_ASCII_CAST_WARN QVariant(const char *str)
|
||||
: QVariant(QString::fromUtf8(str))
|
||||
{}
|
||||
#endif
|
||||
|
||||
QVariant(const QByteArray &bytearray);
|
||||
@ -512,22 +514,6 @@ public:
|
||||
inline const DataPtr &data_ptr() const { return d; }
|
||||
};
|
||||
|
||||
#if QT_DEPRECATED_SINCE(5, 14)
|
||||
template <typename T>
|
||||
QT_DEPRECATED_X("Use QVariant::fromValue() instead.")
|
||||
inline QVariant qVariantFromValue(const T &t)
|
||||
{
|
||||
return QVariant::fromValue(t);
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
QT_DEPRECATED_X("Use QVariant::setValue() instead.")
|
||||
inline void qVariantSetValue(QVariant &v, const T &t)
|
||||
{
|
||||
v.setValue(t);
|
||||
}
|
||||
#endif
|
||||
|
||||
template<>
|
||||
inline QVariant QVariant::fromValue(const QVariant &value)
|
||||
{
|
||||
@ -645,11 +631,7 @@ public:
|
||||
|
||||
friend struct const_iterator;
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||
explicit QSequentialIterable(QtMetaTypePrivate::QSequentialIterableImpl impl);
|
||||
#else
|
||||
explicit QSequentialIterable(const QtMetaTypePrivate::QSequentialIterableImpl &impl);
|
||||
#endif
|
||||
|
||||
const_iterator begin() const;
|
||||
const_iterator end() const;
|
||||
@ -703,11 +685,7 @@ public:
|
||||
|
||||
friend struct const_iterator;
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||
explicit QAssociativeIterable(QtMetaTypePrivate::QAssociativeIterableImpl impl);
|
||||
#else
|
||||
explicit QAssociativeIterable(const QtMetaTypePrivate::QAssociativeIterableImpl &impl);
|
||||
#endif
|
||||
|
||||
const_iterator begin() const;
|
||||
const_iterator end() const;
|
||||
@ -872,16 +850,6 @@ template<> inline QVariant qvariant_cast<QVariant>(const QVariant &v)
|
||||
return v;
|
||||
}
|
||||
|
||||
#if QT_DEPRECATED_SINCE(5, 0)
|
||||
template<typename T>
|
||||
inline QT_DEPRECATED T qVariantValue(const QVariant &variant)
|
||||
{ return qvariant_cast<T>(variant); }
|
||||
|
||||
template<typename T>
|
||||
inline QT_DEPRECATED bool qVariantCanConvert(const QVariant &variant)
|
||||
{ return variant.template canConvert<T>(); }
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DEBUG_STREAM
|
||||
|
Loading…
Reference in New Issue
Block a user