This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] [test] Fix locale.time.get.byname get_date and get_date_wide on Windows
ClosedPublic

Authored by mstorsjo on Feb 14 2022, 3:41 PM.

Details

Summary

Also apply the same fix on glibc. This takes the test one step closer
to passing on glibc, but it still fails on the zh_CN test (which
requires a more involved fix in libc++ itself).

Diff Detail

Event Timeline

mstorsjo requested review of this revision.Feb 14 2022, 3:41 PM
mstorsjo created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 14 2022, 3:41 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
mstorsjo updated this revision to Diff 408751.Feb 15 2022, 1:08 AM

Rerun CI on a non-broken base revision.

Mordante accepted this revision as: Mordante.Feb 15 2022, 9:08 AM

LGTM, the CI issue seems unrelated.

ldionne added inline comments.
libcxx/test/std/localization/locale.categories/category.time/locale.time.get.byname/get_date.pass.cpp
66

Why didn't the test fail on Glibc previously?

mstorsjo added inline comments.Feb 16 2022, 1:22 PM
libcxx/test/std/localization/locale.categories/category.time/locale.time.get.byname/get_date.pass.cpp
66

It previously failed on Glibc, but it still does - see the edited comment further up in the file. Previously it said:

// GLIBC Expects "10/06/2009" for fr_FR as opposed to "10.06.2009"
// GLIBC also fails on the zh_CN test.
// XFAIL: linux

Now I've edited it to say

// GLIBC fails on the zh_CN test.
// XFAIL: linux

(Fixing the zh_CN testcase on Glibc is a bigger issue, which requires fixes to the libc++ library implementation itself - I have a PoC of such a fix that I can send later.)

ldionne accepted this revision.Feb 16 2022, 2:03 PM

Thanks for the explanation, LGTM.

This revision is now accepted and ready to land.Feb 16 2022, 2:03 PM
This revision was landed with ongoing or failed builds.Feb 17 2022, 12:55 AM
This revision was automatically updated to reflect the committed changes.