summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel/qelapsedtimer.h
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2023-02-22 18:59:50 -0800
committerThiago Macieira <thiago.macieira@intel.com>2023-02-25 18:14:11 -0800
commit81783d02e89ee5ad49559bd9f0d7119180e86188 (patch)
treed319853208f1acde1b9a7eff8196ab281d1daf3a /src/corelib/kernel/qelapsedtimer.h
parentcf059ac9ece88a70eb4f582f3f9cf80186cc69a1 (diff)
QElapsedTimer & QDeadlineTimer: use NSDMI for their two fields
Pick-to: 6.5 Change-Id: Ieec322d73c1e40ad95c8fffd174654d643c05097 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'src/corelib/kernel/qelapsedtimer.h')
-rw-r--r--src/corelib/kernel/qelapsedtimer.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/corelib/kernel/qelapsedtimer.h b/src/corelib/kernel/qelapsedtimer.h
index a4db43304a..ab32265cba 100644
--- a/src/corelib/kernel/qelapsedtimer.h
+++ b/src/corelib/kernel/qelapsedtimer.h
@@ -21,11 +21,7 @@ public:
PerformanceCounter
};
- constexpr QElapsedTimer()
- : t1(Q_INT64_C(0x8000000000000000)),
- t2(Q_INT64_C(0x8000000000000000))
- {
- }
+ constexpr QElapsedTimer() = default;
static ClockType clockType() noexcept;
static bool isMonotonic() noexcept;
@@ -51,8 +47,8 @@ public:
friend bool Q_CORE_EXPORT operator<(const QElapsedTimer &lhs, const QElapsedTimer &rhs) noexcept;
private:
- qint64 t1;
- qint64 t2;
+ qint64 t1 = Q_INT64_C(0x8000000000000000);
+ qint64 t2 = Q_INT64_C(0x8000000000000000);
};
QT_END_NAMESPACE