Skip to content
Tcl Source Code View Ticket
Login

View Ticket

invalid use of %g %G in tests

Closed / Fixed961714ffffffffffffffffffffffffffffffffffCreated 23 years agoUpdated 23 years ago
Descriptionplain2004-05-27 17:32:29
The clock tests use %g and %G - these are not valid
sequences.  Please use the already documented and
correct %y and %Y instead.  These changes need to go
into 8.4 and 8.5-head.
kennykbplain2004-05-28 01:32:57
Logged In: YES 
user_id=99768

%g/%G are NOT synonymous with %y/%Y. 

%y/%Y are the year of the Gregorian calendar.

%g/%G are the year of the ISO8601 week-based calendar,
which may differ from the Gregorian year in the first or
last week of the year.  The next time at which they differ
is 2004-12-27, which is 2005-W01-1.

It's actually (IMO) a bug in strftime on HP and AIX that
they don't support %G, since %V makes no sense without it.

The fix changes the 50-odd test failures to one, by testing
that %G works at all before trying to run the tests that
check that it actually gives correct answers.
Log in (anonymous is fine) to add a comment.