Merge integration refs/builds/qtci/dev/1673982362
This commit is contained in:
commit
2e8b75477f
@ -889,7 +889,7 @@ static void writeDoubleToCbor(QCborStreamWriter &writer, double d, QCborValue::E
|
|||||||
// no data loss, we could use float
|
// no data loss, we could use float
|
||||||
#ifndef QT_BOOTSTRAPPED
|
#ifndef QT_BOOTSTRAPPED
|
||||||
if ((opt & QCborValue::UseFloat16) == QCborValue::UseFloat16) {
|
if ((opt & QCborValue::UseFloat16) == QCborValue::UseFloat16) {
|
||||||
qfloat16 f16 = f;
|
qfloat16 f16 = qfloat16(f);
|
||||||
if (f16 == f)
|
if (f16 == f)
|
||||||
return writer.append(f16);
|
return writer.append(f16);
|
||||||
}
|
}
|
||||||
|
@ -552,7 +552,9 @@ QString qulltoa(qulonglong number, int base, const QStringView zero)
|
|||||||
/*!
|
/*!
|
||||||
\internal
|
\internal
|
||||||
|
|
||||||
Converts the initial portion of the string pointed to by \a s00 to a double, using the 'C' locale.
|
Converts the initial portion of the string pointed to by \a s00 to a double,
|
||||||
|
using the 'C' locale. The function sets the pointer pointed to by \a se to
|
||||||
|
point to the character past the last character converted.
|
||||||
*/
|
*/
|
||||||
double qstrntod(const char *s00, qsizetype len, const char **se, bool *ok)
|
double qstrntod(const char *s00, qsizetype len, const char **se, bool *ok)
|
||||||
{
|
{
|
||||||
|
@ -1322,6 +1322,10 @@ void tst_QLocale::strtod_data()
|
|||||||
QTest::newRow("1e2000 cruft") << QString("1e2000 cruft") << qInf() << 6 << false;
|
QTest::newRow("1e2000 cruft") << QString("1e2000 cruft") << qInf() << 6 << false;
|
||||||
QTest::newRow("-1e2000 cruft") << QString("-1e2000 cruft") << -qInf() << 7 << false;
|
QTest::newRow("-1e2000 cruft") << QString("-1e2000 cruft") << -qInf() << 7 << false;
|
||||||
|
|
||||||
|
// NaN and nan
|
||||||
|
QTest::newRow("NaN") << QString("NaN") << qQNaN() << 3 << true;
|
||||||
|
QTest::newRow("nan") << QString("nan") << qQNaN() << 3 << true;
|
||||||
|
|
||||||
// Underflow, ends with cruft - fails but reports right length:
|
// Underflow, ends with cruft - fails but reports right length:
|
||||||
QTest::newRow("1e-2000 cruft") << QString("1e-2000 cruft") << 0.0 << 7 << false;
|
QTest::newRow("1e-2000 cruft") << QString("1e-2000 cruft") << 0.0 << 7 << false;
|
||||||
QTest::newRow("-1e-2000 cruft") << QString("-1e-2000 cruft") << 0.0 << 8 << false;
|
QTest::newRow("-1e-2000 cruft") << QString("-1e-2000 cruft") << 0.0 << 8 << false;
|
||||||
|
@ -373,7 +373,7 @@ static QStringList reverseLookupHelper(const QString &ip)
|
|||||||
QList<QByteArray> lines;
|
QList<QByteArray> lines;
|
||||||
QProcess python;
|
QProcess python;
|
||||||
python.setProcessChannelMode(QProcess::ForwardedErrorChannel);
|
python.setProcessChannelMode(QProcess::ForwardedErrorChannel);
|
||||||
python.start("python", QStringList() << QString("-c") << pythonCode << ip);
|
python.start("python3", QStringList() << QString("-c") << pythonCode << ip);
|
||||||
if (python.waitForFinished()) {
|
if (python.waitForFinished()) {
|
||||||
if (python.exitStatus() == QProcess::NormalExit && python.exitCode() == 0)
|
if (python.exitStatus() == QProcess::NormalExit && python.exitCode() == 0)
|
||||||
lines = python.readAllStandardOutput().split('\n');
|
lines = python.readAllStandardOutput().split('\n');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user