operator==,!=,<,<=,>,>=,<=>(std::chrono::time_point)
<chrono>
bool operator==( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator==( const std::chrono::time_point <Clock,Dur1>& lhs,
bool operator!=( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator!=( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++20)
bool operator<( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator<( const std::chrono::time_point <Clock,Dur1>& lhs,
bool operator<=( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator<=( const std::chrono::time_point <Clock,Dur1>& lhs,
bool operator>( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator>( const std::chrono::time_point <Clock,Dur1>& lhs,
bool operator>=( const std::chrono::time_point <Clock,Dur1>& lhs,
(until C++14)
constexpr bool operator>=( const std::chrono::time_point <Clock,Dur1>& lhs,
constexpr auto operator<=>( const std::chrono::time_point <Clock,Dur1>& lhs,
Compares two time points. The comparison is done by comparing the results time_since_epoch() for the time points.
Dur1
and Dur2
.The !=
operator is synthesized from operator==
.
Contents
[edit] Parameters
[edit] Return value
[edit] Exceptions
May throw implementation-defined exceptions.
[edit] Notes
Two-way comparison operators of time_point
were not constexpr in C++11, this was corrected in C++14.