[libcxx-commits] [libcxx] [libcxx] Handle changing of fr_FR locale thousand sep in Windows libcxx tests (PR #83967)
Martin Storsjö via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Mar 11 04:40:11 PDT 2024
mstorsjo wrote:
Thanks for looking into this! I've also run into this, and have a halfbaked incomplete fix that I've used locally - see https://github.com/mstorsjo/llvm-project/commit/libcxx-test-win-locale-fr.
This uses `std::moneypunct_byname` for getting the current thousands separator, which is pretty short and concise. But I guess this somewhat weakens some of the tests, as some tests essentially just end up asserting that `f.thousands_sep() == f.thousands_sep()` - while your solution to use an independent codepath to fetch the current separator probably retains more test quality.
The idea of checking that the separator is either of the known ones probably would be nice - that possibly helps for some of the tests, but probably not for all of them.
https://github.com/llvm/llvm-project/pull/83967
More information about the libcxx-commits
mailing list