Fix warning when printing of qsizetype
warning: format specifies type 'int' but the argument has type 'qsizetype' (aka 'long long') Change-Id: I6099b53efecea46d191d5dc019c986f99e49c1f1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
99ebbaead7
commit
d96193b0ec
@ -605,8 +605,8 @@ static bool compareStates(const QSignalSpy& spy, const StateList &expectedStates
|
|||||||
|
|
||||||
}
|
}
|
||||||
qDebug("\n"
|
qDebug("\n"
|
||||||
"expected (count == %d): %s\n"
|
"expected (count == %zd): %s\n"
|
||||||
"actual (count == %d): %s\n", expectedStates.count(), qPrintable(e), spy.count(), qPrintable(a));
|
"actual (count == %zd): %s\n", size_t(expectedStates.count()), qPrintable(e), size_t(spy.count()), qPrintable(a));
|
||||||
}
|
}
|
||||||
return equals;
|
return equals;
|
||||||
}
|
}
|
||||||
|
@ -229,7 +229,7 @@ void tst_QCborValue::basics_data()
|
|||||||
if (t == QCborValue::Double)
|
if (t == QCborValue::Double)
|
||||||
return QTest::addRow("Double:%g", exp.toDouble());
|
return QTest::addRow("Double:%g", exp.toDouble());
|
||||||
if (t == QCborValue::ByteArray || t == QCborValue::String)
|
if (t == QCborValue::ByteArray || t == QCborValue::String)
|
||||||
return QTest::addRow("%s:%d", typeString, exp.toString().size());
|
return QTest::addRow("%s:%zd", typeString, size_t(exp.toString().size()));
|
||||||
return QTest::newRow(typeString);
|
return QTest::newRow(typeString);
|
||||||
};
|
};
|
||||||
addRow() << t << v << exp;
|
addRow() << t << v << exp;
|
||||||
|
@ -80,7 +80,7 @@ void tst_QCborValue_Json::toVariant_data()
|
|||||||
if (v.type() == QCborValue::Double)
|
if (v.type() == QCborValue::Double)
|
||||||
return QTest::addRow("Double:%g", exp.toDouble());
|
return QTest::addRow("Double:%g", exp.toDouble());
|
||||||
if (v.type() == QCborValue::ByteArray || v.type() == QCborValue::String)
|
if (v.type() == QCborValue::ByteArray || v.type() == QCborValue::String)
|
||||||
return QTest::addRow("%s:%d", typeString, exp.toString().size());
|
return QTest::addRow("%s:%zd", typeString, size_t(exp.toString().size()));
|
||||||
if (v.type() >= 0x10000)
|
if (v.type() >= 0x10000)
|
||||||
return QTest::newRow(exp.typeName());
|
return QTest::newRow(exp.typeName());
|
||||||
return QTest::newRow(typeString);
|
return QTest::newRow(typeString);
|
||||||
|
@ -1158,7 +1158,7 @@ void PaintCommands::command_drawPolygon(QRegularExpressionMatch re)
|
|||||||
array.append(QPointF(convertToDouble(numbers.at(i)), convertToDouble(numbers.at(i+1))));
|
array.append(QPointF(convertToDouble(numbers.at(i)), convertToDouble(numbers.at(i+1))));
|
||||||
|
|
||||||
if (m_verboseMode)
|
if (m_verboseMode)
|
||||||
printf(" -(lance) drawPolygon(size=%d)\n", array.size());
|
printf(" -(lance) drawPolygon(size=%zd)\n", size_t(array.size()));
|
||||||
|
|
||||||
m_painter->drawPolygon(array, caps.at(2).toLower() == "winding" ? Qt::WindingFill : Qt::OddEvenFill);
|
m_painter->drawPolygon(array, caps.at(2).toLower() == "winding" ? Qt::WindingFill : Qt::OddEvenFill);
|
||||||
}
|
}
|
||||||
@ -1174,7 +1174,7 @@ void PaintCommands::command_drawPolyline(QRegularExpressionMatch re)
|
|||||||
array.append(QPointF(numbers.at(i).toFloat(),numbers.at(i+1).toFloat()));
|
array.append(QPointF(numbers.at(i).toFloat(),numbers.at(i+1).toFloat()));
|
||||||
|
|
||||||
if (m_verboseMode)
|
if (m_verboseMode)
|
||||||
printf(" -(lance) drawPolyline(size=%d)\n", array.size());
|
printf(" -(lance) drawPolyline(size=%zd)\n", size_t(array.size()));
|
||||||
|
|
||||||
m_painter->drawPolyline(array.toPolygon());
|
m_painter->drawPolyline(array.toPolygon());
|
||||||
}
|
}
|
||||||
@ -1499,7 +1499,7 @@ void PaintCommands::command_path_addPolygon(QRegularExpressionMatch re)
|
|||||||
array.append(QPointF(numbers.at(i).toFloat(),numbers.at(i+1).toFloat()));
|
array.append(QPointF(numbers.at(i).toFloat(),numbers.at(i+1).toFloat()));
|
||||||
|
|
||||||
if (m_verboseMode)
|
if (m_verboseMode)
|
||||||
printf(" -(lance) path_addPolygon(name=%s, size=%d)\n", qPrintable(name), array.size());
|
printf(" -(lance) path_addPolygon(name=%s, size=%zd)\n", qPrintable(name), size_t(array.size()));
|
||||||
|
|
||||||
m_pathMap[name].addPolygon(array);
|
m_pathMap[name].addPolygon(array);
|
||||||
}
|
}
|
||||||
@ -2738,7 +2738,7 @@ void PaintCommands::command_pen_setDashPattern(QRegularExpressionMatch re)
|
|||||||
pattern.append(convertToDouble(numbers.at(i)));
|
pattern.append(convertToDouble(numbers.at(i)));
|
||||||
|
|
||||||
if (m_verboseMode)
|
if (m_verboseMode)
|
||||||
printf(" -(lance) pen_setDashPattern(size=%d)\n", pattern.size());
|
printf(" -(lance) pen_setDashPattern(size=%zd)\n", size_t(pattern.size()));
|
||||||
|
|
||||||
QPen p = m_painter->pen();
|
QPen p = m_painter->pen();
|
||||||
p.setDashPattern(pattern);
|
p.setDashPattern(pattern);
|
||||||
@ -2774,7 +2774,7 @@ void PaintCommands::command_drawConvexPolygon(QRegularExpressionMatch re)
|
|||||||
array.append(QPointF(convertToDouble(numbers.at(i)), convertToDouble(numbers.at(i+1))));
|
array.append(QPointF(convertToDouble(numbers.at(i)), convertToDouble(numbers.at(i+1))));
|
||||||
|
|
||||||
if (m_verboseMode)
|
if (m_verboseMode)
|
||||||
printf(" -(lance) drawConvexPolygon(size=%d)\n", array.size());
|
printf(" -(lance) drawConvexPolygon(size=%zd)\n", size_t(array.size()));
|
||||||
|
|
||||||
|
|
||||||
m_painter->drawConvexPolygon(array);
|
m_painter->drawConvexPolygon(array);
|
||||||
|
@ -292,7 +292,7 @@ void tst_QAccessibility::cleanup()
|
|||||||
{
|
{
|
||||||
const EventList list = QTestAccessibility::events();
|
const EventList list = QTestAccessibility::events();
|
||||||
if (!list.isEmpty()) {
|
if (!list.isEmpty()) {
|
||||||
qWarning("%d accessibility event(s) were not handled in testfunction '%s':", list.count(),
|
qWarning("%zd accessibility event(s) were not handled in testfunction '%s':", size_t(list.count()),
|
||||||
QString(QTest::currentTestFunction()).toLatin1().constData());
|
QString(QTest::currentTestFunction()).toLatin1().constData());
|
||||||
for (int i = 0; i < list.count(); ++i)
|
for (int i = 0; i < list.count(); ++i)
|
||||||
qWarning(" %d: Object: %p Event: '%s' Child: %d", i + 1, list.at(i)->object(),
|
qWarning(" %d: Object: %p Event: '%s' Child: %d", i + 1, list.at(i)->object(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user