[libcxx-commits] [libcxx] [libc++] Reduce the dependency of the locale base API on the base system from the headers (PR #117764)

Nico Weber via libcxx-commits libcxx-commits at lists.llvm.org
Wed Nov 27 07:18:58 PST 2024


nico wrote:

As I said on the issue, it looks pretty common: [https://grep.app/search?q=_XOPEN_SOURCE%20500&filter[lang][0]=C%2B%2B](https://grep.app/search?q=_XOPEN_SOURCE%20500&filter%5Blang%5D%5B0%5D=C%2B%2B)

I don't think calling the value "legacy" is terribly useful. People set it to some value because they want to use a function that was added at that value. I'm guessing they probably set it to either the value that is highest when they set it, or to the lowest value needed for whatever function they want – it's more a "set it to this value at least please". OTOH, it's probably also possible that some folks out there want to set it as a "set it to this at most please" if they want to deploy to older systems, I don't know.

The thing we hit in practice is that `<chrono>` used to work, and now it doesn't. If it's easy to fix that, might as well?

Since it was easy to work around in Chromium, I don't have a super strong opinion on this particular issue.

(I _do_ have the opinion that libc++ generally tends to be not very friendly to update. We're currently 3 weeks behind again, _just_ down from 5 weeks, due to at least 4 things that need some kind of tweak landing in fast succession. And this year, our libc++ autoroller needed significantly more handholding than last year. This isn't really the forum for that, though :) If there's interest, I can do an experience report writeup for this year – but I'm guessing this is all working as intended.)

https://github.com/llvm/llvm-project/pull/117764


More information about the libcxx-commits mailing list