This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [v4] Fix strptime era handling, add more era tests [BZ #24394]


Hello DJ Delorie-san,

Thank you for creating this test case.

From: DJ Delorie <dj@redhat.com>
Subject: [v4] Fix strptime era handling, add more era tests [BZ #24394]
Date: Thu, 28 Mar 2019 23:35:31 -0400

> diff --git a/ChangeLog b/ChangeLog
> index bd76c1e28d..db33d8a6a3 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,3 +1,10 @@
> +2019-03-28  DJ Delorie  <dj@redhat.com>
> +
> +	[BZ #24394]
> +	* time/strptime_l.c (%Ey): Fix fencepost error.
> +	* time/tst-strftime3.c: New.
> +	* time/Makefile (tests): Add tst-strftime3.

This test case is intended to check whether strptime can correctly
parse %EY, so it would be nice to rename it to tst-strptime4.c.

The test case to check whether strftime can correctly format %EY
already exists as tst-strftime2.c.  This covers ja_JP, lo_LA, th_TH,
zh_TW, cmn_TW, hak_TW, nan_TW, and lzh_TW.  Regarding *_TW, Rafal-san
is preparing a patch.

In addition to ja_JP locale, I think it is necessary to check the
locale of other countries, in particular *_TW locale.

What about the consideration of %EY, %_EY, and %-EY?

How does it behave if specifying a non-existent date, such as:

Heisei gan nen 01 gatsu 07 nichi
Showa   64 nen 01 gatsu 08 nichi

I think that these tests are also necessary.

Regards,
TAMUKI Shoichi


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]