Re: parse_datetime() and RFC 9557 suffixes

2024-08-01 Thread Alejandro Colomar
Hi Paul, Bruno, On Thu, Aug 01, 2024 at 03:10:29PM GMT, Paul Eggert wrote: > The whole business of time zone offsets is a mess. :) > Third, RFC 9557 does not allow either "2023-09-20[+02:00]" or > "2023-09-20[+0200]". It requires a time before the timezone. (This issue is > minor; I've already m

Re: parse_datetime() and RFC 9557 suffixes

2024-08-01 Thread Paul Eggert
The whole business of time zone offsets is a mess. First, it's not clear whether ISO 8601 requires ":" in numeric time zone offsets. RFC 3339 Appendix A suggests it's not. Second, in practice the colon often is omitted; it's certainly omitted by POSIX and ISO C strftime %z, by the Time Zone D

Re: parse_datetime() and RFC 9557 suffixes

2024-08-01 Thread Bruno Haible
Hi Alejandro, > $ date --date='2023-09-20[+0200]' > date: invalid date ‘2023-09-20[+0200]’ Are you sure this is valid? In RFC 9557 [1] we have the ABNF rules time-zone = "[" critical-flag time-zone-name / time-numoffset "]" time-zone-name= time-zone-part *("/" time-z