QVariant: use QMETATYPE_CONVERTER_ASSIGN_DOUBLE to convert from QCborValue

No-op change. All this does is explicitly wrap the right side of the
expression in a double() function-style cast.

Pick-to: 6.8
Change-Id: I84bc14bf75b4d0a046dcfffd19f318eaf7fe0e9f
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit ab45c44fb5471cef907334a1f6d7dbad279dd707)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Thiago Macieira 2025-03-19 11:07:33 -07:00 committed by Qt Cherry-pick Bot
parent d0665d2628
commit f754cd0ce9

View File

@ -1391,8 +1391,8 @@ static constexpr struct : QMetaTypeModuleHelper
QMETATYPE_CONVERTER_ASSIGN(QCborValue, Char); QMETATYPE_CONVERTER_ASSIGN(QCborValue, Char);
QMETATYPE_CONVERTER_ASSIGN(QCborValue, SChar); QMETATYPE_CONVERTER_ASSIGN(QCborValue, SChar);
QMETATYPE_CONVERTER_ASSIGN(QCborValue, Short); QMETATYPE_CONVERTER_ASSIGN(QCborValue, Short);
QMETATYPE_CONVERTER_ASSIGN(QCborValue, Double); QMETATYPE_CONVERTER_ASSIGN_DOUBLE(QCborValue, Double);
QMETATYPE_CONVERTER_ASSIGN(QCborValue, Float); QMETATYPE_CONVERTER_ASSIGN_DOUBLE(QCborValue, Float);
QMETATYPE_CONVERTER(QCborValue, QStringList, QMETATYPE_CONVERTER(QCborValue, QStringList,
result = QCborArray::fromStringList(source); result = QCborArray::fromStringList(source);
return true; return true;