7 Practical std::chrono Calendar Examples (C++20)
5 points by raymii
5 points by raymii
ymd.year() / January / 1
This is horribile
Heh, I came here to post that I like this syntax. It’s compact, readable and intuitive. I still don’t understand the beef some people have about operator overloading…
Yeah. Feels unnecessary use of operator overloading. I'd much prefer to just use the constructor std::chrono::year_month_day(ymd.year(), January, 1d)
Reminds me:
Within C++, there is a much smaller and cleaner language struggling to get out. (c) Bjarne Stroustrup