From 8c086ce832d22c82bf812dc542714bf1d78aae3c Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Mon, 5 May 2025 16:42:03 +0200 Subject: [PATCH] Correct value of Avogadro's constant used in a test It doesn't matter at all, but it's now got a defined value, so use it. Change-Id: Id8e734cd81624a3d4c139b2639381e3f0b162db4 Reviewed-by: Matthias Rauter --- tests/benchmarks/testlib/tostring/tst_tostring.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/benchmarks/testlib/tostring/tst_tostring.cpp b/tests/benchmarks/testlib/tostring/tst_tostring.cpp index e00b12ef53a..dd2a6651530 100644 --- a/tests/benchmarks/testlib/tostring/tst_tostring.cpp +++ b/tests/benchmarks/testlib/tostring/tst_tostring.cpp @@ -77,7 +77,7 @@ void tst_toString::numeric_data() } QTest::newRow("2e9") << T(2000000000); QTest::newRow("c.s/m") << T(299792458); - QTest::newRow("Avogadro") << T(6.022045e+23); // things/mol (.996 << 79, so ints overflow to max) + QTest::newRow("Avogadro") << T(6.02214076e+23); // things/mol (c. 2^{79}, so ints overflow) QTest::newRow("lowest") << std::numeric_limits::lowest(); QTest::newRow("max") << std::numeric_limits::max();