On Sep 20, 2021, at 7:23 PM, Watson Ladd <watson@cloudflare.com> wrote:
On Mon, Sep 20, 2021 at 9:51 AM Howard Hinnant via tz <tz@iana.org> wrote:
The C++20 standard has adopted the IANA timezone database (not the code) as the basis for a major part of its API: http://eel.is/c++draft/time.zone#general-1
I plea for stability. That doesn’t mean no changes. But it does mean no drastic changes.
Unfortunately you are held hostage to the wishes of British Canadian chicken farmers, Indiana counties, etc, etc. in determining what the zones will be.
Adding new zones is not problematic. Removing or changing the names of existing ones is.
The set of zones may increase due to post-1970 changes in ways that we cannot predict. And the C++20 standard thankfully does not include the list of zones in the API.
A C++20 programmer can easily obtain the list of time zone names and link names from the already standardized API: #include <chrono> #include <iostream> int main() { for (auto& tz : std::chrono::get_tzdb().zones) std::cout << tz.name() << '\n'; for (auto& link : std::chrono::get_tzdb().links) std::cout << link.name() << '\n'; } Current output: Africa/Abidjan Africa/Accra Africa/Algiers Africa/Bissau ... Howard