std::chrono...e_zone_link)(3)
π NAME π
Okay so this page is the std::chrono...e_zone_link)(3) one, from the C++ Standard Libary manual β yes bestie, that's the exact spelling from the header π«Ά.
std::chrono::operator==,(std::chrono::time_zone_link)βstd::chrono::operator==,(std::chrono::time_zone_link)
That comma situation in the name? It's literally just vibing there. Not me questioning the naming choices π.
β¨ Synopsis β¨
Both overloads live in the header <chrono>, and both are (since C++20) β iconic C++20 behavior only π:
Defined in header <chrono>
bool operator==( const std::chrono::time_zone_link& x,
(1) (since C++20)
const std::chrono::time_zone_link& y ) noexcept;
std::strong_ordering operator<=>( const
std::chrono::time_zone_link& x,
(2) (since C++20)
const
std::chrono::time_zone_link& y ) noexcept;
So what's the tea? It compares the two time_zone_link values x and y by name β that's the whole comparison vibe, no cap π.
The <, <=, >, >=, and != operators are synthesized from operator<=> and operator== respectively. The spaceship operator is carrying the whole friend group, honestly π.
Both signatures are marked noexcept in the synopsis. Keep that detail, bestie β it's right there in the code π«Ά.
π Return value π
x.name() == y.name()x.name() <=> y.name()
Like, that's it. Name-based equality for number 1, name-based spaceship comparison for number 2. Clean, simple, C++20-coded β¨.
That's the whole page, bestie π β source: http://cppreference.com, version/date: 2024.06.10 πΈπ¦
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms