Namespaces
Variants
Views
Actions

Talk:cpp/chrono/system clock

From cppreference.com

How long will be std::chrono::system_clock usable? Will it be usable, for example, in year 33000? What is its designed (theoretical) lifetime?

As time elapses, 2100, 2200, grows the distance between current time and the epoch.

As there will be always only one epoch, and on the other hand, system_clock represents the duration on a fix (finite) width data (8 bytes?), something have to be changing.. What exactly will be changing? The accuracy (resolution)? How will (approximately) degrade the the resolution?

62.201.102.190 10:00, 31 January 2020 (PST)

A 64-bit nanosecond resolution timestamp can represent ~ +/-292 years. If humanity still exists in 2262 and C++ is still in use, I'm sure they can figure something out. T. Canens (talk) 16:18, 31 January 2020 (PST)

[edit] std::chrono::system_clock::duration::period is std::nano

This page has a mistake about std::chrono::system_clock::duration::period, actually it is std::nano,not in std::ratio<1>

The page doesn't claim that period is std::ratio<1>, and it's not required to be std::nano --Ybab321 (talk) 04:51, 7 August 2022 (PDT)