Silence warnings from unused variables
Use them, or replace them with existing constants. Pick-to: 6.5 Change-Id: I808028296305e15b68aecb1f961ba6a85b8e9cc7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Øystein Heskestad <oystein.heskestad@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
parent
617165af6b
commit
643b6e5b29
@ -88,6 +88,7 @@ void EventsBench::noEvent()
|
|||||||
QBENCHMARK {
|
QBENCHMARK {
|
||||||
val += tst.foo(1);
|
val += tst.foo(1);
|
||||||
}
|
}
|
||||||
|
QVERIFY(val > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void EventsBench::sendEvent_data()
|
void EventsBench::sendEvent_data()
|
||||||
|
@ -64,6 +64,7 @@ void tst_QThreadStorage::get()
|
|||||||
int *i = ts.localData();
|
int *i = ts.localData();
|
||||||
count += *i;
|
count += *i;
|
||||||
}
|
}
|
||||||
|
QVERIFY(count > 0);
|
||||||
ts.setLocalData(0);
|
ts.setLocalData(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10,4 +10,5 @@ qt_internal_add_benchmark(tst_bench_qdatetime
|
|||||||
tst_bench_qdatetime.cpp
|
tst_bench_qdatetime.cpp
|
||||||
LIBRARIES
|
LIBRARIES
|
||||||
Qt::Test
|
Qt::Test
|
||||||
|
Qt::CorePrivate
|
||||||
)
|
)
|
||||||
|
@ -6,6 +6,7 @@
|
|||||||
#include <QTest>
|
#include <QTest>
|
||||||
#include <QList>
|
#include <QList>
|
||||||
#include <qdebug.h>
|
#include <qdebug.h>
|
||||||
|
#include <QtCore/private/qdatetime_p.h>
|
||||||
|
|
||||||
class tst_QDateTime : public QObject
|
class tst_QDateTime : public QObject
|
||||||
{
|
{
|
||||||
@ -67,8 +68,7 @@ private Q_SLOTS:
|
|||||||
void fromMSecsSinceEpochTz();
|
void fromMSecsSinceEpochTz();
|
||||||
};
|
};
|
||||||
|
|
||||||
constexpr qint64 SECS_PER_DAY = 86400;
|
using namespace QtPrivate::DateTimeConstants;
|
||||||
constexpr qint64 MSECS_PER_DAY = 86400000;
|
|
||||||
constexpr qint64 JULIAN_DAY_1 = 1721426;
|
constexpr qint64 JULIAN_DAY_1 = 1721426;
|
||||||
constexpr qint64 JULIAN_DAY_11 = 1725078;
|
constexpr qint64 JULIAN_DAY_11 = 1725078;
|
||||||
constexpr qint64 JULIAN_DAY_1890 = 2411369;
|
constexpr qint64 JULIAN_DAY_1890 = 2411369;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user