Category "chrono"

Using operator ""s for std::chrono with gcc

I want to use the std::chrono::duration literals, such as 10s to mean "10 seconds", like this: std::chrono::duration<uint64_t, std::milli> millisecs = 10s

How to check for overflow in duration_cast

I need to convert one kind of std::chrono::duration to another kind but I need to know when such a conversion is not possible because the value would not be rep

How to create a time point from milliseconds since Unix epoch?

To create a time point for the current time, you can use: std::chrono::system_clock::now(). I cannot figure out, however, how to create a time point given milli

Outputting Date and Time in C++ using std::chrono

I have been upgrading some old code and have been trying to update to c++11 where possible. The following code is how I used to display the time and date in my