Use steady_clock in the timer

This commit is contained in:
Martin Hořeňovský 2024-09-13 11:15:54 +02:00
parent 02d3304782
commit 7a89b75737
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A

View File

@ -13,7 +13,7 @@ namespace Catch {
namespace {
static auto getCurrentNanosecondsSinceEpoch() -> uint64_t {
return std::chrono::duration_cast<std::chrono::nanoseconds>(std::chrono::high_resolution_clock::now().time_since_epoch()).count();
return std::chrono::duration_cast<std::chrono::nanoseconds>(std::chrono::steady_clock::now().time_since_epoch()).count();
}
} // end unnamed namespace